A bunch of scripts and configs that allows streaming audio via bluetooth to a fake ipod device.
Useful if your car only supports Apple devices for some reason (why Fiat and Alfa, why).
Tested on:
- Raspberry Pi Zero W (Raspbian Stretch Lite 2018-11-13)
- You have a device (e.g. a car) that supports playing music from an iPhone/iPod etc. over USB. You want to play music from something else (e.g. an Android phone) over bluetooth.
- OS: Raspbian Stretch Lite
cd install_files
GOOS=linux GOARCH=arm GOARM=6 go build github.com/oandrew/ipod/cmd/ipod
- add
dtoverlay=dwc2
to the end of /boot/config.txt to enable USB gadget mode - compile the kernel modules (ipod-gadget directory) and put the .ko files in install_files
- copy the pipod directory to the Pi
- run
sudo ./install.sh
- enable auto login so that Pulseaudio can start automatically
- edit the file
a2dp-autoconnect
. Replace theNAME
variable with your bluetooth device's MAC address. Also make sure that if you runpactl list sources short
, the value of$PA_SINK
shows up in the output. - Pair and trust your bluetooth device
- Reboot, connect everything (USB to car; manually connect phone via bluetooth) and test!
- Figure out how to get the Pi to automatically connect to the bluetooth device (currently you have to manually connect from the device)
- Use DKMS to auto-build and install kernel modules
- Investigate Pulseaudio 11 which can maybe bypass resampling