BLE - multiple connections
Hi all,
Since im new to bluetooth low energy technology , i need some guidance from you . Following are the issues that im searching for a solution
1 : Is it possible to establish mutiple LE connection at a time . Im using fedora 13 , linux 2.6.39 version with 4.0 LE supported dongles
2: now im not concentrating on user profiles like GATT and ATT . i wanted to do it using HCI and L2cap connections
Thanks and Regards
Hi Ajay,
Quoted 7 lines · Ajay KV
Hi all,
Since im new to bluetooth low energy technology , i need some guidance from you . Following are the issues that im searching for a solution
Quoted 5 lines
1 : Is it possible to establish mutiple LE connection at a time . Im using fedora 13 , linux 2.6.39 version with 4.0 LE supported dongles
2: now im not concentrating on user profiles like GATT and ATT . i wanted to do it using HCI and L2cap connections
You are able to establish one LE connection at a time. If you have more than one device you want to connect to, you can use whitelist. Add the devices to whitelist and issue the LE connection command. As soon as one of the devices starts advertising, the connection will be established.
You can use hcitool to add devices to whitelist and issue LE connection command.
BR,
Andre
Hi,
So that means at a time i can not able to establish two LE
active connections. One more task i wanna try is to send L2cap data packets through L2cap signalling channel (cid 0x05) . But as per my knowledge kernel has designed it to work only on cid 0x05
Quoted 30 lines · Andre Guedes
Hi Ajay,
Quoted 6 lines · Ajay KV
Hi all,
Since im new to bluetooth low energy technology , i need some guidance from you . Following are the issues that im searching for a solution
Quoted 6 lines
1 : Is it possible to establish mutiple LE connection at a time . Im using fedora 13 , linux 2.6.39 version with 4.0 LE supported dongles
2: now im not concentrating on user profiles like GATT and ATT . i wanted to do it using HCI and L2cap connections
You are able to establish one LE connection at a time. If you have more than one device you want to connect to, you can use whitelist. Add the devices to whitelist and issue the LE connection command. As soon as one of the devices starts advertising, the connection will be established.
You can use hcitool to add devices to whitelist and issue LE connection command.
BR,
Andre
Quoted 39 lines · Ajay KV
Hi,
So that means at a time i can not able to establish two LE
active connections. One more task i wanna try is to send L2cap
data packets through L2cap signalling channel (cid0x05) . But as per my knowledge kernel has designed it to work only on cid0x05Quoted 30 lines · Andre Guedes
Hi Ajay,
Quoted 7 lines · Ajay KV
Hi all,
Since im new to bluetooth low energy technology , i need some guidance from
you . Following are the issues that im searching for a solutionQuoted 7 lines
1 : Is it possible to establish mutiple LE connection at a time . Im using
fedora 13 , linux 2.6.39 version with 4.0 LE supported dongles2: now im not concentrating on user profiles like GATT and ATT . i wanted to
do it using HCI and L2cap connectionsYou are able to establish one LE connection at a time. If you have more than one device you want to connect to, you can use whitelist. Add the devices to whitelist and issue the LE connection command. As soon as one of the devices starts advertising, the connection will be established.
You can use hcitool to add devices to whitelist and issue LE connection command.
BR,
Quoted 8 lines
Quoted 2 lines
Andre
--
To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
As Andre said - you can not create multiple connections at the same time, but you can have multiple active connections at the same time. The only limitation is during the connection creation procedure. After an LE connection has been established to device A, you can create a second LE connection to device B.
BR,
Chen Ganir
Texas Instruments.
Hi,
Quoted 10 lines · Ajay KV
1: suppose device A and B is in connected state (B as initiator and A as advertising mode) , so obviously role change happens and A switches to slave mode . meanwhile i wanted to connect device C to A (C as initiator and A as advertising mode) , since A has switched to slave mode , it cant able to advertise again ( controller returns error message " command disallowed") . Even i tried to change the role forcefully through hcitool command , the result was same.
My intention is to make the device A as a server with multiple
clients. Currently im not using any of theprofiles(ATT , GATT). i want it to be done using L2CAP sockets
You need to check if your controller supports the LE state combinations you are trying to use. Run "hciconfig hci0 lestates" And check the supported states. Also see Core Spec v4.0 page 1096 for more details.
Some controllers don't support LE scanning and LE advertising at the same time, so make sure you don't have LE scanning enabled in "A" while trying to re-enable advertising.
Quoted 2 lines
2. Is it possible to change the imtu of the LE connection other than 23bits( which is hardcoded in L2cap driver)
I think this was fixed on more recent kernel releases. See patches from Andre Guedes around May 31st (which are already upstream).
Best Regards,
Signature · 3 lines
Anderson Lizardo Instituto Nokia de Tecnologia - INdT Manaus - Brazil
Hi ,
I am facing some more issues regarding BLE multiple connection
, which is mentioned below . please show me the right direction , since i got stucked
1: suppose device A and B is in connected state (B as initiator and A as advertising mode) , so obviously role change happens and A switches to slave mode . meanwhile i wanted to connect device C to A (C as initiator and A as advertising mode) , since A has switched to slave mode , it cant able to advertise again ( controller returns error message " command disallowed") . Even i tried to change the role forcefully through hcitool command , the result was same.
My intention is to make the device A as a server with
multiple clients. Currently im not using any of the profiles(ATT , GATT) . i want it to be done using L2CAP sockets
2. Is it possible to change the imtu of the LE connection other than 23bits( which is hardcoded in L2cap driver)
Quoted 29 lines · Andre Guedes
Hi Ajay,
Quoted 6 lines · Ajay KV
Hi all,
Since im new to bluetooth low energy technology , i need some guidance from you . Following are the issues that im searching for a solution
Quoted 6 lines
1 : Is it possible to establish mutiple LE connection at a time . Im using fedora 13 , linux 2.6.39 version with 4.0 LE supported dongles
2: now im not concentrating on user profiles like GATT and ATT . i wanted to do it using HCI and L2cap connections
You are able to establish one LE connection at a time. If you have more than one device you want to connect to, you can use whitelist. Add the devices to whitelist and issue the LE connection command. As soon as one of the devices starts advertising, the connection will be established.
You can use hcitool to add devices to whitelist and issue LE connection command.
BR,
Andre
Hi Ajay,
Quoted 2 lines · Ajay KV
i could not able to figure it out yet , why its showing this error
" command disallowed" . Here im using fedora 13 with kernel 2.6.39 . i tried
This kernel is too old. For sure a lot of LE stuff will not work correctly on it. Can you try compiling your own kernel (latest version) and use tha latest BlueZ version with it?
Quoted 4 lines
with both dongles , iogear and cirago . But the result is same. i dont think that its something wrong with kernel version, as we uses hci commands (hciconfig hci0 leadv ) that directly talks with controller . please clear this issue..
Sorry, but I ran out of ideas. Can you describe with more details which exact steps are you taking to get the "command disallowed" HCI error? I.e. right after you attach the dongle, which commands are you issuing.
Also an hcidump showing the entire session (since the dongle is attached) should help. Without more information we are not unable to help further.
Regards,
Signature · 3 lines
Anderson Lizardo Instituto Nokia de Tecnologia - INdT Manaus - Brazil
Hi,
Quoted 25 lines · Ajay KV
Quoted 18 lines · Anderson Lizardo
Hi Ajay
[your emails to BlueZ mailing list may be getting blocked because you are using HTML. Please fix that on your mail client. Also remember to not top-post]
Quoted 11 lines · Ajay KV
Thanks for your reply. i have 2 dongles of different made (iogear and chirago) . "Hciconfig hci0 lestates" gives this following result
Supported link layer states:
[...]Here my issue is to know whether (connected mode + advertising
mode) is possible at a time . Once A is connected to B (initiator), i could not able to enable advertise in A (getting command disallowed ) , so that device C is not getting the connectable advertising packets on scanning.Quoted 5 lines
I could not see any reason to get "command disallowed" when enabling LE adv. Did you try changing dongle combinations to make sure it is not some hardware issue?
Regards,
Quoted 7 lines
Hi,
i could not able to figure it out yet , why its showing
this error " command disallowed" . Here im using fedora 13 with kernel 2.6.39 . i tried with both dongles , iogear and cirago . But the result is same. i dont think that its something wrong with kernel version, as we uses hci commands (hciconfig hci0 leadv ) that directly talks with controller . please clear this issue..
Most probably the controller is in the page scan or inquiry scan state. Try doing 'hciconfig hci0 noscan', before enabling advertising.
Quoted 6 lines
--
To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Cheers,
Signature · 1 line
Vinicius
Quoted 20 lines · Anderson Lizardo
Hi Ajay
[your emails to BlueZ mailing list may be getting blocked because you are using HTML. Please fix that on your mail client. Also remember to not top-post]
Quoted 12 lines · Ajay KV
Thanks for your reply. i have 2 dongles of different made (iogear and chirago) . "Hciconfig hci0 lestates" gives this following result
Supported link layer states:
[...]Here my issue is to know whether (connected mode + advertising
mode) is possible at a time . Once A is connected to B (initiator), i could not able to enable advertise in A (getting command disallowed ) , so that device C is not getting the connectable advertising packets on scanning.
Quoted 6 lines
I could not see any reason to get "command disallowed" when enabling LE adv. Did you try changing dongle combinations to make sure it is not some hardware issue?
Regards,
Hi,
i could not able to figure it out yet , why its showing this
error " command disallowed" . Here im using fedora 13 with kernel 2.6.39 . i tried with both dongles , iogear and cirago . But the result is same. i dont think that its something wrong with kernel version, as we uses hci commands (hciconfig hci0 leadv ) that directly talks with controller . please clear this issue..
Quoted 36 lines · Vinicius Costa Gomes
Hi,
Quoted 25 lines · Ajay KV
Quoted 18 lines · Anderson Lizardo
Hi Ajay
[your emails to BlueZ mailing list may be getting blocked because you are using HTML. Please fix that on your mail client. Also remember to not top-post]
Quoted 11 lines · Ajay KV
Thanks for your reply. i have 2 dongles of different made (iogear and chirago) . "Hciconfig hci0 lestates" gives this following result
Supported link layer states:
[...]Here my issue is to know whether (connected mode + advertising
mode) is possible at a time . Once A is connected to B (initiator), i could not able to enable advertise in A (getting command disallowed ) , so that device C is not getting the connectable advertising packets on scanning.Quoted 5 lines
I could not see any reason to get "command disallowed" when enabling LE adv. Did you try changing dongle combinations to make sure it is not some hardware issue?
Regards,
Quoted 7 lines
Hi,
i could not able to figure it out yet , why its showing
this error " command disallowed" . Here im using fedora 13 with kernel 2.6.39 . i tried with both dongles , iogear and cirago . But the result is same. i dont think that its something wrong with kernel version, as we uses hci commands (hciconfig hci0 leadv ) that directly talks with controller . please clear this issue..
Quoted 5 lines
Most probably the controller is in the page scan or inquiry scan state. Try doing 'hciconfig hci0 noscan', before enabling advertising.
Cheers,
Hi,
Still not working , getting the same old error. i just want to know ,
whether my dual-mode dongle allows this operation or not (Advertising mode+ connected mode)
Regards,
Hi Ajay,
Quoted 3 lines · Ajay KV
Still not working , getting the same old error. i just want to know
, whether my dual-mode dongle allows this operation or not (Advertising mode+ connected mode)
Did you try my suggestion?
1) Enable LE adv on A
2) Connect from B to A
3) Try to enable LE adv on A (should give the error you are getting)
4) disconnect connection from A side (using hcitool ledc)
5) try to enable LE adv on A
if step (5) works, we have confirmation that a dual mode dongle in slave mode is not accepting more than one active connection.
Anyway, I finally found the section from Core Spec v4.0, where it clearly says that a LE device operating in slave mode does not accept more than one connection (but a master device can create multiple connections). See Vol. 6, Part B, Section 1.1.1 "State and Role Combination Restrictions" (page 2195), specially second bullet. I copy the relevant text here:
"""
The Link Layer may optionally support multiple state machines. If it does support multiple state machines, the following state and role restrictions shall apply.
* The Link Layer in the Connection State shall not operate in the Master Role and Slave Role at the same time.
* The Link Layer in the Connection State operating in the Slave Role shall have only one connection.
[...]
"""
That means you can't send connectable advertising from a slave LE device if one connection is active.
Best regards,
Signature · 3 lines
Anderson Lizardo Instituto Nokia de Tecnologia - INdT Manaus - Brazil