ember em35x development kit user guide - 120-4030-000ember application development fundamentals...

37
UG113 Rev 0.1 Copyright © 2015 by Silicon Laboratories UG113 EM34 X DEVELOPMENT KIT USERS GUIDE Contents 1 About This Guide ............................................................................................................................................ 4 1.1 Purpose ................................................................................................................................................... 4 1.2 Audience.................................................................................................................................................. 4 1.3 Documentation Conventions..................................................................................................................... 4 2 Introducing the EM34x Development Kit .......................................................................................................... 4 2.1 Overview.................................................................................................................................................. 4 2.2 Development Kit Contents ........................................................................................................................ 5 2.3 Hardware Requirements .......................................................................................................................... 5 2.4 Software Requirements ............................................................................................................................ 5 2.5 Hardware ................................................................................................................................................. 5 2.6 Software .................................................................................................................................................. 6 2.7 Documentation......................................................................................................................................... 6 2.8 Before You Begin ..................................................................................................................................... 7 3 Development Kit Components ......................................................................................................................... 7 3.1 Overview.................................................................................................................................................. 7 3.2 Hardware ................................................................................................................................................. 8 3.2.1 EM341 Remote Control ..................................................................................................................... 8 3.2.2 EM35x Breakout Board ....................................................................................................................10 3.2.3 EM34x Modules ...............................................................................................................................11 3.2.4 Debug Adapter (ISA3) ......................................................................................................................12 3.3 Acceptable Power Sources for Normal Operation ....................................................................................12 3.3.1 USB Power Supply with Adapters.....................................................................................................13 3.4 Software .................................................................................................................................................13 3.4.1 Network Stack ..................................................................................................................................13 3.4.2 Hardware Abstraction Layer .............................................................................................................13 3.4.3 Sample Applications .........................................................................................................................14 3.4.4 Ember Desktop ................................................................................................................................15 4 Setting up Hardware Components ..................................................................................................................16 4.1 Overview.................................................................................................................................................16 4.2 EM34x Radio Communications Module (RCM) ........................................................................................16

Upload: others

Post on 05-Jun-2020

5 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Ember EM35x Development Kit User Guide - 120-4030-000Ember Application Development Fundamentals series (UG103) • Testing and Debugging Applications for the Ember EM2xx and EM35xxPlatforms

UG113

Rev 0.1 Copyright © 2015 by Silicon Laboratories UG113

EM34X DEVELOPMENT KIT USER’S GUIDE

Contents 1 About This Guide ............................................................................................................................................ 4

1.1 Purpose ................................................................................................................................................... 4

1.2 Audience .................................................................................................................................................. 4

1.3 Documentation Conventions..................................................................................................................... 4

2 Introducing the EM34x Development Kit .......................................................................................................... 4

2.1 Overview .................................................................................................................................................. 4

2.2 Development Kit Contents ........................................................................................................................ 5

2.3 Hardware Requirements .......................................................................................................................... 5

2.4 Software Requirements ............................................................................................................................ 5

2.5 Hardware ................................................................................................................................................. 5

2.6 Software .................................................................................................................................................. 6

2.7 Documentation ......................................................................................................................................... 6

2.8 Before You Begin ..................................................................................................................................... 7

3 Development Kit Components ......................................................................................................................... 7

3.1 Overview .................................................................................................................................................. 7

3.2 Hardware ................................................................................................................................................. 8

3.2.1 EM341 Remote Control ..................................................................................................................... 8

3.2.2 EM35x Breakout Board ....................................................................................................................10

3.2.3 EM34x Modules ...............................................................................................................................11

3.2.4 Debug Adapter (ISA3) ......................................................................................................................12

3.3 Acceptable Power Sources for Normal Operation ....................................................................................12

3.3.1 USB Power Supply with Adapters .....................................................................................................13

3.4 Software .................................................................................................................................................13

3.4.1 Network Stack ..................................................................................................................................13

3.4.2 Hardware Abstraction Layer .............................................................................................................13

3.4.3 Sample Applications .........................................................................................................................14

3.4.4 Ember Desktop ................................................................................................................................15

4 Setting up Hardware Components ..................................................................................................................16

4.1 Overview .................................................................................................................................................16

4.2 EM34x Radio Communications Module (RCM) ........................................................................................16

Page 2: Ember EM35x Development Kit User Guide - 120-4030-000Ember Application Development Fundamentals series (UG103) • Testing and Debugging Applications for the Ember EM2xx and EM35xxPlatforms

UG113

2 Rev. 0.1

4.3 Hardware Connections ............................................................................................................................16

4.4 Connecting the Breakout Board and RCM ...............................................................................................17

4.5 Breakout Board Power Configurations .....................................................................................................17

4.6 Breakout Board Serial Configurations ......................................................................................................19

4.7 Common Hardware Configurations ..........................................................................................................19

4.8 Connecting the RF Cable to the RCM ......................................................................................................24

5 Installing the Software ....................................................................................................................................25

5.1 Overview .................................................................................................................................................25

5.2 Installing the Ember Stack .......................................................................................................................25

5.3 Installing Ember Desktop.........................................................................................................................25

5.4 Installing IAR Embedded Workbench for ARM .........................................................................................25

5.5 Installing the Debug Adapter (ISA3) Utilities ............................................................................................25

5.6 Installing FTDI USB Drivers .....................................................................................................................26

6 Using the Debug Adapter (ISA3) ....................................................................................................................26

6.1 Overview .................................................................................................................................................26

6.2 Connectivity and Power ...........................................................................................................................26

6.3 Ethernet Settings ....................................................................................................................................27

6.4 Using the Admin Interface over USB .......................................................................................................27

6.5 Using the Admin Interface over Ethernet .................................................................................................27

6.6 Using the Serial Ports..............................................................................................................................28

6.7 Updating the Firmware ............................................................................................................................28

7 Debug Adapter (ISA3) Commands .................................................................................................................29

7.1 Syntax Conventions ................................................................................................................................29

7.2 Entering Commands ...............................................................................................................................29

7.3 Command List .........................................................................................................................................29

7.3.1 button...............................................................................................................................................29

7.3.2 debug...............................................................................................................................................30

7.3.3 config ...............................................................................................................................................30

7.3.4 connections ......................................................................................................................................30

7.3.5 help ..................................................................................................................................................30

7.3.6 hostname .........................................................................................................................................31

7.3.7 ip......................................................................................................................................................31

7.3.8 port ..................................................................................................................................................31

7.3.9 power ...............................................................................................................................................31

7.3.10 reset ................................................................................................................................................32

Page 3: Ember EM35x Development Kit User Guide - 120-4030-000Ember Application Development Fundamentals series (UG103) • Testing and Debugging Applications for the Ember EM2xx and EM35xxPlatforms

UG113

Rev. 0.1 3

7.3.11 usbaddr ............................................................................................................................................32

7.3.12 version .............................................................................................................................................32

8 Software Tools Overview................................................................................................................................33

8.1 Running the remote control sample application........................................................................................33

8.2 Programming your Application on the EM34x ..........................................................................................35

8.3 Programming Manufacturing Tokens .......................................................................................................36

8.3.1 Programming Certificates & Installation Codes .................................................................................36

8.4 Using the Debugger in IAR Embedded Workbench with an Ember Debug Adapter (ISA3) .......................36

Page 4: Ember EM35x Development Kit User Guide - 120-4030-000Ember Application Development Fundamentals series (UG103) • Testing and Debugging Applications for the Ember EM2xx and EM35xxPlatforms

UG113

4 Rev. 0.1

