Silicon Laboratories Z3GatewayFreeRTOS Quick Start Manual

Silicon Laboratories Z3GatewayFreeRTOS Quick Start Manual

Cloud gateway example on amebad sdk and run on lcgw

Advertisement

Quick Links

Quick Start Guide:
Build Z3GatewayFreeRTOS Cloud Gateway
Example on AmebaD SDK and Run on LCGW
This article serves as a quick guidance for users wishing to build
Silicon Labs' Z3GatewayFreeRTOS cloud gateway example
application on Realtek's AmebaD Wi-Fi SDK.
Silicon Labs' EFR32MG21/MG13 is used as the Zigbee NCP
while the targetted NCP host is Realtek RTL872xCS/DN Wi-Fi
SoC.
This document is aligned with the v1.0.x release of the
Z3GatewayFreeRTOS Library and the cloud gateway application example source-codes.
silabs.com | Smart. Connected. Energy-friendly
KEY FEATURES
• Hardware and firmware preparations
• Source-code generation and compilation on
amebaD sdk
• Flasing AmebaD application firmware on LCGW
• Runing example cloud gateway application
Rev. 1.0.2

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the Z3GatewayFreeRTOS and is the answer not in the manual?

Questions and answers

Summary of Contents for Silicon Laboratories Z3GatewayFreeRTOS

  • Page 1 • Flasing AmebaD application firmware on LCGW SoC. • Runing example cloud gateway application This document is aligned with the v1.0.x release of the Z3GatewayFreeRTOS Library and the cloud gateway application example source-codes. silabs.com | Smart. Connected. Energy-friendly Rev. 1.0.2...
  • Page 2: Table Of Contents

    Build Environment Preparation and Source-code Compiling on AmebaD SDK ..........5 Set up Linux Build Environment for AmebaD SDK....................5 Generate and Compile Z3GatewayFreeRTOS Library Source Code Package on AmebaD SDK ......6 Flash the AmebaD Firmware Application ....................... 8 Flash the AmebaD Application Firmware Binaries ....................
  • Page 3: Hardware And Firmware Preparations

    Hardware and Firmware Preparations Hardware and Firmware Preparations 1.1 The Following Hardware are Needed • LCGWv2 Kit PTA pins Mini-Simplicity • LCGWv2 board jumpers: Jumpers Wi-Fi P7: Default shorted to enable AmebaD log message and firmware upgrade over USB P8: Mini-simplicity TX, RX pins route to Zigbee module Zigbee NCP or AmebaD log UART module...
  • Page 4: Ncp Firmware Preparation

    Hardware and Firmware Preparations 1.2 NCP Firmware Preparation • Please refer to User Guide document of “NCP and Bootloader Firmware Customization for LCGW” 1.3 NCP Firmware Programming • There should be a factory firmware in the Zigbee NCP chip in the LCGWv2 Kit. To reprogram the firmware: Note: Make sure Wi-Fi module Ameba firmware has been flashed (refer to section 3.1) before flashing the NCP firmware.
  • Page 5 Hardware and Firmware Preparations In “Kit” UI, change the debug mode of WSTK to “OUT” mode as below and then click the top “Target” “Connect”. Com- mander should able to identify the target device to be “EFR32MG21A02F1024”. Switch to “Flash” UI, browse to select the NCP .s37 file, e.g. ncp-hw-znet655_pta.s37, and then click “Flash” to flash the firmware binary.
  • Page 6: Build Environment Preparation And Source-Code Compiling On Amebad Sdk

    NDA version: Required signed NDA, please contact Realtek, its distributors or its IDHs for details Silicon Labs’ Z3GatewayFreeRTOS library and the Aliyun gateway example could be built on top of both the public version Ame- baD SDK and the NDA version SDK. The difference is that the RTL872xCS/DN Wi-Fi and EFR32MG13/MG21 Zigbee 2.4GHz ISM band PTA coexistence is only available on the NDA version AmebaD SDK through a SW-PTA patch applied on it.
  • Page 7: Generate And Compile Z3Gatewayfreertos Library Source Code Package On Amebad Sdk

    It will start downloading packages, it’s going to take a while depending on your internet speed. The released Z3GatewayFreeRTOS package depends on earlier ZNet SDK v6.6. If this doesn’t match, please go to “Launcher” -> “Update Software” -> “Package Manger” -> “SDKs” -> select “Categories” = “EmberZNet SDK”, “Ver- sion”=”All”...
  • Page 8 In Simplicity Studio, new a project->select Silicon Labs AppBuilder Project->Select Silicon Labs Zigbee-> select EmberZnet 6.6.x GA Host->Z3GatewayFreeRTOS Name the project as “lib_z3ctrl” for the Aliyun cloud gateway application example. Alternatively, you may use the default project name (Z3GatewayFreeRTOS) or another project name for your own project. It is REQUIRED to select the project location at specific location in the AmebaD SDK project: i.e.
  • Page 9: Flash The Amebad Firmware Application

    Flash the AmebaD Firmware Application Flash the AmebaD Firmware Application 3.1 Flash the AmebaD Application Firmware Binaries • Realtek’s Windows ImageTool.exe is recommended for flashing the AmebaD RESET firmware to the LCGW HW. Set LCGWv2 kit into Uart Download and Flashing mode: FLASH Open the bottom plastic cover of the LCGWv2 kit Plug the micro-USB cable to LCGWv2 and power it up from PC’s USB port...
  • Page 10: Run The Aliyun Gateway Example Application

    Run the Aliyun Gateway Example Application Run the Aliyun Gateway Example Application 4.1 Download Alibaba Cloud Intelligence Mobile Phone App • Download and install Alibaba “Cloud Intelligence” mobile App on your mobile phone by scanning below QR code: Note: There are two mobile App editions, i.e. User edition (recommended) and Developer edition. •...
  • Page 11 Run the Aliyun Gateway Example Application • Step 2: Connect your mobile phone to the Wi-Fi network that the LCGWv2 is targeted to be connected to internet Note: The mobile phone Wi-Fi must be connected to a 2.4GHz Wi-Fi network, otherwise provisioning will fail. •...
  • Page 12 Run the Aliyun Gateway Example Application You will see Adding Devices in progress… Wait LCGW device added in less than 1 minute. Optional to rename GW. Optional to rename the house and select room Tap “Complete” button 10. In GW panel, tap “<” icon to return main page. See the LED indicators: If GW connected to Aliyun: Cloud (GREEN) indicator turns on Wi-Fi (BLUE) and Zigbee (RED) indicators restore to slow blinking 11.
  • Page 13 Run the Aliyun Gateway Example Application Alternative Method 1: Scan the LCGW’s QR-code Tap top-right “+” icon Tap “[-]” scan icon Scan LCGW’s QR-code or below: QR-code for LCGWv2 Follow sub-step (3) to (10) of previous Step 3 to add the LCGW accordingly silabs.com | Smart.
  • Page 14 Run the Aliyun Gateway Example Application Alternative Method 2: Manually add the LCGW device Note: Only the product that is in the Mass Production stage and whose name has passed the inspection of Aliyun platform will be shown in the Product List. Tap top-middle “Add Manually”...
  • Page 15: Adding Zigbee Light To Network And Aliyun

    Run the Aliyun Gateway Example Application 4.3 Adding Zigbee Light to network and Aliyun Three different methods to add Zigbee sub-devices: (1) Scan device’s product QR-code generated from living.aliyun.com (2) Manually select a device product from full product list (3) LCGW single CONFIG button to permit Zigbee device joining in 180s using default global link-key. Note: Method 3 CONFIG button method requires the first device of a product has been added via QR-code successfully.
  • Page 16 Run the Aliyun Gateway Example Application • Step 3: Add Z3Light device Tap “Add Device” button on the App You will see Adding Devices in progress and GW Zigbee (RED) indicator is fast blinking, 100ms on 100ms off. Wait till adding device process completes in less than 1 minute.
  • Page 17 Run the Aliyun Gateway Example Application • Step 4: Z3Light Control and Settings After successful adding the device, it’ll appear on the Device page of the App. (If not, please refresh the page.) Tap the “On/Off” button to toggle the Z3 Light on/off Tap “siliconlabs ZigbeeLight Z3L”...
  • Page 18 Run the Aliyun Gateway Example Application Method 2: Manually add the Zigbee Light device Note: Only the product that is in the Mass Production stage and whose name has passed the inspection of Aliyun platform will be shown in the Product List. Tap top “Add Manually”...
  • Page 19: Adding Zigbee Switch To Network And Aliyun

    Run the Aliyun Gateway Example Application 4.4 Adding Zigbee Switch to Network and Aliyun Method 1: Scan Zigbee Switch’s product QR-code • Before adding a Zigbee device, the gateway should have automatically formed a Zigbee network. • Step 1: Scan the device’s QR-code by the Cloud Intelligence mobile phone App Tap top-right “+”...
  • Page 20 Run the Aliyun Gateway Example Application • Step 3: Add the Z3Switch device Tap “Add Device” button You will see Adding Devices in progress and GW Zigbee (RED) indicator is fast blinking, 100ms on 100ms off. Wait till adding device process completes in less than 1 minute. Once the device joins successfully or the 180s expires, the Zigbee (RED) indicator returns back to slow blinking (100ms on 1900ms off) Tap “<”...
  • Page 21 Run the Aliyun Gateway Example Application • Step 4: Z3Switch Settings After successful adding the device, it’ll appear on the Device page of the App. (If not, please refresh the page.) Tap “siliconlabs ZigbeeWallSW Z3SW” icon itself to open the Switch Control panel Tap “…”...
  • Page 22 Run the Aliyun Gateway Example Application Method 2: Manually add the Zigbee Switch device Note: Only the product that is in the Mass Production stage and whose name has passed the inspection of Aliyun platform will be shown in the Product List. Tap top “Add Manually”...
  • Page 23: Important Notice

    Run the Aliyun Gateway Example Application 4.5 Important Notice By using the public Cloud Intelligence mobile phone App, no matter the User edition or the Developer edition, once a device, including the gateway itself, is added (bound) to one user account, the other user account will be unable to add (bind) the same device again, i.e.
  • Page 24 Run the Aliyun Gateway Example Application • This is very important when the default pre-defined Triple-unit-groups of the gateway and test devices have been used in the gateway project sample code in a shared manner among multiple parties. To avoid conflicts of the default pre-defined Triple- unit-groups, a user should ▪...
  • Page 25: Further Reference

    Run the Aliyun Gateway Example Application 4.6 Further Reference • Please refer to user guide document “ug_Aliyun_iotkit_integration_of_Z3GatwayFreeRTOS_for_LCGW” for further gateway and device operation details for Aliyun. silabs.com | Smart. Connected. Energy-friendly Rev. 1.0.2 | 24 | 24...
  • Page 26: Amebad At Commands And Z3Gatewayfreertos Cli Commands

    The implementation of the CLI functions is also a demonstration of the usage of standard API, i.e. silabs-host-cmd.h (please refers to “API reference Guide on Z3GatewayFreeRTOS”). We make use of the original AmebaD console ser- vice(log_service.c) and added extra demo codes to implement a series of functions with silabs-host-cmd.h. This is by default disabled, to Enable it, change “#define LOGSEV_PROCESS_UP_MSG ”...
  • Page 27 AmebaD AT commands and Z3GatewayFreeRTOS CLI commands ncpupdate Please refer to user guide document “ug_Z3GatewayFreeRTOS_app_development_on_AmebaD_SDK” for these sample CLI commands details. Command examples for basic Zigbee network management and adding Zigbee devices: ▪ z2 leave gateway leaves Zigbee network and delete all nodes info ▪...
  • Page 28: Document Revision History

    Document Revision History Document Revision History Revision 0.1 April 22, 2020 EmberZNet PRO version: 6.6.5.0 • Initial release with LCGW v1.0 RC1 software package Revision 0.2 May 6, 2020 EmberZNet PRO version: 6.6.5.0 • Release for LCGW internal training • 2.1 added Ubuntu build environment to install 32-bit version of build packages •...

Table of Contents