-
-
Notifications
You must be signed in to change notification settings - Fork 40.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Change the Bluetooth API to use a driver framework #22783
Conversation
looking good. Chances for a |
@dexter93; Strongly doubt faux will adopt this. He did mention on Discord that he wants to redo the BlueFruit driver first... my guess is that that will then expose some deficiencies in the whole approach and he'll change the whole thing up ... I can think of a few just off the cuff.. e.g.
None of the above is impossible - many co's who make KB's (even on QMK) do so already... just: How do you do it |
It's kinda sad to have a whole framework depend on a single device driver.. this one would at least open up the possibility of new/other ones. The BlueFruit driver is assumed to be in rework for.. ages at this point.
Abstract a battery service reporter, make it modular enough to either use ADC ( thanks ChibiOS), or a value straight up from a power IC
Currently, ChibiOS devices can make use of the
tri-mode and other-mode: can manage it through outputselect. The issue with nRF and QMK is licencing conflicts ( although at some point it was discussed that blobs might be the answer there on a bring-your-own basis).
That would assume the BT module advertises RAW HID, which most don't. Usually it's proprietary protocols for OTA flashing, or worse in the case of BCM chips, bluetool requiring heavily guarded .hex's. I don't see a reason to do so in the keyboard firmware.
Sure, most of the above can be implemented. However, with the state of the project and the amount of core maintainers it would require significant effort/time. A PR like this one is a good candidate for a starting point, since it abstracts the driver selection. From then on, specifics and feature for each driver can be added in the future by said co's/mfg's or collaborators/contributors. |
Thank you for your contribution! |
Thank you for your contribution! |
Description
[ Redo of #22746, due to rebase error. ]
Convert the Bluetooth implementation to a RGB Matrix -esque driver.
No attempt has been made to change the 2 driver's code, however
bluefruit_le.cpp
has been renamed tobluefruit_le_spi.cpp
, since there could be abluefruit_le_uart.cpp
in the future.The old
bluetoodth.c
API has been replicated in thebluetooth_legacy.c
file set in case keyboard makers have build their code on that basis.Some keyboard dependencies existed, and these have been adjusted to the new code.
bioi/
..morgan65
g60ble
handwired/promethium
nek_type_a
The "Feture Bluetooth" doc page has also been rewritten to explain usage of the new driver based Bluetooth API.
Types of Changes
Issues Fixed or Closed by This PR
Checklist