Commit graph

544 commits

Author SHA1 Message Date
TreeHugger Robot
74f6bc8e31 Merge "Added new properties on Vehicle HAL to support user management." 2020-02-03 03:14:17 +00:00
felipeal
c5afe480bd Added new properties on Vehicle HAL to support user management.
These initial properties are:

- INITIAL_USER_INFO: gets information about the initial user, it will
  replace the android.car.systemuser.bootuseroverrideid system property
  approach.
- SWITCH_USER_REQUEST: used to communicate a user switch request from
  Android to HAL, or vice versa.

This CL only defines the new types, they're not implemented or used yet.

Test: m -j android.hardware.automotive.vehicle@2.0-service
Bug: 146207078

Change-Id: I25055f8adc90aaebaf3a3faa9a9b73c284440624
2020-01-31 09:24:15 -08:00
Zhaoming Yin
cafc24b5a5 Merge "Add fuzzer for EVS HAL" 2020-01-31 02:24:51 +00:00
TreeHugger Robot
230a2eb1d6 Merge "Use regex names for EVS HAL implementations" 2020-01-30 23:08:21 +00:00
Zhaoming Yin
838c4c19d3 Add fuzzer for EVS HAL
Bug: 147513710
Test: Follow go/android-fuzzing to build and test

Change-Id: Ia2a64f73d3928bc529a1785e999ed7f032446f8a
2020-01-30 13:14:38 -08:00
TreeHugger Robot
87880e82d0 Merge "Change the location of a configuration file" 2020-01-30 21:02:21 +00:00
Changyeon Jo
b0e72927dc Change the location of a configuration file
Move a configuration xml file from /system/etc to /vendor/etc.

Bug: 148424402
Test: m -j selinux_policy
Test: check violations while EVS service is running.
Change-Id: I17c74798564bb0f5684157c483b45857b39ab6bd
Signed-off-by: Changyeon Jo <changyeon@google.com>
2020-01-30 09:00:35 -08:00
Changyeon Jo
8bcb492309 Use regex names for EVS HAL implementations
This change deprecates EvsEnumeratorHw, which has been a name for
EVS HAL Enumerator implementations, and uses regex names for them.

New method, isHardware(), is added to IEvsEnumerator and the clients
should use this method to tell whether current service is EVS manager
or driver.

Bug: 147010694
Test: m -j
Test: atest VtsHalEvsV1_1TargetTest
Change-Id: I89441936734fde0f0cc2f0151ee9b6622f61814d
Signed-off-by: Changyeon Jo <changyeon@google.com>
2020-01-29 19:59:48 -08:00
Enrico Granata
4744b174ea Merge "Remove spurious cflags from AudioControl HAL 1.0" 2020-01-28 19:30:29 +00:00
Hao Chen
5a97c389e9 Apply Grpc Client to current VHal Implementation
Test: tested on Cuttlefish VM

 - Use virtualization HAL implementation, device/google/cuttlefish/shared/auto/device.mk, PRODUCT_PACKAGES:
      remove android.hardware.automotive.vehicle@2.0-service
      add:
        android.hardware.automotive.vehicle@2.0-virtualization-service
        android.hardware.automotive.vehicle@2.0-virtualization-grpc-server

 - configure the server CID and port, add the following device/google/cuttlefish/shared/config/init.vendor.rc:
        setprop ro.vendor.vehiclehal.server.cid 3
        setprop ro.vendor.vehiclehal.server.port 9210
 - Build and Launch cuttlefish VM
        m && acloud create --boot-timeout 3600 -vv --local-instance --local-image
 - VHAL should work as normal, see tests in ag/9693857

Bug: b/141493212

Change-Id: I97df02dd26b89f60d3d87b2c32c4f4f8919b1294
2020-01-23 13:34:34 -08:00
Hao Chen
46df8f5909 Grpc Vehicle Connectors
Test: Build; test with ag/9869095

Bug: b/141493212

Change-Id: Ia4c0b0b5b358b1c67aae43d8c64f781b83725329
2020-01-23 13:14:29 -08:00
Hayden Gomes
ebebc9c266 Adding v2 of audiocontrol hal
- Removes deprecated getBusForContext
- Adds APIs for enabling HAL to request and abandon audio focus

