Science and technology

How to hack Android Auto to show customized content material

Google’s Android Auto utility casts content material from a smartphone to a automobile’s head unit show. Officially, that content material consists of navigation (e.g., Google Maps and Waze), media gamers (e.g., VLC, Spotify), and messaging apps. The utility is helpful, however it will be even higher in the event you might present a movie in your head unit’s show or use it as an interface to a customized onboard pc that manages a number of cameras, GPS, and so forth.

This article will reveal Android Auto Client-Server (AACS), an early-stage utility I am growing to do these duties.

How to hack Android Auto

There are two approaches for displaying different content material on the pinnacle unit’s display: you may hack the Android Auto utility, or you may reimplement the protocol from scratch. The first method appears less complicated however is considerably dangerous: it could use Google’s mental property and subsequently be topic to authorized motion, and it could break with new Android Auto variations (particularly since Google actively works to make that occur).

Therefore, reimplementing the protocol from scratch is the safer method for the long term. One such implementation of the Android Auto protocol is OpenAuto, a head unit emulator by Michal Szwaj. However, this text makes use of the opposite aspect of the communication interface—the cellular system aspect of the protocol.

Android Auto Client-Server (AACS)

AACS presently consists of three core modules and one exterior module that run on ODROID N2, an ARM-based single-board pc:

  1. AAServer is an implementation of Android Auto Protocol (AAP) that communicates with the automobile’s head unit. It handles encrypted AAP-over-USB communication and exposes it over a Unix socket to be used by different modules.
  2. AAClient is an AAP implementation that communicates with a cellphone which may be linked to ODROID N2 and forwards all visitors to AAServer. By utilizing AAClient, you don’t want to decide on whether or not to attach your cellular or ODROID N2—you may join each concurrently.
  3. AAVideoSink is a GStreamer sink that sends video from a GStreamer Gst pipeline to AAServer. Combined with different Gst parts (akin to ximagesrc), it means that you can solid any utility to your automobile’s head unit.
  4. GetOccasions is an utility that connects to AAServer and forwards contact occasions from the automobile’s head unit contact display to the chosen utility window utilizing X Server’s XTest extension.

Try it out

To attempt AACS, you want the next :

  1. An ODROID N2 with energy provide
  2. An SD card (16GB must be sufficient to begin; 32GB is really useful) with a USB SD card reader
  3. A USB Type-A to Micro USB cable
  4. A cigarette lighter plug to 2.1/5.5mm plug cable (to energy the ODROID within the automobile)
  5. A GPS USB receiver (I’ve examined the u-blox 7); this isn’t required to check AACS, nevertheless it’s helpful

Once you will have the :

  1. Grab the latest AACS release.
  2. Concatenate the information, unpack them, and replica the outcomes to an SD card:

    $ cat
    aacs_image_20201029.img.xz.aa
    aacs_image_20201029.img.xz.ab
    aacs_image_20201029.img.xz.ac
    aacs_image_20201029.img.xz.advert |
    unxz | dd of=/dev/sdX bs=1M

  3. Move the cardboard to the ODROID N2. Make certain the ODROID is linked to the net by Ethernet and switch it on.
  4. Get the ODROID’s IP tackle and connect with it by Virtual Network Computing. The password is odroid.
  5. You ought to see the OsmAnd begin display. Download applicable maps and different information, then flip off the ODROID.
  6. Go to your automobile, change the automobile’s date to someplace between July three, 2014, and April 6, 2020 (these are the certificates validity dates).
  7. Connect USB and energy to your ODROID. Try connecting to the ODROID from the pinnacle unit with Android Auto. After roughly 30 seconds, you will notice a management video on the pinnacle unit, and some minutes extra, you will notice navigation (OsmAnd).

Development standing

Please bear in mind that this isn’t production-quality software program but. It is nearer to a proof of idea, so I want to invite others to take part in its growth.

Currently, the software program has the next limitations:

  1. It was examined on just one head unit—an LG unit in a 2019 SEAT Ateca—and must be examined AACS with different head models.
  2. The solely utility that’s accessible out of the field is OsmAnd operating on Anbox. It can be nice to produce other functions accessible on AACS for issues akin to managing cameras (recording, street signal recognition), cellphone name help (a number of telephones linked over Bluetooth), paid car parking zone functions, and so on.
  3. It was examined solely on ODROID N2. If you port it to different single-board computer systems, please submit patches.
  4. It helps solely enter and video channels. It can be nice to have help for audio, voice enter, and different channels.

If the undertaking appears to be like fascinating to you, join me on Github to submit concepts, patches, report points, or assist promote the undertaking.

Most Popular

To Top