Tutorial to upgrade Slaesh's CC2652RB Zigbee USB stick

After hours and hours of reading, trying, unluckaly no results.
I’d like to upgrade the firmware of my CC2652RB stick. I have a MAC and Windows machine.
Instruction can be found on CC2652R stick - slae.sh

I thought the Texas Instruments Uniflash software would be the easiest option but the device is not recognised. In another thread I found I had to install the USB driver from Windows driver so I did. The stick became COM7, even changed to COM1, restarted W10, restarted software but the Uniflash software does not detect the CC2652 USB stick.

Started the Python method. Installed Python 3.10.1 on my W10 machine. Started Python and got the command line. Nothing worked, googled and found Python should run in a shell (cmd on Windows).
Finally had:
Microsoft Windows [Version 10.0.19042.1415]
(c) Microsoft Corporation. All rights reserved.

C:\Users\j.hoorde>python
Python 3.9.9 (tags/v3.9.9:ccb0e6a, Nov 15 2021, 18:08:50) [MSC v.1929 64 bit (AMD64)] on win32
Type β€œhelp”, β€œcopyright”, β€œcredits” or β€œlicense” for more information.

The >>> means the shell. First simle command to check the version is:
py --version
Traceback (most recent call last):
File β€œβ€, line 1, in
NameError: name β€˜py’ is not defined
The result is not what I suspected but it’s explained: if you see this result you should go to: getting started tutorial and there they explain Python should run in a shell.

Can anyone help me how to continue?
Thanks in advance !!!

1 Like

Same issues here

I finally suceeded to upgrade the firmware. Many thanks to Tinkerer, Puddly and silverstone on Discord to teach a newbie in Python.

On MacOS:
1/ Download the latest Python version
2/ Open terminal and type
python3 --version it should give Python 3.10.1
3/ Install pyserial and intelhex by the command pip3 install pyserial intelhex
In the terminal:

pip3 install pyserial intelhex
Collecting pyserial
  Downloading pyserial-3.5-py2.py3-none-any.whl (90 kB)
     |β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 90 kB 2.6 MB/s 
Collecting intelhex
  Downloading intelhex-2.3.0-py2.py3-none-any.whl (50 kB)
     |β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 50 kB 13.0 MB/s 
Installing collected packages: pyserial, intelhex
Successfully installed intelhex-2.3.0 pyserial-3.5
WARNING: You are using pip version 21.2.4; however, version 21.3.1 is available.
You should consider upgrading via the '/Library/Frameworks/Python.framework/Versions/3.10/bin/python3.10 -m pip install --upgrade pip' command.

I ignored the warning :wink:
4/ I then cloned the repo by the command git clone https://github.com/JelmerT/cc2538-bsl.git
I got a popup that some develloper tool must be installed, this took about 10 minutes on a new MAC with M1 processor… Afterward you get a popup that the software is successfully installed.
5/ Run now once more the command git clone https://github.com/JelmerT/cc2538-bsl.git
You should see in the terminal:

git clone https://github.com/JelmerT/cc2538-bsl.git
Cloning into 'cc2538-bsl'...
remote: Enumerating objects: 430, done.
remote: Counting objects: 100% (18/18), done.
remote: Compressing objects: 100% (16/16), done.
remote: Total 430 (delta 7), reused 8 (delta 2), pack-reused 412
Receiving objects: 100% (430/430), 155.30 KiB | 2.35 MiB/s, done.
Resolving deltas: 100% (189/189), done.

6/ In your user folder where you normally have Downloads, Documents you should have a folder:
Schermafbeelding 2022-01-03 om 21.03.48

7/ Download the new firmware
Unzip and you get a .hex file. Move the .hex file in your user folder
(At time of this post the .zip file contains CC2652RB_coordinator_20211217.hex)

8/ Discover the path to your USB stick:
Enter in the terminal the command ls -l /dev/cu.*
You should see something like:

ls -l /dev/cu.* 
crw-rw-rw-  1 root  wheel  0x9000003 24 dec 10:13 /dev/cu.Bluetooth-Incoming-Port
crw-rw-rw-  1 root  wheel  0x9000005  3 jan 19:52 /dev/cu.usbserial-1110
crw-rw-rw-  1 root  wheel  0x9000001 24 dec 10:07 /dev/cu.wlan-debug

Unplug the USB stick and determine which line corresponds. In my case the 2th line disappeared so the path to the Zigbee USB stick is /dev/cu.usbserial-1110
P.S. On Windows it should be something like /dev/serial/by-id/...

9/ Now the magic should happen by entering the final command:
python3 cc2538-bsl/cc2538-bsl.py -p /dev/cu.usbserial-1110 -evw CC2652RB_coordinator_20211217.hex
In terminal you should see:

