utils: codegen: controls.py: Parse direction information
In preparation for adding support for querying direction information from controls, parse the direction information from control ID definitions. This can later be plugged in directly to the IPA code generators simply by using ctrl.direction. Signed-off-by: Paul Elder <paul.elder@ideasonboard.com> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com> Reviewed-by: Stefan Klug <stefan.klug@ideasonboard.com>
This commit is contained in:
parent
9bd9d25a82
commit
39fe4ad968
4 changed files with 26 additions and 4 deletions
|
@ -71,7 +71,7 @@ def main(argv):
|
|||
ctrls = controls.setdefault(vendor, [])
|
||||
|
||||
for i, ctrl in enumerate(data['controls']):
|
||||
ctrl = Control(*ctrl.popitem(), vendor)
|
||||
ctrl = Control(*ctrl.popitem(), vendor, args.mode)
|
||||
ctrls.append(extend_control(ctrl, i, ranges))
|
||||
|
||||
# Sort the vendors by range numerical value
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue