-
Notifications
You must be signed in to change notification settings - Fork 1.3k
bleio: add central and scanner functionality, cleanup bleio API, some code restructure #1993
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
Conversation
… now 2. Add scan response capability to advertising.
…n_hal routines instead. Changes made but not yet tested.
…e Characteristic Service
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is super exciting! I like the simplifications you've done and the move to common hal. A number of small questions I have for now. I'm excited for the world where a scan reveals all of the circuitpython powered devices I have going around me.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me! Thank you for your hard work on this.
Service
,Characteristic
, andCharacteristicBuffer
. Add new native classesCentral
andScanner
.Device
code (was combined central and peripheral).AddressType
. Now it's just an integer.Address
changed correspondingly.AdvertisementData.
BLE Advertisement data is now constructed in Python, inadafruit_ble.advertising
.Broadcaster
removed as a separate class for beacons to avoid a lot of duplicated code. Now handled byPeripheral
.bleio
object struct fields directly inshared-bindings/
. Usecommon-hal
operations instead.bleio
object structs out ofshared-module
intoports/nrf/common-hal
, as they were not necessarily port-independent.list_clear()
inpy/objlist.c
to publicmp_obj_list_clear()
, because I had a use for it elsewhere.shared-module/displayio/TileGrid.c
to fix gcc warning.This new version of
bleio
requires an updated version ofAdafruit_CircuitPython_BLE
(adafruit_ble
) library. Changes are in adafruit/Adafruit_CircuitPython_BLE#15.