zoukankan      html  css  js  c++  java
  • Examples

    在学习bluetoothctl命令时,执行bluetoothctl,然后执行show,提示No default controller available。

    1. 执行hciconfig,发现有hci0,并且处于UP状态

    2. 执行hcitool lescan,可以进行扫描。

    3. 执行ps -ef|grep blue,有bluetoothd进程

    4. 执行service --status-all | grep blue ,发现有bluetooth service。

    后来发现,bluetoothd进程是系统自带的bluez执行的进程,而我执行的bluetoothctl是自己编译的bluez,难道是因为bluez版本问题?

    解决方法:

    1. 停止bluetoothd

    rfkill block bluetooth
    sudo service bluetooth stop
    rfkill unblock bluetooth

    2. 启动自己编译的bluetoothd

    ./bluetoothd -n -d  &

    然后在执行./bluetoothctl, 就能检测到hci设备了。

  • 相关阅读:
    毕设(五)ListView
    毕设(四)ListBox
    毕设(三)NotifyIcon
    hdu 1.2.3
    ZOJ 1789 The Suspects
    ZOJ 2833 Friendship
    git
    yum wget rpm
    上传绕过
    LAMP 和 LNMP
  • 原文地址:https://www.cnblogs.com/hjj801006/p/12957205.html
Copyright © 2011-2022 走看看