I’ve replaced my old coordinator hardware with CC2530 with an external antenna and therefore one of CC2531 was not used.
The guys on GitHub asked me to make a router firmware for СС2531 too. I’ve spent some time and prepared 3 variants:
- CC2531-router.hex – just a router, without diagnostics and a USB serial port.
- CC2531-router-diag.hex – a router with diagnostic reports and without a USB serial port.
- CC2531-router-diag-usb.hex – a router with diagnostic reports and a USB serial port. The firmware dumps diagnostic reports to the serial port too.
Note: This firmware is for simple CC2531 boards without an additional RF front-ends.
SW1 – Changes a virtual state of the router (the router sends it in a diagnostic report) and a state of the green light.
- Short single press – to re-send a binding request to a coordinator (it allows you to test a connection).
- Long single press (about 5 seconds) – to reset the router and initiate a joining process.
Green light – a short blink when the router connected to a network.
- short fast blinks (one per second) – the router is connecting to a network.
- long blinks (one short flash per 4 seconds) – normal operations.
- three short blinks – the router cannot send a report to a coordinator.
How to use
- Download and flash the firmware.
- Power off/on (restart) the router.
- Permit joining to a network on your coordinator.
Added the “Aging” mode. The router forgets child devices that didn’t send any data for four hours. It helps when an end-device selects a new path to a coordinator.
1. Allows a router to use all possible channels (the old firmware was used the channel #11). But now, the router will take more time to connect to a coordinator.
2. A router may report link quality for all connected neighbors.
1. The previous version allowed to join for deleted devices.
2. СС2530 can be re-paired if you power on/power off it three times (power on, wait 2 seconds, power off, repeat this cycle three times).
Hello, is it possible to use simple CC2531 module as repeater (range extender)? What firmware do I use for this?
Yes, you can use this stick as a router (repeater) using the firmware from this page.
I downloaded cc2531 router software from the link below shown. It unzips to the files with this dates shown below. HOWEVER, zigbee2mqtt reports a firmware build date of 2018-09-26
What should I believe?
Thanks for your work on this project and help on this question!
Firmware build date
[email protected] 3 d staff 102 Feb 13 18:04 coordinator
-rw-rw-r–@ 1 d staff 542945 Sep 28 2020 router-cc2531-std.hex
-rw-rw-r–@ 1 d staff 564683 Sep 28 2020 router-cc2531-diag-usb.hex
-rw-rw-r–@ 1 d staff 550341 Sep 28 2020 router-cc2531-diag.hex
-rw-rw-r–@ 1 d staff 2792 Jun 6 2019 README.txt
Please ignore the timestamp in Z2M.
Hello! Thank yo very very much for your excellent firmware. I installed it without a hitch as router to extend the signal further from the coordinator. I have one question/observation, though.
The router seems to be sending too many MQTT message (to the coordinator). The console of the coordinator (running Tasmota) shows a message every second. Why so many? Are they needed? Nothing else on my 30+-device network is so actively sending messages.
If this frequency is not required, can it be reduced somehow? I am just concerned about it flooding he coordinator and keeping it unnecessarily busy.
I can only offer to build a custom firmware using my configurable firmware. It has a preset for the CC2531 router. Please enable the “Disable configuring interval remotely” option on the Expert tab.
Wow that would be excellent. In general, Tasmota devices send tele msgs every 1 minute, so that would be a good option.
I am not clear, though, on your answer above. To extend the period to 1 min, you or I would have to rebuild the firmware? I do not know to to build it, nor how to use the tabs. Kindly let me know.
Thank you very much again. You are great.
Hello, i have cc2531 coordinator now i need change to router.I can flash by Serial boot tool(i don’t have cc debuger). But SBT can’t flash hex file. Can can you compile hex to bin? Thx for great work!
Hello. You can find an instruction on the Internet how to convert hex to bin. Please, note, my firmware does not have SBT. You cannot return back or change to another firmware without a CC debugger.
I tried several options found on the Internet, at all at the end of the download it gives an error
I found it easiest to use raspberry pi. You can use the hex file. There are many instruction on the net on that (or search for it on youtube from NotEnoughTech. It took no more than about 5-10 minutes. You have to solder the pins, though.
Thanks – I already have a coordinator I would connect this to – I’m trying to make some smart devices with some CS2531+sbc with software on the sbc, and the adapter to connect it to the zigbee network talking to it with ZigbeeNet for example. Be nice if these were also routers like e.g. smart lightbulbs usually are. Am I looking in the wrong place?
I’m sorry, but I confused. It seems I didn’t understand your first question. A stick with CC2531-router-diag-usb.hex should create a UART on your SBC and dump some debug info to it. Does your coordinator use CC2531 too? Do you see it the devices list in your SBC?
Sorry It’s because I don’t know much about this. I have one CC2531 which I’ve been playing with, I’ll buy a different one to be coordinator at some point for sure. I also have an existing hive hub, but I can get rid of this.
I was trying the firmwares over at https://github.com/Koenkk/Z-Stack-firmware….
router Z-Stack_Home_1.2 for CS2513 (this is attributed to ptvo.info, I think it’s CC2531-router.hex):
– Flashed and pairs with the hive hub (suprisingly), but no usb serial uart
– Flashed, has a usb serial port, can connect to HomeAssistant using zigbee2mqtt for example
– Flashed, but doesn’t pair with hive hub. It does have a usb serial port. Tried to see if HomeAssistant would work with ZHA on that port – it says it can’t connect.
I assume this is because it’s just outputting diagnostic data over the usb, rather than accepting commands to send/recieve messages.
What I’m wondering if I can do, is put a firmware on the CC2531 that will expose a usb serial and join a zigbee network as a router (or as an end-device) and do some stuff like this:
So that I can code a smart device on something with the CC2531 plugged into it without writing firmware…e.g. expose some gpios on a rpi as smart lights etc.
I see. Unfortunately, my router firmware cannot work as your wish. It cannot accept external commands. You can download ZStack 1.2 SDK and use simple examples from it.
Hi and also thanks for your work 🙂
I’m a software engineer but new to zigbee, I have a CC2531 and I’d like to use e.g. ZigbeeNet to code up a zigbee device on a sbc, using the router firmware here.
I know I need to start by connecting to the zigbee network controller via serial e.g. `new ZigBeeSerialPort(“/dev/ttyACM0”);`.
Is it actually `CC2531-router.hex` I need? I read that as not having a usb serial port and installed `CC2531-router-diag-usb.hex` instead but that didn’t want to connect.
Hi! The router is a standalone device. It should be wirelessly connected to a coordinator. The coordinator works together with an SBC. So, first of all, you need a coordinator and firmware for it.
Thanks for your reply, as to 2. Yes: I stated two possibilities, therefore a retry:
case b) If the device is paired to the coordinator and moved out of reach but within reach of a router with your firmware -> does the device still count as a connection in the limited list of the coordinator?
Answer 3. I am using Domoticz and a network map indeed shows the connections. I suppose that if there is no connection between coordinator and device, that means it does not count as a device in the (limited cc2531) coordinator list?
1. The device should select a new parent device. When it has done, it will free a slot on a coordinator.
2. Yes, correct.
Hi, thanks for your work, I am using it with success with Zigbee2Mqtt, although some practical issues are not clear to me:
I use one cc2531 as a coordinator and another one as router in an attempt to support more than 20 devices.
1. a) Do I need to pair devices at the location of the router, or b) can I pair at the coordinator and move them out of reach, but within reach of the router?
2. In case of b): does the device then take a space in the limited list of the coordinator or of the router?
3. Is it possible to find information on devices whether they count in the list for the coordinator or for a router?
4. I have Ledvance smart plugs in my network that also have router capabilities. There are other devices like that such as switches or dimmers with router properties. Do these operate similar to the cc2531 with router firmware? Or is the cc2531 router much more powerful?
Thanks for your help in my understanding.
3. For example, Z2M can show a device’s map, where you can see direct connections and count them.
4. CC2531 may work better because it is outside a wall.