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

Commit 37833e17 authored by shrikar's avatar shrikar
Browse files

Added HANDS_ON_DETECTION_ENABLED to hardware layer.

Bug: 261739790
Test: atest VtsHalAutomotiveVehicle_TargetTest
Change-Id: I382bad54ba5c26f398b9d925e9dd1672446b684b
parent 808a294e
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -241,4 +241,5 @@ enum VehicleProperty {
  LANE_CENTERING_ASSIST_ENABLED = 287313930,
  EMERGENCY_LANE_KEEP_ASSIST_ENABLED = 287313933,
  ADAPTIVE_CRUISE_CONTROL_ENABLED = 287313935,
  HANDS_ON_DETECTION_ENABLED = 287313941,
}
+16 −0
Original line number Diff line number Diff line
@@ -3484,6 +3484,22 @@ enum VehicleProperty {
    ADAPTIVE_CRUISE_CONTROL_ENABLED =
            0x100F + VehiclePropertyGroup.SYSTEM + VehicleArea.GLOBAL + VehiclePropertyType.BOOLEAN,

    /**
     * Enable or disable hands on detection (HOD).
     *
     * Set true to enable HOD and false to disable HOD. When HOD is enabled, a system inside the
     * vehicle should be monitoring the presence of the driver's hands on the steering wheel and
     * send a warning if it detects that the driver's hands are no longer on the steering wheel.
     *
     * This property is defined as read_write, but OEMs have the option to implement it as read
     * only.
     *
     * @change_mode VehiclePropertyChangeMode.ON_CHANGE
     * @access VehiclePropertyAccess.READ_WRITE
     */
    HANDS_ON_DETECTION_ENABLED =
            0x1015 + VehiclePropertyGroup.SYSTEM + VehicleArea.GLOBAL + VehiclePropertyType.BOOLEAN,

    /***************************************************************************
     * End of ADAS Properties
     **************************************************************************/
+1 −0
Original line number Diff line number Diff line
@@ -241,6 +241,7 @@ std::unordered_map<VehicleProperty, VehiclePropertyAccess> AccessForVehiclePrope
        {VehicleProperty::LANE_CENTERING_ASSIST_ENABLED, VehiclePropertyAccess::READ_WRITE},
        {VehicleProperty::EMERGENCY_LANE_KEEP_ASSIST_ENABLED, VehiclePropertyAccess::READ_WRITE},
        {VehicleProperty::ADAPTIVE_CRUISE_CONTROL_ENABLED, VehiclePropertyAccess::READ_WRITE},
        {VehicleProperty::HANDS_ON_DETECTION_ENABLED, VehiclePropertyAccess::READ_WRITE},
};

}  // namespace vehicle
+1 −0
Original line number Diff line number Diff line
@@ -241,6 +241,7 @@ std::unordered_map<VehicleProperty, VehiclePropertyChangeMode> ChangeModeForVehi
        {VehicleProperty::LANE_CENTERING_ASSIST_ENABLED, VehiclePropertyChangeMode::ON_CHANGE},
        {VehicleProperty::EMERGENCY_LANE_KEEP_ASSIST_ENABLED, VehiclePropertyChangeMode::ON_CHANGE},
        {VehicleProperty::ADAPTIVE_CRUISE_CONTROL_ENABLED, VehiclePropertyChangeMode::ON_CHANGE},
        {VehicleProperty::HANDS_ON_DETECTION_ENABLED, VehiclePropertyChangeMode::ON_CHANGE},
};

}  // namespace vehicle
+2 −1
Original line number Diff line number Diff line
@@ -232,7 +232,8 @@ public final class AccessForVehicleProperty {
        Map.entry(VehicleProperty.LANE_DEPARTURE_WARNING_ENABLED, VehiclePropertyAccess.READ_WRITE),
        Map.entry(VehicleProperty.LANE_CENTERING_ASSIST_ENABLED, VehiclePropertyAccess.READ_WRITE),
        Map.entry(VehicleProperty.EMERGENCY_LANE_KEEP_ASSIST_ENABLED, VehiclePropertyAccess.READ_WRITE),
        Map.entry(VehicleProperty.ADAPTIVE_CRUISE_CONTROL_ENABLED, VehiclePropertyAccess.READ_WRITE)
        Map.entry(VehicleProperty.ADAPTIVE_CRUISE_CONTROL_ENABLED, VehiclePropertyAccess.READ_WRITE),
        Map.entry(VehicleProperty.HANDS_ON_DETECTION_ENABLED, VehiclePropertyAccess.READ_WRITE)
    );

}
Loading