Re: [Bluez-devel] L2CAP: One failing connection hurts others?

Stefan Mischke
2004-09-15T22:13:03Z

Hi Marcel!

Marcel Holtmann schrieb:

>
>this is supported much longer, but it was not easy to get it working.
>
>
>
Well, yes, I remember there was a device hci0, but it didn't work. I
haven't tried any harder. Now (Kernel 2.6.5) it works just by pluggin it
in as ist should. Nice, now I have 4 dongles but I need to assemble
another pc from the parts lying around here...

>
>You must recompile your kernel and actually modifying them makes not
>really sense, because for example the HCI disconnect timeout is useful
>to keep the ACL link open for 2-4 seconds so that it can be reused by
>the next L2CAP connection.
>
>
>
I fond something much easier and better: "hciconfig hci0 pageto
<slots>". When I use connect() in blocking mode and set the pageto to a
small value, the connection attempt failure is reported in acceptable
time. Since hcitool can do it programmatically, I can surely do it, too
(by simply looking it up). I noticed that I have to increase the pageto
up to 10000 or higher for the first paging. I suppose because the clock
offset needs to be synchronized and afterwards it work even with a
pageto of only 1 slot (but 500 slots = 312,5 ms is ok for me).

Regards
Stefan