Closed sebastienroy closed 4 years ago
First, following https://www.sigmdel.ca/michel/ha/rpi/bluetooth_02_fr.html and https://scribles.net/updating-bluez-on-raspberry-pi-5-43-to-5-48/ I've updated the bluez library to 5.54 The initial version was 5.50
This article is more recent: https://scribles.net/streaming-bluetooth-audio-from-phone-to-raspberry-pi-using-alsa/ And the result is OK! I succeed in playing music on the raspberry from the phone. I have now to be able to modify the volume and to integrate the command lines in the radio code.
In order to send commands to the bluetoothctl service:
echo -e "discoverable on" | bluetoothctl
Interesting documentation: https://www.linux-magazine.com/Issues/2017/197/Command-Line-bluetoothctl https://docs.ubuntu.com/core/en/stacks/bluetooth/bluez/docs/ https://git.kernel.org/pub/scm/bluetooth/bluez.git/tree/doc/agent-api.txt https://www.kynetics.com/docs/2018/pairing_agents_bluez/#simple-agent
This is the page of a bluetooth daemon : https://github.com/lukasjapan/bt-speaker
Automatically accept bluetooth pairing :
https://raspberrypi.stackexchange.com/questions/50496/automatically-accept-bluetooth-pairings
It would be nice if the radio could behave as a bluetooth device when the it is switched off. So that, it could be used to listen to podcasts for instance.
Interesting resources on bluetooth can be found there : https://www.sigmdel.ca/michel/ha/rpi/bluetooth_02_fr.html And following : https://www.sigmdel.ca/michel/ha/rpi/bluetooth_02_fr.html https://gist.github.com/mill1000/74c7473ee3b4a5b13f6325e9994ff84c