Bluetooth on STM32WB55 board not working #15522
-
This is my first question here and I hope it is not to specific. I am trying to run micropython on a WeAct Studio STM32WB55CGU6 board: and started with the USBDONGLE_WB55 board definition. All I changed was pin definition for LED and removed user button. I flashed the custom firmware but could not start BLE. Therefore I tested Micropython (v1.23.0) without any modifications but starting BLE failed again with "OSError: [Errno 110] ETIMEDOUT"
WeAct Studio docu states that stm32wb5x_BLE_Stack_full_fw.bin / protocol stack,v1.19.0.2 is installed. My first idea was that maybe the WS does not match .
which corresponds to the WeAct docu. In the NUCLEO_WB55 directory I found the rfcore_debug.py
I verified that there is no hardware issue with the board by flashing the stm ble example from https://github.com/STMicroelectronics/STM32CubeWB/tree/master/Projects/P-NUCLEO-WB55.USBDongle/Applications/BLE/BLE_p2pServer/Binary and it works (ble service P2PSRV1 shows up) I have currently no idea what could be wrong. Timing problem? Any hints, ideas, suggestions for further investigations? |
Beta Was this translation helpful? Give feedback.
Replies: 4 comments 6 replies
-
I have enabled HCI trace and debug output in rfcore.c ... |
Beta Was this translation helpful? Give feedback.
-
Urgh yeah the WB55 can be just the worst sometimes. When it doesn't want to work it just gives you nothing to go by. That It's been some time since I've used the WB55 BLE, there's a chance that newer rfcore versions have broken the compatibility perhaps? I think 1.13 is the last one I've used personally. The changes in this PR might have an effect too: #8452 your post here reminded me I needed to rework that one as @dpgeorge cleaned up the flash code significantly which should mean my changes there can be reduced dramatically. |
Beta Was this translation helpful? Give feedback.
-
I had a terrible time trying to find the bug. At one point the timeout behavior suddenly changed and I realized that fus was active and ws was not. I was able to get back to active ws mode easily using STM32_Programmer_CLI, but soon after I gave up. Now I stumbled upon this {https://community.st.com/t5/stm32-mcus-wireless/bluetooth-application-on-nucleo-wb55rg-in-micropython/td-p/80091) thread on the STM forum where people were having the same timeout error on their official STM32WB55 boards, which leads me to believe that it may be an incompatibility with STM's latest wireless stack. @andrewleech was 1.13 the version of the wireless stack or micropython? Could you please have a look which ws version is running on your board, I looks like I can do a ws firmware downgrade. Thank you. |
Beta Was this translation helpful? Give feedback.
-
I haven't looked into it any deeper yet however on my NUCLEO_WB55 I just installed the v1.21.0 It was loaded at address 0x080DA000 for my STM32WB5xxG (1MB Flash) chip as per the release note.
|
Beta Was this translation helpful? Give feedback.
Yeah this BLE diagnostics is crazy hard on these chips with the core 2 radio a big black box.
I was referring to stm ws 1.13 as the last version I've used with micropython.