Is this normal with this BLE component?
In this project, I'm trying to send and receive data simultaneously. It works perfectly with the Bluetooth HC-05, but I can't achieve it with BLE. What am I doing wrong? I really don't trust AI anymore!
Is it possible to read and write simultaneously with BLE? It's not possible with App Inventor, which I doubt! the python code is
import bluetooth
from Ble import BLEUART
from machine import Pin
bluetooth.BLE().active()
import time
Dear @Julio_Macias, first of all if you try to use the HC05 as a BLE, it will never work: the HC05 is a standard BT shield (provided it isn't a "fake" HC05 and it carries on it an AT-09 module instead. There is a very recent topic on the matter, look for it in the forum).
Assumed that your HC05 is a true one, therefore a standard BT, forget all about BLE.
On the opposite, whether you have a true BLE board to connect, there are really many examples on @Taifun's (puravidapps) , @ChrisWard's (professorcad) or @TIMAI2's (metricrat) web sites.
Moreover, as far as the simultaneous connection toward two different BT devices (one classic, i.e. an HC05 and one BLE, i.e. an HM-10) is concerned, the answer is yes, an AI2 app can connect such devices at the same time. A time ago I've developed an example to show how to connect two ESP32: the first via BLE and the second via classic BT. The ESP32 board features both BT's but I've use two of them because my aim was to see if a unique app could connect two different devices on two different BT standards.
You can find it here:
My problem is that I'm trying to create a program with App Inventor using an Arduino Nano ES32. When I made the program with the HC-05 using App Inventor, it was simple and intuitive, but now with the ESP32 Nano (Bluetooth LE), I'm having trouble.
It either reads from the Bluetooth module or sends text.
I can't get it to work bidirectionally.
I asked the AI... and I don't believe its answer, which is why I wrote in the forum.