Getting Started with Android Automotive OS Development
An introduction to building apps and system features for Android Automotive OS, based on my experience working with major OEMs.
Android Automotive OS (AAOS) is fundamentally different from regular Android development. When I first started working with it, the learning curve was steep, but incredibly rewarding.
What Makes AAOS Different?
Unlike Android Auto, which runs on your phone and mirrors to the car display, AAOS is the actual operating system running in the vehicle. This means:
- Direct hardware access: You’re working with the car’s actual systems
- Strict safety requirements: Anything that could distract the driver is heavily restricted
- Long-term support: Cars are on the road for 10+ years
Key Concepts
Car API
The Car API provides access to vehicle-specific features. Here’s a simple example of accessing vehicle speed:
val carPropertyManager = car.getCarManager(Car.PROPERTY_SERVICE) as CarPropertyManager
val speed = carPropertyManager.getFloatProperty(VehiclePropertyIds.PERF_VEHICLE_SPEED, 0)
Driver Distraction Optimization
One of the biggest considerations is ensuring your app doesn’t distract the driver. AAOS provides the CarUxRestrictionsManager to help:
carUxRestrictionsManager.registerListener { restrictions ->
if (restrictions.isRequiresDistractionOptimization) {
// Simplify UI, disable certain features
}
}
Getting Your Environment Set Up
- Download the Android Automotive system image from SDK Manager
- Set up the automotive emulator
- Familiarize yourself with the Car library APIs
The automotive emulator is surprisingly capable and lets you simulate various vehicle states.
Next Steps
In future posts, I’ll dive deeper into specific topics like integrating with the vehicle CAN bus, building custom system apps, and optimizing for the unique constraints of in-vehicle systems.