RIOT icon indicating copy to clipboard operation
RIOT copied to clipboard

pkg: add ZBOSS ZigBee stack round #2

Open Lukas-Luger opened this issue 8 months ago • 5 comments

Contribution description

This PR adds pkg support for ZBOSS ZigBee stack.

The provided example allows IEEE 802.15.4 capable devices to connect to ZigBee devices using Touchlink Commissioning.

As scanning is not yet fully implemented, the channel of the opponent device must be guessed and set using the set_ch command. Once a device has been successfully joined (using the tl_scan command), it can be toggled using the zcl_toggle command.

There are also other commands left over from the previous PR #14213 for sending packets out of the device and inputting packets into the local ZBOSS stack.

Testing procedure

Flash the new zigbee-zll example and try to pair a ZigBee bulb to the Riot node.

I've tested it on boards containing the nrf52840 cpu using Phillips Hue and Tradfri light bulbs. It may not work on other platforms.

Issues/PRs references

Flashpage usage may be incorrect, since FLASHPAGE_SIZE is missing on some boards (listed in tests/pkg/zboss/Makefile), although periph_flashpage is a required feature of the package.

This PR is a reboot of #14213.

Lukas-Luger avatar Apr 14 '25 16:04 Lukas-Luger

Murdock results

:x: FAILED

7a41c51af373e1b685b9dd1004304745ad9103f9 fixup! pkg: add ZBOSS ZigBee stack

Build failures (13)
Application Target Toolchain Runtime (s) Worker
tests/pkg/zboss native64 gnu 0.57 alien
tests/pkg/zboss msb-430 gnu 0.96 alien
tests/pkg/zboss native32 gnu 3.19 mobi6
tests/pkg/zboss adafruit-itsybitsy-m4 gnu 2.19 mobi6
tests/pkg/zboss samr21-xpro gnu 1.09 alien
tests/pkg/zboss nrf52840dk gnu 2.50 mobi6
tests/pkg/zboss frdm-k64f gnu 2.98 skyleaf
tests/pkg/zboss native64 llvm 2.81 skyleaf
tests/pkg/zboss native32 llvm 3.95 mobi7
tests/pkg/zboss samr21-xpro llvm 2.31 mobi7
tests/pkg/zboss stk3200 gnu 2.48 mobi6
tests/pkg/zboss esp32-wroom-32 gnu 9.40 mobi6
tests/pkg/zboss esp32s3-devkit gnu 8.78 mobi7
Test failures (16)
Application Target Toolchain Runtime (s) Worker
tests/net/gnrc_netif native32 gnu 0.00 alien
tests/net/gnrc_netif native64 gnu 0.00 alien
tests/net/gnrc_netif native32 llvm 0.00 mobi7
tests/net/gnrc_netif native64 llvm 0.00 mobi7
tests/net/gnrc_sixlowpan_frag_minfwd native32 gnu 0.00 alien
tests/net/gnrc_sixlowpan_frag_minfwd native32 llvm 0.00 skyleaf
tests/net/gnrc_sixlowpan_frag_minfwd native64 gnu 0.00 mobi6
tests/net/gnrc_sixlowpan_frag_minfwd native64 llvm 0.00 mobi7
tests/net/gnrc_sixlowpan_frag_sfr native64 gnu 0.00 mobi6
tests/net/gnrc_sixlowpan_frag_sfr native32 gnu 0.00 mobi6
tests/net/gnrc_sixlowpan_frag_sfr native32 llvm 0.00 mobi6
tests/net/gnrc_sixlowpan_frag_sfr native64 llvm 0.00 mobi6
tests/net/gnrc_sixlowpan_frag_sfr_congure native32 gnu 0.00 mobi6
tests/net/gnrc_sixlowpan_frag_sfr_congure native64 gnu 0.00 mobi6
tests/net/gnrc_sixlowpan_frag_sfr_congure native32 llvm 0.00 mobi6
tests/net/gnrc_sixlowpan_frag_sfr_congure native64 llvm 0.00 mobi6

Artifacts

riot-ci avatar Apr 24 '25 17:04 riot-ci

Update

tl_scan now automatically scans for devices and joins them. Multiple devices are now supported. Persistency is mostly implemented, therefore a reset command is introduced. (Lights will now be controllable after reboot.) zcl_toggle now needs a short address and an endpoint. A new command dev_info is introduced to show addresses and endpoints. Note that some devices have multiple endpoints and not all of them support the toggle command. set_ch has been removed to avoid unnecessary channel switching by the user.

Lukas-Luger avatar May 13 '25 09:05 Lukas-Luger

Let us know once you want a (preliminary) review. For the time being, there are some static test errors you can look at. Also you can change the doc.txt file to doc.md, see #21220.

crasbe avatar May 14 '25 22:05 crasbe

The #21617 Pull Request created a Merge Conflict. Perhaps you can take a look at that? Then the compile test will run again as well.

crasbe avatar Aug 13 '25 13:08 crasbe

Update

Added some documentation to the package and rebased to the most recent RIOT version. Most of the recent work went into ZBOSS itself, fixing bugs and extending functionality behind the scenes. The examples now include some mandatory clusters as defined by the ZigBee Lighting & Occupancy Device Specification Version 1.0. (missing clusters: Identify, Scenes, Level Control) Also the remote example now features on and off in addition to the toggle command.

Lukas-Luger avatar Nov 17 '25 14:11 Lukas-Luger