Open TheBrunez opened 6 years ago
From provided logs if i being you i would try to see whats going on in this line:
FC_1->getData();
because there is no print in this line:
DEBUGLN(FC_1->dataStr());
I have few application where ble + wifi works great, but its different kind of app.
After some testing I located the "error". The program blocks inside FC_1->getData()
, at the call to _BLEClient->connect(*_addr)
inside FlowerCare_BLE.cpp
.
Going deeper I found that it blocks inside BLEClient.cpp
when calling m_semaphoreOpenEvt.wait("connect")
. The problem is that despite I located the error I don't know what to do, can you help me?
I would start with commenting out this line and see what would happend:
m_semaphoreOpenEvt.wait("connect")
This wont fix the issue, maybe even cause some other issues but it can give you more info.
I don't know if it is a good idea, but I can try it. I was hoping that someone else encountered this problem before and resolved it. I know that there is some applications that use BLE and Wifi at the same time (like this) but with arduino core I'm unable to get it working without modifying the "standard" BLE library for arduino core
I did run into an issue with BLE+WiFi and found that ensuring my BLE connection was complete before connecting to WiFi avoided the problem. That was a while ago (6 months perhaps) and I haven't retested since. Doing that, my BLE->WiFi gateway now runs happily for hours on end!
Great, but my project works in a little different way. I have the WiFi always connected and then I have to connect to different BLE server in sequence. I will do more test and let you know if I found and solve the problem
Hi, as in the title I'm trying to create a BLE gateway. The problem is that if I am already connected to the WiFi the BLE part doesn't work.
Here is the main code, see also my FlowerCare library if necessary.
The following is the terminal output I'm able to obtain: