This is a guide is for creating, building, and running a Dotdot OTA Server and Client using available sample applications. The OTA Server will be on a Host application on the Raspberry Pi that has an NCP connected. This KBA assumes that the user has reviewed UG116 and is familiar with running a Raspberry Pi Host with NCP. (Please note, it is not a requirement for the OTA Server to also be a Border Router).
This KBA was written with the following software tools:
Simplicity Studio
Gecko SDK version 2.5
IAR Workbench 7.80.4
GCC 6.3.0
With the following recommended hardware:
Raspberry Pi 2 Model B
Two BRD4164s or equivalent EFR32MG12 reference boards with WSTKs
Sample Applications
Create projects for the following sample applications found in Gecko SDK version 2.5 through the Application Wizard. These can be found through the File menu going to File -> New -> Project -> Silicon Labs AppBuilder Project.
OTA Server (Host)
Light (Soc)
NCP UART HW (Hardware Flow Control)
SPI Flash Storage Bootloader (single image)
The Light and OTA Server are pre-commissioned and will be in the same network at startup, unless the devices were already in a previous network. Resetting the network parameters will coax the devices to enter the networking state-machine. The reset command is as follows:
ota-server> network-management reset
OTA Server Configuration
The OTA Server (Host) Sample application has all the plugins required to be an OTA Server. Most notable are the following:
OTA Bootload Core
OTA Bootload Server
OTA Bootload Server Policy
OTA Bootload Storage CLI
OTA Bootload Storage Core
OTA Bootload Storage UNIX
In OTA Server Sample app we recommend making the following changes for testing:
Under the Printing tab enable the following debug output
ICMP CLI
OTA Bootload Core
OTA Bootload Server
OTA Bootload Storage UNIX
OTA Bootload Storage Core
OTA Bootload Server Policy
In OTA Bootload Server Plugin
Change the Image Notify Period to 1 minute
Generate, transfer to Raspberry Pi, Compile the OTA server application. Also, compile ip-driver-app found under v2.x/protocol/thread/ with the following command:
$> make -f app/ip-ncp/ip-driver-app.mak
Light OTA Client Configuration
The OTA Client is based on the Light sample app. The following plugins are used to enable the OTA functionality. Here we assume the device you are using has external EEPROM:
OTA Bootload Client
OTA Bootload Client Policy
OTA Bootload Core
OTA Bootload Storage CLI
OTA Bootload Storage Core
OTA Bootload Storage EEPROM
In the OTA Bootload Client options set the following to maximize the recurrence of OTA Client/Server communication:
Discover Server Period to 1 minute
Query Next Image Period to 1 minute
In the OTA Bootload Client Policy options note the following and/or set them to something unique. These will be used for creating the OTA image:
Current Image Manufacturer Code
Current Image Type
Current Image Version
In the OTA Bootload Storage EEPROM plugin make sure the value of EEPROM OTA Storage End Address is one less than the value found in SPI Flash Storage Bootloader Slot 0 size (under the Storage tab). If the size does not match the download will fail.
We also recommend enabling the following plugins for testing:
ICMP CLI
COAP CLI
UDP CLI
As well as the following for debug output under the Printing tab:
EEPROM
OTA Bootload Storage EEPROM
OTA Bootload Client Policy
OTA Bootload Core
NVM3 Library
ZCL Core
OTA Bootload Client
Generate, Build, and Flash the Light application and bootloader to the EFR32.
Building OTA Image
Recall the values in OTA Bootload Client Policy plugin for the Light. In order for the Light application to flash an image it must verify if the image has met the criteria of the OTA policy. The Manufacturer ID, Image Type ID need to be the same, and the Firmware Version must be a higher value. We will need to create a second image with a higher version number. For example, the first image will be version 0x00000001 and the new image will have version 0x00000002. Go back to AppBuilder and update the project to have a higher version number by changing the setting, generating, and compiling. (Note: this will overwrite your old image. If it needs to be available store it in a different place or rename the GBL file.)
The Image Builder tool will wrap the GBL file in an OTA file. The tool can be found under the SDK directory tree ../gecko_sdk_suite/v2.5/protocol/thread/tool/image-builder/. The following command can be called in a terminal:
On the Light side open the console and check the network parameters using the info command and make sure it is on the same network as the OTA Server. The results should be similar to the lines below:
light_01> info
network status: 0x03
eui64: >000B57FFFE25FAFC
macExtendedId: >776A3C93A3776E86
network id: precommissioned
node type: 0x02
extended pan id: >4F8EC75FB4E1EFC6
pan id: 0x1075
channel: 19
radio tx power: 3 dBm
ula prefix: fd01::/64
mesh-local: fd01::1f0e:750c:b36:7ce5
link-local: fe80::756a:3c93:a377:6e86
To kickoff the search for an OTA Server use the following command:
light_01> ota-bootload-client update
The following lines should output to console:
Sent discovery command: .well-known/core?rt=urn:zcl:c.2000.s&
get 0x00
Using upgrade server discovery
Discovered server: fd01::63e6:a84:377c:3305->5683
If the server is discovered then the OTA transfer will start in ~1 minute (as we configured in OTA Bootload Client plugin).
Knowledge Base Articles
ZigBee and Thread
Hello,
This Thread is very helpful however, I've been trying to work through this with several attempts, I have been able to set up the IP-Driver and NCP without any problems,
The OTA-Server-Host seems to be working fine, it can also see my generated .OTA file "OTA Bootload Server Policy: GetNextImageCallback a=fd01::c663:4636:4ec6:ca9e m=0x1234 t=0x5678 v=0x00000001 m=0x1234 t=0x5678 v=0x00000002 s=0x00"
My OTA client (Light example) has joined the network, however on startup it displays;
After a short amount of time, I get an ASSERT reset
Setting up an OTA Server for Dotdot over Thread
This is a guide is for creating, building, and running a Dotdot OTA Server and Client using available sample applications. The OTA Server will be on a Host application on the Raspberry Pi that has an NCP connected. This KBA assumes that the user has reviewed UG116 and is familiar with running a Raspberry Pi Host with NCP. (Please note, it is not a requirement for the OTA Server to also be a Border Router).
This KBA was written with the following software tools:
With the following recommended hardware:
Sample Applications
Create projects for the following sample applications found in Gecko SDK version 2.5 through the Application Wizard. These can be found through the File menu going to File -> New -> Project -> Silicon Labs AppBuilder Project.
The Light and OTA Server are pre-commissioned and will be in the same network at startup, unless the devices were already in a previous network. Resetting the network parameters will coax the devices to enter the networking state-machine. The reset command is as follows:
OTA Server Configuration
The OTA Server (Host) Sample application has all the plugins required to be an OTA Server. Most notable are the following:
In OTA Server Sample app we recommend making the following changes for testing:
Generate, transfer to Raspberry Pi, Compile the OTA server application. Also, compile ip-driver-app found under v2.x/protocol/thread/ with the following command:
Light OTA Client Configuration
The OTA Client is based on the Light sample app. The following plugins are used to enable the OTA functionality. Here we assume the device you are using has external EEPROM:
In the OTA Bootload Client options set the following to maximize the recurrence of OTA Client/Server communication:
In the OTA Bootload Client Policy options note the following and/or set them to something unique. These will be used for creating the OTA image:
In the OTA Bootload Storage EEPROM plugin make sure the value of EEPROM OTA Storage End Address is one less than the value found in SPI Flash Storage Bootloader Slot 0 size (under the Storage tab). If the size does not match the download will fail.
We also recommend enabling the following plugins for testing:
As well as the following for debug output under the Printing tab:
Generate, Build, and Flash the Light application and bootloader to the EFR32.
Building OTA Image
Recall the values in OTA Bootload Client Policy plugin for the Light. In order for the Light application to flash an image it must verify if the image has met the criteria of the OTA policy. The Manufacturer ID, Image Type ID need to be the same, and the Firmware Version must be a higher value. We will need to create a second image with a higher version number. For example, the first image will be version 0x00000001 and the new image will have version 0x00000002. Go back to AppBuilder and update the project to have a higher version number by changing the setting, generating, and compiling. (Note: this will overwrite your old image. If it needs to be available store it in a different place or rename the GBL file.)
The Image Builder tool will wrap the GBL file in an OTA file. The tool can be found under the SDK directory tree ../gecko_sdk_suite/v2.5/protocol/thread/tool/image-builder/. The following command can be called in a terminal:
More information can be found in AN716: Instructions for Using Image-Builder
Kicking off OTA upgrade
Copy the OTA image to the same directory where the Server Host application is called. Start the ip-driver-app followed by the ota-server.
In ota-server call the following command to see if it has found the OTA image.
The output should be similar to the lines below:
On the Light side open the console and check the network parameters using the info command and make sure it is on the same network as the OTA Server. The results should be similar to the lines below:
To kickoff the search for an OTA Server use the following command:
The following lines should output to console:
If the server is discovered then the OTA transfer will start in ~1 minute (as we configured in OTA Bootload Client plugin).
Hello,
This Thread is very helpful however, I've been trying to work through this with several attempts, I have been able to set up the IP-Driver and NCP without any problems,
The OTA-Server-Host seems to be working fine, it can also see my generated .OTA file "OTA Bootload Server Policy: GetNextImageCallback a=fd01::c663:4636:4ec6:ca9e m=0x1234 t=0x5678 v=0x00000001 m=0x1234 t=0x5678 v=0x00000002 s=0x00"
My OTA client (Light example) has joined the network, however on startup it displays;
After a short amount of time, I get an ASSERT reset

Dose anyone have any Idea what I'm doing wrong?
Thanks
Bryce