Vehicle properties
ADAS & driver assistance
ULTRASONICS_SENSOR_POSITION
What it is
Static data for the position of each ultrasonic sensor installed on the vehicle.
Each individual sensor is identified by its unique VehicleAreaConfig#areaId and returns the sensor's position formatted as [x, y, z] where:
int32Values[0] = x, the position of the sensor along the x-axis relative to the origin of
the Android Automotive sensor coordinate frame in millimeters
int32Values[1] = y, the position of the sensor along the y-axis relative to the origin of
the Android Automotive sensor coordinate frame in millimeters.
int32Values[2] = z, the position of the sensor along the z-axis relative to the origin of
the Android Automotive sensor coordinate frame in millimeters.If the data is aggregated by another ECU, then OEMs have the option of reporting the same reading across all included sensors or reporting a virtual representation of all the included sensors as if they were one sensor.
How the ID is built
A property ID is a 32-bit value packing four fields. Reading 0x18410c20 apart:
| Field | Mask | Value | Means |
|---|---|---|---|
| Group | 0xf0000000 | 0x10000000 | SYSTEM |
| Area | 0x0f000000 | 0x08000000 | VENDOR |
| Type | 0x00ff0000 | 0x00410000 | INT32_VEC |
| Ordinal | 0x0000ffff | 0x00000c20 | 0xc20 |
Reading it from an app
CarPropertyManager mgr = (CarPropertyManager)
car.getCarManager(Car.PROPERTY_SERVICE);
CarPropertyValue<Integer> value =
mgr.getProperty(VehiclePropertyIds.ULTRASONICS_SENSOR_POSITION, areaId);This property is read-only — writes are rejected. It is static for the life of the vehicle, so read it once and cache it.

