今天,突然想折腾一下linux的蓝牙,于是将我放置已久的蓝牙模块插到了USB上
[root@localhost ~]# lsusb
Bus 002 Device 002: ID 0bda:2838 Realtek Semiconductor Corp. RTL2838 DVB-T
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 006 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 005 Device 002: ID 0a12:0001 Cambridge Silicon Radio, Ltd Bluetooth Dongle (HCI mode)
Bus 005 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
当我参照网上的教程使用lsusb查看usb设备时,发现系统已经识别到蓝牙模块了,但是紧接着按照教程上的方法使用hciconfig -a
时就出现了问题,系统输出找不到命令。
[root@localhost ~]# hciconfig -a
-bash: hciconfig: 未找到命令
于是我找了很多,大部分都为驱动未安装,于是我找到了一个帖子:--这个帖子--
使用命令yum install bluez
将所谓的驱动安装好了
在执行完安装后,再次使用hciconfig -a
发现问题解决!
[root@localhost ~]# hciconfig -a
hci0: Type: Primary Bus: USB
BD Address: xx:xx:xx:xx:xx:xx ACL MTU: 310:10 SCO MTU: 64:8
DOWN
RX bytes:574 acl:0 sco:0 events:30 errors:0
TX bytes:368 acl:0 sco:0 commands:30 errors:0
Features: 0xff 0xff 0x8f 0xfe 0xdb 0xff 0x5b 0x87
Packet type: DM1 DM3 DM5 DH1 DH3 DH5 HV1 HV2 HV3
Link policy: RSWITCH HOLD SNIFF PARK
Link mode: SLAVE ACCEPT
这里不能写小纸条呢~