MicroBlocks BLE Extension

There is nearly no issue with connecting and disconnecting. The "BLE Connected" block correctly reports "true" while it is connected. However, I suspect there might be a problem related to registering with the services. My testing procedure is as follows:

  1. Connect.
  2. Send a command string.
  3. Disconnect.
  4. Wait for 2 seconds and then repeat from step 1.

Additionally, I implemented code in MicroBlocks to send messages every second when BLE is connected. I discovered that the problem occurs on both ends. During my tests, when the phone is unable to send any messages to the ESP32, the ESP32 also cannot send messages to the phone, even though BLE appears to be connected.

I tested it with sending messages from a board to the phone every 10 msec to make a live chart running. I had no problem with that. Maybe your ESP32 need more time to connect again and your waiting time is to short. I made a live LED editor for a ESP32 board with a RGB LED display and that also worked without a problem. Maybe it is related to a certain ESP32 board.