UG110
34 Rev. 1.0
• Waking up is accomplished via either act i vity on the SerialWire deb ugger or pressing BUTTON0 or
BUTTON1.
To measure deep slee p while the Packet Trac e Port cable is still attached, issue the "swjdisabl e 1" command in
Nodetest to disable the SerialWire/JTAG port, and place the S WJ pins in a low current state. While the SWJ is
disabled, the Packet Trace Port/debugger will not be functional until ei t her the command "swjdisable 0" is issued or
the chip resets.
8.4 Example of Opening, Building, and Programming an Application Builder Scenario
Application for EmberZNet PRO
Follow these steps to create, open, build, and program the HA Light scenario application as included with
EmberZNet. If you are working with other protocols, see QSG1 05, Getting Started with Si li con Labs Wireless
Networking Software, for similar instructions.
1. Open Ember Desktop.
2. From the menus, choose File > New > Application Framework Configuration.
3. Choose “ZCL Application Framework V2 ”, and click Next.
4. Choose the stack installation upon whi ch you’d like to base your application, such as “EmberZNet 5.3 GA
EM35X”, and click N ext.
5. Choose “Start from a selected sample appl ication:”, and click on “HaSampleLight”. Then click Next.
6. Enter a name for y our application, such as “MyLi ght ”, and click Finish.
7. Optional: Ma ke any desired changes to your appl ication configurat ion
8. Click the Generate button in the top right corner of the AppBuilder user interface.
9. If prompted to overwrite the callbacks. c file, make sure to leav e this option unselected ( don’ t overwrite).
10. After the generat i on results are display ed, click OK. Note the locati on of the EWW file, such as
C:\Users\{username}\Ember\EmberZNet5.3.0\EM35x\app\builder\MyLight\MyLight.eww
11. Open the EWW file for your application, such as MyLight.eww, in IAR Embedded Workbench for A RM
(EWARM). This can be done by either double clicking the MyLight.eww file (located in the
”app\builder\{appName}” subdirectory within your EmberZNet installation) or fro m i nside of EWARM using
File > Open > Workspace and navigating to the MyLight.eww file.
12. Select Project > Make (F7) from inside of EWARM.
13. After making the project, the firmware file used for programmi ng is found at
”{EmberZNet_Install_Dir}\build\MyLight\MyLight.ebl” (an ap pl ication image in Em ber bootloader file format)
14. To program this fi l e to the node, connect y our Debug Adapter (ISA3) to the chip and your computer (this
example assumes the Debug Adapter (ISA3) is connected via USB . See the next section for how t o
program if the Debug Adapter (ISA3) is connected via Ethernet.
15. Open a command line of your choice (such a s DOS or cygwin).
16. Navigate to the dire ct ory where the MyLight.ebl file was built.
17. Invoke the com m and " em3xx_load.exe" without any build option s. Thi s will ensure that em3xx_l oad.exe
can be found in your path and will cause em3x x_load.exe to print it s on-line help menu.
18. To download the EBL file to the EM357 chip, invoke the command "em3xx_l oad.exe MyLight.ebl". (Note
that this application also requires that you load bootloader firmware to the chip. This must be done before
the application firmware will run. Bootloader firmware can be f ound as *.s37 files within t he
tool/bootloader-em357 or bootloader-em351 directory within your stack installation and is loaded in a
manner similar to that of the *.ebl file above. I f bootloader firmware is not already present on the chip
when the application is loaded, em3xx_load wil l display a warning about a “bootloading and a pplication
mismatch”.)
19. Download will compl ete when em3xx_load prints the string "Run (b y toggling nRESET)".