Replies: 2 comments
-
The ESP32-C3 has a slightly different BLE stack than the Pi Pico W. It’s possible that the aioble module (which is often based on the ubluetooth or other BLE libraries) handles advertising differently on these platforms. |
Beta Was this translation helpful? Give feedback.
-
I just tried running the same code on a C3 and ran into the same issue, there's certainly something wrong there. As a point of comparison I just ran the aioble test sensor example on the C3 and it did run correctly - I think from a quick look it's quite similar to |
Beta Was this translation helpful? Give feedback.
-
I found this sketch that permit to connect two Pi Pivo W via BLE and exchange messages between a Ble Server and a Ble Client including also an acknoledge msg from the Client to the Server: (https://github.com/kevinmcaleer/pi_to_pico_bluetooth/blob/main/lesson_01/pico_a.py).
Used with the Pi Pico w it works perfectly but when I try to use with ESP32 C3 as Peripheral I got a problem .
The pico_a.py can be customised to works as client or serve changing only the variable at line 12 " IAM = 'Peripheral' or IAM = 'Client' "
When I use the sketch with an ESP32c3 as Client there are no problems but when I use configured as Peripheral I got this error
The same sketch loaded on the Pi Pico w works fine.
About the " OSError -530 " I'mk not able to find any explanation in google.
The code line 118 of pico_a.py seems nothing special ( services=[BLE_SVC_UUID], )
and common to other sketch that I've found for ESP32.
At this point I don't know if the issue could be inside the aioble module "/lib/aioble/peripheral.py", line 158
and if aioble modules change in such way if loaded on ESP32 or on Pi Pico.
Any suggestion is wellcome.
Beta Was this translation helpful? Give feedback.
All reactions