1 About This Guide 1.1 Purpose This document describes the EM34x Development Kit and explains how to set up its hardware and use the Ember Debug Adapter (ISA3). For information on developing and debugging applications with Ember Desktop, see its on-line HTML help. See section 2.7, Documentation, for a list of other EM3xx documents of interest.

1.2 Audience This document is intended for embedded software and hardware engineers who are responsible for developing wireless applications with the ZigBee Remote Control (ZRC) Development Kit. This document assumes that the reader has a solid understanding of embedded systems design and programming in the C language. Experience with networking and radio frequency systems is useful but not expected.

1.3 Documentation Conventions

Notation Meaning Example

Italics Identifies on-screen software menu options. Connect

UPPERCASE Identifies a keyboard key. ENTER

Right-angle bracket Delimits a series of software program menu options to be clicked. Open > Save

Courier Identifies software code and, in body text, variables.

void Main(String[] argv) the buffer variable

Courier Italics Identifies a variable name. ipAddress

2 Introducing the EM34x Development Kit 2.1 Overview The EM34x Development Kit is used for evaluation and application design and development. The Development Kit contains a variety of hardware for quickly creating a prototype of the customer’s hardware, EmberZNet, Silicon Labs' implementation of the ZigBee ZRC stack software specification, and various development tools that enable the development of the customer’s application software. EmberZNet runs on top of an IEEE 802.15.4-compliant radio and link layer software. Combined with the powerful IEEE 802.15.4 compliant EM34x radios, the EmberZNet network stack provides complete networking services from the physical layer up to a reliable application profile support layer. The stack produces ZRC networks that are reliable, flexible, secure, and easy to use. EmberZNet provides a common Application Programming Interface (API) that utilizes the underlying layers. This API provides support for the following layers of the Open System Interconnection Reference Model (OSI Model): • PHY: radio control • MAC: medium access • NETWORK: routing, association • APPLICATION: Application Profile Support for reliable message delivery The Development Kit includes Ember Desktop, which facilitates application development and debugging. The Debug Adapter (ISA3) incorporates Power-over-Ethernet (PoE) capability, which can simplify node deployment in

Page 5: Ember EM35x Development Kit User Guide - 120-4030-000Ember Application Development Fundamentals series (UG103) • Testing and Debugging Applications for the Ember EM2xx and EM35xxPlatforms

UG113

Rev. 0.1 5

the test environment. The Breakout Board provides a direct connection for debugging customer-designed hardware, while the remote control provides a low cost, form factor reference design. For detailed information about the EM35x Breakout Board, see document TS6, EM35xx Breakout Board Technical Specification.

2.2 Development Kit Contents Table 1 summarizes the components and the specified count for each component in the EM34x Development Kit.

Table 1. EM34x Development Kit Components Component EM34x Development Kit EM341 Remote Control 1 Debug Adapter (ISA3) 1 EM35x Breakout Board 1 EM34x Modules 4 Data Emulation Interface (DEI) Cable 1 Packet Trace Port Cable 1 Radio Frequency Cable 1 EM34x Quick Start Guide 1 AA Batteries 2 Ethernet Cable 1 USB Cable 1 USB Power Brick 1

2.3 Hardware Requirements • PC with Ethernet connectivity • Network hub with DHCP server

