Add support in VHAL tool for generating property area IDs. - #555
Add support in VHAL tool for generating property area IDs.#555jankubovy wants to merge 2 commits into
Conversation
Signed-off-by: Jan Kubovy <jan.kubovy@bmw.de>
d84e360 to
78c8516
Compare
| VhalAreaType, | ||
| ) | ||
|
|
||
| # All possible VSS positional instance strings (lowercase) |
There was a problem hiding this comment.
why lowercase? And can customers overwrite possible keywords?
There was a problem hiding this comment.
just that it's consistent - will remove the comment, we are lowecasing that on use.
|
|
||
| # Global VSS translation map (normalizing terminology) | ||
| VSS_SIDE_TO_COLUMN: dict[str, str] = { | ||
| "driverside": "left", # ambiguous |
There was a problem hiding this comment.
Depends on the market, doesn't it?
There was a problem hiding this comment.
Yes it does. What is meant here is that VSS is defining "driverside", "driver", "passengerside", "passenger"and "middle", e.g. here:
Vehicle.Occupant:
type: branch
instances:
- Row[1,2]
- ["DriverSide","Middle","PassengerSide"]
description: Occupant (Driver or Passenger) data.
while Android's Area IDs for seat define "left", "right", "center" (https://cs.android.com/android/platform/superproject/main/+/main:hardware/interfaces/automotive/vehicle/aidl_property/android/hardware/automotive/vehicle/VehicleAreaSeat.aidl)
A mapping needs to be done - the comment should highlight, that is not optimal.
| if str(item) == value or item.name == value or item.value == value: | ||
| return item | ||
| logging.error(f"{cls} can have values: {', '.join(options)}; but was {value}") | ||
| sys.exit(1) |
There was a problem hiding this comment.
Should raise instead of sys.exit()
|
MoM:
|
Signed-off-by: Jan Kubovy <jan.kubovy@bmw.de>
Enables VHAL Area IDs
Maps instances into areas, e.g., seats, windows, mirrors.