Page 1 of 1

Error updating Z-Station firmware

Posted: 13 May 2024 21:20
by beeguy123
Hi I just purchased a Z-Station and have tried updating the firmware to use OpenThread.
I used command

Code: Select all

./zme_zigbee update open_thread_EFR32MG21A020F1024IM32.gbl -d /dev/ttyUSB1 -p 12
The result was

Code: Select all

Openning port                            ..............................                            OK
                SDK VERSION:            00001000
Openning file                            ..............................                            OK
Writing data                             ..............................                            OK
Soft update reset                        ..............................                            OK
Waiting for update[*  ]                  ..............................CRITICAL [2024-05-13 18:50:30,639]  Reset protocol fail
Waiting for update[ * ]                  ..............................Traceback (most recent call last):
  File "zme_zigbee.py", line 581, in <module>
  File "zme_zigbee.py", line 577, in Main
  File "zme_zigbee.py", line 161, in updateFunc
  File "zigbee/zigbee.py", line 463, in connect
  File "zigbee/ezsp.py", line 315, in reset
  File "zigbee/ash_v2.py", line 90, in reset
  File "zigbee/ash_v2.py", line 138, in response
UnboundLocalError: local variable 'cmd' referenced before assignment
[530549] Failed to execute script 'zme_zigbee' due to unhandled exception!
Note that prior to this, an info command appeared to work fine. But now this too results in

Code: Select all

Traceback (most recent call last):
  File "zme_zigbee.py", line 581, in <module>
  File "zme_zigbee.py", line 577, in Main
  File "zme_zigbee.py", line 85, in infoFunc
  File "zigbee/zigbee.py", line 463, in connect
  File "zigbee/ezsp.py", line 315, in reset
  File "zigbee/ash_v2.py", line 90, in reset
  File "zigbee/ash_v2.py", line 138, in response
UnboundLocalError: local variable 'cmd' referenced before assignment
[531483] Failed to execute script 'zme_zigbee' due to unhandled exception!
I do this on a Raspberry Pi 4.
Please advise what may be the cause.
(Just a hunch : does my installed python version play any role ? I have tried with 3.9 and 3.11)

Re: Error updating Z-Station firmware

Posted: 13 May 2024 22:12
by PoltoS
Once you have uploaded the OT firmware, zme_zigbee is not able anymore to communicate with it. You can try the

Code: Select all

./zme_openthread info -d /dev/ttyUSB1
to see the device info and confirm it works.

Re: Error updating Z-Station firmware

Posted: 13 May 2024 22:25
by beeguy123
Thank you ! Indeed I had just realized that it is in fact working and not an error after all.