Edison Kitのbluetooth有効化
Posted on: 2014-12-23 /
Categories: Edison Kit for Arduino
1. パッケージのインストール
1 |
# opkg install bluez5-dev |
2. OS設定変更
Edisonのbluetoothを有効にします。
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 |
# rfkill unblock bluetooth # hciconfig hci0 up # systemctl enable bluetooth # bluetoothctl [NEW] Controller XX:XX:XX:XX:XX:XX BlueZ 5.18 [default] [bluetooth]# power on Changing power on succeeded [bluetooth]# devices [bluetooth]# scan on Discovery started [CHG] Controller XX:XX:XX:XX:XX:XX Discovering: yes [bluetooth]# exit |
またbluetooth機器と接続する場合には下記のコマンドも使用できます。
1 2 3 4 5 |
[bluetooth]# scan on [bluetooth]# agent on <span style="line-height:1.5;">[bluetooth]# pair </span>[bluetooth]# trust [bluetooth]# connect |
周辺のbluetooth機器をスキャンするには下記のコマンドを使用します。
1 2 3 |
# hcitool lescan # hcitool scan |