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

Commit f898641c authored by Nishtha Ahuja's avatar Nishtha Ahuja Committed by Android (Google) Code Review
Browse files

Merge "Add default config for new VHAL properties in Android T." into tm-dev

parents 237cd1c0 10651a6e
Loading
Loading
Loading
Loading
+97 −0
Original line number Diff line number Diff line
@@ -287,6 +287,71 @@ const std::vector<ConfigDeclaration> kVehicleProperties = {
                 },
         .initialValue = {.floatValues = {0.0f}}},

        {.config =
                 {
                         .prop = toInt(VehicleProperty::EV_CHARGE_CURRENT_DRAW_LIMIT),
                         .access = VehiclePropertyAccess::READ_WRITE,
                         .changeMode = VehiclePropertyChangeMode::ON_CHANGE,
                 },
         .initialValue = {.floatValues = {(float)VehicleUnit::AMPERE}}},

        {.config =
                 {
                         .prop = toInt(VehicleProperty::EV_CHARGE_PERCENT_LIMIT),
                         .access = VehiclePropertyAccess::READ_WRITE,
                         .changeMode = VehiclePropertyChangeMode::ON_CHANGE,
                         .configArray = {20, 40, 60, 80, 100},
                 },
         .initialValue = {.floatValues = {40}}},

        {.config =
                 {
                         .prop = toInt(VehicleProperty::EV_CHARGE_STATE),
                         .access = VehiclePropertyAccess::READ,
                         .changeMode = VehiclePropertyChangeMode::ON_CHANGE,
                 },
         .initialValue = {.int32Values = {2}}},

        {.config =
                 {
                         .prop = toInt(VehicleProperty::EV_CHARGE_SWITCH),
                         .access = VehiclePropertyAccess::READ_WRITE,
                         .changeMode = VehiclePropertyChangeMode::ON_CHANGE,
                 },
         .initialValue = {.int32Values = {0 /* false */}}},

        {.config =
                 {
                         .prop = toInt(VehicleProperty::EV_CHARGE_TIME_REMAINING),
                         .access = VehiclePropertyAccess::READ,
                         .changeMode = VehiclePropertyChangeMode::CONTINUOUS,
                 },
         .initialValue = {.int32Values = {20}}},

        {.config =
                 {
                         .prop = toInt(VehicleProperty::EV_REGENERATIVE_BRAKING_STATE),
                         .access = VehiclePropertyAccess::READ,
                         .changeMode = VehiclePropertyChangeMode::ON_CHANGE,
                 },
         .initialValue = {.int32Values = {2}}},

        {.config =
                 {
                         .prop = toInt(VehicleProperty::TRAILER_PRESENT),
                         .access = VehiclePropertyAccess::READ,
                         .changeMode = VehiclePropertyChangeMode::ON_CHANGE,
                 },
         .initialValue = {.int32Values = {2}}},

        {.config =
                 {
                         .prop = toInt(VehicleProperty::VEHICLE_CURB_WEIGHT),
                         .access = VehiclePropertyAccess::READ,
                         .changeMode = VehiclePropertyChangeMode::STATIC,
                 },
         .initialValue = {.int32Values = {30}}},

        {.config =
                 {
                         .prop = toInt(VehicleProperty::RANGE_REMAINING),
@@ -818,6 +883,22 @@ const std::vector<ConfigDeclaration> kVehicleProperties = {
                 },
         .initialValue = {.int32Values = {LIGHT_STATE_ON}}},

        {.config =
                 {
                         .prop = toInt(VehicleProperty::FRONT_FOG_LIGHTS_STATE),
                         .access = VehiclePropertyAccess::READ,
                         .changeMode = VehiclePropertyChangeMode::ON_CHANGE,
                 },
         .initialValue = {.int32Values = {LIGHT_STATE_ON}}},

        {.config =
                 {
                         .prop = toInt(VehicleProperty::REAR_FOG_LIGHTS_STATE),
                         .access = VehiclePropertyAccess::READ,
                         .changeMode = VehiclePropertyChangeMode::ON_CHANGE,
                 },
         .initialValue = {.int32Values = {LIGHT_STATE_ON}}},

        {.config =
                 {
                         .prop = toInt(VehicleProperty::HAZARD_LIGHTS_STATE),
@@ -850,6 +931,22 @@ const std::vector<ConfigDeclaration> kVehicleProperties = {
                 },
         .initialValue = {.int32Values = {LIGHT_SWITCH_AUTO}}},

        {.config =
                 {
                         .prop = toInt(VehicleProperty::FRONT_FOG_LIGHTS_SWITCH),
                         .access = VehiclePropertyAccess::READ_WRITE,
                         .changeMode = VehiclePropertyChangeMode::ON_CHANGE,
                 },
         .initialValue = {.int32Values = {LIGHT_SWITCH_AUTO}}},

        {.config =
                 {
                         .prop = toInt(VehicleProperty::REAR_FOG_LIGHTS_SWITCH),
                         .access = VehiclePropertyAccess::READ_WRITE,
                         .changeMode = VehiclePropertyChangeMode::ON_CHANGE,
                 },
         .initialValue = {.int32Values = {LIGHT_SWITCH_AUTO}}},

        {.config =
                 {
                         .prop = toInt(VehicleProperty::HAZARD_LIGHTS_SWITCH),