Bug: 148098383
Test: vts-tradefed -module VtsHalAudioControlV2_0TargetTest
Change-Id: I353bbd8ea7708ffb59831a8e1008951146798034
2020-01-23 01:06:12 +00:00
Enrico Granata
1d2be904df Remove spurious cflags from AudioControl HAL 1.0
Nothing in the Android tree appears to reference AudCntrlDrv, and
there is no reason why we should ship a HAL implementation running
at O0

Test: build
Change-Id: I14a3d910d9654ce438930bfa83cec39a7ef99dc2
2020-01-21 16:08:23 -08:00
Tyler Trephan
8081fb6eba Merge "Updated PERF_STEERING_ANGLE to support rear steering." 2020-01-18 00:17:06 +00:00
Tyler Trephan
e57c109d3e Adding INFO_EXTERIOR_DIMENSIONS car property.
Fix: 146020990
Test: Tested on device.
Change-Id: I003cbb05de0a91efb8e393860fc64ba508515b26
2020-01-17 11:31:09 -08:00
Tyler Trephan
cb8d72c707 Updated PERF_STEERING_ANGLE to support rear steering.
Change-Id: I2d8d8eff076ab2b76476a8b4edc18d213df71d45
Fix: 146022250
Test: Tested on device.
2020-01-14 16:12:55 -08:00
chrisweir
204b8f9206 Refactor baudrate to bitrate
Refactoring baudrate to bitrate to be consistent with terminology in
the broader literature.

Bug: 147448388
Test: Manual + VTS
Change-Id: I161b39727a3fd50ea5eddafed6fbd4924ccd149f
2020-01-11 01:05:59 +00:00
chrisweir
39187dbbff Add support for registering existing interfaces
This adds support for native and slcan interfaces which are already
configured up to be registered in the CAN bus HAL.

Bug: 142655647
Test: manual
Change-Id: Ifd129db14dbf473bb627ebc9b9d13f5cb945b611
2020-01-07 15:49:15 -08:00
TreeHugger Robot
1d0c4bbee9 Merge "Enable java backend for occupant awareness iface." 2020-01-06 20:19:32 +00:00
Chris Weir
d7e18f699d Merge "Add VTS tests for EFF/RTR" 2020-01-06 19:23:32 +00:00
chrisweir
f53a4e2ff3 Add VTS tests for EFF/RTR
Remote transmission request, and extended format id's require testing to
verify that the feature works correctly.

Also included is a fix which correctly sets the EFF and RTR flags of the
canfd_frame object based on the state of the CanMessage object.

A readability change is made to the types.hal which improves clarity of
the way filters are defined.

Bug: 146173498
Test: run the VTS tests in vts/functional - verify that they pass
Change-Id: I9892a2e2465b8c381774e7ee277bfa8660f25028
2020-01-06 10:05:25 -08:00
Changyeon Jo
6caf74b061 Implement getPhysicalCameraInfo() method
This change adds a new method, getPhysicalCameraInfo(), to IEvsCamera
interface, implements it in the default implementation, and update
corresponding VTS test cases.

Bug: 142275664
Test: VtsHalEvsV1_1TargetTest
Change-Id: Ic993d5670c34f05ef8d807708f27dec75008b04b
Signed-off-by: Changyeon Jo <changyeon@google.com>
2020-01-04 09:56:06 -08:00
Changyeon Jo
a203a13bf3 Update EVS VTS test cases
This change updates existing EVS VTS test cases to verify the logical
camera device.

Bug: 142275664
Test: VtsHalEvsV1_1TargetTest
Change-Id: Ieebb09a3bbf948ab60d0498a359be8f8c726735c
Signed-off-by: Changyeon Jo <changyeon@google.com>
2020-01-04 09:56:06 -08:00
Changyeon Jo
273c37d303 Fix EVS frame handler for VTS
This change updates FrameHandler to handle and count delivered EVS
frames correctly.

Bug: 142275664
Test: VtsHalEvsV1_1TargetTest
Change-Id: I098bcf8155c9e4211ec0152b2a828520b6c22dc2
Signed-off-by: Changyeon Jo <changyeon@google.com>
2020-01-04 09:56:06 -08:00
Changyeon Jo
3e80b3b528 Fix EVS VTS test cases
This change modifies logics to verify test results that need to parse
events from EVS manager.  Especially, test cases that run multiple
camera clients spawn threads to listen EVS events.

