Justin McLemore

How does CarPlay or Android Auto work?

Created: · Justin McLemore

Inspiration

When I’m driving in vehicle with CarPlay or Android Auto, it connects to wired and wirelessly.

My guess before digging in

That’s not something that the Bluetooth standard can carry, and if I turn off WiFi, I get a message that CarPlay won’t work wirelessly, so that tells me it’s using WiFi in some capacity. I know WiDi from a long time ago.

Findings

  • “Wireless CarPlay works by having the phone exchange network credentials with a supporting CarPlay receiver over Bluetooth, establishing a two-way Wi-Fi connection.” (Source)
  • I couldn’t find anything on the Apple Developer site talking about the underlying technology.
  • The Wi-Fi Alliance has a standard called Wi-Fi Direct
  • The Wi-Fi - Wikipedia article calls this ad hoc WiFi transmission

Etymology

  • ad hoc - when necessary or needed

Follow-up questions

What is a “SoftAP” or “virtual router”?

  • It stands for “software enabled access point”
  • This is software than can use a wifi adapter to act as a wireless access point
  • They’re commonly used in headless applications like setting up IoT devices. The Wikipedia article says that this is complex for the mainstream user, so developers are adding BLE, ZipKey, data-over-sound or other technologies to improve the OOBE
  • This is also how mobile hotspots work. The devices need an alternative source for the internet when the WiFi adapter is being used as an AP

[[What is Bluetooth Low Energy?]]

What is TDLS?

  • Tunneled Direct Link Setup is a way to stream media and data between devices on the same Wi-Fi network without involving the wireless network’s router. TDLS-linked devices benefit from an optimized connection and therefore don’t burden the network as a whole.
  • Google’s Cast protocol used by Chromecast uses TDLS to initiate screen mirroring.

These posts and spreadsheets are free to use, tweak, and make your own. I built them to organize my own chaos and figured they might help someone else too.

If you find value in them and want to support the time I spend creating and updating these resources, feel free to buy me a tea. It helps fuel the next round of nerdery.
Buy me a tea