]> git.donarmstrong.com Git - qmk_firmware.git/commit
Connect the adafruit ble code to the lufa main loop
authorWez Furlong <wez@fb.com>
Mon, 28 Nov 2016 06:51:30 +0000 (22:51 -0800)
committerWez Furlong <wez@fb.com>
Sat, 3 Dec 2016 06:46:23 +0000 (22:46 -0800)
commit044fa3ff856393d75a80fe6625b4a5682b81b76d
treecb631f61e517ba8219ca6ef8c85bd69c04e8c01b
parent7f88c9506c1fbfb7de1ee51e0611eb8c46bee7f7
Connect the adafruit ble code to the lufa main loop

There are now 3 potential locations to send HID reports:

1. USB
2. The bluefruit easy key
3. Adafruit BLE

Generally speaking, if USB is connected then we should prefer to
send the reports there; it is generally the best channel for this.

The bluefruit module has no feedback about bluetooth connectivity
so the code must speculatively send reports over both USB and bluetooth.

The BLE module has connectivity feedback.  In general we want to
prefer to send HID reports over USB while connected there, even
if BLE is connected.  Except that it is convenient to force them
over BLE while testing the implementation.

This policy has been extracted out into a where_to_send function
which returns a bitmask of which of the channels should be used.
tmk_core/protocol/lufa/lufa.c