Skip to content
Vehicle properties
Windshield & wipers

WINDSHIELD_WIPERS_STATE

What it is

Windshield wipers state.

Returns the current state of the windshield wipers. The value of WINDSHIELD_WIPERS_STATE may not match the value of WINDSHIELD_WIPERS_SWITCH. (e.g. WINDSHIELD_WIPERS_STATE = ON and WINDSHIELD_WIPERS_SWITCH = WindshieldWipersSwitch#AUTO).

If WINDSHIELD_WIPERS_STATE = ON and WINDSHIELD_WIPERS_PERIOD is implemented, then WINDSHIELD_WIPERS_PERIOD must reflect the time period of 1 full cycle of the wipers.

For each supported area ID, the VehicleAreaConfig#supportedEnumValues array must be defined unless all states in WindshieldWipersState are supported (including OTHER, which is not recommended).

How the ID is built

A property ID is a 32-bit value packing four fields. Reading 0x13400bc6 apart:

FieldMaskValueMeans
Group0xf00000000x10000000SYSTEM
Area0x0f0000000x03000000WINDOW
Type0x00ff00000x00400000INT32
Ordinal0x0000ffff0x00000bc60xbc6

Reading it from an app

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

int value =
        mgr.getIntProperty(VehiclePropertyIds.WINDSHIELD_WIPERS_STATE, areaId);

This property is read-only — writes are rejected. It fires a callback whenever the value changes.