Also, this updates waitForEvent() method to return more precise results.

Bug: 142275664
Test: VtsHalEvsV1_1Target
Change-Id: Ic328217be1e49a3a862facf783a5356ac34ce9ed
Signed-off-by: Changyeon Jo <changyeon@google.com>
2020-01-04 09:56:06 -08:00
Changyeon Jo
56c9b37795 Prerequsite changes for EVS multi-camera support
This change modifies existing methods and data types for upcoming EVS
multi-camera support.
- deliverFrame_1_1() and doneWithFrame_1_1() are modified to take
  multiple buffer descriptors.
- setIntParameter() and getIntParameter() are changed to return multiple
  parameter values.
- Device ID and timestamp fields are added to BufferDesc.
- EvsEvent is renamed as EvsEventDesc and Device Id is added.

Bug: 142275664
Test: VtsHalEvsV1_1TargetTest
Change-Id: I0415b2cb0642d1377f4d23a4e154080a66c81187
Signed-off-by: Changyeon Jo <changyeon@google.com>
2020-01-04 09:56:06 -08:00
Tomasz Wasilczyk
f9e869e277 CAN bus HAL VTS: read interface names from device manifest
Bug: 143635976
Test: VTS
Change-Id: I99dc0de992dff8ffef03572fd38f57f38b7975ab
2020-01-02 14:31:29 -08:00
Kathan Shukla
ce00636ce5 Enable java backend for occupant awareness iface.
This change also enables VNDK libbraries to use occupant awareness NDK.

Test: Build test.
Change-Id: Ib85ca91252b9b96b53d886ad85f723b1d1f6178e
2019-12-26 03:22:55 -08:00
Hao Chen
bae27ff8c1 Merge changes I6686a15d,I6c561d51
* changes:
  Set Timestamp By the Server when the client called 'set'
  Simplify Connector class APIs and hierachy
2019-12-20 18:50:36 +00:00
Hao Chen
0885f9b10a Set Timestamp By the Server when the client called 'set'
Test: Build; unit tests `atest packages/services/Car/tests/vehiclehal_test/src/com/android/car/vehiclehal/test/CarPropertyTest.java`

Bug: b/141493212

Change-Id: I6686a15d6e9fa483d9b361acfe88001b7497b937
2019-12-20 10:48:45 -08:00
Hao Chen
de6835be3e Simplify Connector class APIs and hierachy
Test: Build; unit tests `atest
 packages/services/Car/tests/vehiclehal_test/src/com/android/car/vehiclehal/test/CarPropertyTest.java`

Bug: b/141493212

Change-Id: I6c561d517646760dfff63cb6c6b50c3c5994098a
2019-12-20 10:48:15 -08:00
TreeHugger Robot
00df3442e4 Merge "Migrate CAN bus HAL to nested namespaces" 2019-12-20 18:46:49 +00:00
Tomasz Wasilczyk
55f21936e9 Migrate CAN bus HAL to nested namespaces
Test: it builds
Change-Id: I83d9ef4f1fff1585e6487c95f09b55b1aa5b3e63
2019-12-20 09:20:24 -08:00
Hao Chen
5f82b989bb Merge changes from topic "proto_package_name"
* changes:
  A more generalized package name for VHal proto IDLs
  Protobuf message converter should be a public utility library
2019-12-19 21:30:40 +00:00
Chris Weir
d65c829d30 Merge "Add support for error, RTR, and EFF frames" 2019-12-13 22:47:56 +00:00
chrisweir
bee3d2c3c9 Add support for error, RTR, and EFF frames
Error frames, remote transmission request, and extended format frames
require some changes to the way that we set up our sockets.

Bug: 142655821
Bug: 144774939
Test: manual
Change-Id: I06212cb852d480c1c7093e8c509ca8aa9f85f81f
2019-12-12 14:21:38 -08:00
Zhaoming Yin
497cc64544 Add fuzzer for FormatConvert
Bug: 146086281
Test: Follow go/android-fuzzing to build and test

Change-Id: Id94c57ba1b327cd4af2ae72fb0259953fa941d45
2019-12-12 13:09:57 -08:00
Hao Chen
5deac06ad9 A more generalized package name for VHal proto IDLs
Test: build; test (and submit) with ag/9868729