python3 cc2538-bsl/cc2538-bsl.py -p /dev/cu.usbserial-1110 -evw CC2652RB_coordinator_20211217.hex
Opening port /dev/cu.usbserial-1110, baud 500000
Reading data from CC2652RB_coordinator_20211217.hex
Your firmware looks like an Intel Hex file
Connecting to target...
CC1350 PG2.0 (7x7mm): 352KB Flash, 20KB SRAM, CCFG.BL_CONFIG at 0x00057FD8
Primary IEEE Address: 00:12:4B:00:21:CC:47:C6
    Performing mass erase
Erasing all main bank flash sectors
    Erase done
Writing 360448 bytes starting at address 0x00000000
Write 104 bytes at 0x00057F980
    Write done                                
Verifying by comparing CRC32 calculations.
    Verified (match: 0x49cb5a2e)

Congratz, you also succeeded!

7 Likes

Can confirm this worked, thanks!

1 Like

Great work, thank you for the efforts. Works like a charm!

1 Like

i’m having problems on this step, the steps that i did are:
go to cmd
type python3
in the welcome i see i’m on python 3.10.2 so i’m happy
i type >>> pip3 install pyserial intelhex
but i get this,
File β€œβ€, line 1
pip3 install pyserial intelhex
^^^^^^^
SyntaxError: invalid syntax

also the same happens when i try to see if i can skip the step and go to the next :smiley:

git clone GitHub - JelmerT/cc2538-bsl: Python cross-platform script to upload firmware via the serial boot loader onto the CC13xx, CC2538 and CC26xx SoC.
File β€œβ€, line 1
git clone GitHub - JelmerT/cc2538-bsl: Python cross-platform script to upload firmware via the serial boot loader onto the CC13xx, CC2538 and CC26xx SoC.
^^^^^
SyntaxError: invalid syntax

any suggestion on what could be the cause?

Hi, I really don’t know. I would recommend to ask the question on Discord

Can you do this by just plugging the stick into a pc? Does it require an adapter? Did it erase all your paired devices?

@mouth4war, You just have to plugin the stick into the PC without adapter. The paired devices are not stored into the stick so after upgrade they all remained.

I’ve had one of these sticks for about a year now and have never updated the firmware. Are there any benefits of doing so or any release notes about improved performance or anything like that? Thanks

I think there are. I’m just getting an error when I want to connect new bulbs:

zigbee2mqtt/bridge/request/permit_join faild SRSP - ZDO - mgmtPermitJoinReq

Small search on the internet shows updating the stick can be helpfull.
I’d wish updating it would have been easier and possible through HS, but unfortunate that’s not the case

2 Likes

thanks a lot works like a charm

1 Like

When I run this command, I always only see the cu.Bluetooth-Incoming-Port, not the other ports.
Any suggestion what I might be overlooking?

Disregard my question. Was missing the proper driver, which I found meanwhile. So all good so far.

1 Like

Help please. I am using windows and I have flashed other ZigBee sticks like the Zhh sticks that you can place into bootloader mode and they then appear as COM ports but the Slaesh stick is being detected by windows as "other devices " and I cannot flash it.

I am stuck on Step 8, identifying path to usb, the command " ls -l /dev/cu.* " does not work on windows.

Does any one know how to direct the python script to the current port on a windows machine?

I have tried the PowerShell command in Slaesh’s flashing page , that returns COM1 but the cc2538-bsl.py script says cannot open port.

Is there a easy way to put the Stick into bootloader mode?

Found the answer here :- Flashing Slaesh's CC2652RB on a Windows PC - #10 by dnedeltchev

Just needed to download the driver for the stick and using device manager update windows.

Found the COM port and flashed OK

cc2538-bsl.py -p COM4 -evw Slaesh.hex
Opening port COM4, baud 500000
Reading data from Slash.hex
Your firmware looks like an Intel Hex file
Connecting to target…
CC1350 PG2.0 (7x7mm): 352KB Flash, 20KB SRAM, CCFG.BL_CONFIG at 0x00057FD8
Primary IEEE Address: 00:12:4B:00:21:CC:3B:95
Performing mass erase
Erasing all main bank flash sectors
Erase done
Writing 360448 bytes starting at address 0x00000000
Write 104 bytes at 0x00057F980
Write done
Verifying by comparing CRC32 calculations.
Verified (match: 0x86ce91c7)

Today, I wanted to upgrade again.
Got an error in step 4:
git clone https://github.com/JelmerT/cc2538-bsl.git xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at: /Library/Developer/CommandLineTools/usr/bin/xcrun
The command xcode-select --install installs this missing xcrun tools. It requires 15 Gb of space!
Once these tools were installed, I could proceed as before.
If you don’t need the xcrun tools anymore you could remove them: Uninstall Xcode Command Line Tools Β· Mac Install Guide