2.4 Software Requirements • Microsoft Windows XP or Windows 7 • Java, version 1.6 or later • Adobe Acrobat Reader (available free from http://get.adobe.com/reader/)

2.5 Hardware • Remote Control provides a low cost, single-sided, form factor reference design. The remote is programmable

via the Packet Trace connector and Debug Adapter (ISA3). It provides an ideal solution to quickly prototype and develop a fully functioning ZRC remote control application

• Breakout Board serves as a test bed for network hardware and applications. The Breakout Board will have an associated EM34x Module, which can be deployed as a node within a network application. The Breakout Board connects with a Debug Adapter (ISA3) through two communication links: the Packet Trace Port and the DEI Port. This allows the Breakout Board’s EM34x Module to interface with Ember Desktop through the Debug Adapter (ISA3)’s Packet Trace Port and its wired Ethernet connection. These interconnections are described later in this chapter. The Breakout Board also has a prototype breadboard area for application-specific hardware development.

• EM34x modules contain the EM34x System-on-Chip (SoC) solution providing a complete radio and microcontroller solution. The kit includes both EM341 (ZRC Controller) and EM346 (ZRC Target) module variants.

Page 6: Ember EM35x Development Kit User Guide - 120-4030-000Ember Application Development Fundamentals series (UG103) • Testing and Debugging Applications for the Ember EM2xx and EM35xxPlatforms

UG113

6 Rev. 0.1

• Debug Adapter (ISA3) connects a Breakout Board to the Ethernet. The adapter transmits network data collected through its Packet Trace Port and conveys it over its Ethernet connection to Ember Desktop. It also picks up any messages or new software that is addressed to the Breakout Board.

The Packet Trace Port is a cabled communication link between the Debug Adapter (ISA3) and the EM34x Module mounted on the Breakout Board. It can also be used to program the remote control. • Packet Trace Port Cable connects Debug Adapter (ISA3) to a Breakout Board. • USB Power Supply with Adapters power the Breakout Board and/or Debug Adapter (ISA3) from wall socket. • Ethernet Cable connects the Debug Adapter (ISA3) to an Ethernet subnet. • Data Emulation Interface (DEI) cable provides a peripheral interface connection between the Debug Adapter

(ISA3) and Breakout Board. The DEI cable supports UART functionality.

2.6 Software After registering for ZigBee software access on the Silicon Labs technical support portal, the software components can be obtained online through the “Software Releases” tab. Refer to the QSG100 for information on downloading the latest version of the software via Silicon Labs’ technical support portal, https://siliconlabs.force.com.

• Ember Desktop • EmberZNet • ISA3 Utilities (drivers and executables to manage the Debug Adapter (ISA3) • IAR Embedded Workbench for ARM

Licenses and support are provided separately and can be obtained from IAR Systems at http://www.iar.com.

Note: The appropriate IAR Embedded Workbench version varies with the revision of EmberZNet. Check the release notes to verify which IAR compiler version you should use.

2.7 Documentation QSG100, the EM34x Development Kit Quick-Start Guide, is shipped with the EM34x Development Kit. All other documented listed below are available from Silicon Labs’ website (www.silabs.com) via the Search toolbar as Adobe PDF files or as on-line HTML help:

• The Ember Application Development Fundamentals series (UG103) • Testing and Debugging Applications for the Ember EM2xx and EM35xx Platforms (UG104) • Advanced Application Programming with the Stack and HAL APIs (UG105) • EM35x Breakout Board Technical Specification (TS6) • EM3xx Module Technical Specification (TS8) • Ember Debug Adapter (ISA3) Technical Specification (TS7) • EM341 Remote Control Reference Design • EM341, EM342 and EM346 Data Sheet • Ember Desktop on-line HTML help • Application notes (various)

Page 7: Ember EM35x Development Kit User Guide - 120-4030-000Ember Application Development Fundamentals series (UG103) • Testing and Debugging Applications for the Ember EM2xx and EM35xxPlatforms

UG113

Rev. 0.1 7

2.8 Before You Begin The EM34x Development Kit is designed only for the operating conditions and interfaces specified in documents TS7, Debug Adapter (ISA3) Technical Specification, TS6, EM35x Breakout Board Technical Specification, and TS8, EM3xx Module Technical Specification. Any modifications or alterations to the hardware are liable to cause irreparable damage to the EM34x Development Kit, and shall render its warranty null and void. If you wish to use the EM34x Development Kit in a non-standard fashion, consult with Silicon Labs Customer Support or Sales before starting custom development. This is especially true if you are embarking on an aggressive development cycle, plan to use custom hardware, or wish to use alternate software configuration files, images, or hardware configurations. Contact us and describe your plan, so we can help you minimize the risk of delays in your development cycle.

3 Development Kit Components 3.1 Overview Figure 1 shows the key components in the EM34x Series Development Kit.

Figure 1. EM34x Series Development Kit

This chapter describes the hardware and software components in the EM34x Series Development Kit.

Page 8: Ember EM35x Development Kit User Guide - 120-4030-000Ember Application Development Fundamentals series (UG103) • Testing and Debugging Applications for the Ember EM2xx and EM35xxPlatforms

UG113

8 Rev. 0.1

3.2 Hardware The EM34x Series Development Kit development board set has four major hardware components:

• EM341 Remote Control • EM35x Breakout Board • EM34x Modules • Debug Adapter (ISA3) The EM34x Series Development Kit also includes the following components:

• USB Power Adapter • Miscellaneous Cables (Ethernet, USB, DEI, Packet Trace Port, and RF Coax)

3.2.1 EM341 Remote Control

The Remote Control has the following features:

• 47 buttons • Bi-color backlit Power button • Packet Trace connector (under battery cover) • Powered by 2x AAA batteries

The case is secured by 8 locking tabs (see figure for approximate location). Care should be taken if opening the case as the tabs may break. The remote must be in the case for the batteries and keyboard to function properly.

Page 9: Ember EM35x Development Kit User Guide - 120-4030-000Ember Application Development Fundamentals series (UG103) • Testing and Debugging Applications for the Ember EM2xx and EM35xxPlatforms

UG113

Rev. 0.1 9

Figure 2. Remote Control

For information about the Remote Control, see the reference design files at http://www.silabs.com/products/wireless/zigbee/Pages/zigbee-reference-designs.aspx

Page 10: Ember EM35x Development Kit User Guide - 120-4030-000Ember Application Development Fundamentals series (UG103) • Testing and Debugging Applications for the Ember EM2xx and EM35xxPlatforms

UG113

10 Rev. 0.1

3.2.2 EM35x Breakout Board

Figure 3. EM35x Breakout Board

The Breakout Board (Figure 3) has the following components:

• External power supply connectors • One DB-9 serial port connector for RS-232 serial communication • One USB connector for EM35x SC1 virtual COM port serial communication • One header with TTL-compliant UART signals for EM35x SC1 SPI serial communication • A buzzer, two buttons, two LEDs, and a temperature sensor for application development purposes • Hardware reset buttons for the EM34x module • Prototype or bread-boarding area (28 x 20, 0.1” pitch array) for application-specific hardware development • One data emulation interface connector For detailed information about the Breakout Board, see document TS6, the EM35x Breakout Board Technical Specification.

Page 11: Ember EM35x Development Kit User Guide - 120-4030-000Ember Application Development Fundamentals series (UG103) • Testing and Debugging Applications for the Ember EM2xx and EM35xxPlatforms

UG113

Rev. 0.1 11

3.2.3 EM34x Modules The EM34x Series Development Kit Module pictured in Figure 4 is used together with the Development Kit Breakout Board to prototype customer hardware, and to develop and debug application software. Its low-power design represents a good starting point for your own product design.

Figure 4. EM35x Breakout Board with EM34x Module installed

The EM34x Module includes these components:

• The Ember EM34x SoC (IEEE 802.15.4-compliant, 2.4 GHz radio transceiver with ARM® Cortex-M3 microcontroller).

• All off-chip components required for optimum SoC performance • Two LEDs • Packet Trace Port connector For detailed information about the modules, see document TS8, the EM3xx Module Technical Specification. Once you move away from the EM3xxx Module and toward application-specific hardware, refer to the extensive Ember reference design library at http://www.silabs.com/products/wireless/zigbee/Pages/zigbee-reference-designs.aspx. Each reference design provides a schematic, Bill of Materials (BOM), characterization data, and layout files. They are designed and delivered in a manner that reduces both time to market and hardware implementation risk. For assistance in locating the best design for your needs, contact support at www.silabs.com/zigbee-support.

EM34x Module

Page 12: Ember EM35x Development Kit User Guide - 120-4030-000Ember Application Development Fundamentals series (UG103) • Testing and Debugging Applications for the Ember EM2xx and EM35xxPlatforms

UG113

12 Rev. 0.1

3.2.4 Debug Adapter (ISA3) The Debug Adapter (ISA3) provides an efficient and configurable debug interface to the Development Kit Breakout Board for processing emulation and debug commands. It also provides an interface to Ember Desktop for monitoring and managing network data. The Debug Adapter (ISA3) has the following components:

• Debug Port interface to the Breakout Board’s Extended Debug Interface Connector • Packet Trace Port interface to the radio communication module, providing programming and debugging

services • TCP/IP 10/100 Ethernet interface with Power-over-Ethernet functionality • USB Interface

3.3 Acceptable Power Sources for Normal Operation Table 2 lists all of the components and the acceptable combinations of power sources that yield normal operation for the EM35x Breakout Board. Potential power sources include the following:

• Power-Over-Ethernet (PoE) Switch • USB cable

• Connected to PC • Connected to USB Power Supply with Adapters

• Power over Packet Trace Port on Debug Adapter (ISA3) (the target power select switch on the front panel must be set to Int (Internal)).

• From RCM dedicated power • External dc adapter (not supplied with the Development Kit)

Table 2. Safe Combination of Operating Power

PoE External DC Packet Trace Port USB Breakout

Board Debug Adapter (ISA3) X N/A N/A X N/A EM34x Module N/A N/A X1 N/A X EM35x Breakout Board N/A X2 X3 X N/A Notes:

1. Power is sourced from the Debug Adapter (ISA3) to the RCM module using the Packet Trace Port cable connected to the Debug Adapter (ISA3) with its target power select switch set to Int (Internal).

2. External dc power between 4 V and 20 V can be connected to clip leads J1 (+) and J32 (-) on the EM35x Breakout Board.

3. Power is sourced from the Debug Adapter (ISA3) to the EM35x Breakout Board using the Packet Trace Port cable connected to the Debug Adapter (ISA3) with its target power select switch set to Int (Internal).

Page 13: Ember EM35x Development Kit User Guide - 120-4030-000Ember Application Development Fundamentals series (UG103) • Testing and Debugging Applications for the Ember EM2xx and EM35xxPlatforms

UG113

Rev. 0.1 13

3.3.1 USB Power Supply with Adapters The USB power adapter (Figure 5) is a linear regulated wall plug power supply with 5 V dc at 1 A regulated output. It has a USB type-B connector for connecting power via a USB cable to the USB port of the Debug Adapter (ISA3) or Breakout Board. Four interchangeable snap-in input plugs are provided with various port configurations suitable for various locales: North America, Europe, United Kingdom, and Australia.

Figure 2. USB Power Supply with Interchangeable AC Adapters

3.4 Software The EM34x Development Kit provides customers with access to the following software components:

• Network Stack • Hardware Abstraction Layer • Ember Application Framework with sample scenarios • Ember Desktop

3.4.1 Network Stack The EmberZNet provides an advanced implementation of the ZigBee Remote Control 2.0 specification. ZigBee Remote Control provides a global standard for advanced RF remotes that removes line-of-sight restrictions while also delivering two-way communication and longer range

3.4.2 Hardware Abstraction Layer The hardware abstraction layer (HAL) acts as a conduit between the network stack and the node processor and radio. Separating network stack functionality from the specific hardware implementation enables easy portability. HAL code is provided as a combination of pre-built libraries for complex, stack-critical functionality and C source code that you can alter in order to customize, extend, or reduce device functionality across various hardware platforms.

Page 14: Ember EM35x Development Kit User Guide - 120-4030-000Ember Application Development Fundamentals series (UG103) • Testing and Debugging Applications for the Ember EM2xx and EM35xxPlatforms

UG113

14 Rev. 0.1

3.4.3 Sample Applications The Ember ZNET ZRC software contains sample applications. These demonstrate aspects of the ZRC stac kbased on the ZRC 2.0 specification. Silicon Labs provides an IAR project and workspace file for each application as well as a S.37 binary file. Table 4 lists the sample applications that are in the current distribution. All applications are in the app directory.

Table 3. Development Kit Sample Applications Application name Directory Description

ZRC 2.0 Controller ZRC

The ZRC2.0 controller application demonstrates basic ZRC network functionality and ZRC2.0 application functionality. This application acts as a generic remote control. It utilizes the ZRC Profile plugin to provide core application-level ZRC functionality and the ZRC GDP and ZRC2.0 plugins to provide ZRC2.0-specific behavior.

ZRC 2.0 Target ZRC

The ZRC2.0 target application demonstrates basic ZRC network functionality and ZRC2.0 application functionality. This application acts as a generic target device. It utilizes the ZRC Profile plugin to provide core application-level ZRC functionality and the ZRC GDP and ZRC2.0 plugins to provide ZRC2.0-specific behavior.

The target will automatically start the network. The controller is responsible for initiating pairing to an existing network. The controller application will disable its receiver automatically to conserve power. This is representative of a sleepy device that is generally a transmit-only device that acts when directed by the user (i.e., a button press). The controller application is allowed to pair to two targets, i.e., a set-top box (STB) and a TV target. The target application acts as either a STB or a TV target and can accept up to maximum 5 pairings. Pressing and holding the PAIR button and then pressing the STB button on the controller will cause the device to initiate the binding process to discover, pair and validate with a target. Note: When remote control is connected to the Ember Adapter (ISA3), the controller firmware will auto-remap some key-matrix GPIO pins for debugging and some buttons will not be available. The key combination for pairing when debugging are changed as shown below:

• Press SETUP + TV keys to bind to the TV target • Press SETUP + STB keys to bind to the STB target

The ZRC GDP and ZRC ZRC2.0 plugins manage discovery, pairing, and validation and notify the application when binding completes. If the binding completes successfully, the controller can begin sending actions to the target. Pressing the STB or the TV button switches the controller to STB or TV mode accordingly. Buttons pressed in STB mode will be sent to the STB target and buttons pressed in TV mode will be sent to the TV. Depending on the mode, either an RF or IR signal will be generated. Some keys (such as power) may send both an RF command and an IR command. When actions are sent, the ZRC ZRC2.0 plugin will keep track of timing in order to automatically repeat actions for keys that are held down. The target provides feedback by playing tunes. A rising two-tone tune indicates a successful operation while a falling two-tone tune indicates a failure. A brief tone indicates that the device has performed a long-running action and is waiting for a result. All application code is contained in the ZRC-callbacks.c files within each application directory.

Page 15: Ember EM35x Development Kit User Guide - 120-4030-000Ember Application Development Fundamentals series (UG103) • Testing and Debugging Applications for the Ember EM2xx and EM35xxPlatforms

UG113

Rev. 0.1 15

3.4.4 Ember Desktop Ember Desktop is a graphical tool incorporating a Network Analyzer utility that manages the Development Kit hardware and displays network and node activity in real time (see Figure 6). It provides a rich and flexible interface to Ember-embedded networks, which helps you develop and debug new network applications. Ember Desktop includes these features:

• Ember AppBuilder, a tool for generating ZigBee-compliant applications, made up of the Ember application framework and a graphical tool for configuring the included source code. Ember AppBuilder gives you an interface for turning on or off embedded clusters and features in the code compiled into a finished application.

• An Integrated Development Environment (IDE) with multiple editor panes that provide tiered views of network activity, letting you drill down from a high-level map of node interactions to the details of each packet.

• Customizable filters that let you specify exactly which network activities to display. • Log files that save captured data, so you can step through transactions and events for detailed analysis. • A file browser that lets you easily upload new applications to any connected node. An Adapters view shown in Figure 6 allows you to interact with the Debug Adapter (ISA3) and RCM to download new firmware, reset, and manage each of the devices.

Figure 3. Ember Desktop

For detailed information about Ember Desktop, refer to Ember Desktop’s on-line HTML help.

Page 16: Ember EM35x Development Kit User Guide - 120-4030-000Ember Application Development Fundamentals series (UG103) • Testing and Debugging Applications for the Ember EM2xx and EM35xxPlatforms

UG113

16 Rev. 0.1

4 Setting up Hardware Components 4.1 Overview This chapter contains the following sections:

• EM34x Radio Communications Module (RCM) • Hardware Connections • Connecting the Breakout Board and RCM • Breakout Board Power Configurations • Breakout Board Serial Configurations • Common Hardware Configurations • Connecting the RF Cable to the RCM

4.2 EM34x Radio Communications Module (RCM) The EM34x Series Development Kit contains various types of EM34x Radio Communications Modules designed by Silicon Labs’ partner, California Eastern Laboratories (CEL). These modules contain either the EM341 or EM346 IC and are configured to use either the PCB antenna or the on-board RF connector (U.FL). These configuration options are noted in the Module Product Label, as shown the example label in Figure 7. This label can be found on the bottom of the module. The top line contains the Silicon Labs Part Number, while the bottom line contains the Module Serial Number. The Module Serial Number is also listed in the Hardware Identification List attached to your Quick Start Guide. You can determine the EUI-64 of each module based on this list.

Figure 4. Module Product Serial Number Label

The module shipped already installed on the Breakout Board is module variant EM346-MOD-ANT-C. All other module variants are contained in the EM34x Development Kit. Refer to Table 5 for configuration comparisons of the modules included in your development kit.

Table 4. Module Product Variant Matrix

Silicon Labs Part Number CEL Part Number

Silicon Labs

Product Number IC

Antenna or Connector

PA or non-PA

Qty Included

in Kit EM341-MOD-ANT-C ZICM341SP0-1-SL 0740 EM341 Antenna Non-PA 1 EM341-MOD-RF-C ZICM341SP0-1C-SL 0741 EM341 Connector Non-PA 1 EM346-MOD-ANT-C ZICM346SP0-1-SL 0742 EM346 Antenna Non-PA 1 EM346-MOD-RF-C ZICM346SP0-1C-SL 0743 EM346 Connector Non-PA 1

4.3 Hardware Connections To avoid communication problems, verify that the radio communication module is firmly seated in its Breakout Board connector, and its Packet Trace Port cable is properly seated.

Page 17: Ember EM35x Development Kit User Guide - 120-4030-000Ember Application Development Fundamentals series (UG103) • Testing and Debugging Applications for the Ember EM2xx and EM35xxPlatforms

UG113

Rev. 0.1 17

4.4 Connecting the Breakout Board and RCM Refer to document EM34x Quick Start Guide, included in your development kit for detailed step-by-step instructions for setting up your hardware.

CAUTION: Observe electrostatic discharge (ESD) precautions when removing, handling, or replacing RF communication modules.

To remove the radio communication module: Carefully pull the RCM away from the Breakout Board. To attach the radio communication module: Align the radio communication module to its footprint outline on the Breakout Board, and then press it into place. Make sure that the RCM sits firmly in its mating connector. To attach the Debug Adapter (ISA3):

1. Plug the Packet Trace Port cable into the Debug Adapter (ISA3). 2. Plug one end of the Packet Trace Port cable into the 10-pin Packet Trace Port (J31) on the Breakout

Board, and the other end into the Debug Adapter (ISA3). If desired, the Packet Trace Port cable may be connected directly to the RCM instead of the Breakout Board, but the Breakout Board connector allows for straight cable paths and more convenient swapping of modules.

3. Verify that the Debug Adapter (ISA3)’s Target Power Select switch is set to Int (Internal). To remove the Debug Adapter (ISA3):

1. Unplug the Packet Trace Port cable from the Breakout Board (or radio communication module). 2. Unplug the Packet Trace Port cable from the Debug Adapter (ISA3).

4.5 Breakout Board Power Configurations The Breakout Board may be powered in one of four ways: • Breakout Board Power Supplied by Debug Adapter (ISA3) (Figure 8): The default configuration is to supply

power via the Debug Adapter (ISA3) and Packet Trace Port cable. Ensure the power switch on the Debug Adapter (ISA3) is in the INT (Internal) position. The power supply of the Debug Adapter (ISA3) is also controlled via the admin interface. You may need to connect to the admin port of the Debug Adapter (ISA3) and issue the “power on” command. No external power supply should be connected to the Breakout Board when supplying power from the Debug Adapter (ISA3). The power supply jumper on the Breakout Board should be in the

Page 18: Ember EM35x Development Kit User Guide - 120-4030-000Ember Application Development Fundamentals series (UG103) • Testing and Debugging Applications for the Ember EM2xx and EM35xxPlatforms

UG113

18 Rev. 0.1

horizontal position, connecting V_ISA to the center pin. The V_ISA LED (DS3) will illuminate when power is applied.

Figure 5. Breakout Board Power Supplied by Debug Adapter (ISA3)

• Breakout Board Power Supplied by USB (Figure 9): The Breakout Board may also be powered through the USB connector (J5), either using a USB cable plugged in to the USB power adapter included in the development kit, or by connecting it to your PC. The power supply jumper on the Breakout Board should be in the lower vertical position, connecting V_REG to the center pin. The V_FTDI LED (DS2) will illuminate when power is applied. When powering the Breakout Board in this way, ensure the power switch on the Debug Adapter (ISA3) is in the EXT (External) position.

Figure 6. Breakout Board Power Supplied by USB (J5)

• Breakout Board Power Supplied by DC Jumpers (Figure 10): The Breakout Board may also be powered by an external power source that provides 4-20 V dc. The power supply should be connected to jumpers J1 (+

Page 19: Ember EM35x Development Kit User Guide - 120-4030-000Ember Application Development Fundamentals series (UG103) • Testing and Debugging Applications for the Ember EM2xx and EM35xxPlatforms

UG113

Rev. 0.1 19

supply) and J32 (ground). The power supply jumper on the Breakout Board should be in the lower vertical position, connecting V_REG to the center pin. The VIN LED (DS1) will illuminate when power is applied. When powering the Breakout Board in this way, ensure the power switch on the Debug Adapter (ISA3) is in the EXT (External) position.

Figure 7. Breakout Board Power Supplied by DC Jumpers

4.6 Breakout Board Serial Configurations Serial connectivity to the Breakout Board can be made in a number of ways. The default configuration of your development kit will match your expected usage scenario. • To use the pass-through UART feature of the Debug Adapter (ISA3): Plug the larger 12-pin DEI cable into

the DEI header on the Breakout Board and the connector on the Debug Adapter (ISA3). Ensure that jumpers are installed across the 8th (PB2) and 10th (PB1) rows of headers next to the DEI port on the Breakout Board to pass the UART RX and TX signals through. The serial port selection jumpers between the USB and DB-9 connectors should be removed, or placed on their center pins. Connection to the UART pass-through port can then be made using either of the two options below:

a. Connect to the Debug Adapter (ISA3) using Ember Desktop. Launch the console. Choose the Serial 1 tab.

b. Run a terminal application (for example, Microsoft Telnet Client, HyperTerminal, PuTTY). Connect to port 4901 on the Debug Adapter (ISA3).

• To use the RS-232 interface: Connect a serial cable to the DB-9 connector on the Breakout Board. Ensure the four jumpers above the DB-9 connector are positioned towards the DB-9 connector to send the UART signals to the RS-232 transceiver, and remove the jumpers from the row of headers next to the DEI port or make sure the DEI cable is disconnected.

• To use the USB interface: Install the FTDI USB drivers as described in Section 5.6, Installing FTDI USB Drivers, and connect a USB cable to J5 of the Breakout Board and to your PC. Ensure the four jumpers above the DB-9 connector are positioned towards the USB connector to send the UART signals to the FTDI chip, and remove the jumpers from the row of headers next to the DEI port or make sure the DEI cable is disconnected.

4.7 Common Hardware Configurations Common configurations of the Breakout Board and Debug Adapter (ISA3) can be seen in Figure 13, Figure 14, Figure 15 and Figure 16.

Page 20: Ember EM35x Development Kit User Guide - 120-4030-000Ember Application Development Fundamentals series (UG103) • Testing and Debugging Applications for the Ember EM2xx and EM35xxPlatforms

UG113

20 Rev. 0.1

Figure 8. Debug Adapter (ISA3) Supplying Power; Pass-through UART Being Used for Serial

Communication

Page 21: Ember EM35x Development Kit User Guide - 120-4030-000Ember Application Development Fundamentals series (UG103) • Testing and Debugging Applications for the Ember EM2xx and EM35xxPlatforms

UG113

Rev. 0.1 21

Figure 9. Debug Adapter (ISA3) Connecting Packet Trace to Remote Control for programming

Page 22: Ember EM35x Development Kit User Guide - 120-4030-000Ember Application Development Fundamentals series (UG103) • Testing and Debugging Applications for the Ember EM2xx and EM35xxPlatforms

UG113

22 Rev. 0.1

Figure 10. Power Supplied Via USB Connector; Pass-through UART Being Used for Communication

Page 23: Ember EM35x Development Kit User Guide - 120-4030-000Ember Application Development Fundamentals series (UG103) • Testing and Debugging Applications for the Ember EM2xx and EM35xxPlatforms

UG113

Rev. 0.1 23

Figure 11. Debug Adapter (ISA3) Supplying Power; FTDI Serial <-> USB Converter Used for Communication

Page 24: Ember EM35x Development Kit User Guide - 120-4030-000Ember Application Development Fundamentals series (UG103) • Testing and Debugging Applications for the Ember EM2xx and EM35xxPlatforms

UG113

24 Rev. 0.1

4.8 Connecting the RF Cable to the RCM As detailed in Table 5, depending on the configuration of the module, some RCMs include a PCB antenna while others include an RF connector (type U.FL) where an external antenna can be connected via an RF adapter cable. See Figure 18 for an example of a module with a PCB antenna. The RF connector may also be used as a connection to test equipment. The development kit contains an RF adapter cable (type U.FL) that plugs into the RF Connector on these modules. See Figure 19 for an example of a module with this RF connector.

Figure 12. Module with PCB Antenna

Figure 13. Module with U.FL RF Connector

RF Connector

Page 25: Ember EM35x Development Kit User Guide - 120-4030-000Ember Application Development Fundamentals series (UG103) • Testing and Debugging Applications for the Ember EM2xx and EM35xxPlatforms

UG113

Rev. 0.1 25

5 Installing the Software 5.1 Overview Ember software for the EM34x platform is distributed through Silicon Labs’ support portal at www.silabs.com/zigbee-support. You must contact Customer Support for a portal username.

5.2 Installing the Ember Stack The Ember Stack installer, ember-stack-<version>-em35x-dev.exe, should be installed first. It performs the following actions:

1. Installs the files needed to develop applications on the Ember Stack into a directory specified by the user (The default location is C:\Users\{username}\Ember\{release name}\em35x.)

2. Adds a shortcut to the Start Menu into the folder specified by the user (default directory is Ember\{release name}\em35x).

3. Adds an entry to “Add/Remove Programs” (accessed from Windows Control Panel) so the stack can be uninstalled.

This release should be installed in a different directory from prior installations. It is possible for multiple installations to exist together.

5.3 Installing Ember Desktop Ember Desktop can be installed by running the Ember_Desktop_Installer_<version>.exe self-extracting executable found on the portal. the EM34x Quick Start Guide, included in your EM34x Development Kit, provides details about installing Ember Desktop for the first time and running the First-Time Setup Wizard.

5.4 Installing IAR Embedded Workbench for ARM A link to a 30-day evaluation version of EWARM in included in the EM34x Quick Start Guide.

Note: The appropriate IAR Embedded Workbench version varies with the revision of EmberZNet. Check the release notes to verify which IAR compiler version you should use. Refer to the “Quickstart Installation Information” section of the IAR installer for additional information about the installation process and how to configure your license.

5.5 Installing the Debug Adapter (ISA3) Utilities The installer ISA3_Utilites_<version>.exe performs the following actions:

1. Installs the USB driver for the Debug Adapter (ISA3). 2. Installs the following command line utilities:

• em3xx_load.exe • em3xx_isa.exe • em3xx_convert.exe

3. Adds an entry to “add/remove programs” (accessed from Windows Control Panel) so that the utilities can be uninstalled.

4. Modifies your PATH environment variable so that the command line utilities can be easily executed from a Windows Command Prompt.

Note: The Debug Adapter (ISA3) Utilities installer should always be run after all previous installers, including after IAR Embedded Workbench for ARM.

Page 26: Ember EM35x Development Kit User Guide - 120-4030-000Ember Application Development Fundamentals series (UG103) • Testing and Debugging Applications for the Ember EM2xx and EM35xxPlatforms

UG113

26 Rev. 0.1

5.6 Installing FTDI USB Drivers To use the FTDI USB interface of the Breakout Board for UART connectivity, you must install the drivers for the FTDI USB<->Serial converter. You can obtain this driver from FTDI at http://www.ftdichip.com/Drivers/VCP.htm. These drivers are not required if you connect to the UART of the Breakout Board using the RS-232 port or via the pass-through UART functionality of the Debug Adapter (ISA3).

6 Using the Debug Adapter (ISA3) 6.1 Overview The Debug Adapter (ISA3) provides an Ethernet connection to EM35x devices. You can use the Debug Adapter (ISA3) to perform the following tasks:

• Program and debug using Serial Wire or JTAG. • Monitor packets sent and received by the radio. • Send and receive serial port data. • Send and receive debugging data. • Turn power on and off. • Control reset, bootloader and GPIO signals.

6.2 Connectivity and Power All the features of the Debug Adapter (ISA3) are available via the Ethernet connection. The Debug Adapter (ISA3) can also be connected to a PC via USB to change the Ethernet settings. When connected via USB, the Debug Adapter (ISA3) will also be powered via USB. It should be connected to a powered USB hub, or port on your PC that is capable of supplying full power to connected devices. When connected via Ethernet, the Debug Adapter (ISA3) may be powered in one of two ways:

1. Using an Ethernet switch that supplies Power Over Ethernet (PoE). 2. Using a USB power supply.

The Debug Adapter (ISA3) will also supply power to the connected EM35x device when the power switch is in the INT (Internal) position. If the connected EM35x device has its own power supply, ensure the power switch is kept in the EXT (External) position. You can connect via Ethernet to the ports listed in

Page 27: Ember EM35x Development Kit User Guide - 120-4030-000Ember Application Development Fundamentals series (UG103) • Testing and Debugging Applications for the Ember EM2xx and EM35xxPlatforms

UG113

Rev. 0.1 27

Table 6 using either Ember Desktop or a terminal application (for example, Microsoft Telnet Client, HyperTerminal, or PuTTY). Table 5. Debug Adapter (ISA3) Ports

Port Use 4900 Virtual serial port on EM35x via Packet Trace Port cable. 4901 Physical serial port on EM35x via Data Emulation Interface cable. 4902 or 23 Admin interface.

6.3 Ethernet Settings By default, Debug Adapter (ISA3) is configured to get an IP address via DHCP. It is assigned a hostname of EM-ISA3-00. You can use Ember Desktop to discover the Debug Adapter (ISA3) on the network and see its IP address. If you are unable to use DHCP, the Ethernet configuration may be changed using the admin interface over USB as described in “Using the Admin Interface over USB.” The following example changes the settings to a static IP address of 192.168.1.100 with a netmask of 255.255.255.0 and a gateway of 192.168.1.1.

>em3xx_isa.exe --admin "ip static 192.168.1.100 255.255.255.0 192.168.1.1" em3xx_isa version 1.0.9 DLL version 1.0.13, compiled Aug 19 2009 19:42:00 Success: ip: (after reboot) Static 192.168.1.100 255.255.255.0 192.168.1.1 >em3xx_isa.exe --admin "ip dhcp off" em3xx_isa version 1.0.9 DLL version 1.0.13, compiled Aug 19 2009 19:42:00 Success: ip: (after reboot) DHCP off

You can change the hostname to make it more descriptive or to avoid conflicts if Debug Adapters (ISA3)s from multiple development kits are connected to the same network. To change the hostname, use the admin command hostname set <hostname>.

6.4 Using the Admin Interface over USB 1. Connect the Debug Adapter (ISA3) to the PC using USB. 2. Run em3xx_isa.exe with the --admin option. 3. Configure the Debug Adapter (ISA3) using the commands described in Chapter 7, Debug Adapter (ISA3)

Commands.

6.5 Using the Admin Interface over Ethernet 1. Connect the Debug Adapter (ISA3) to the network using Ethernet. 2. Connect to the admin port on the Debug Adapter (ISA3) using either Ember Desktop or a terminal

application:

• Connect to the Debug Adapter (ISA3) using Ember Desktop. Right click on the EM-ISA3 device and select Launch Console. Choose the Admin tab

OR

• Run a terminal application (e.g., Microsoft Telnet Client, HyperTerminal, PuTTY). Connect to port 4902 or 23 on the Debug Adapter (ISA3).

3. Configure the Debug Adapter (ISA3) using the commands described in Chapter 7, Debug Adapter (ISA3) Commands.

Page 28: Ember EM35x Development Kit User Guide - 120-4030-000Ember Application Development Fundamentals series (UG103) • Testing and Debugging Applications for the Ember EM2xx and EM35xxPlatforms

UG113

28 Rev. 0.1

6.6 Using the Serial Ports Connect to port 4900 or 4901 on the Debug Adapter (ISA3) using either Ember Desktop or a terminal application. Port 4900 connects to the virtual serial port on the EM35x via the Packet Trace Port cable. The virtual serial port has no baud rate or other settings. Port 4901 connects to the physical serial port on the EM35x via the Data Emulation Interface (DEI) cable. The default settings are 115200 baud, 8-n-1 (8 data bits, no parity bit, 1 stop bit). To change the default settings, use the port admin command. For example, for 19200 baud, 8-n-1, use the command port 1 19200 8-n-1.

6.7 Updating the Firmware Periodically, Silicon Labs provides updated firmware for the Debug Adapter (ISA3). You can perform the update using em3xx_isa.exe or em3xx_load.exe. Both utilities automatically update the firmware to the latest version each time they run. To update a Debug Adapter (ISA3) over USB, run em3xx_isa.exe with no options. For example:

>em3xx_isa.exe em3xx_isa version 1.0.9 DLL version 1.0.13, compiled Aug 19 2009 19:42:00 Updating firmware: Ember InSight Adapter V1 compiled May 26 2009 13:47:00 V0.2b4 Replacing firmware: Ember InSight Adapter V1 compiled Feb 26 2009 21:54:00 ... Firmware update successful. CRC=8DA7 Waiting for new firmware to boot New firmware booted successfully

To update a Debug Adapter (ISA3) over Ethernet, run em3xx_isa.exe with the --ip option. For example:

>em3xx_isa.exe --ip 192.168.1.100 em3xx_isa version 1.0.9 DLL version 1.0.13, compiled Aug 19 2009 19:42:00 Connecting to IP address 192.168.1.100 Updating firmware: Ember InSight Adapter V1 compiled May 26 2009 13:47:00 V0.2b4 Replacing firmware: Ember InSight Adapter V1 compiled Feb 26 2009 21:54:00 ... Firmware update successful. CRC=8DA7 Waiting for new firmware to boot New firmware booted successfully

Page 29: Ember EM35x Development Kit User Guide - 120-4030-000Ember Application Development Fundamentals series (UG103) • Testing and Debugging Applications for the Ember EM2xx and EM35xxPlatforms

UG113

Rev. 0.1 29

7 Debug Adapter (ISA3) Commands 7.1 Syntax Conventions

Element Meaning Example

Literal A command or argument that is entered exactly as shown. hostname read

Variable An argument that is entered as the desired value for that variable. hostname set hostname

[ | ] An argument chosen from a list. [on|off]

7.2 Entering Commands • Commands can be entered over USB (see Section 6.4, “Using the Admin Interface over USB”) or Ethernet (see

Section 6.5, “Using the Admin Interface over Ethernet”). • Commands are not case sensitive. • Arguments are separated with a single space. • Backspace can be used to correct mistakes.

7.3 Command List • button • config • connections • debug • help • hostname • ip • port • power • reset • usbaddr • version

7.3.1 button button [0|1] [press|release]

Description Simulates button 0 or 1 on the Breakout Board being pressed or released. The Data Emulation Interface cable must be connected. Example

button 1 press

Page 30: Ember EM35x Development Kit User Guide - 120-4030-000Ember Application Development Fundamentals series (UG103) • Testing and Debugging Applications for the Ember EM2xx and EM35xxPlatforms

UG113

30 Rev. 0.1

7.3.2 debug debug [on|off|disable]

Description Turns BackChannel Debug on (the default), off (for sleepy devices), or disable (for read-protected devices). With no arguments specified, it prints the current debug status. Examples

debug debug off debug disable

7.3.3 config config

Description Displays the configuration of the Debug Adapter (ISA3):

• hostname and static IP settings • IP mode (static or DHCP) and current IP settings • serial port settings • firmware version • serial number and Ethernet MAC address • type, EUI and board name of the attached EM35x device You can also view the configuration using Ember Desktop.

7.3.4 connections connections

Description Displays active and inactive TCP connections across the various Ethernet ports of the ISA3. Example

connections

7.3.5 help help

Description Displays a list of all Debug Adapter (ISA3) commands.

Page 31: Ember EM35x Development Kit User Guide - 120-4030-000Ember Application Development Fundamentals series (UG103) • Testing and Debugging Applications for the Ember EM2xx and EM35xxPlatforms

UG113

Rev. 0.1 31

7.3.6 hostname hostname set hostname hostname read

Description Sets or displays the hostname of the Debug Adapter (ISA3). The Debug Adapter (ISA3) must be reset for a change to take effect. You can also view the hostname using Ember Desktop. Example

hostname set mydevice3

7.3.7 ip ip static ipaddress netmask gateway ip dhcp [on|off]

Description Sets the static IP address, netmask and gateway. These are only used when DHCP is turned off. Turns DHCP on or off. The Debug Adapter (ISA3) must be reset for a change to take effect. Examples

ip static 192.168.1.100 255.255.255.0 192.168.1.1 ip dhcp off

7.3.8 port port 1 port 1 baud port 1 baud [5|6|7|8]-[n|o|e]-[1|2]

Description Displays the configuration of the serial port. Sets the baud rate, data bits (5, 6, 7 or 8), parity (none, odd or even) and stop bits (1 or 2). Examples

port 1 port 1 57600 port 1 115200 8-n-1

7.3.9 power power [on|off|read]

Description Turns the power to the attached EM35x device on or off. Displays the current power setting. You can also turn the power on and off using Ember Desktop. Example

power on

Page 32: Ember EM35x Development Kit User Guide - 120-4030-000Ember Application Development Fundamentals series (UG103) • Testing and Debugging Applications for the Ember EM2xx and EM35xxPlatforms

UG113

32 Rev. 0.1

7.3.10 reset reset reset adapter reset host [hold]

Description Resets the attached EM35x device if no arguments are specified Resets the Debug Adapter (ISA3) when “adapter” argument is specified. Resets the host MCU (if using the EM35x NCP Host Breakout Board and DEI cable is connected to ISA3), optionally holding the host MCU in reset state if “hold” is specified. You can also reset the device using Ember Desktop.

7.3.11 usbaddr usbaddr read usbaddr set [0|1|2|3|FF]

Description Displays the USB address configuration of a specific Debug Adapter (ISA3). Sets the USB address configuration, range is 0-3 or FF (default). The Debug Adapter (ISA3) must be reset for a change to take effect. See document AN717, Programming Options for the EM35x Platform, for step by step instructions on setting the address of a Debug Adapter (ISA3).

7.3.12 version version

Description Displays the firmware version of the Debug Adapter (ISA3). You can also view the version using Ember Desktop.

Page 33: Ember EM35x Development Kit User Guide - 120-4030-000Ember Application Development Fundamentals series (UG103) • Testing and Debugging Applications for the Ember EM2xx and EM35xxPlatforms

UG113

Rev. 0.1 33

8 Software Tools Overview 8.1 Running the remote control sample application There are sample applications for both the remote control (ZRC Controller) and the EM35x breakout board (ZRC Target). The sample applications demonstrate basic RF4CE network and ZRC application functionality. The remote application acts as a generic remote control while the EM35x breakout board acts as a target device. Both devices utilize the ZRC Profile plugin to provide core application-level functionality and the GDP and ZRC plugins to provide ZRC2.0 specific behavior. The target device will automatically start the network. The controller device is responsible for initiating pairing to an existing network. The controller application will disable its receiver automatically to conserve power. This is representative of a sleepy device that is generally a transmit-only device that acts when directed by the user (i.e., a button press). Pressing a button on the controller will result in a command being sent to the target device. The target device will receive the command and send an acknowledgment back to the controller.

1. Launch Ember Desktop Software. a. Start>All Programs>Ember>Ember Desktop>Ember Desktop

2. Enter the Ember ZigBee support portal username obtained from Silicon Labs support and click Save username and Continue. If you don’t have a username, click Continue without registration. Once you have a user name, you can register with Help>Register. If prompted to start the First-Time Setup Wizard, just click Continue to Ember Desktop.

3. Program the remote control with the low-cost-controller application. a. Remove the battery cover and install the batteries in the remote control.

Note: The remote control is programmed with the sample application from the factory. Follow the steps below to reprogram the remote control with the sample application.

b. Change the ISA Target Power select switch to the EXT position. c. Insert the Packet Trace cable from the ISA3 adapter to the packet trace connector located under

the battery cover on the remote control. d. Right click on the EM-ISA-00 adapter shown in the Adapters window and select Connect. e. Right click on the EM-ISA-00 adapter and select Upload application. f. Click on the folder to browse for the application.

g. Browse to <znet-install-directory>\app\rf4ce\sample-app\low-cost-controller\ and select the

low-cost-controller.s37 file to upload.

Page 34: Ember EM35x Development Kit User Guide - 120-4030-000Ember Application Development Fundamentals series (UG103) • Testing and Debugging Applications for the Ember EM2xx and EM35xxPlatforms

UG113

34 Rev. 0.1

h. Click Bootloader; browse to <znet-install-directory>\tool\bootloader-em341\app-bootloader\; select app-bootloader.s37.

i. Click on the Erase chip option and click OK. j. Wait until application upload is done and click OK on the dialog box when complete. k. Unplug the Packet Trace cable from the remote control and replace the battery cover.

4. Program the EM35x breakoutboard with the target-zrc20 application. a. Make sure the EM346-MOD-ANT-C module is plugged into the EM35x breakout board. b. Change the ISA Target Power select switch to the INT position. If providing power from USB, the

max current limit is 500 mA. Note: If providing USB power from a PC/Laptop USB port, it may not provide enough current to power both the ISA3 adapter and the EM35x board.

c. Connect both the Packet Trace cable and DEI cable to the EM35x breakout board. d. Right click on the EM-ISA-00 adapter and select Upload application. e. Click on the folder to browse for the application. f. Browse to <znet-install-directory>\app\rf4ce\sample-app\full-featured-target\ and select the

full-featured-target.s37 file to upload. g. Click on the Erase chip option and click OK. h. Click Bootloader; browse to <znet-install-directory>\tool\bootloader-em346\app-bootloader\;

select app-bootloader.s37. i. Wait till application upload is done and click OK on the dialog box when complete.

5. Set up the Capture session to decode ZRC packets. a. Select File>Preferences and then select Decoding. b. Select the option Change the stack version and profile. c. Select Ember RF4CE stack and click Apply and OK.

6. Start the Capture session. a. Right click the EM-ISA-00 adapter and select Start capture.

7. Pair the devices. a. Press and hold down both the PAIR and STB buttons on the remote. If a debug cable is attached

to the remote, the PAIR button cannot be used; the SETUP button must be used instead. The Power button should turn red while it is searching for a target device. Release both buttons.

b. Press Button1 on the EM35x breakout board to accept the pairing. c. Once pairing is completed, the Power button on the remote will turn off.

8. View Capture activity. a. Press buttons on the remote to see the packet information sent over the air with the Ack from the

breakout board.

Page 35: Ember EM35x Development Kit User Guide - 120-4030-000Ember Application Development Fundamentals series (UG103) • Testing and Debugging Applications for the Ember EM2xx and EM35xxPlatforms

UG113

Rev. 0.1 35

8.2 Programming your Application on the EM34x Programming EM34x flash is accomplished with the em3xx_load.exe utility, either via the Windows Command Prompt or via the Upload Application action in Ember Desktop’s Adapters view. The em3xx_load utility is included as part of the Debug Adapter (ISA3) Utilities Installer, in the “bin” subdirectory. A complete summary of em3xx_load functionality with brief descriptions of each option can be found in em3xx_load's own help menu. Invoking "em3xx_load.exe" without options or invoking "em3xx_load.exe --help" will print this help menu. More information about using Ember Desktop to upload application can be found in the Ember Desktop User’s Guide and in the online help for Ember Desktop The most common usage of em3xx_load is to simply program flash. em3xx_load takes the S37 specific version of Motorola S-record file formats, and these files use the .s37 extension. If you are using a bootloader, em3xx_load can also load a .ebl file, which is a proprietary, binary file format designed for applications that use an Ember Bootloader. Given an S37 file called "file.s37", the most basic command for programming flash is simply:

em3xx_load.exe file.s37

Em3xx_load will then print out the versions it is using, the devices it is connected to, the steps it is performing, and programming progress. By default, the last step em3xx_load performs is to run the chip by toggling the nRESET pin. By default, em3xx_load.exe assumes the Debug Adapter (ISA3) is connected via USB when no other options are given. If the Debug Adapter (ISA3) is connected via Ethernet, use the --ip option to specify the IP address or hostname of the Debug Adapter (ISA3) to be used. Given a Debug Adapter (ISA3) with an IP address of 123.123.123.123, programming can be accomplished with the command:

em3XX_load.exe --ip 123.123.123.123 file.s37

Page 36: Ember EM35x Development Kit User Guide - 120-4030-000Ember Application Development Fundamentals series (UG103) • Testing and Debugging Applications for the Ember EM2xx and EM35xxPlatforms

UG113

36 Rev. 0.1

8.3 Programming Manufacturing Tokens The em3xx_load utility has the ability to program manufacturing tokens. In the case of the EM34x, these tokens are contained in the Customer Information Block (CIB). For more information on using the em3xx_load utility, refer to document UG107, EM35xx Utilities Guide. For more information about CIB tokens and how to program them, refer to document AN710, Bringing Up Custom Devices for the EM35xx Platform.

8.3.1 Programming Certificates & Installation Codes Certificates and installation codes can be programmed using the same em3xx_load tool that is used to program other tokens. There is a separate application note which describes the process in detail. For more information, see document AN708, Setting Manufacturing Certificates and Installation Codes.

8.4 Using the Debugger in IAR Embedded Workbench with an Ember Debug Adapter (ISA3)

1. Start IAR Embedded Workbench. Open the workspace (*.eww). 2. Select Project > Options. Select the Debugger > J-Link/J-Trace category. Select the Connection tab. 3. Select TCP/IP Communication and enter the IP address of the Debug Adapter (ISA3). Click OK. 4. Embedded Workbench is not able to program the flash on the EM34x. Every time the project is re-built,

you must manually load it onto the EM34x (using em3xx_load.exe) before starting a debug session. 5. Once the correct image has been loaded onto the EM34x, select Project > Debug without Downloading to

start the debug session

Page 37: Ember EM35x Development Kit User Guide - 120-4030-000Ember Application Development Fundamentals series (UG103) • Testing and Debugging Applications for the Ember EM2xx and EM35xxPlatforms

UG113

Rev. 0.1 37

CONTACT INFORMATION Silicon Laboratories Inc. 400 West Cesar Chavez Austin, TX 78701 Tel: 1+(512) 416-8500 Fax: 1+(512) 416-9669 Toll Free: 1+(877) 444-3032 Please visit the Silicon Labs Technical Support web page for ZigBee products: www.silabs.com/zigbee-support and register to submit a technical support request

Patent Notice Silicon Labs invests in research and development to help our customers differentiate in the market with innovative low-power, small size, analog-intensive mixed-signal solutions. Silicon Labs' extensive patent portfolio is a testament to our unique approach and world-class engineering team.

The information in this document is believed to be accurate in all respects at the time of publication but is subject to change without notice. Silicon Laboratories assumes no responsibility for errors and omissions, and disclaims responsibility for any consequences resulting from the use of information included herein. Additionally, Silicon Laboratories assumes no responsibility for the functioning of undescribed features or parameters. Silicon Laboratories reserves the right to make changes without further notice. Silicon Laboratories makes no warranty, representation or guarantee regarding the suitability of its products for any particular purpose, nor does Silicon Laboratories assume any liability arising out of the application or use of any product or circuit, and specifically disclaims any and all liability, including without limitation consequential or incidental damages. Silicon Laboratories products are not designed, intended, or authorized for use in applications intended to support or sustain life, or for any other application in which the failure of the Silicon Laboratories product could create a situation where personal injury or death may occur. Should Buyer purchase or use Silicon Laboratories products for any such unintended or unauthorized application, Buyer shall indemnify and hold Silicon Laboratories harmless against all claims and damages.

Silicon Laboratories, Silicon Labs, and Ember are registered trademarks of Silicon Laboratories Inc.

Other products or brandnames mentioned herein are trademarks or registered trademarks of their respective holders.