2台のLinuxシステム間でBluetooth PANを設定しようとしています。 2つのRaspberry Pi 3sの間でBlueZ 5.23を実行しています。私はのbluez 4.101を実行している別のLinuxシステムを接続しようとすると、しかし、私はこのエラーを取得:Bluetooth PANを設定しようとすると「接続タイムアウト(100)」が発生する
pand[27746]: Connect to B8:27:EB:6C:CE:26 failed. Connection timed out(110)
私は正常にお互いに話をするために2つのbluez 4.101システムを得ているが、ときに私は一貫してそのエラーで失敗します私のPi3 NAPと話をしてみてください。残念ながら、BlueZの古いバージョンは非常に小さな組み込みシステム上で動作しており、簡単にhcidumpを実行することはできません。しかし、私はPI3に話をするには、2つの異なる試みのためhcidumpの出力を持っている:
これは、別のPI3からの接続に成功した試みであった:
HCI sniffer - Bluetooth packet analyzer ver 5.45 btsnoop version: 1 datalink type: 1002
> HCI Event: Connect Request (0x04) plen 10
bdaddr B8:27:EB:99:1C:22 class 0x000000 type ACL < HCI Command: Accept Connection Request (0x01|0x0009) plen 7
bdaddr B8:27:EB:99:1C:22 role 0x00
Role: Master
> HCI Event: Command Status (0x0f) plen 4
Accept Connection Request (0x01|0x0009) status 0x00 ncmd 1
> HCI Event: Role Change (0x12) plen 8
status 0x00 bdaddr B8:27:EB:99:1C:22 role 0x00
Role: Master
> HCI Event: Connect Complete (0x03) plen 11
status 0x00 handle 12 bdaddr B8:27:EB:99:1C:22 type ACL encrypt 0x00 < HCI Command: Read Remote Supported Features (0x01|0x001b) plen 2
handle 12
> HCI Event: Command Status (0x0f) plen 4
Read Remote Supported Features (0x01|0x001b) status 0x00 ncmd 1
> HCI Event: Read Remote Supported Features (0x0b) plen 11
status 0x00 handle 12
Features: 0xbf 0xfe 0xcf 0xfe 0xdb 0xff 0x7b 0x87 < HCI Command: Read Remote Extended Features (0x01|0x001c) plen 3
handle 12 page 1
> HCI Event: Command Status (0x0f) plen 4
Read Remote Extended Features (0x01|0x001c) status 0x00 ncmd 1
> HCI Event: Read Remote Extended Features (0x23) plen 13
status 0x00 handle 12 page 1 max 2
Features: 0x03 0x00 0x00 0x00 0x00 0x00 0x00 0x00 < HCI Command: Remote Name Request (0x01|0x0019) plen 10
bdaddr B8:27:EB:99:1C:22 mode 2 clkoffset 0x0000 < ACL data: handle 12 flags 0x00 dlen 10
L2CAP(s): Info req: type 2
> HCI Event: Max Slots Change (0x1b) plen 3
handle 12 slots 5
> HCI Event: Command Status (0x0f) plen 4
Remote Name Request (0x01|0x0019) status 0x00 ncmd 1
> ACL data: handle 12 flags 0x02 dlen 10
L2CAP(s): Info req: type 2 < ACL data: handle 12 flags 0x00 dlen 16
L2CAP(s): Info rsp: type 2 result 0
Extended feature mask 0x02b8
Enhanced Retransmission mode
Streaming mode
FCS Option
Fixed Channels
Unicast Connectless Data Reception
> HCI Event: Remote Name Req Complete (0x07) plen 255
status 0x00 bdaddr B8:27:EB:99:1C:22 name 'raspberrypi'
> ACL data: handle 12 flags 0x02 dlen 16
L2CAP(s): Info rsp: type 2 result 0
Extended feature mask 0x02b8
Enhanced Retransmission mode
Streaming mode
FCS Option
Fixed Channels
Unicast Connectless Data Reception < ACL data: handle 12 flags 0x00 dlen 10
L2CAP(s): Info req: type 3
> HCI Event: Number of Completed Packets (0x13) plen 5
handle 12 packets 2
> ACL data: handle 12 flags 0x02 dlen 10
L2CAP(s): Info req: type 3 < ACL data: handle 12 flags 0x00 dlen 20
L2CAP(s): Info rsp: type 3 result 0
Fixed channel list 0x00000006
L2CAP Signalling Channel
L2CAP Connless
> ACL data: handle 12 flags 0x02 dlen 20
L2CAP(s): Info rsp: type 3 result 0
Fixed channel list 0x00000006
L2CAP Signalling Channel
L2CAP Connless
> HCI Event: Number of Completed Packets (0x13) plen 5
handle 12 packets 2
> ACL data: handle 12 flags 0x02 dlen 12
L2CAP(s): Connect req: psm 1 scid 0x0040 < ACL data: handle 12 flags 0x00 dlen 16
L2CAP(s): Connect rsp: dcid 0x0040 scid 0x0040 result 0 status 0
Connection successful < ACL data: handle 12 flags 0x00 dlen 23
L2CAP(s): Config req: dcid 0x0040 flags 0x00 clen 11
RFC 0x00 (Basic)
そして、これは、接続しようとして失敗ですbluez 4.101を実行しているシステムから:
> HCI Event: Connect Request (0x04) plen 10
bdaddr 00:07:80:C0:D8:73 class 0x000000 type ACL
< HCI Command: Accept Connection Request (0x01|0x0009) plen 7
bdaddr 00:07:80:C0:D8:73 role 0x00
Role: Master
> HCI Event: Command Status (0x0f) plen 4
Accept Connection Request (0x01|0x0009) status 0x00 ncmd 1
> HCI Event: Role Change (0x12) plen 8
status 0x00 bdaddr 00:07:80:C0:D8:73 role 0x00
Role: Master
> HCI Event: Connect Complete (0x03) plen 11
status 0x00 handle 11 bdaddr 00:07:80:C0:D8:73 type ACL encrypt 0x00
< HCI Command: Read Remote Supported Features (0x01|0x001b) plen 2
handle 11
> HCI Event: Command Status (0x0f) plen 4
Read Remote Supported Features (0x01|0x001b) status 0x00 ncmd 1
> HCI Event: Read Remote Supported Features (0x0b) plen 11
status 0x00 handle 11
Features: 0xff 0xff 0x8f 0xfe 0xdb 0xff 0x5b 0x87
< HCI Command: Read Remote Extended Features (0x01|0x001c) plen 3
handle 11 page 1
> HCI Event: Command Status (0x0f) plen 4
Read Remote Extended Features (0x01|0x001c) status 0x00 ncmd 1
> HCI Event: Read Remote Extended Features (0x23) plen 13
status 0x00 handle 11 page 1 max 1
Features: 0x01 0x00 0x00 0x00 0x00 0x00 0x00 0x00
< HCI Command: Remote Name Request (0x01|0x0019) plen 10
bdaddr 00:07:80:C0:D8:73 mode 2 clkoffset 0x0000
< ACL data: handle 11 flags 0x00 dlen 10
L2CAP(s): Info req: type 2
> HCI Event: Command Status (0x0f) plen 4
Remote Name Request (0x01|0x0019) status 0x00 ncmd 1
> HCI Event: Max Slots Change (0x1b) plen 3
handle 11 slots 5
> ACL data: handle 11 flags 0x02 dlen 16
L2CAP(s): Info rsp: type 2 result 0
Extended feature mask 0x00b8
Enhanced Retransmission mode
Streaming mode
FCS Option
Fixed Channels
< ACL data: handle 11 flags 0x00 dlen 10
L2CAP(s): Info req: type 3
> HCI Event: Number of Completed Packets (0x13) plen 5
handle 11 packets 2
> ACL data: handle 11 flags 0x02 dlen 20
L2CAP(s): Info rsp: type 3 result 0
Fixed channel list 0x00000002
L2CAP Signalling Channel
> HCI Event: Remote Name Req Complete (0x07) plen 255
status 0x00 bdaddr 00:07:80:C0:D8:73 name 'BT111'
> HCI Event: Disconn Complete (0x05) plen 4
status 0x00 handle 11 reason 0x13
Reason: Remote User Terminated Connection
一切のタイムスタンプが、すべてがかなり早く、それが約30秒間一時停止が起こった非常に終わりDisconn Complete
イベントまではありません。
明らかに、4.101のPANUが何かを待っていますが、私は何がわかるのか分からず、どこを探しているのかわかりません。ダンプで見た唯一の違いは次のとおりです。
- ハンドルは1つで11、もう1つは12です。
- イベント
Read Remote Extended Features
は、別の機能セットを返します。 (0x03の後に0x01の代わりに7バイトが続きます) - L2CAP拡張機能マスクに
Unicast Connectless Data Reception
をサポートしました。
ハンドルが異なっているとは限りません。私は、拡張機能のためのデコーダリングの周りにグーグルでは、私が見ているものにマップされているように思えた何かを見つけることができませんでした。しかし、違いは1ビットです。多分それは魔法のビットです。
また、pi-pi接続でSDPが使用されていて、sdpdが私の小さな組み込みシステムで動作していないことに気付きました。
私がUnicast Connectless Data Reception
に見つけることができる唯一の参考文献は、PTSの提出物です。私は今BT認証に興味がありません。
とにかく、何が起こっているのか、なぜ私の接続が機能していないのかを説明するのに、私はBluetoothの専門家(私はそうではない)が必要なようです。