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

Commit 2dae80f7 authored by shrikar's avatar shrikar
Browse files

Added EV_STOPPING_MODE to hardware layer.

Bug: 262901831
Test: atest VtsHalAutomotiveVehicle_TargetTest
Change-Id: I11dd297c96594c864beaf4917f3a2a3706a0cd76
parent f0c24dad
Loading
Loading
Loading
Loading
+41 −0
Original line number Diff line number Diff line
/*
 * Copyright (C) 2022 The Android Open Source Project
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
///////////////////////////////////////////////////////////////////////////////
// THIS FILE IS IMMUTABLE. DO NOT EDIT IN ANY CASE.                          //
///////////////////////////////////////////////////////////////////////////////

// This file is a snapshot of an AIDL file. Do not edit it manually. There are
// two cases:
// 1). this is a frozen version file - do not edit this in any case.
// 2). this is a 'current' file. If you make a backwards compatible change to
//     the interface (from the latest frozen version), the build system will
//     prompt you to update this file with `m <name>-update-api`.
//
// You must not make a backward incompatible change to any AIDL file built
// with the aidl_interface module type with versions property set. The module
// type is used to build AIDL files in a way that they can be used across
// independently updatable components of the system. If a device is shipped
// with such a backward incompatible change, it has a high risk of breaking
// later when a module using the interface is updated, e.g., Mainline modules.

package android.hardware.automotive.vehicle;
@Backing(type="int") @VintfStability
enum EvStoppingMode {
  OTHER = 0,
  CREEP = 1,
  ROLL = 2,
  HOLD = 3,
}
+1 −0
Original line number Diff line number Diff line
@@ -80,6 +80,7 @@ enum VehicleProperty {
  IGNITION_STATE = 289408009,
  ABS_ACTIVE = 287310858,
  TRACTION_CONTROL_ACTIVE = 287310859,
  EV_STOPPING_MODE = 289408013,
  HVAC_FAN_SPEED = 356517120,
  HVAC_FAN_DIRECTION = 356517121,
  HVAC_TEMPERATURE_CURRENT = 358614274,
+43 −0
Original line number Diff line number Diff line
/*
 * Copyright (C) 2022 The Android Open Source Project
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

package android.hardware.automotive.vehicle;

/**
 * Used by EV_STOPPING_MODE to enumerate the current state of the stopping mode.
 *
 * This enum may be extended to include more states in the future.
 */
@VintfStability
@Backing(type="int")
enum EvStoppingMode {
    /**
     * Other EV stopping mode. Ideally, this should never be used.
     */
    OTHER = 0,
    /**
     * Vehicle slowly moves forward when the brake pedal is released.
     */
    CREEP = 1,
    /**
     * Vehicle rolls freely when the brake pedal is released (similar to neutral gear).
     */
    ROLL = 2,
    /**
     * Vehicle stops and holds its position when the brake pedal is released.
     */
    HOLD = 3,
}
+14 −0
Original line number Diff line number Diff line
@@ -602,6 +602,20 @@ enum VehicleProperty {
     */
    TRACTION_CONTROL_ACTIVE = 0x040B + 0x10000000 + 0x01000000
            + 0x00200000, // VehiclePropertyGroup:SYSTEM,VehicleArea:GLOBAL,VehiclePropertyType:BOOLEAN
    /**
     * Represents property for the current stopping mode of the vehicle.
     *
     * For the global area ID (0), the VehicleAreaConfig#supportedEnumValues must be defined unless
     * all enum values of EvStoppingMode are supported.
     *
     * The EvStoppingMode enum may be extended to include more states in the future.
     *
     * @change_mode VehiclePropertyChangeMode.ON_CHANGE
     * @access VehiclePropertyAccess.READ_WRITE
     * @data_enum EvStoppingMode
     */
    EV_STOPPING_MODE =
            0x040D + VehiclePropertyGroup.SYSTEM + VehicleArea.GLOBAL + VehiclePropertyType.INT32,
    /**
     * HVAC Properties
     *
+1 −0
Original line number Diff line number Diff line
@@ -80,6 +80,7 @@ std::unordered_map<VehicleProperty, VehiclePropertyAccess> AccessForVehiclePrope
        {VehicleProperty::IGNITION_STATE, VehiclePropertyAccess::READ},
        {VehicleProperty::ABS_ACTIVE, VehiclePropertyAccess::READ},
        {VehicleProperty::TRACTION_CONTROL_ACTIVE, VehiclePropertyAccess::READ},
        {VehicleProperty::EV_STOPPING_MODE, VehiclePropertyAccess::READ_WRITE},
        {VehicleProperty::HVAC_FAN_SPEED, VehiclePropertyAccess::READ_WRITE},
        {VehicleProperty::HVAC_FAN_DIRECTION, VehiclePropertyAccess::READ_WRITE},
        {VehicleProperty::HVAC_TEMPERATURE_CURRENT, VehiclePropertyAccess::READ},
Loading