Bluetooth 如何在不拔下USB/重新启动的情况下在linux上重置蓝牙适配器?

Bluetooth 如何在不拔下USB/重新启动的情况下在linux上重置蓝牙适配器?,bluetooth,raspberry-pi,raspberry-pi4,Bluetooth,Raspberry Pi,Raspberry Pi4,如何在RaspberryPi v4上重置蓝牙适配器? 重置将重置大部分设置,但不是所有设置。 示例名称未更改 pi@raspberrypi:~/ $ sudo hciconfig hci0 name hci0: Type: Primary Bus: UART BD Address: DC:A6:32:02:12:1B ACL MTU: 1021:8 SCO MTU: 64:1 Name: 'raspberrypi' pi@raspberrypi:~/ $

如何在RaspberryPi v4上重置蓝牙适配器? 重置将重置大部分设置,但不是所有设置。 示例名称未更改

pi@raspberrypi:~/ $ sudo hciconfig hci0 name
hci0:   Type: Primary  Bus: UART
        BD Address: DC:A6:32:02:12:1B  ACL MTU: 1021:8  SCO MTU: 64:1
        Name: 'raspberrypi'
pi@raspberrypi:~/ $ sudo hciconfig hci0 name rpi
pi@raspberrypi:~/ $ sudo hciconfig hci0 reset
pi@raspberrypi:~/$ sudo hciconfig hci0 name
hci0:   Type: Primary  Bus: UART
        BD Address: DC:A6:32:02:12:1B  ACL MTU: 1021:8  SCO MTU: 64:1
        Name: 'rpi'

预期名称将从“rpi”更改回“raspberrypi”

您还必须结合适配器重置服务:

sudo hciconfig hci0 reset
sudo invoke-rc.d bluetooth restart