Armadilloフォーラム

Armadillo-840でBlueZの組込み

tariga

2016年4月25日 11時59分

tarigaです
いつもお世話になっています。

現在、Armadillo-840を購入して、色々、触っております。
そこで、Blutooth USB接続で通信をさせる必要があり、現在、BlueZを組込もうとしております。

しかし、
https://users.atmark-techno.com/blog/750/774
などのブログを参考に組込みを行ってみましたが、組込みがうまく行きません。

根本的に組込み方法が間違っていると思われ、Armadillo-840で最新のカーネル、Atmark Distを
使った場合の組込み方法をご存知の方がいれば、アドバイス頂けませんでしょうか?

よろしくお願いいたします。

コメント

otsuka

2016年4月25日 12時23分

大塚と申します。

> 現在、Armadillo-840を購入して、色々、触っております。
> そこで、Blutooth USB接続で通信をさせる必要があり、現在、BlueZを組込もうとしております。
>
> しかし、
> https://users.atmark-techno.com/blog/750/774
> などのブログを参考に組込みを行ってみましたが、組込みがうまく行きません。

こちらの記事のあとに kernel 3.14 前提の以下の記事を
アットマークテクノさんが公開してくださっています。

Armadillo-IoTで最新のbluezを使ってみる
https://users.atmark-techno.com/blog/750/1552

こちらの記事を参考になさって再度試されてみてはいかがでしょうか。

tariga

2016年4月25日 15時57分

tarigaです。
お世話になっております。

> Armadillo-IoTで最新のbluezを使ってみる
> https://users.atmark-techno.com/blog/750/1552

さっそくですが、ご回答ありがとうございます。
Armadillo-IoTでの記事があったのですね。
気が付きませんでした。

記事の通りに組込んで動作することを確認しました。
ありがとうございました。

以上です。

tariga

2016年4月26日 19時16分

tarigaです。
お世話になっております。

昨日、ご指摘頂いた内容でbluezの組込みが行えて、実際にUSBドングルを差し込みSPPで、スマホとの通信をさせようと考えております。

USBアダプタ:BT-Micro4
https://www.planex.co.jp/products/bt-micro4/

hciconfigコマンド等を使って認識はできており、ペアリングを行おうとすると以下のようにエラーとなってしまいます。
bluetoothでの組込み初めてのため、ネットでの情報を集めながら確認をしておりますが、どうしてもペアリングがうまくいかない状況です。
ペアリングの仕方で問題があるのかどうか、ご教授頂けませんでしょうか?

[root@armadillo840-0 (ttySC2) ~]# bluetoothctl
[NEW] Controller 00:1B:DC:05:3D:03 BlueZ 5.39 [default]
[bluetooth]# power on
Changing power on succeeded
[CHG] Controller 00:1B:DC:05:3D:03 Powered: yes
[bluetooth]# agent on
Agent registered
[bluetooth]# default-agent
Default agent request successful
[bluetooth]# pariable on
Invalid command
[bluetooth]# pairable on
Changing pairable on succeeded
[bluetooth]# scan on
Discovery started
[CHG] Controller 00:1B:DC:05:3D:03 Discovering: yes
[NEW] Device 4C:BB:58:1C:09:2A TEST
[CHG] Device 4C:BB:58:1C:09:2A RSSI: -64
[CHG] Device 4C:BB:58:1C:09:2A RSSI: -55
[CHG] Device 4C:BB:58:1C:09:2A RSSI: -67
[CHG] Device 4C:BB:58:1C:09:2A RSSI: -54
[CHG] Device 4C:BB:58:1C:09:2A RSSI: -77
[CHG] Device 4C:BB:58:1C:09:2A RSSI: -59
[NEW] Device 68:76:4F:A1:FE:3C Xperia Z1 f
[bluetooth]# scan off
[CHG] Device 68:76:4F:A1:FE:3C RSSI is nil
[CHG] Device 4C:BB:58:1C:09:2A RSSI is nil
Discovery stopped
[CHG] Controller 00:1B:DC:05:3D:03 Discovering: no
[bluetooth]# pair 68:76:4F:A1:FE:3C
Attempting to pair with 68:76:4F:A1:FE:3C
[CHG] Device 68:76:4F:A1:FE:3C Class: 0x5a020c
[CHG] Device 68:76:4F:A1:FE:3C Icon: phone
[CHG] Device 68:76:4F:A1:FE:3C Connected: yes
Failed to pair: org.bluez.Error.AuthenticationCanceled
[CHG] Device 68:76:4F:A1:FE:3C Connected: no
[DEL] Device 4C:BB:58:1C:09:2A TEST
Failed to pair: org.bluez.Error.AuthenticationCanceled

以上です。