Through a new product named trout
, Android Automotive (AAOS) now provides support
for deployment as a guest virtual machine (VM) in environments compatible with the
VirtIO
standard. trout
is based on the
Cuttlefish
virtual reference platform and is available as the trout
device configuration. The
userspace source code can be found at device/google/trout
. The table
below describes the technology used to virtualize each of the subsystems in trout
.
Feature | Technology |
---|---|
Audio Control HAL | vsock/gRPC |
Audio HAL | virtio-snd |
Bluetooth | virtio-console |
Dumpstate HAL | vsock/gRPC |
Extended View System (EVS) | virtio-video |
Garage mode | vsock/gRPC |
Graphics | virtio-gpu |
Global navigation satellite system (GNSS) | virtio-console |
Sensor HAL 2.0 | virtio-scmi and IIO |
Touchscreen input | virtio-input |
Vehicle HAL | vsock/gRPC |
Extending trout
trout
can be used as a starting point to create new In-Vehicle Infotainment (IVI)
Android targets. The build infrastructure is designed to be extended and customized.
For example:
# Inherit trout-arm64 default values and settings $(call inherit-product, device/google/trout/aosp_trout_arm64.mk) # Customize HALs as needed LOCAL_VHAL_PRODUCT_PACKAGE := vendor.oem.vhal@2.0-service LOCAL_AUDIO_PRODUCT_PACKAGE := vendor.oem.audio@6.0-impl # Configure SELinux policy BOARD_SEPOLICY_DIRS += device/oem/car/sepolicy/vendor/oem # Configure properties LOCAL_DUMPSTATE_PROPERTIES := \ ro.vendor.dumpstate.server.cid=22 \ ro.vendor.dumpstate.server.port=406 \ ro.vendor.helpersystem.log_loc=/data/dumpstate [... and more as needed ...]
Several Android HALs can be individually replaced with custom implementations, or the
default implementations maintained but certain configuration parameters adjusted to establish
proper inter-VM communication in the target environment. These HALs (including Vehicle HAL,
Audio Control HAL, and Dumpstate HAL) are implemented by means of a gRPC interface backed by a
vsock
connection between the AAOS guest and a host system providing the
underlying feature implementation. These must be configured by means of supplying the proper
vsock
connection parameters as vendor properties.
Building trout
Compile the userspace
To compile the userspace:
- Download the Android source tree:
repo init -u https://android.googlesource.com/platform/manifest -b master repo sync -j8
- Build the environment:
source build/envsetup.sh lunch aosp_trout_arm64-userdebug make -j24
Building the kernel
For trout
1.0, the kernel codebase is provided in AOSP. The trout
kernel is composed of the same
code as the upstream ACK 5.10, with the addition of trout
-specific modules for VirtIO subsystems.
- To clone the kernel, run:
repo init https://android.googlesource.com/kernel/manifest -b trout-android12-5.10 && repo sync
- To build the kernel for the OpenSynergy environment, run:
BUILD_CONFIG=common-modules/virtual-device/build.config.trout.coqos build/build.sh
Compliance
When AAOS runs as a guest VM, our goal is to be a compatible Android deployment from the
framework perspective. Host side issues are the purview of each implementation and outside the
scope of trout
1.0.
In trout
1.0, several CTS issues remain. The following CTS modules are known to include test
failures:
CtsStagedInstallHostTestCases CtsRollbackManagerHostTestCases CtsVideoTestCases CtsHostsideNetworkTests CtsActivityManagerBackgroundActivityTestCases CtsAdbHostTestCases CtsNativeHardwareTestCases CtsContentTestCases CtsCarHostTestCases CtsOsTestCases CtsStatsdHostTestCases CtsVoiceInteractionTestCases CtsViewTestCases CtsCameraTestCases CtsLocationGnssTestCases CtsGraphicsTestCases CtsIncidentHostTestCases CtsInstallHostTestCases CtsNativeVerifiedBootTestCases CtsNetTestCases |
CtsWindowManagerDeviceTestCases CtsMediaStressTestCases CtsAppTestCases CtsUsbTests CtsAutoFillServiceTestCases CtsDisplayTestCases CtsMediaTestCases CtsDeqpTestCases CtsDumpsysHostTestCases CtsOpenGLTestCasesCtsLibcoreTestCases CtsSecurityHostTestCases CtsInputMethodTestCases CtsStatsdAtomHostTestCases CtsPermission4TestCases CtsNNAPIBenchmarkTestCases CtsSimpleperfTestCases CtsAccessibilityTestCases CtsAppSecurityHostTestCases CtsKeystoreTestCases |
The following CTS-V areas are known to include test failures:
Car Launcher test Bluetooth Low Energy (BLE) Advertiser test Streaming Video Quality Verifier Bluetooth HID Device test Hifi Ultrasound Microphone test Hifi Ultrasound Speaker test |
Unlocked Device Required test Dynamic Sensor Discovery test Off Body Sensor test Significant Motion test Audio Output Routing Notification test Network Request or Suggestion test |
Release notes
trout
1.0 contains the following known issues:
- User builds of
trout
are not available. The system is built as-userdebug
, which may affect some CTS tests. - Access to TrustZone for Android is not supported in
trout
1.0. - Android Verified Boot (AVB) is not supported.
- Neural accelerators are not exposed to NNAPI in
trout
1.0. - Wi-Fi virtualization is not available, with some implementations offering limited support for a `virtio-net` tunnel.
- In some cases, the transfer of large files from or to Android through the Android Debug Bridge (ADB) may cause the system to hang.
- In some instances, the SMS app may stop synchronizing with a paired Bluetooth phone.
- A VHAL event injection may not work for some sensors.
- The ADB serial of the underlying SoC is not forwarded to Android as the guest’s ADB serial.
- In some implementations, Ethernet may not be available to the host for network connectivity.
For additional details, refer to the partner release notes for your specific deployment of
trout
.