Skip to content
Vehicle properties
ADAS & driver assistance

ULTRASONICS_SENSOR_DETECTION_RANGE

What it is

Static data for the detection range of each ultrasonic sensor in millimeters.

Each individual sensor is identified by its VehicleAreaConfig#areaId and returns the sensor's detection range formatted as [minimum, maximum] where:

    int32Values[0] = minimum, the minimum range detectable by the ultrasonic sensor in
                     millimeters.
    int32Values[1] = maximum, the maximum range detectable by the ultrasonic sensor 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 0x18410c23 apart:

FieldMaskValueMeans
Group0xf00000000x10000000SYSTEM
Area0x0f0000000x08000000VENDOR
Type0x00ff00000x00410000INT32_VEC
Ordinal0x0000ffff0x00000c230xc23

Reading it from an app

CarPropertyManager mgr = (CarPropertyManager)
        car.getCarManager(Car.PROPERTY_SERVICE);

CarPropertyValue<Integer> value =
        mgr.getProperty(VehiclePropertyIds.ULTRASONICS_SENSOR_DETECTION_RANGE, 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.