Logitech K810 Bluetooth keyboard

Maksim Yevmenkin maksim.yevmenkin at gmail.com
Mon Nov 10 23:28:37 UTC 2014


On Mon, Nov 10, 2014 at 1:20 PM, Iain Hibbert <plunky at ogmig.net> wrote:
> On Fri, 7 Nov 2014, george ember wrote:
>
>> After reboot my hcibump -x
>>
>> ember at FreeBSD ~ $ sudo hcidump -x
>> Password:
>> HCIDump - HCI packet analyzer ver 1.5
>> device: any snap_len: 65535 filter: 0xffffffffffffffff
>> > HCI Event: Connect Request(0x04) plen 10
>>   C5 F2 4D 20 1F 00 40 05 00 01
>> < HCI Command: Accept Connection Request(0x01|0x0009) plen 7
>>   C5 F2 4D 20 1F 00 00
>> > HCI Event: Command Status(0x0f) plen 4
>>   00 01 09 04
>> > HCI Event: Role Change(0x12) plen 8
>>   00 C5 F2 4D 20 1F 00 00
>> > HCI Event: Connect Complete(0x03) plen 11
>>   00 0B 00 C5 F2 4D 20 1F 00 01 00
>> < HCI Command: Write Link Policy Settings(0x02|0x000d) plen 4
>>   0B 00 05 00
>> > HCI Event: Command Complete(0x0e) plen 6
>>   01 0D 08 00 0B 00
>> > HCI Event: Link Key Request(0x17) plen 6
>>   C5 F2 4D 20 1F 00
>> < HCI Command: Link Key Request Negative Reply(0x01|0x000c) plen 6
>>   C5 F2 4D 20 1F 00
>> > HCI Event: Command Complete(0x0e) plen 10
>>   01 0C 04 00 C5 F2 4D 20 1F 00
>> > HCI Event: Disconn Complete(0x05) plen 4
>>   00 0B 00 13
>
> This seems consistent with the fact that you put "nokey" in the config
> file.. the FreeBSD host states that it does not have a key but presumably
> the keyboard is expecting one (if it has one stored for this host), so the
> connection is refused, with the reason given "Remote User Terminated
> Connection" (0x13 at the end)

yes :)

so, i _think_ the keyboard is expecting link key because it was paired
with this particular host device before.  since the keyboard is
initiating request, then, it makes me think that the keyboard is _not_
in the pairing mode.

the questions is: why is the keyboard expecting the key, and, why is
it not getting it. i vaguely recall (from the previous conversation)
that the same two devices, i.e. host device and the keyboard were
paired under another OS, i.e. windows. obviously, generated link key
is _not_ available to other OS, i.e. freebsd. thus the keyboard must
be re-paired under freebsd. now, if you boot into windows again, link
keys would not match and re-pair would be needed again.

i've asked the question about dual booting, and, it it does not seem
to be the case. so, was the keyboard re-paired? or same pair of
devices used with another OS?

last time i suggested to pair devices under freebsd. obtain link key
from bthid.keys file and program it directly into the host device.
this way, device will use it and re-pair would not be needed. another
suggestion is to use different dongle with different OS. this was link
keys would not clash.

> can you show a hcidump of the pairing process, when a PIN is given? also,
> after the keyboard is paired and the key is known (if you can get that
> far) what about the dump that time?

yes, so basically, i think, all is needed is to re-pair keyboard under
freebsd. and then make sure to never re-pair it with the same devices
on another OS. then it will "just work"


thanks
max


More information about the freebsd-bluetooth mailing list