Change-Id: Iacdf518d8c90485430a009e341dd1fd705b7ee83
2019-12-06 16:01:28 -08:00
Hao Chen
1c1fdca026 Protobuf message converter should be a public utility library
Test: Built, and flashed to Osprey (go/enable-google-vhal-on-osprey)

```
# See value changed in Vehicle HAL tab, KitchenSink app:
$ python packages/services/Car/tools/emulator/prop_event_simulator.py
--property
VEHICLEPROPERTY_HVAC_AC_ON --area 0 --value 1

# unit tests
$ atest android.hardware.automotive.vehicle@2.0-default-impl-unit-tests
```

Change-Id: I3841870614f316f2f0e2f54283674223a0b036f4
2019-12-06 15:58:20 -08:00
TreeHugger Robot
46966c824f Merge "Fix sp<> crash on stack-allocated service object." 2019-12-06 17:55:16 +00:00
Kathan Shukla
d37e5c122a Add VTS tests for Occupant Awareness HIDL.
Test: VTS tests

Change-Id: Ib278986334439d181348800c01332606f9d36a89
2019-12-05 18:31:03 -08:00
Tomasz Wasilczyk
201734e551 Fix sp<> crash on stack-allocated service object.
Bug: 145609858
Test: build, boot
Change-Id: Ia705750c77ee8ba950d19eae9bbd208b0dac2310
2019-12-05 13:54:50 -08:00
Kathan Shukla
56c98e4cf1 Mock hal for Occupant Awareness interface.
Mock hal has limited capability - driver and front passenger presence
detection and driver monitoring detection.

Bug: 142383127
Test: VTS tests
Change-Id: I72e4b443a0d8063288e14333bd9ebbb1f2c19720
2019-12-05 11:19:47 -08:00
Kathan Shukla
88d63ccbd7 Fix spelling of presence in Occupant Awareness.
Test: Build test
Change-Id: I1961c54cafd343acd75fac04535e952000dbdb99
2019-12-04 15:55:15 -08:00
Kathan Shukla
b6261cb2ae Default hal for Occupant Awareness.
Bug: 142383127
Test: Verified that the system starts the default hal automatically.
Change-Id: I851f85bc283165891943b82c6c07f3273847b032
2019-11-26 14:54:35 -08:00
Kathan Shukla
382ed1d65d Occupant Awareness HAL definitions.
Occupant awareness default HAL and VTS tests will be added as part of a
separate commit / CL.

Bug: 142383127
Test: Verified that system starts default hal.
Change-Id: I24e1c52c9873fc4e0fc09db24d0def9a04175120
2019-11-26 14:54:32 -08:00
Keun-young Park
f3b8f482be Merge "Add DISABLED_OPTIONAL_FEATURES property" 2019-11-25 17:58:41 +00:00
Hao Chen
ad1222486d Merge "Add GRPC Server as a Library to VHal Build File" 2019-11-22 22:37:18 +00:00
Hao Chen
744fe1a75b Merge changes Iab77a0ae,Ibf525ffe
* changes:
  Applying the vehicle connector to the VHAL
  Implement the connector for emulated vehicles
2019-11-22 19:03:40 +00:00
Hao Chen
fba3ac86cc Applying the vehicle connector to the VHAL
Make VHAL to use the connector/server interfaces instead of talking to
the (faked) vehicle directly. Use passthrough connector for now since we
have not moved to the virtualized scenario yet (but soon :)

Bug: b/141493212

Test: On both Osprey and Hawk. Build and flash the image. If on Osprey, see
go/enable-google-vhal-on-osprey; if on hawk, `aae app vhal apply google`
to enable Google VHAL

```
# no VHAL crash
$ adb logcat

$ vts-tradefed
> run vts-hal-auto -m VtsHalAutomotiveVehicleV2_0Host
# 30 passed, 2 failed, the same as the result before this patch

# See value changed in Vehicle HAL tab, KitchenSink app:
$ python packages/services/Car/tools/emulator/prop_event_simulator.py --property
VEHICLEPROPERTY_HVAC_AC_ON --area 0 --value 1

# unit tests
$ atest packages/services/Car/tests/vehiclehal_test/src/com/android/car/vehiclehal/test/CarPropertyTest.java
```

Change-Id: Iab77a0ae32db2c55b4c65aa8f3e4f73ec9ef2644
2019-11-21 16:57:31 -08:00