Commit graph

1541 commits

Author SHA1 Message Date
Ronish Kalia
98ef872235 Merge "Migrate Test Targets to New Android Ownership Model" into main 2024-04-22 15:01:56 +00:00
Felix Obenhuber
38f12da7b8 automotive aidl: Add required @RustDerive annotations
Derive vehicle hal parcelables from the Clone trait where applicable. This is is
supportive for implementing a vehicle hal service in Rust because caching e.g
VehiclePropValue or VehiclePropConfig instances allow less verbose code and
increase performance. Cloning a VehiclePropConfig instead of constructing each
time needed is less verbose. Property configs are normally not updated at
runtime.

This is not an API change, so in order to avoid having to bump the AIDL
API version for this HAL we used the hash_gen.sh script as below:

$ m android.hardware.automotive.vehicle-update-api
$ m android.hardware.automotive.vehicle-freeze-api

$ vim vehicle/aidl/Android.bp # removed frozen_api argument and the newly
created version 3 block

$ cp -r aidl_api/android.hardware.automotive.vehicle/3/* aidl_api/android.hardware.automotive.vehicle/2/
$ rm -rf aidl_api/android.hardware.automotive.vehicle/3/

./system/tools/aidl/build/hash_gen.sh \
    hardware/interfaces/automotive/vehicle/aidl/aidl_api/android.hardware.automotive.vehicle/2 \
    1 \
    hardware/interfaces/automotive/vehicle/aidl/aidl_api/android.hardware.automotive.vehicle/2/.hash

Test: manual - used new derives in custom implementation
Change-Id: I586b89b160eb7a01ce24fad211b9e909175cdd3c
Merged-In: I889c0d51f2c2633908231dd39c9ea5259de36667
2024-03-14 01:29:28 +00:00
Aditya Choudhary
04ef2121cd Migrate Test Targets to New Android Ownership Model
This CL is created as a best effort to migrate test targets to the new Android ownership model.
It is based on historical data from repository history and insights from git blame.
Given the nature of this effort, there may be instances of incorrect attribution. If you find incorrect or unnecessary
attribution in this CL, please create a new CL to fix that.

For detailed guidelines and further information on the migration please refer to the link below,
go/new-android-ownership-model

Bug: 304529413
Test: N/A
Change-Id: Ibe1360ca3f7eb919834715aa90b0b842fbcd0692
2024-02-02 14:00:43 +00:00
Yu Shan
9540e47340 Create EmuMetadataGenerator to check meta.json.
Create EmuMetadataGenerator to convert AIDL generated java files
to meta.json that can be used by emulator to populate the available
vhal props list.

Added build rules to generate the Java files from AIDL files and
check whether the meta.json file needs to be updated.

Test: make sdk_car_x86_64-trunk_staging-userdebug target
Bug: 318747444
Change-Id: Ib3bc7b68a1312152617fdab4598ed389447c20cd
Merged-In: Ib3bc7b68a1312152617fdab4598ed389447c20cd
2024-02-01 00:03:59 +00:00
Yu Shan
9fbf4066cb Merge "Add retry in setProp test." into android14-tests-dev am: 2c12f0e9ae am: 83a9e12f6d
Original change: https://android-review.googlesource.com/c/platform/hardware/interfaces/+/2934133

Change-Id: I2c79c14e22d42e783c113b9c6604af5b9c0718f0
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2024-01-31 03:06:01 +00:00
Yu Shan
83a9e12f6d Merge "Add retry in setProp test." into android14-tests-dev am: 2c12f0e9ae
Original change: https://android-review.googlesource.com/c/platform/hardware/interfaces/+/2934133

Change-Id: I0639e2f1bc6152c37e7fc6fac76d271871195b32
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2024-01-31 02:21:18 +00:00
Yu Shan
2c12f0e9ae Merge "Add retry in setProp test." into android14-tests-dev 2024-01-31 01:40:17 +00:00
Xin Li
757e0a265f Merge "Merge Android 24Q1 Release (ab/11220357)" into aosp-main-future 2024-01-30 22:44:06 +00:00
Xin Li
763c473c3d Merge Android 24Q1 Release (ab/11220357)
Bug: 319669529
Merged-In: I976f80006aeb88bde2ae34ca4f9be72cea727d9e
Change-Id: Id94b25af52bd2e2847b6858697ab21cc6ce27aa3
2024-01-30 10:36:50 -08:00
Yu Shan
ec8db77066 Fix HIDL VHAL descriptor name in VTS. am: 928062ccac am: 8cda776ffe
Original change: https://android-review.googlesource.com/c/platform/hardware/interfaces/+/2928798

Change-Id: I7662938de3cdccbdedf1ef60f36dce21225332c7
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2024-01-30 18:11:52 +00:00
Yu Shan
8cda776ffe Fix HIDL VHAL descriptor name in VTS. am: 928062ccac
Original change: https://android-review.googlesource.com/c/platform/hardware/interfaces/+/2928798

Change-Id: I6f7dd76ee3c813194085f131fe495e8f60492f7c
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2024-01-30 18:09:37 +00:00
Yu Shan
1837df06c2 Add retry in setProp test.
Set property operation is async so getting the property value
immediately after setting the property might not return the new
value. This CL adds the logic to retry when we do not get the
expected values back.

This CL also skips the test case if getting property or setting
property returns unavailable.

Test: atest VtsHalAutomotiveVehicle_TargetTest
Bug: 322070490
Change-Id: If9349a097a92c51101c7b5f4bf807b610ab2cb0b
Merged-In: If9349a097a92c51101c7b5f4bf807b610ab2cb0b
2024-01-29 22:50:49 +00:00
Yu Shan
928062ccac Fix HIDL VHAL descriptor name in VTS.
Bug: 322418005
Test: Manual test with HIDL VHAL, VTS pass.
Change-Id: I93e92d3587243c44b5651ab85d47442ebb64c51a
Merged-In: I93e92d3587243c44b5651ab85d47442ebb64c51a
2024-01-27 02:28:25 +00:00
Felix Obenhuber
a77f2df473 automotive: Add Rust backend to the vhal AIDL
This enables us to write a vhal service in Rust.

Test: Verified with a custom replacement of the DefaultVehicleHal and ran in cuttlefish
Change-Id: I53601e1a10cee75877e76ae04f7837e7d1a20ebd
2024-01-10 16:23:03 +01:00
Victor Shutemov
1e14bd55bd Fix AIDL VHAL metadata extraction script
Add capability to process values from imports.
Update json metadata file with new data.

Testing:
1. cd hardware/interfaces/automotive/vehicle/aidl/emu_metadata
2. ./generate_emulator_metadata.py ../../aidl_property/android/hardware/automotive/vehicle out.json

Bug: 317529575
Test: manual
Change-Id: I315f1f75c2372796bde3bdacd39246344579c002
2024-01-03 13:25:57 +01:00
Tyler Trephan
35bf32ff0f Fixed spelling mistake in LaneCenteringAssistCommand
Test: None
Bug: 290972334
(cherry picked from https://googleplex-android-review.googlesource.com/q/commit:077e36dee61db38ad8d0e28a62542e571e2921ae)
Merged-In: Ic85ba803abe349ea9a7edd7dca5cbe7159df34ac
Change-Id: Ic85ba803abe349ea9a7edd7dca5cbe7159df34ac
2023-12-27 20:02:52 +00:00
Yu Shan
c61a19bc28 Merge "Make sure the VehiclePropValue object is initialized" into main 2023-12-15 19:57:50 +00:00
Eva Chen
3e595ac343 Merge "Add ULTRASONICS_SENSOR_SUPPORTED_RANGES to HAL layer." into main 2023-12-14 05:47:08 +00:00
Eva Chen
13715242aa Merge "Add ULTRASONICS_SENSOR_DETECTION_RANGE to HAL layer." into main 2023-12-14 04:48:04 +00:00
Eva Chen
5bf8c4d338 Merge "Add ULTRASONICS_SENSOR_FIELD_OF_VIEW to HAL layer." into main 2023-12-14 03:31:13 +00:00
Eva Chen
8626ab361c Merge "Add ULTRASONICS_SENSOR_ORIENTATION to HAL layer." into main 2023-12-14 00:33:52 +00:00
Eva Chen
784e3c325c Merge "Add ULTRASONICS_SENSOR_POSITION to HAL layer." into main 2023-12-14 00:01:40 +00:00
Shrikar Amirisetty
255cfa2840 Merge "Added CROSS_TRAFFIC_MONITORING_WARNING_STATE to HAL" into main 2023-12-13 23:32:48 +00:00
Aaqib Ismail
691b6a1adc Merge "Change temp approximations to be accurate" into main 2023-12-13 22:30:38 +00:00
Shrikar Amirisetty
60927e3ae5 Merge "Added CROSS_TRAFFIC_MONITORING_ENABLED to HAL" into main 2023-12-13 22:29:11 +00:00
Shrikar Amirisetty
55ca206d93 Merge "Added ELECTRONIC_STABILITY_CONTROL_STATE to HAL" into main 2023-12-13 22:28:46 +00:00
Maxim Pleshivenkov
510537ffa7 Merge "Update VehicleApPowerStateShutdownParam" into main 2023-12-13 20:21:16 +00:00
Liu, Kai1
cb700ebc64 Make sure the VehiclePropValue object is initialized
If MALLOC_ZERO_CONTENTS is false, the new created VehiclePropValue
object maybe filled with dirty data, we should initialize it so that
its status member can be initialized to zero to avoid timeout when
car services get properties, such as property OBD2_LIVE_FRAME.

Bug: 315728228
Test: hidl_test

Change-Id: I530bc95a3074c917be853f55cd1736558b140da4
Signed-off-by: Liu, Kai1 <kai1.liu@intel.com>
2023-12-13 16:52:05 +08:00
Eva Chen
df05df56ba Add ULTRASONICS_SENSOR_SUPPORTED_RANGES to HAL layer.
Bug: 292141998
Test: atest VtsHalAutomotiveVehicle_TargetTest
Test: atest CtsCarTestCases:CarPropertyManagerTest
Test: atest CtsCarTestCases:VehiclePropertyIdsTest
Change-Id: Id648eeba8590c93d19dbdc5cc9b84fab67f30db4
2023-12-12 22:56:08 -08:00
Eva Chen
968bf44f66 Add ULTRASONICS_SENSOR_DETECTION_RANGE to HAL layer.
Bug: 292141998
Test: atest VtsHalAutomotiveVehicle_TargetTest
Test: atest CtsCarTestCases:CarPropertyManagerTest
Test: atest CtsCarTestCases:VehiclePropertyIdsTest
Change-Id: I52808bc26422691d2b80e5f45f31a82a44fdfbc4
2023-12-12 22:56:07 -08:00
Eva Chen
727aa3f29d Add ULTRASONICS_SENSOR_FIELD_OF_VIEW to HAL layer.
Bug: 292141998
Test: atest VtsHalAutomotiveVehicle_TargetTest
Test: atest CtsCarTestCases:CarPropertyManagerTest
Test: atest CtsCarTestCases:VehiclePropertyIdsTest
Change-Id: I2e8b35317ab7ecc952de1e8680ebfc8eac2a020f
2023-12-12 22:56:07 -08:00
Eva Chen
9e226e5099 Add ULTRASONICS_SENSOR_ORIENTATION to HAL layer.
Bug: 292141998
Test: atest VtsHalAutomotiveVehicle_TargetTest
Test: atest CtsCarTestCases:CarPropertyManagerTest
Test: atest CtsCarTestCases:VehiclePropertyIdsTest
Change-Id: I5b40cb5ce27a0d4e2b2b67c0a94b47aafa3ebd5c
2023-12-12 22:56:07 -08:00
Eva Chen
544b24ba94 Add ULTRASONICS_SENSOR_POSITION to HAL layer.
Bug: 292141998
Test: atest VtsHalAutomotiveVehicle_TargetTest
Test: atest CtsCarTestCases:CarPropertyManagerTest
Test: atest CtsCarTestCases:VehiclePropertyIdsTest
Change-Id: I97d2576179bc7e668f6036c911235dc1dcd67dcb
2023-12-12 22:56:06 -08:00
Eva Chen
95e88820a1 Merge "Add new VENDOR VehicleArea to HAL layer." into main 2023-12-13 04:54:16 +00:00
Treehugger Robot
5feeb3a5eb Merge "Update OWNERS file." into main am: e35fd5922b am: 8262c93f22 am: 3721dc7ecd
Original change: https://android-review.googlesource.com/c/platform/hardware/interfaces/+/2871780

Change-Id: I319ee1497cba9062349a09faae65825e9e25afb5
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-12-13 03:54:57 +00:00
Maxim Pleshivenkov
c9782c2e58 Update VehicleApPowerStateShutdownParam
Add Emergency Shutdown to VehicleApPowerStateShutdownParam

Bug: 316026370
Change-Id: Ieb250e0d84314a9926fb87ebdb4aa92c247778e0
Test: manual build
2023-12-13 02:58:43 +00:00
Treehugger Robot
e35fd5922b Merge "Update OWNERS file." into main 2023-12-13 01:28:25 +00:00
Yu Shan
bdd4c1aaea Update OWNERS file.
Test: None
Bug: None
Change-Id: I0c2b9bba98c0543ed44cf7c5ad1a350e195b7b29
2023-12-12 17:24:42 -08:00
Aaqib Ismail
5e119598fa Change temp approximations to be accurate
We need to use a more accurate ratio of celsius to fahrenheit along
with better min/max temperature conversions so if a client sets the
value using standard conversion or using this table, they will produce
the same result. Also, we need to round to the closest increment instead
of truncating.

Bug: 305274504
Bug: 313720524
Test: atest CtsCarTestCases:CarPropertyManagerTest
Test: atest FakeVehicleHardwareTest
Change-Id: Ia4d53e1a904fb2b40f5ec428ab548895c8f307ed
2023-12-12 22:42:29 +00:00
shrikar
813ba7c571 Added CROSS_TRAFFIC_MONITORING_WARNING_STATE to HAL
Bug: 313664286
Test: atest VtsHalAutomotiveVehicle_TargetTest
FakeVehicleHardwareTest

Change-Id: I49c6ff1a583a9d2e8504700a4c95de0c69bee21a
2023-12-12 21:27:47 +00:00
shrikar
7fde8f5084 Added CROSS_TRAFFIC_MONITORING_ENABLED to HAL
Bug: 313466942
Test: atest VtsHalAutomotiveVehicle_TargetTest
Change-Id: I8d65d4ab577254a60859ed2f65e0317829ff70b2
2023-12-12 21:21:01 +00:00
shrikar
a45d1cfdc9 Added ELECTRONIC_STABILITY_CONTROL_STATE to HAL
Bug: 313455695
Test: atest VtsHalAutomotiveVehicle_TargetTest
FakeVehicleHardwareTest

Change-Id: I8d8d7d749f530a7c738c8a9dfd712496d118715a
2023-12-12 21:19:45 +00:00
shrikar
33a3369d18 Added ELECTRONIC_STABILITY_CONTROL_ENABLED to HAL
Bug: 313435670
Test: atest VtsHalAutomotiveVehicle_TargetTest
Change-Id: I7d9bdc5bfccc3037a29d7d9b72c705797cc53064
2023-12-12 21:16:32 +00:00
shrikar
84866f7c35 Added VALET_MODE_ENABLED to HAL
Bug: 313324764
Test: atest VtsHalAutomotiveVehicle_TargetTest
Change-Id: I2365ac050978ade0d441ff96bf9160bd2b6651e4
2023-12-12 21:16:32 +00:00
shrikar
858c4e1791 Added LOW_SPEED_COLLISION_WARNING_STATE to HAL
Bug: 310955303
Test: atest VtsHalAutomotiveVehicle_TargetTest
FakeVehicleHardwareTest

Change-Id: I30980af5af1d6b954d6a4166be4df6ac92235388
2023-12-12 21:16:32 +00:00
shrikar
45df34b615 Added LOW_SPEED_COLLISION_WARNING_ENABLED to HAL
Bug: 310252857
Test: atest VtsHalAutomotiveVehicle_TargetTest
Change-Id: Ie2072d9cc0c8af83caf2f6e5590d5d1bd6c4e4aa
2023-12-12 21:16:32 +00:00
shrikar
a492e7d598 Added EV_BATTERY_AVERAGE_TEMPERATURE to HAL
Bug: 309861157
Test: atest VtsHalAutomotiveVehicle_TargetTest
Change-Id: I3ddf1d71969b233516cf6e617a4f9328e256ea7f
2023-12-12 21:16:32 +00:00
shrikar
d816e0433c Added IMPACT_DETECTED to HAL
Bug: 309826888
Test: atest VtsHalAutomotiveVehicle_TargetTest
Change-Id: I79c72bed8dcd96632cf9c7b6ff71c04198625467
2023-12-12 21:16:31 +00:00
shrikar
7717aa80ac Added SEAT_BELT_PRETENSIONER_DEPLOYED to HAL
Bug: 309666683
Test: atest VtsHalAutomotiveVehicle_TargetTest
Change-Id: I79ca3e68c18fb961e83d1bd67f794256fe806f55
2023-12-12 21:16:31 +00:00
shrikar
420b31dddf Added SEAT_AIRBAGS_DEPLOYED to HAL
Bug: 309620475
Test: atest VtsHalAutomotiveVehicle_TargetTest
Change-Id: I90db503d61c70cb2ab2581d3327a09b3225ac62c
2023-12-12 21:16:31 +00:00