cancel
Showing results for 
Search instead for 
Did you mean: 

Bootloader STM_OTA update firmware and access to BLE characteristics via BLE and python script or other CLI

PawelM
Associate III

Hi all,

I using Nucleo STM32WB55 and bootloader from STM (STM_OTA). For update firmware I using for now STM32CubeMonitor-RF and stm32WB USB DONGLE (which is part of nucleo kit). Now I would like to do this in other way - other tools, CLI, scripts...

Is some other tools to use to get access to BLE characteristics read/write and update firmware, some kind may CLI (STM32CubeMonitor-RF - i don't found any commands) or script in pyton or other laguage ?

I found BlueST-SDK but in my opinion don't work with nucleo STM32WB55 - I have issuess when try update firmware :

~/Downloads/BlueSTSDK_Python/blue_st_examples $ sudo python3 example_ble_6.py 
 
##################
# BlueST Example #
##################
 
Scanning Bluetooth devices...
 
Discovery started.
New device discovered: STM_OTA.
Discovery stopped.
 
Connecting to STM_OTA...
Device STM_OTA connected.
Connection done.
 
Features:
No features found.
1) Firmware upgrade
 
Select an action ('0' to quit): 1   
1)node-stm32wb55
 
Select a firmware ('0' to cancel): 1
 
Upgrading firmware...
1
<bound method Node.get_debug of <blue_st_sdk.node.Node object at 0x7647b490>>
none
2
Traceback (most recent call last):
  File "example_ble_6.py", line 327, in main
    upgrade_console.add_listener(upgrade_console_listener)
AttributeError: 'NoneType' object has no attribute 'add_listener'
 
During handling of the above exception, another exception occurred:
 
Traceback (most recent call last):
  File "example_ble_6.py", line 391, in <module>
    main(sys.argv[1:])
  File "example_ble_6.py", line 346, in main
    upgrade_console.remove_listener(upgrade_console_listener)
AttributeError: 'NoneType' object has no attribute 'remove_listener'
Device STM_OTA disconnected.
Exception ignored in: <function Peripheral.__del__ at 0x76572108>
Traceback (most recent call last):
  File "/usr/local/lib/python3.7/dist-packages/bluepy/btle.py", line 630, in __del__
  File "/usr/local/lib/python3.7/dist-packages/blue_st_sdk/node.py", line 555, in disconnect
  File "/usr/local/lib/python3.7/dist-packages/blue_st_sdk/node.py", line 398, in _update_node_status
  File "/usr/lib/python3.7/concurrent/futures/thread.py", line 151, in submit
RuntimeError: cannot schedule new futures after shutdown

Thanks for help

0 REPLIES 0