Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 1a7ac6a7 authored by Yu Shan's avatar Yu Shan
Browse files

Update doc for GEAR_SELECTION.

Part of a large doc update. Add doc for new supported value range
APIs. For be backward compatible with older VHAL clients still
using deprecated fields, we still require the old fields to be
populated.

Test: None
Bug: 371636116
Flag: EXEMPT no code change
Change-Id: I4cbf7352604355c84caf32d920314cbc63f305c3
parent 04e79d73
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -222,7 +222,7 @@
                    "VehicleGear"
                ],
                "data_enum": "VehicleGear",
                "description": "Currently selected gear\nThis is the gear selected by the user.\nValues in the config data must represent the list of supported gears for this vehicle. For example, config data for an automatic transmission must contain {GEAR_NEUTRAL, GEAR_REVERSE, GEAR_PARK, GEAR_DRIVE, GEAR_1, GEAR_2,...} and for manual transmission the list must be {GEAR_NEUTRAL, GEAR_REVERSE, GEAR_1, GEAR_2,...}\nIn the case of an automatic transmission vehicle that allows the driver to select specific gears on demand (i.e. \"manual mode\"), GEAR_SELECTION's value must be set to the specific gear selected by the driver instead of simply GEAR_DRIVE."
                "description": "Currently selected gear\nThis is the gear selected by the user.\n{@code VehicleAreaConfig.HasSupportedValueInfo.hasSupportedValuesList} for the global area ID (0) must be {@code true}.\n{@code getSupportedValuesList} for [GEAR_SELECTION, areaId=0] must return a {@code SupportedValuesListResult} that contains non-null {@code supportedValuesList}.\nThe supportedValues must represent the list of supported gears for this vehicle. For example, for an automatic transmission, the list can be {GEAR_NEUTRAL, GEAR_REVERSE, GEAR_PARK, GEAR_DRIVE, GEAR_1, GEAR_2,...} and for manual transmission it can be {GEAR_NEUTRAL, GEAR_REVERSE, GEAR_1, GEAR_2,...}.\nIn the case of an automatic transmission vehicle that allows the driver to select specific gears on demand (i.e. \"manual mode\"), GEAR_SELECTION's value must be set to the specific gear selected by the driver instead of simply GEAR_DRIVE.\nFor backward compatibility, config array for this property must be a list of values same as the supported values at boot-time."
            },
            {
                "name": "CURRENT_GEAR",
+15 −4
Original line number Diff line number Diff line
@@ -620,18 +620,29 @@ enum VehicleProperty {
     *
     * This is the gear selected by the user.
     *
     * Values in the config data must represent the list of supported gears for this vehicle. For
     * example, config data for an automatic transmission must contain {GEAR_NEUTRAL, GEAR_REVERSE,
     * GEAR_PARK, GEAR_DRIVE, GEAR_1, GEAR_2,...} and for manual transmission the list must be
     * {GEAR_NEUTRAL, GEAR_REVERSE, GEAR_1, GEAR_2,...}
     * {@code VehicleAreaConfig.HasSupportedValueInfo.hasSupportedValuesList} for the global area ID
     * (0) must be {@code true}.
     *
     * {@code getSupportedValuesList} for [GEAR_SELECTION, areaId=0] must return a
     * {@code SupportedValuesListResult} that contains non-null {@code supportedValuesList}.
     *
     * The supportedValues must represent the list of supported gears for this vehicle. For example,
     * for an automatic transmission, the list can be {GEAR_NEUTRAL, GEAR_REVERSE, GEAR_PARK,
     * GEAR_DRIVE, GEAR_1, GEAR_2,...} and for manual transmission it can be {GEAR_NEUTRAL,
     * GEAR_REVERSE, GEAR_1, GEAR_2,...}.
     *
     * In the case of an automatic transmission vehicle that allows the driver to select specific
     * gears on demand (i.e. "manual mode"), GEAR_SELECTION's value must be set to the specific gear
     * selected by the driver instead of simply GEAR_DRIVE.
     *
     * For backward compatibility, config array for this property must be a list of values
     * same as the supported values at boot-time.
     *
     * @change_mode VehiclePropertyChangeMode.ON_CHANGE
     * @access VehiclePropertyAccess.READ
     * @data_enum VehicleGear
     * @require_supported_values_list
     * @legacy_supported_values_in_config
     * @version 2
     */
    GEAR_SELECTION = 0x0400 + 0x10000000 + 0x01000000