-
Notifications
You must be signed in to change notification settings - Fork 22
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
Full Bluetooth 5.1 stack for V2? #51
Comments
Hi @AllegroGavin At the moment, that's SoftDevice and a lightly modified Nordic bootloader https://github.com/microbit-foundation/v2-bootloader (in the process of opening this, so may 404 today, but should be working soon), so that the flash for the Bluetooth stack can be shared between the user app and the bootloader. If we didn't do this, then a user who had programmed their micro:bit with MicroPython wouldn't be able to use their smartphone to switch over to a MakeCode programme and vice versa. That means that the S113 Bluetooth stack is always in flash and available to MicroPython, but S113 can't be a GAP Central device, and SoftDevice is a different stack to what is used for other MicroPython BLE ports. Furthermore, lots of micro:bit users expect the micro:bit radio protocol to be available and this is (mostly/realistically) mutually exclusive with BLE at the moment. We're looking at what the best way to let MicroPython programs use BLE, and having some use-cases will help. Would you like to be a GAP Peripheral? Central? Do you want yo use just a BLE UART, or are you trying to write your own services, etc? I know this isn't quite an answer to your question, but I hope explaining some of the Ux background for why the answer isn't just "yes, it's over there" is useful. |
Is there a way to compile in BLE instead radio module?
|
Found |
Even after bluetooth pairing… → #84 |
It depends what you mean by "compile in BLE". But, as mentioned above, MicroPython on the microbit does not currently support using the BLE from Python, it only supports using the raw radio. |
If you, like me, found this issue (or bbcmicrobit/micropython#702) when trying to figure out how to use BLE with the Micro:bit v2, I managed to get BLE working using CircuitPython: https://github.com/adafruit/circuitpython/tree/main/ports/nrf/boards/microbit_v2. CircuitPython is a fork of MicroPython, and as of Oct 2021 provides the Adafruit also has the The main drawback to this approach is that CircuitPython expects you can load a |
That's awesome, thanks for sharing @bradjc!
If you can enable "storage" at build time so that something like |
Hi @bradjc can you make a quick tutorial by any chance? |
Definitely still waiting on BLE support. All I want to do is pass data from an attached sensor (I2C) over bluetooth. Such a simple thing is proving to be very difficult :( |
A while ago I integrated the MyNewt RTOS/BLE stack into the uPy codebase for MB v1 allowing the creation of custom GATT services. Can't recall if I wrapped the central API (may have been flash limited so probably a no/alternate hex build, but wouldn't be such an limitation on v2 to have both in a single firmware image) |
@WayneKeenan hello, nice to hear from you. Your timing couldn't be more perfect. This is unusually good timing, as we've got @ForrestFairy at Lancaster University looking at doing something quite like this for CODAL as a University project. |
Hey @jaustin good to hear from you too. Cool. Sounds interesting... |
Apologies if there's a better place to ask about this, but I'm curious if we will be able to get a V2 uP version at some point that includes the full Bluetooth stack and an appropriate Python API.
The text was updated successfully, but these errors were encountered: