Atmel AVR2131: Lightweight Mesh Getting Started Guide [APPLICATION NOTE]
42029A
−
AVR
−
09/2012
6
5.2
Over-the-Air upgrade
WSNDemo sample application includes a limited demo of the Over-the-Air (OTA) upgrade feature. Lightweight Mesh
SDK comes with a set of tools required to perform OTA upgrades. For further assistance with using this feature, please
contact technical support (
).
6.
Creating a new application
6.1
Starting from a template application
The best way to start a new standalone application is to use the provided
Template
application as a base, and make
custom modifications. Using template project files will ensure that all necessary components are included in the build,
and that all required definitions are present. The template application can be found in the
<SDK Root>/apps/Template
directory.
6.2
Starting from scratch
If Lightweight Mesh has to be integrated into a larger existing project, it is recommended to include all required files and
definitions into the existing project.
and
present a lists of files, include paths and
definitions that are required for normal Lightweight Mesh operation.
Table 6-1. Required files.
Platform
Files
Common for all platforms
<SDK Root>\nwk\src\nwk.c
<SDK Root>\nwk\src\nwkDataReq.c
<SDK Root>\nwk\src\nwkSecurity.c
<SDK Root>\nwk\src\nwkFrame.c
<SDK Root>\nwk\src\nwkRoute.c
<SDK Root>\nwk\src\nwkRx.c
<SDK Root>\nwk\src\nwkTx.c
<SDK Root>\sys\src\sys.c
<SDK Root>\sys\src\sysTimer.c
<SDK Root>\sys\src\sysEncrypt.c (only if security is enabled)
ZigBit
<SDK Root>\hal\atmega1281\src\hal.c
<SDK Root>\hal\atmega1281\src\halPhy.c
<SDK Root>\hal\atmega1281\src\halTimer.c
<SDK Root>\phy\at86rf230\src\phy.c
STK600-mega128rfa1,
RCB128RFA1
<SDK Root>\hal\atmega128rfa1\src\hal.c
<SDK Root>\hal\atmega128rfa1\src\halTimer.c
<SDK Root>\phy\atmega128rfa1\src\phy.c
RCB231
<SDK Root>\hal\atmega1281\src\hal.c
<SDK Root>\hal\atmega1281\src\halPhy.c
<SDK Root>\hal\atmega1281\src\halTimer.c
<SDK Root>\phy\at86rf231\src\phy.c