手機做爲藍牙音頻源鏈接到Linux時,如何經過音量鍵調節傳入的音量大小

背景一:
咱們知道,把手機做爲音頻源經過藍牙鏈接到電腦,就能夠把手機的聲音轉移到電腦上。
背景二:
我喜歡帶着耳機用個人Linux本刷youtube,也喜歡用個人iPhone聽音樂。爲了同時作這兩件事,我常用背景一提到的方法。

可是我發現一個問題:
手機藍牙傳入的音量始終是固定的,不能經過手機的音量鍵控制。並且聲音每每太大,蓋過了電腦視頻的音量。ios

如何解決這個問題呢?
很簡單:運行 bluetoothd 的時候加上 --plugin=a2dp 的參數。git

具體步驟以下:github

sudo vim /lib/systemd/system/bluetooth.service

append --plugin=a2dp to the following lineubuntu

ExecStart=/usr/lib/bluetooth/bluetoothd

Then it will looks like this:vim

ExecStart=/usr/lib/bluetooth/bluetoothd --plugin=a2dp --compat

for Debian / Raspbian Stretch users, maybe you'll also need to add --noplugin=sap:bash

ExecStart=/usr/lib/bluetooth/bluetoothd --plugin=a2dp --compat --noplugin=sap

Then:app

sudo systemctl daemon-reload
sudo systemctl restart bluetooth

Now you're able to control the music volume passed into your laptop using the volume buttons of your iPhone.this

https://askubuntu.com/questions/997553/ubuntu-18-04-17-10-pulseaudio-bluetooth-ios-volume-control
https://github.com/hadess/CHIP-bluetooth-speaker/issues/83d

相關文章
相關標籤/搜索