通过树莓派Raspberry Pi 3B+板载蓝牙自带bluealsa连接蓝牙音箱接入Home Assistnant
I have a bluetooth speaker and I want to use it as media player. I have a Raspberry Server with Debian and Home Assistnant core in host mode.
How could I configure it?
在树莓派上要让 Home Assistant 发声朗读 ,从
硬件
软件
硬件连接
首先你要把可以播放声音的设备连接到树莓派上。使用有源音箱或者无源的耳机都可以。我使用的是耳塞,连接到树莓派的3.5mm音频输出接口上,如下图所示:
http://www.codelast.com/wp-content/uploads/2016/12/raspberry_pi_3.5mm_audio.png
Prerequisites
A bluetooth speaker
https://blog.csdn.net/weixin_45820944/article/details/104236412
https://jasiek.me/2014/10/04/bluetooth-console-on-a-raspberry-pi-using-a-usb-adapter.html
While playing with my Raspberry PI, I looked at different networking options available – Ethernet is great, if your house is already cabled, Wi-Fi is great if it isn’t (but on the other hand, not all adapters work reliably and they pull a lot of power, and generate a bit of heat).
sudo bluetoothctl
pair 9A:07:65:B4:21:EC
trust 9A:07:65:B4:21:EC
connect 9A:07:65:B4:21:EC
select 9A:07:65:B4:21:EC
exit
树莓派3B+连接蓝牙音箱
systemctl status bluetooth
sudo systemctl restart bluetooth
systemctl status bluealsa
sudo systemctl restart bluealsa
other
useful links
案列:基于树莓派bluealsa的连接天猫精灵蓝牙音箱,在多块TF卡测试安装过,已连接天猫精灵稳定使用数月,未遇爆音、丢音、失声。
https://bbs.hassbian.com/thread-5375-1-1.html
https://bbs.hassbian.com/thread-5375-1-1.html
I have a bluetooth speaker and I want to use it as media player. I have a Raspberry Server with Debian and Home Assistnant core in host mode.
How could I configure it?
在树莓派上要让 Home Assistant 发声朗读 ,从
硬件
我们需要 3.5mm插口音箱(耳机)或usb口音箱(耳机)、hdmi 显示器、蓝牙音箱。
软件
我们需要一个媒体播放器以及 tts ( 将文字转化为语音的服务 )。
硬件连接
首先你要把可以播放声音的设备连接到树莓派上。使用有源音箱或者无源的耳机都可以。我使用的是耳塞,连接到树莓派的3.5mm音频输出接口上,如下图所示:
http://www.codelast.com/wp-content/uploads/2016/12/raspberry_pi_3.5mm_audio.png
Prerequisites
A bluetooth speaker
https://blog.csdn.net/weixin_45820944/article/details/104236412
https://jasiek.me/2014/10/04/bluetooth-console-on-a-raspberry-pi-using-a-usb-adapter.html
While playing with my Raspberry PI, I looked at different networking options available – Ethernet is great, if your house is already cabled, Wi-Fi is great if it isn’t (but on the other hand, not all adapters work reliably and they pull a lot of power, and generate a bit of heat).
sudo bluetoothctl
pair 9A:07:65:B4:21:EC
trust 9A:07:65:B4:21:EC
connect 9A:07:65:B4:21:EC
select 9A:07:65:B4:21:EC
exit
树莓派3B+连接蓝牙音箱
bluetoothctl // 蓝牙配置工具
power on // 开启蓝牙
agent on // 开启客户端
scan on // 开启扫描和发现
pair XX:XX:XX:XX:XX // 配对发现的设备
connect XX:XX:XX:XX:XX // 连接蓝牙设备
trust XX:XX:XX:XX:XX //信任设备,下次自动连接
info XX:XX:XX:XX:XX //显示已连接的设备信息
systemctl status bluetooth
sudo systemctl restart bluetooth
systemctl status bluealsa
sudo systemctl restart bluealsa
other
sudo apt-get install bluealsa
useful links
案列:基于树莓派bluealsa的连接天猫精灵蓝牙音箱,在多块TF卡测试安装过,已连接天猫精灵稳定使用数月,未遇爆音、丢音、失声。
https://bbs.hassbian.com/thread-5375-1-1.html
https://bbs.hassbian.com/thread-5375-1-1.html
0