Bangle.js to ESP32 via BLE #6152
Replies: 1 comment
-
Posted at 2021-05-25 by Robin Mon 2021.05.24
Did the thirty or so functions within the NRF class not catch your eye?
Posted at 2021-05-25 by RandallSY I guess what I meant to say, is I'm not sure what directly applies to the ESP32, in this context. Is it fair to say that the generic NRF class is completely, implemented? I could use my other Espruino boards to prototype and test with, if that is/was the case. Thanks for the consideration your reply... Posted at 2021-05-25 by JumJum Implementation of BLE on ESP32 became incomplete. Posted at 2021-05-25 by RandallSY JumJum it's very interesting to look through your old posts, a lot of great work there. Thanks for posting. Posted at 2021-05-25 by @gfwilliams Yes, @jumjum has done a bunch of work on this, but it's been a bit of a moving target both with Espressif's SDK and things changing inside Espruino itself, and unfortunately I haven't had any time to put into this either. For nRF52-based devices, support for the NRF.* API is complete, but on ESP32 it's very much 'try it and see'. I'd suggest if you really want to use ESP32 for Bluetooth, going with the Arduino IDE is probably your best bet right now. If you went with BLE advertising (http://www.espruino.com/BLE+Advertising) I think there's a good chance you could knock something up with ESP32 and the Arduino IDE relatively quickly. Posted at 2021-05-25 by RandallSY Hi Gordon, thanks for your comments. Great minds run together, I ran some experiments this morning with the latest ESP32 dev module and the new Arduino IDE 2.o beta. The latest gen CHXXX USB serial interface does rip, and the serial programming performance is very good. My only motivation for using Espruino on the ESP32, was consistency with my other code examples. I am working on some education materials, and am looking at some gentle, progressive code snippets to get familiar with the "big ideas" in low power BLE. I'm getting a lot of inspiration from your recent YouTube videos on the subject. https://www.youtube.com/watch?v=lWjuMEIrmY8 I really like how you show the evolution of a generic BLE serial console, to a unique custom characteristic of your design, and then hit the Android Nordic nRF connect console to demonstrate manually stuffing a bit in the "register" to activate the servo. That seems like the learning trajectory best to follow. Posted at 2021-05-26 by @gfwilliams Great, glad it helps! It's a shame about the lack of BLE support for ESP32 - but it's quite a hard, painful job making it reliable. It's definitely not something I think many people would want to take on as a fun thing to do in their free time! Posted at 2021-05-26 by @fanoush
Unfortunately true for all other BLE platforms. Could be relatively easy to build Espruino for any random platform and get GPIO,uart,spi.i2c working but getting BLE stack working so that Espruino BLE API works is major effort. Maybe some port of the api to generic HCI protocol and then linking with HCI support from the manufacturer SDK could make it reusable (but probably more bloated) Posted at 2021-05-26 by @gfwilliams
This would actually be really cool if it could be implemented. I'm not thinking so much for MCUs, but for Linux devices (even OpenWRT-type stuff) it'd be really useful Posted at 2022-02-12 by HilmarSt I'm not sure if this is the right thread, but it's the only one I've found: Posted at 2022-02-13 by @fanoush
What you mean by "not necessarily with BLE", is using wires OK then? there is no other Bluetooth than LE in Bangle.js Posted at 2022-02-14 by HilmarSt Sorry for the confusion, but I thought there's also a non LE available. Does this mean there is no possibility to connect a Bangle.js 2 with an ESP32 because the ESP32 doesn't support BLE? Should I create a new thread not mentioning BLE? Posted at 2022-02-14 by myownself ESP32 does support BLE*. Maybe you are mixing up with ESP8266 which doesn't?
Posted at 2022-02-14 by @fanoush the best is to simply try :-) recently I tried BLE advertising and it worked fine in latest ESP32 build. Maybe opening connection (at least in one direction - from ESP32 to bangle? ) would work too? Posted at 2023-08-02 by user156138 Anyone fine a way to do a bidirectional connection between bangle.js and esp32? Posted at 2023-08-03 by @gfwilliams Yes - if you use a recent Espruino build for ESP32 then this code should work fine: http://www.espruino.com/BLE+UART#receiving-evaluating Or if you're programming it using some other language, it's pretty easy too - just implement the Nordic UART BLE endpoint a bit like is done at https://www.espruino.com/Interfacing#bluetooth-le - if you google it, you'll likely find an implementation already |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Posted at 2021-05-24 by RandallSY
Just got my Bangle.js from Adafruit yesterday, and was thinking about getting some data logging happening...
This is very interesting, and would be a great place to start ...
http://www.espruino.com/Bangle.js+Data+Streaming
But I could also imagine I might want to also communicate via BLE to a ESP32 "remote" bidirectionally. I see that there is some support for the nRF library, on ESP32, but don't see much in the way of documentation regarding how complete it is.
Simple BLE advertisement ESP32 to the Bangle.js , could be step one.
Any advice on where to begin understanding this?
Thanks!
Beta Was this translation helpful? Give feedback.
All reactions