Created
January 8, 2018 01:02
-
-
Save willwhui/98b3595ab5a2b15cf55f260e615829f9 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
为hass添加独立的喇叭作为media_player |
调整音量
不知为何声音太小,这里有通过hass配置声音的办法:
https://home-assistant.io/components/media_player/
- service: media_player.volume_set
entity_id: media_player.speaker_1
data:
volume_level: 1.0
然而并不能增大音量。
在树莓派命令行输入命令:
alsamixer
然后在控制台按方向键增大减少音量。
于是可以了。
hass配置文件中的音量控制可以去掉了。
但是我的几个小喇叭,在没有播放音频的时候都有电流噪音,不好。
如果能像google home那样安静就好了
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
首先安装 vlc-nox,就是vlc的no x window版本:
然后连好音频线。
参照这里: https://www.raspberrypi.org/documentation/configuration/audio-config.md
将音频输出强制指向耳机:
运行:
根据文章指引进行设置。
估计等效于此命令:
然后根据 https://home-assistant.io/components/media_player.vlc/ 进行配置
即,只需要在配置文件(configuration.yaml)中新增以下内容即可
根据文章所述,还需要将homeassistant用户添加到audio group: