Bluetoothctl set passkey

后端 未结 5 683
北荒
北荒 2021-02-05 12:39

I have a Raspberry Pi 2 running Raspbian kernel 4.1.15 and Bluez version 5.23.

I want to be able to connect a device (like an Android phone) to the rapsberry which shoul

5条回答
  •  借酒劲吻你
    2021-02-05 13:32

    First you have to configurate sspmode 0, for pin request: hciconfig hci0 sspmode 0

    And using bt-agent aplicattion (you can run as deamon too):

    bt-agent -c NoInputNoOutput -p /root/bluethooth.cfg
    

    Edit the file configuration, you can put tha mac address and the pin: For example:

    XX:XX:XX:XX:XX:XX 1234
    

    Or if you want a pin to all the device the same pin code, for example 1234, edit the file like this: * 1234

    This work for me!

提交回复
热议问题