-
Notifications
You must be signed in to change notification settings - Fork 2
Description
Proof-of-concept: https://github.com/mmvanheusden/arduino_web-bluetooth-api
Testing
To test, leaphy-extensions bluetooth branch must be cloned to ~/Arduino/libraries
with folder name Leaphy_Extensions
.
leaphy-webbased-backend
will try to overwrite the library with the upstream one so the skip-libraries branch must be used, and Leaphy_Extensions
should be ignored in the config.
conf.py
:
<snip>
ignored_libraries: list[str] = [
- ""
+ "Leaphy_Extensions"
] # Libraries that should be ignored when downloading them, for testing unpublished changes to libraries
<snip>
Architecture
Learn: https://learn.adafruit.com/introduction-to-bluetooth-low-energy/gatt
Test with: https://punchthrough.com/how-to-use-lightblue/
Every Leaphy SHOULD have a Leaphy BLE service with the same UUID across Leaphy devices. This can then be used by other apps to distinguish a Leaphy Bluetooth device from a not Leaphy Bluetooth device.
The most important logic is in the LeaphyBLE abstraction file.
To-do list:
- There should be no more than one
BLE.poll();
inloop()
. -
Add LeaphyBLE wrapper toDone: feat: add LeaphyBLE Bluetooth LE wrapper leaphy-extensions#8leaphy-extensions
. This removes the need to maintain a fork of ArduinoBLE - Ability to initiate a connection from a Leaphy to possibly another Leaphy or Bluetooth device with characteristics. For example a device with a binary characteristic that controls a LED.
- Explore Web Bluetooth API. With
chromium-browser --enable-features=WebBluetooth
A Chromium-based browser supports web Bluetooth. See PoC. - Some types of characteristics need a size set when initialized. Can this overflow and is it large enough?