Zigbee FAQ Z3Light Z3Switch On Module Based Kits - MarkDing/IoT-Developer-Boot-Camp GitHub Wiki
Table of Contents
Z3Light and Z3Switch is the most commonly used sample projects for Zigbee beginners. Most of the Zigbee tutorials are based on these two sample projects. However, it's not easy to use them on a module based radio boards, such as BRD43xx series. All these radio boards are based on a Zigbee module instead of SoC, and there are only 32-pins on all of the Zigbee modules. As inherited from the beginning, all module based radio board use the same pin for LEDs and buttons, which makes it difficult to run Z3Light and Z3Switch on them.
In this article, we will introduce an approach to make the Z3Light and Z3Switch sample projects run on these module based radio boards.
Gecko SDK Suite 3.0
- BRD4308A
Connect the WSTK to PC through USB cable
In this demo, we will use a custom plugin named "virtual LED". With this plugin, we will draw two LEDs on the LCD screen. Please download this plugin first, and then extract it to the folder protocol\zigbee\app\framework\plugin
of your SDK. After that, please restart Simplicity Studio. If the plugin place correctly, you would see this plugin in the plugin list:
Below are the steps of setting up the projects:
-
Create the sample
Z3Light
/Z3Switch
; -
Turn to
HAL
tab, hit the buttonOpen Hardware Configurator
, then disableLED
. -
Turn to
Plugins
tab, select the following plugins:- WSTK Display Driver
- Graphics Library
- Virtual LED
-
Save and generate.
-
Edit the source file
Z3Light_callbacks.c
, replace the hal function of controlling the LEDs to the functions of controlling vleds.HAL LED Virtual LED halSetLed vled_On halClearLed vled_Off halToggleLed vled_Toggle -
Save and build.
Follow instructions in QSG106 to test. When you need to check the LED status, check the picture on the screen instead of the physical LED.
Start Simplicity Studio, import the project and then open the .isc
file. Turn to "General" tab, hit the button Edit Architecture
, change the board type or compiler.
NA