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

Commit 6383653c authored by Aaqib Ismail's avatar Aaqib Ismail Committed by Android (Google) Code Review
Browse files

Merge "Add HAL changes for EV_BRAKE_REGENERATION_LEVEL"

parents 9568c57a c69e968b
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -71,6 +71,7 @@ enum VehicleProperty {
  CURRENT_GEAR = 289408001,
  PARKING_BRAKE_ON = 287310850,
  PARKING_BRAKE_AUTO_APPLY = 287310851,
  EV_BRAKE_REGENERATION_LEVEL = 289408012,
  FUEL_LEVEL_LOW = 287310853,
  NIGHT_MODE = 287310855,
  TURN_SIGNAL_STATE = 289408008,
+15 −0
Original line number Diff line number Diff line
@@ -490,6 +490,21 @@ enum VehicleProperty {
     */
    PARKING_BRAKE_AUTO_APPLY = 0x0403 + 0x10000000 + 0x01000000
            + 0x00200000, // VehiclePropertyGroup:SYSTEM,VehicleArea:GLOBAL,VehiclePropertyType:BOOLEAN
    /**
     * Regenerative braking level of a electronic vehicle
     *
     * The maxInt32Value and minInt32Value in VehicleAreaConfig must be defined. All values between
     * minInt32Value and maxInt32Value must be supported. The minInt32Value must be 0.
     *
     * The maxInt32Value in default area's VehicleAreaConfig indicates the maximum amount of energy
     * regenerated from braking. The minInt32Value in default area's VehicleAreaConfig indicates no
     * regenerative braking.
     *
     * @change_mode VehiclePropertyChangeMode.ON_CHANGE
     * @access VehiclePropertyAccess.READ_WRITE
     */
    EV_BRAKE_REGENERATION_LEVEL =
            0x040C + VehiclePropertyGroup.SYSTEM + VehicleArea.GLOBAL + VehiclePropertyType.INT32,
    /**
     * Warning for fuel low level.
     *
+1 −0
Original line number Diff line number Diff line
@@ -71,6 +71,7 @@ std::unordered_map<VehicleProperty, VehiclePropertyAccess> AccessForVehiclePrope
        {VehicleProperty::CURRENT_GEAR, VehiclePropertyAccess::READ},
        {VehicleProperty::PARKING_BRAKE_ON, VehiclePropertyAccess::READ},
        {VehicleProperty::PARKING_BRAKE_AUTO_APPLY, VehiclePropertyAccess::READ},
        {VehicleProperty::EV_BRAKE_REGENERATION_LEVEL, VehiclePropertyAccess::READ_WRITE},
        {VehicleProperty::FUEL_LEVEL_LOW, VehiclePropertyAccess::READ},
        {VehicleProperty::NIGHT_MODE, VehiclePropertyAccess::READ},
        {VehicleProperty::TURN_SIGNAL_STATE, VehiclePropertyAccess::READ},
+1 −0
Original line number Diff line number Diff line
@@ -71,6 +71,7 @@ std::unordered_map<VehicleProperty, VehiclePropertyChangeMode> ChangeModeForVehi
        {VehicleProperty::CURRENT_GEAR, VehiclePropertyChangeMode::ON_CHANGE},
        {VehicleProperty::PARKING_BRAKE_ON, VehiclePropertyChangeMode::ON_CHANGE},
        {VehicleProperty::PARKING_BRAKE_AUTO_APPLY, VehiclePropertyChangeMode::ON_CHANGE},
        {VehicleProperty::EV_BRAKE_REGENERATION_LEVEL, VehiclePropertyChangeMode::ON_CHANGE},
        {VehicleProperty::FUEL_LEVEL_LOW, VehiclePropertyChangeMode::ON_CHANGE},
        {VehicleProperty::NIGHT_MODE, VehiclePropertyChangeMode::ON_CHANGE},
        {VehicleProperty::TURN_SIGNAL_STATE, VehiclePropertyChangeMode::ON_CHANGE},
+1 −0
Original line number Diff line number Diff line
@@ -63,6 +63,7 @@ public final class AccessForVehicleProperty {
        Map.entry(VehicleProperty.CURRENT_GEAR, VehiclePropertyAccess.READ),
        Map.entry(VehicleProperty.PARKING_BRAKE_ON, VehiclePropertyAccess.READ),
        Map.entry(VehicleProperty.PARKING_BRAKE_AUTO_APPLY, VehiclePropertyAccess.READ),
        Map.entry(VehicleProperty.EV_BRAKE_REGENERATION_LEVEL, VehiclePropertyAccess.READ_WRITE),
        Map.entry(VehicleProperty.FUEL_LEVEL_LOW, VehiclePropertyAccess.READ),
        Map.entry(VehicleProperty.NIGHT_MODE, VehiclePropertyAccess.READ),
        Map.entry(VehicleProperty.TURN_SIGNAL_STATE, VehiclePropertyAccess.READ),
Loading