a285654974
deepin
2019-08-23 06:53 https://bbs.deepin.org/user/1647 https://bbs.deepin.org/user/4892 https://bbs.deepin.org/user/122443 论坛的审核机制是否有问题,我编辑的帖子内容就是上述附件中的文本,提交后提示“抱歉您填写的信息包含不良信息而无法提交”。整个内容没有任何问题啊。
Reply Like 0 View the author
https://bbs.deepin.org/post/182114
@youyou2011 @diyiliaoya @lkzxing 论坛的审核机制是否有问题,我编辑的帖子内容就是上述附件中的文本,提 ...



https://bbs.deepin.org/post/182114
很赞。这个真的有用。我还以为是蓝牙驱动出问题了。
https://bbs.deepin.org/post/182114
不知道是不是你帖子里的各种地址搞的
https://bbs.deepin.org/post/182114
这个都是版本太老惹的祸,自从debian10发布后,9就过时了。
新版本问题得到了改善(20.5), 偶尔卡顿,包括蓝牙鼠标、音箱一起,关闭蓝牙,重新链接可以解决。 但这是权宜之策,不是根本,好在出现次数少
Popular Events
More
Deepin15.11使用下来存在严重的蓝牙问题,主要体现在音频滞后严重,频繁出现卡顿。
本人设备联想Z50笔记本i5-4210U,GeForce 840M,RTL8723BE蓝牙一体无线网卡。
解决方案为使用第三方蓝牙音频codec模块:pulseaudio-modules-bt。
该方法在本人设备上有效,不保证其他平台效果。
具体方法如下:1.升级pulseaudio到12.2
deepin自带的pulseaudio是10.0版本,pulseaudio-modules-bt需要12版本以上
官网:https://www.freedesktop.org/wiki/Software/PulseAudio/
sudo vim /etc/apt/sources.list
将#deb-src的注释去掉
安装编译依赖:
sudo apt install build-essential
sudo apt-get build-dep pulseaudio
下载源码
git clone git://anongit.freedesktop.org/pulseaudio/pulseaudio
检出到12.2
cd pulseaudio && git checkout v12.2
编译
./bootstrap.sh
make
sudo make install
rm -rf ~/.config/pulse/
完成后重启
2.安装cmake
deepin仓库里的cmake是3.9.5版本,编译pulseaudio-modules-bt需要cmake3.11以上版本
官网:https://cmake.org/download/
下载最新版本(截止20190822是3.15.2)
wget https://github.com/Kitware/CMake ... Linux-x86_64.tar.gz
安装到系统
tar -vxpf cmake-3.15.2-Linux-x86_64.tar.gz
sudo cp -r cmake-3.15.2-Linux-x86_64/* /usr/
3.安装ffmpeg(可选,aptX、aptX-HD编码支持)
pulseaudio-modules-bt编译要求ffmpeg大于4.0,deepin自带版本为3.2.12
官网:https://ffmpeg.org/download.html
下载最新版(截止20190822是4.2)
wget https://ffmpeg.org/releases/ffmpeg-4.2.tar.bz2
安装编译依赖:
sudo apt install nasm yasm
编译:
tar -vxf ffmpeg-4.2.tar.bz2
cd ffmpeg-4.2
./configure
make
sudo make install
4.安装fdk-aac(可选,AAC编码支持)
pulseaudio-modules-bt编译要求fdk-aac大于0.1.5,deepin自带版本为0.1.4
官网:https://github.com/mstorsjo/fdk-aac
git clone https://github.com/mstorsjo/fdk-aac.git
cd fdk-aac
git checkout v2.0.0
./autogen.sh
./configure
make
sudo make install
5.安装ldacBT(可选,LDAC编码支持)
pulseaudio-modules-bt编译要求ldacBT或者libldac,deepin仓库中不存在
官网:https://github.com/EHfive/ldacBT
git clone https://github.com/EHfive/ldacBT.git
cd ldacBT
git checkout v2.0.23
git submodule update --init
mkdir build && cd build
cmake -DCMAKE_INSTALL_PREFIX=/usr -DINSTALL_LIBDIR=/usr/lib -DLDAC_SOFT_FLOAT=OFF ..
sudo make DESTDIR=$DEST_DIR install
6.安装pulseaudio-modules-bt
官网:https://github.com/EHfive/pulseaudio-modules-bt
安装编译依赖
sudo apt install libbluetooth-dev libsbc-dev libdbus-1-dev bluez pkg-config libtool
备份原始的pulseaudio bt modules:
MODDIR=`pkg-config --variable=modlibexecdir libpulse`
sudo find $MODDIR -regex ".*\(bluez5\|bluetooth\).*\.so" -exec cp {} {}.bak \;
下载源码:
git clone https://github.com/EHfive/pulseaudio-modules-bt.git
cd pulseaudio-modules-bt
git submodule update --init
编译安装:
git -C pa/ checkout v`pkg-config libpulse --modversion|sed 's/[^0-9.]*\([0-9.]*\).*/\1/'`
mkdir build && cd build
cmake ..
make
sudo make install
加载模块
pulseaudio -k
pulseaudio --start
7.手动选择codec(可选,默认自动选择LDAC > APTX HD > APTX > SBC)
修改/usr/lib/systemd/system/bluetooth.service
[Unit]
Description=Bluetooth service
Documentation=man:bluetoothd(8)
ConditionPathIsDirectory=/sys/class/bluetooth
[Service]
Type=dbus
BusName=org.bluez
ExecStart=/usr/lib/bluetoothd -E
NotifyAccess=main
#WatchdogSec=10
#Restart=on-failure
CapabilityBoundingSet=CAP_NET_ADMIN CAP_NET_BIND_SERVICE
LimitNPROC=1
ProtectHome=true
ProtectSystem=full
[Install]
WantedBy=bluetooth.target
在启动项目后面增加 -E,最终变成:
ExecStart=/usr/lib/bluetooth/bluetoothd -E
重启蓝牙服务
systemctl daemon-reload
systemctl restart bluetooth
使用命令 pactl set-card-profile 切换
或者安装pavucontrol,图形化操作
参考
https://github.com/EHfive/pulseaudio-modules-bt
https://github.com/EHfive/pulseaudio-modules-bt/wiki
https://plumz.me/archives/10518/
https://sparkydogx.github.io/2018/10/29/fix-sound-in-ubuntu/