730
EmberZNet API Reference: For the EM260 Co-Processor October 28 2010 120-3020-000K

EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

  • Upload
    haminh

  • View
    275

  • Download
    10

Embed Size (px)

Citation preview

Page 1: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor

October 28 2010 120-3020-000K

Page 2: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

Copyright © 2010 by Ember Corporation

All rights reserved.

The information in this document is subject to change without notice. The statements,

configurations, technical data, and recommendations in this document are believed to be accurate

and reliable but are presented without express or implied warranty. Users must take full

responsibility for their applications of any products specified in this document. The information in

this document is the property of Ember Corporation.

Title, ownership, and all rights in copyrights, patents, trademarks, trade secrets and other

intellectual property rights in the Ember Proprietary Products and any copy, portion, or

modification thereof, shall not transfer to Purchaser or its customers and shall remain in Ember

and its licensors.

No source code rights are granted to Purchaser or its customers with respect to all Ember

Application Software. Purchaser agrees not to copy, modify, alter, translate, decompile,

disassemble, or reverse engineer the Ember Hardware (including without limitation any embedded

software) or attempt to disable any security devices or codes incorporated in the Ember Hardware.

Purchaser shall not alter, remove, or obscure any printed or displayed legal notices contained on or

in the Ember Hardware.

Ember, Ember Enabled, EmberZNet, InSight, and the Ember logo are trademarks of Ember

Corporation.

All other trademarks are the property of their respective holders.

Page 3: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

About this Guide Purpose

This document is a unified collection of API reference documentation covering the EmberZNet 3.x. Ember recommends that you use this document as a searchable reference.

It includes all of the information contained in the html version of these materials that are provided as an online reference for developers of EmberZNet-based ZigBee wireless applications. There are three key advantages that this document provides over the online html versions:

• Everything is contained in this single document.

• This document is fully searchable using the Adobe Acrobat search engine that is part of the free Acrobat Reader (available from www.adobe.com).

• This document can be easily printed.

Audience

This document is intended for use by programmers and designers developing ZigBee wireless networking products based on the EmberZNet Stack Software 3.x.

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.

Getting Help

Developer kit customers are eligible for training and technical support. You can use the Ember web site www.ember.com to obtain information about all Ember products and services, and to sign up for product support.

You can also contact Ember technical support at http://portal.ember.com.

If you have any questions about your Developer Kit, please contact Ember at [email protected].

3

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 4: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Introduction

Introduction

EmberZNet 4.3.0 - Document 120-3020-000K

The EmberZNet API Reference documentation for the EM260 includes the following API sets:

● Ember Common● Hardware Abstraction Layer (HAL) API Reference● Application Utilities API Reference

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/main.htm [10/29/2010 2:42:30 PM]

4

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 5: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Module Index

EmberZNet API Reference: For the EM260 Co-Processor Modules

Here is a list of all modules:

● Ember Common �❍ Ember Common Data Types �❍ Sending and Receiving Messages �❍ Ember Status Codes �❍ Smart Energy Security �❍ Configuration �❍ Debugging Utilities

● Hardware Abstraction Layer (HAL) API Reference �❍ Common Microcontroller Functions �❍ Sample APIs for Peripheral Access

■ Serial UART Communication ■ Hardware-Specific UART

■ ADC Control ■ Button Control ■ Buzzer Control ■ LED Control ■ Carrier Board Control ■ SPI Access

�❍ System Timer Control �❍ HAL Utilities

■ Cyclic Redundancy Code (CRC) ■ Random Number Generation

�❍ Asynchronous Serial Host (ASH) Framework ● Application Utilities API Reference

�❍ Forming and Joining Networks �❍ Bootloading

■ Stand-Alone Bootloader Interface ■ Stand-Alone Bootloader for EZSP ■ Stand-Alone Bootloader Library

�❍ Command Interpreter �❍ ZigBee Device Object (ZDO) Information

■ ZigBee Device Object �❍ Message Fragmentation �❍ Network Manager �❍ Serial Communication

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/modules.htm (1 of 2) [10/29/2010 2:42:31 PM]

5

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 6: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Module Index

�❍ ASH Application Utility ● Deprecated

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/modules.htm (2 of 2) [10/29/2010 2:42:31 PM]

6

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 7: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common

Ember Common

Modules

Ember Common Data Types Sending and Receiving Messages Ember Status Codes Smart Energy Security Configuration Debugging Utilities

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__common.htm [10/29/2010 2:42:31 PM]

7

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 8: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

Ember Common Data Types [Ember Common]

Detailed Description

See ember-types.h for source code.

Data Structures

struct EmberZigbeeNetwork Defines a ZigBee network and the associated parameters. More...

struct EmberNetworkParameters Holds network parameters. More...

struct EmberApsFrame An in-memory representation of a ZigBee APS frame of an incoming or outgoing message. More...

struct EmberBindingTableEntry Defines an entry in the binding table. More...

struct EmberNeighborTableEntry Defines an entry in the neighbor table. More...

struct EmberRouteTableEntry Defines an entry in the route table. More...

struct EmberMulticastTableEntry Defines an entry in the multicast table. More...

struct EmberEventControl Control structure for events. More...

struct EmberTaskControl Control structure for tasks. More...

struct EmberKeyData This data structure contains the key data that is pasesd into various other functions. More...

struct EmberCertificateData This data structure contains the certificate data that is used for Certificate Based Key Exchange (CBKE). More...

struct EmberPublicKeyData This data structure contains the public key data tha is used for Certificate Based Key Exchange (CBKE). More...

struct EmberPrivateKeyData This data structure contains the private key data tha is used for Certificate Based Key Exchange (CBKE). More...

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (1 of 54) [10/29/2010 2:42:38 PM]

8

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 9: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

struct EmberSmacData

This data structure contains the Shared Message Authentication Code (SMAC) data that is used for Certificate Based Key Exchange (CBKE). More...

struct EmberSignatureData This data structure contains a DSA signature. It is the bit concatenantion of the 'r' and 's' components of the signature. More...

struct EmberMessageDigest This data structure contains an AES-MMO Hash (the message digest). More...

struct EmberAesMmoHashContext This data structure contains the context data when calculating an AES MMO hash (message digest). More...

struct EmberInitialSecurityState This describes the Initial Security features and requirements that will be used when forming or joining the network. More...

struct EmberCurrentSecurityState This describes the security features used by the stack for a joined device. More...

struct EmberKeyStruct This describes a one of several different types of keys and its associated data. More...

ZDO response status.

Most responses to ZDO commands contain a status byte. The meaning of this byte is defined by the ZigBee Device Profile.

enum EmberZdoStatus { EMBER_ZDP_SUCCESS, EMBER_ZDP_INVALID_REQUEST_TYPE, EMBER_ZDP_DEVICE_NOT_FOUND, EMBER_ZDP_INVALID_ENDPOINT, EMBER_ZDP_NOT_ACTIVE, EMBER_ZDP_NOT_SUPPORTED, EMBER_ZDP_TIMEOUT, EMBER_ZDP_NO_MATCH, EMBER_ZDP_NO_ENTRY, EMBER_ZDP_NO_DESCRIPTOR, EMBER_ZDP_INSUFFICIENT_SPACE, EMBER_ZDP_NOT_PERMITTED, EMBER_ZDP_TABLE_FULL, EMBER_ZDP_NOT_AUTHORIZED, EMBER_NWK_ALREADY_PRESENT, EMBER_NWK_TABLE_FULL, EMBER_NWK_UNKNOWN_DEVICE }

ZDO server mask bits

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (2 of 54) [10/29/2010 2:42:38 PM]

9

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 10: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

These are used in server discovery requests and responses.

enum EmberZdoServerMask { EMBER_ZDP_PRIMARY_TRUST_CENTER, EMBER_ZDP_SECONDARY_TRUST_CENTER, EMBER_ZDP_PRIMARY_BINDING_TABLE_CACHE, EMBER_ZDP_SECONDARY_BINDING_TABLE_CACHE, EMBER_ZDP_PRIMARY_DISCOVERY_CACHE, EMBER_ZDP_SECONDARY_DISCOVERY_CACHE, EMBER_ZDP_NETWORK_MANAGER }

ZDO configuration flags.

For controlling which ZDO requests are passed to the application. These are normally controlled via the following configuration definitions:

EMBER_APPLICATION_RECEIVES_SUPPORTED_ZDO_REQUESTS EMBER_APPLICATION_HANDLES_UNSUPPORTED_ZDO_REQUESTS EMBER_APPLICATION_HANDLES_ENDPOINT_ZDO_REQUESTS EMBER_APPLICATION_HANDLES_BINDING_ZDO_REQUESTS

See ember-configuration.h for more information.

enum EmberZdoConfigurationFlags { EMBER_APP_RECEIVES_SUPPORTED_ZDO_REQUESTS, EMBER_APP_HANDLES_UNSUPPORTED_ZDO_REQUESTS, EMBER_APP_HANDLES_ZDO_ENDPOINT_REQUESTS, EMBER_APP_HANDLES_ZDO_BINDING_REQUESTS }

Miscellaneous Ember Types

typedef int8u EmberStatustypedef int8u EmberEUI64 [EUI64_SIZE]typedef int8u EmberMessageBuffer

typedef int16u EmberNodeIdtypedef int16u EmberMulticastIdtypedef int16u EmberPanId

#define EUI64_SIZE#define EXTENDED_PAN_ID_SIZE#define EMBER_ENCRYPTION_KEY_SIZE

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (3 of 54) [10/29/2010 2:42:38 PM]

10

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 11: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

#define EMBER_CERTIFICATE_SIZE#define EMBER_PUBLIC_KEY_SIZE#define EMBER_PRIVATE_KEY_SIZE#define EMBER_SMAC_SIZE#define EMBER_SIGNATURE_SIZE#define EMBER_AES_HASH_BLOCK_SIZE#define EMBER_MAX_802_15_4_CHANNEL_NUMBER#define EMBER_MIN_802_15_4_CHANNEL_NUMBER#define EMBER_NUM_802_15_4_CHANNELS#define EMBER_ALL_802_15_4_CHANNELS_MASK#define EMBER_ZIGBEE_COORDINATOR_ADDRESS#define EMBER_NULL_NODE_ID#define EMBER_NULL_BINDING#define EMBER_TABLE_ENTRY_UNUSED_NODE_ID#define EMBER_MULTICAST_NODE_ID#define EMBER_UNKNOWN_NODE_ID#define EMBER_DISCOVERY_ACTIVE_NODE_ID#define EMBER_NULL_ADDRESS_TABLE_INDEX#define EMBER_ZDO_ENDPOINT#define EMBER_BROADCAST_ENDPOINT#define EMBER_ZDO_PROFILE_ID

ZigBee Broadcast Addresses

ZigBee specifies three different broadcast addresses that reach different collections of nodes. Broadcasts are normally sent only to routers. Broadcasts can also be forwarded to end devices, either all of them or only those that do not sleep. Broadcasting to end devices is both significantly more resource-intensive and significantly less reliable than broadcasting to routers.

#define EMBER_BROADCAST_ADDRESS#define EMBER_RX_ON_WHEN_IDLE_BROADCAST_ADDRESS#define EMBER_SLEEPY_BROADCAST_ADDRESS

Ember Concentrator Types

#define EMBER_LOW_RAM_CONCENTRATOR#define EMBER_HIGH_RAM_CONCENTRATOR

txPowerModes for emberSetTxPowerMode and mfglibSetPower

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (4 of 54) [10/29/2010 2:42:38 PM]

11

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 12: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

#define EMBER_TX_POWER_MODE_DEFAULT#define EMBER_TX_POWER_MODE_BOOST#define EMBER_TX_POWER_MODE_ALTERNATE#define EMBER_TX_POWER_MODE_BOOST_AND_ALTERNATE

Alarm Message and Counters Request Definitions

#define EMBER_PRIVATE_PROFILE_ID#define EMBER_BROADCAST_ALARM_CLUSTER#define EMBER_UNICAST_ALARM_CLUSTER#define EMBER_CACHED_UNICAST_ALARM_CLUSTER#define EMBER_REPORT_COUNTERS_REQUEST#define EMBER_REPORT_COUNTERS_RESPONSE#define EMBER_REPORT_AND_CLEAR_COUNTERS_REQUEST#define EMBER_REPORT_AND_CLEAR_COUNTERS_RESPONSE#define EMBER_OTA_CERTIFICATE_UPGRADE_CLUSTER

Network and IEEE Address Request/Response

Network request: <transaction sequence number: 1> <EUI64:8> <type:1> <start index:1> IEEE request: <transaction sequence number: 1> <node ID:2> <type:1> <start index:1> <type> = 0x00 single address response, ignore the start index = 0x01 extended response -> sends kid's IDs as well Response: <transaction sequence number: 1> <status:1> <EUI64:8> <node ID:2> <ID count:1> <start index:1> <child ID:2>*

#define NETWORK_ADDRESS_REQUEST#define NETWORK_ADDRESS_RESPONSE#define IEEE_ADDRESS_REQUEST#define IEEE_ADDRESS_RESPONSE

Node Descriptor Request/Response

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (5 of 54) [10/29/2010 2:42:38 PM]

12

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 13: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

Request: <transaction sequence number: 1> <node ID:2> Response: <transaction sequence number: 1> <status:1> <node ID:2> <type:1> <APS flags, freq:1> <MAC flags:1> <manufacturer:2> <max buffer size:1> <max transfer size:2>

#define NODE_DESCRIPTOR_REQUEST#define NODE_DESCRIPTOR_RESPONSE

Power Descriptor Request / Response

Request: <transaction sequence number: 1> <node ID:2> Response: <transaction sequence number: 1> <status:1> <node ID:2> <current power mode, available power sources:1> <current power source, current power source level:1>

#define POWER_DESCRIPTOR_REQUEST#define POWER_DESCRIPTOR_RESPONSE

Simple Descriptor Request / Response

Request: <transaction sequence number: 1> <node ID:2> <endpoint:1> Response: <transaction sequence number: 1> <status:1> <node ID:2> <length:1> <endpoint:1> <app profile ID:2> <app device ID:2> <app device version, app flags:1> <input cluster count:1> <input cluster:2>* <output cluster count:1> <output cluster:2>*

#define SIMPLE_DESCRIPTOR_REQUEST#define SIMPLE_DESCRIPTOR_RESPONSE

Active Endpoints Request / Response

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (6 of 54) [10/29/2010 2:42:38 PM]

13

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 14: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

Request: <transaction sequence number: 1> <node ID:2> Response: <transaction sequence number: 1> <status:1> <node ID:2> <endpoint count:1> <endpoint:1>*

#define ACTIVE_ENDPOINTS_REQUEST#define ACTIVE_ENDPOINTS_RESPONSE

Match Descriptors Request / Response

Request: <transaction sequence number: 1> <node ID:2> <app profile ID:2> <input cluster count:1> <input cluster:2>* <output cluster count:1> <output cluster:2>* Response: <transaction sequence number: 1> <status:1> <node ID:2> <endpoint count:1> <endpoint:1>*

#define MATCH_DESCRIPTORS_REQUEST#define MATCH_DESCRIPTORS_RESPONSE

Discovery Cache Request / Response

Request: <transaction sequence number: 1> <source node ID:2> <source EUI64:8> Response: <transaction sequence number: 1> <status (== EMBER_ZDP_SUCCESS):1>

#define DISCOVERY_CACHE_REQUEST#define DISCOVERY_CACHE_RESPONSE

End Device Announce and End Device Announce Response

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (7 of 54) [10/29/2010 2:42:38 PM]

14

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 15: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

Request: <transaction sequence number: 1> <node ID:2> <EUI64:8> <capabilities:1> No response is sent.

#define END_DEVICE_ANNOUNCE#define END_DEVICE_ANNOUNCE_RESPONSE

System Server Discovery Request / Response

This is broadcast and only servers which have matching services respond. The response contains the request services that the recipient provides.

Request: <transaction sequence number: 1> <server mask:2> Response: <transaction sequence number: 1> <status (== EMBER_ZDP_SUCCESS):1> <server mask:2>

#define SYSTEM_SERVER_DISCOVERY_REQUEST#define SYSTEM_SERVER_DISCOVERY_RESPONSE

Find Node Cache Request / Response

This is broadcast and only discovery servers which have the information for the device of interest, or the device of interest itself, respond. The requesting device can then direct any service discovery requests to the responder.

Request: <transaction sequence number: 1> <device of interest ID:2> <d-of-i EUI64:8> Response: <transaction sequence number: 1> <responder ID:2> <device of interest ID:2> <d-of-i EUI64:8>

#define FIND_NODE_CACHE_REQUEST#define FIND_NODE_CACHE_RESPONSE

End Device Bind Request / Response

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (8 of 54) [10/29/2010 2:42:38 PM]

15

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 16: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

Request: <transaction sequence number: 1> <node ID:2> <EUI64:8> <endpoint:1> <app profile ID:2> <input cluster count:1> <input cluster:2>* <output cluster count:1> <output cluster:2>* Response: <transaction sequence number: 1> <status:1>

#define END_DEVICE_BIND_REQUEST#define END_DEVICE_BIND_RESPONSE

Binding types and Request / Response

Bind and unbind have the same formats. There are two possible formats, depending on whether the destination is a group address or a device address. Device addresses include an endpoint, groups don't.

Request: <transaction sequence number: 1> <source EUI64:8> <source endpoint:1> <cluster ID:2> <destination address:3 or 10> Destination address: <0x01:1> <destination group:2> Or: <0x03:1> <destination EUI64:8> <destination endpoint:1> Response: <transaction sequence number: 1> <status:1>

#define UNICAST_BINDING#define UNICAST_MANY_TO_ONE_BINDING#define MULTICAST_BINDING#define BIND_REQUEST#define BIND_RESPONSE#define UNBIND_REQUEST#define UNBIND_RESPONSE

LQI Table Request / Response

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (9 of 54) [10/29/2010 2:42:38 PM]

16

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 17: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

Request: <transaction sequence number: 1> <start index:1> Response: <transaction sequence number: 1> <status:1> <neighbor table entries:1> <start index:1> <entry count:1> <entry:22>* <entry> = <extended PAN ID:8> <EUI64:8> <node ID:2> <device type, rx on when idle, relationship:1> <permit joining:1> <depth:1> <LQI:1>

The device-type byte has the following fields:

Name Mask Values device type 0x03 0x00 coordinator 0x01 router 0x02 end device 0x03 unknown

rx mode 0x0C 0x00 off when idle 0x04 on when idle 0x08 unknown

relationship 0x70 0x00 parent 0x10 child 0x20 sibling 0x30 other 0x40 previous child reserved 0x10

The permit-joining byte has the following fields

Name Mask Values permit joining 0x03 0x00 not accepting join requests 0x01 accepting join requests 0x02 unknown reserved 0xFC

#define LQI_TABLE_REQUEST#define LQI_TABLE_RESPONSE

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (10 of 54) [10/29/2010 2:42:38 PM]

17

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 18: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

Routing Table Request / Response

Request: <transaction sequence number: 1> <start index:1> Response: <transaction sequence number: 1> <status:1> <routing table entries:1> <start index:1> <entry count:1> <entry:5>* <entry> = <destination address:2> <status:1> <next hop:2>

The status byte has the following fields:

Name Mask Values status 0x07 0x00 active 0x01 discovery underway 0x02 discovery failed 0x03 inactive 0x04 validation underway

flags 0x38 0x08 memory constrained 0x10 many-to-one 0x20 route record required

reserved 0xC0

#define ROUTING_TABLE_REQUEST#define ROUTING_TABLE_RESPONSE

Binding Table Request / Response

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (11 of 54) [10/29/2010 2:42:38 PM]

18

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 19: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

Request: <transaction sequence number: 1> <start index:1> Response: <transaction sequence number: 1> <status:1> <binding table entries:1> <start index:1> <entry count:1> <entry:14/21>* <entry> = <source EUI64:8> <source endpoint:1> <cluster ID:2> <dest addr mode:1> <dest:2/8> <dest endpoint:0/1>

Note:

If Dest. Address Mode = 0x03, then the Long Dest. Address will be used and Dest. endpoint will be included. If Dest. Address Mode = 0x01, then the Short Dest. Address will be used and there will be no Dest. endpoint.

#define BINDING_TABLE_REQUEST#define BINDING_TABLE_RESPONSE

Leave Request / Response

Request: <transaction sequence number: 1> <EUI64:8> <flags:1> The flag bits are: 0x40 remove children 0x80 rejoin Response: <transaction sequence number: 1> <status:1>

#define LEAVE_REQUEST#define LEAVE_RESPONSE#define LEAVE_REQUEST_REMOVE_CHILDREN_FLAG#define LEAVE_REQUEST_REJOIN_FLAG

Permit Joining Request / Response

Request: <transaction sequence number: 1> <duration:1> <permit authentication:1> Response: <transaction sequence number: 1> <status:1>

#define PERMIT_JOINING_REQUEST

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (12 of 54) [10/29/2010 2:42:38 PM]

19

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 20: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

#define PERMIT_JOINING_RESPONSE

Network Update Request / Response

Request: <transaction sequence number: 1> <scan channels:4> <duration:1> <count:0/1> <manager:0/2>

If the duration is in 0x00 ... 0x05, then 'count' is present but not 'manager'. Perform 'count' scans of the given duration on the given channels.

If duration is 0xFE, then 'channels' should have a single channel and 'count' and 'manager' are not present. Switch to the indicated channel. If duration is 0xFF, then 'count' is not present. Set the active channels and the network manager ID to the values given.

Unicast requests always get a response, which is INVALID_REQUEST if the duration is not a legal value.

Response: <status:1> <scanned channels:4> <transmissions:2> <failures:2> <energy count:1> <energy:1>*

#define NWK_UPDATE_REQUEST#define NWK_UPDATE_RESPONSE

Unsupported

Not mandatory and not supported.

#define COMPLEX_DESCRIPTOR_REQUEST#define COMPLEX_DESCRIPTOR_RESPONSE#define USER_DESCRIPTOR_REQUEST#define USER_DESCRIPTOR_RESPONSE#define DISCOVERY_REGISTER_REQUEST#define DISCOVERY_REGISTER_RESPONSE#define USER_DESCRIPTOR_SET#define USER_DESCRIPTOR_CONFIRM

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (13 of 54) [10/29/2010 2:42:38 PM]

20

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 21: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

#define NETWORK_DISCOVERY_REQUEST#define NETWORK_DISCOVERY_RESPONSE#define DIRECT_JOIN_REQUEST#define DIRECT_JOIN_RESPONSE#define CLUSTER_ID_RESPONSE_MINIMUM

Defines

#define EMBER_JOIN_DECISION_STRINGS#define EMBER_DEVICE_UPDATE_STRINGS#define emberInitializeNetworkParameters(parameters)#define EMBER_COUNTER_STRINGS#define EMBER_STANDARD_SECURITY_MODE#define EMBER_TRUST_CENTER_NODE_ID#define EMBER_NO_TRUST_CENTER_MODE

Typedefs

typedef int8u EmberTaskIdstruct { EmberEventControl * control void(* handler )(void)} EmberEventData

typedef int8u EmberLibraryStatus

Enumerations

enum EmberNodeType { EMBER_UNKNOWN_DEVICE, EMBER_COORDINATOR, EMBER_ROUTER, EMBER_END_DEVICE, EMBER_SLEEPY_END_DEVICE, EMBER_MOBILE_END_DEVICE }

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (14 of 54) [10/29/2010 2:42:38 PM]

21

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 22: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

enum EmberApsOption { EMBER_APS_OPTION_NONE, EMBER_APS_OPTION_DSA_SIGN, EMBER_APS_OPTION_ENCRYPTION, EMBER_APS_OPTION_RETRY, EMBER_APS_OPTION_ENABLE_ROUTE_DISCOVERY, EMBER_APS_OPTION_FORCE_ROUTE_DISCOVERY, EMBER_APS_OPTION_SOURCE_EUI64, EMBER_APS_OPTION_DESTINATION_EUI64, EMBER_APS_OPTION_ENABLE_ADDRESS_DISCOVERY, EMBER_APS_OPTION_POLL_RESPONSE, EMBER_APS_OPTION_ZDO_RESPONSE_REQUIRED, EMBER_APS_OPTION_FRAGMENT }

enum EmberIncomingMessageType { EMBER_INCOMING_UNICAST, EMBER_INCOMING_UNICAST_REPLY, EMBER_INCOMING_MULTICAST, EMBER_INCOMING_MULTICAST_LOOPBACK, EMBER_INCOMING_BROADCAST, EMBER_INCOMING_BROADCAST_LOOPBACK }

enum EmberOutgoingMessageType { EMBER_OUTGOING_DIRECT, EMBER_OUTGOING_VIA_ADDRESS_TABLE, EMBER_OUTGOING_VIA_BINDING, EMBER_OUTGOING_MULTICAST, EMBER_OUTGOING_BROADCAST }

enum EmberNetworkStatus { EMBER_NO_NETWORK, EMBER_JOINING_NETWORK, EMBER_JOINED_NETWORK, EMBER_JOINED_NETWORK_NO_PARENT, EMBER_LEAVING_NETWORK }

enum EmberNetworkScanType { EMBER_ENERGY_SCAN, EMBER_ACTIVE_SCAN }

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (15 of 54) [10/29/2010 2:42:38 PM]

22

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 23: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

enum EmberBindingType { EMBER_UNUSED_BINDING, EMBER_UNICAST_BINDING, EMBER_MANY_TO_ONE_BINDING, EMBER_MULTICAST_BINDING }

enum EmberJoinDecision { EMBER_USE_PRECONFIGURED_KEY, EMBER_SEND_KEY_IN_THE_CLEAR, EMBER_DENY_JOIN, EMBER_NO_ACTION }

enum EmberDeviceUpdate { EMBER_STANDARD_SECURITY_SECURED_REJOIN, EMBER_STANDARD_SECURITY_UNSECURED_JOIN, EMBER_DEVICE_LEFT, EMBER_STANDARD_SECURITY_UNSECURED_REJOIN, EMBER_HIGH_SECURITY_SECURED_REJOIN, EMBER_HIGH_SECURITY_UNSECURED_JOIN, EMBER_HIGH_SECURITY_UNSECURED_REJOIN }

enum EmberClusterListId { EMBER_INPUT_CLUSTER_LIST, EMBER_OUTPUT_CLUSTER_LIST }

enum EmberEventUnits { EMBER_EVENT_INACTIVE, EMBER_EVENT_MS_TIME, EMBER_EVENT_QS_TIME, EMBER_EVENT_MINUTE_TIME, EMBER_EVENT_ZERO_DELAY }

enum EmberJoinMethod { EMBER_USE_MAC_ASSOCIATION, EMBER_USE_NWK_REJOIN, EMBER_USE_NWK_REJOIN_HAVE_NWK_KEY, EMBER_USE_NWK_COMMISSIONING }

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (16 of 54) [10/29/2010 2:42:38 PM]

23

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 24: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

enum EmberCounterType { EMBER_COUNTER_MAC_RX_BROADCAST, EMBER_COUNTER_MAC_TX_BROADCAST, EMBER_COUNTER_MAC_RX_UNICAST, EMBER_COUNTER_MAC_TX_UNICAST_SUCCESS, EMBER_COUNTER_MAC_TX_UNICAST_RETRY, EMBER_COUNTER_MAC_TX_UNICAST_FAILED, EMBER_COUNTER_APS_DATA_RX_BROADCAST, EMBER_COUNTER_APS_DATA_TX_BROADCAST, EMBER_COUNTER_APS_DATA_RX_UNICAST, EMBER_COUNTER_APS_DATA_TX_UNICAST_SUCCESS, EMBER_COUNTER_APS_DATA_TX_UNICAST_RETRY, EMBER_COUNTER_APS_DATA_TX_UNICAST_FAILED, EMBER_COUNTER_ROUTE_DISCOVERY_INITIATED, EMBER_COUNTER_NEIGHBOR_ADDED, EMBER_COUNTER_NEIGHBOR_REMOVED, EMBER_COUNTER_NEIGHBOR_STALE, EMBER_COUNTER_JOIN_INDICATION, EMBER_COUNTER_CHILD_REMOVED, EMBER_COUNTER_ASH_OVERFLOW_ERROR, EMBER_COUNTER_ASH_FRAMING_ERROR, EMBER_COUNTER_ASH_OVERRUN_ERROR, EMBER_COUNTER_NWK_FRAME_COUNTER_FAILURE, EMBER_COUNTER_APS_FRAME_COUNTER_FAILURE, EMBER_COUNTER_ASH_XOFF, EMBER_COUNTER_APS_LINK_KEY_NOT_AUTHORIZED, EMBER_COUNTER_NWK_DECRYPTION_FAILURE, EMBER_COUNTER_APS_DECRYPTION_FAILURE, EMBER_COUNTER_ALLOCATE_PACKET_BUFFER_FAILURE, EMBER_COUNTER_TYPE_COUNT }

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (17 of 54) [10/29/2010 2:42:38 PM]

24

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 25: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

enum EmberInitialSecurityBitmask { EMBER_DISTRIBUTED_TRUST_CENTER_MODE, EMBER_GLOBAL_LINK_KEY, EMBER_PRECONFIGURED_NETWORK_KEY_MODE, EMBER_HAVE_TRUST_CENTER_EUI64, EMBER_TRUST_CENTER_USES_HASHED_LINK_KEY, EMBER_HAVE_PRECONFIGURED_KEY, EMBER_HAVE_NETWORK_KEY, EMBER_GET_LINK_KEY_WHEN_JOINING, EMBER_REQUIRE_ENCRYPTED_KEY, EMBER_NO_FRAME_COUNTER_RESET, EMBER_GET_PRECONFIGURED_KEY_FROM_INSTALL_CODE }

enum EmberCurrentSecurityBitmask { EMBER_STANDARD_SECURITY_MODE_, EMBER_DISTRIBUTED_TRUST_CENTER_MODE_, EMBER_GLOBAL_LINK_KEY_, EMBER_HAVE_TRUST_CENTER_LINK_KEY, EMBER_TRUST_CENTER_USES_HASHED_LINK_KEY_ }

enum EmberKeyStructBitmask { EMBER_KEY_HAS_SEQUENCE_NUMBER, EMBER_KEY_HAS_OUTGOING_FRAME_COUNTER, EMBER_KEY_HAS_INCOMING_FRAME_COUNTER, EMBER_KEY_HAS_PARTNER_EUI64, EMBER_KEY_IS_AUTHORIZED }

enum EmberKeyType { EMBER_TRUST_CENTER_LINK_KEY, EMBER_TRUST_CENTER_MASTER_KEY, EMBER_CURRENT_NETWORK_KEY, EMBER_NEXT_NETWORK_KEY, EMBER_APPLICATION_LINK_KEY, EMBER_APPLICATION_MASTER_KEY }

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (18 of 54) [10/29/2010 2:42:38 PM]

25

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 26: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

enum EmberKeyStatus { EMBER_APP_LINK_KEY_ESTABLISHED, EMBER_APP_MASTER_KEY_ESTABLISHED, EMBER_TRUST_CENTER_LINK_KEY_ESTABLISHED, EMBER_KEY_ESTABLISHMENT_TIMEOUT, EMBER_KEY_TABLE_FULL, EMBER_TC_RESPONDED_TO_KEY_REQUEST, EMBER_TC_APP_KEY_SENT_TO_REQUESTER, EMBER_TC_RESPONSE_TO_KEY_REQUEST_FAILED, EMBER_TC_REQUEST_KEY_TYPE_NOT_SUPPORTED, EMBER_TC_NO_LINK_KEY_FOR_REQUESTER, EMBER_TC_REQUESTER_EUI64_UNKNOWN, EMBER_TC_RECEIVED_FIRST_APP_KEY_REQUEST, EMBER_TC_TIMEOUT_WAITING_FOR_SECOND_APP_KEY_REQUEST, EMBER_TC_NON_MATCHING_APP_KEY_REQUEST_RECEIVED, EMBER_TC_FAILED_TO_SEND_APP_KEYS, EMBER_TC_FAILED_TO_STORE_APP_KEY_REQUEST, EMBER_TC_REJECTED_APP_KEY_REQUEST }

enum EmberLinkKeyRequestPolicy { EMBER_DENY_KEY_REQUESTS, EMBER_ALLOW_KEY_REQUESTS }

enum EmberMacPassthroughType { EMBER_MAC_PASSTHROUGH_NONE, EMBER_MAC_PASSTHROUGH_SE_INTERPAN, EMBER_MAC_PASSTHROUGH_EMBERNET, EMBER_MAC_PASSTHROUGH_EMBERNET_SOURCE, EMBER_MAC_PASSTHROUGH_APPLICATION }

Functions

int8u * emberKeyContents (EmberKeyData *key)int8u * emberCertificateContents (EmberCertificateData *cert)int8u * emberPublicKeyContents (EmberPublicKeyData *key)int8u * emberPrivateKeyContents (EmberPrivateKeyData *key)int8u * emberSmacContents (EmberSmacData *key)int8u * emberSignatureContents (EmberSignatureData *sig)

Define Documentationfile:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (19 of 54) [10/29/2010 2:42:38 PM]

26

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 27: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

#define EUI64_SIZE

Size of EUI64 (an IEEE address) in bytes (8).

Definition at line 37 of file ember-types.h.

#define EXTENDED_PAN_ID_SIZE

Size of an extended PAN identifier in bytes (8).

Definition at line 42 of file ember-types.h.

#define EMBER_ENCRYPTION_KEY_SIZE

Size of an encryption key in bytes (16).

Definition at line 47 of file ember-types.h.

#define EMBER_CERTIFICATE_SIZE

Size of Implicit Certificates used for Certificate Based Key Exchange.

Definition at line 53 of file ember-types.h.

#define EMBER_PUBLIC_KEY_SIZE

Size of Public Keys used in Eliptical Cryptography ECMQV algorithms.

Definition at line 58 of file ember-types.h.

#define EMBER_PRIVATE_KEY_SIZE

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (20 of 54) [10/29/2010 2:42:38 PM]

27

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 28: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

Size of Private Keys used in Eliptical Cryptography ECMQV alogrithms.

Definition at line 63 of file ember-types.h.

#define EMBER_SMAC_SIZE

Size of the SMAC used in Eliptical Cryptography ECMQV alogrithms.

Definition at line 68 of file ember-types.h.

#define EMBER_SIGNATURE_SIZE

Size of the DSA signature used in Eliptical Cryptography Digital Signature Algorithms.

Definition at line 74 of file ember-types.h.

#define EMBER_AES_HASH_BLOCK_SIZE

The size of AES-128 MMO hash is 16-bytes. This is defined in the core. ZigBee specification.

Definition at line 79 of file ember-types.h.

#define EMBER_MAX_802_15_4_CHANNEL_NUMBER

The maximum 802.15.4 channel number is 26.

Definition at line 122 of file ember-types.h.

#define EMBER_MIN_802_15_4_CHANNEL_NUMBER

The minimum 802.15.4 channel number is 11.

Definition at line 127 of file ember-types.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (21 of 54) [10/29/2010 2:42:38 PM]

28

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 29: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

#define EMBER_NUM_802_15_4_CHANNELS

There are sixteen 802.15.4 channels.

Definition at line 132 of file ember-types.h.

#define EMBER_ALL_802_15_4_CHANNELS_MASK

Bitmask to scan all 802.15.4 channels.

Definition at line 138 of file ember-types.h.

#define EMBER_ZIGBEE_COORDINATOR_ADDRESS

The network ID of the coordinator in a ZigBee network is 0x0000.

Definition at line 143 of file ember-types.h.

#define EMBER_NULL_NODE_ID

A distinguished network ID that will never be assigned to any node. Used to indicate the absence of a node ID.

Definition at line 149 of file ember-types.h.

#define EMBER_NULL_BINDING

A distinguished binding index used to indicate the absence of a binding.

Definition at line 155 of file ember-types.h.

#define EMBER_TABLE_ENTRY_UNUSED_NODE_ID

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (22 of 54) [10/29/2010 2:42:38 PM]

29

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 30: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

A distinguished network ID that will never be assigned to any node.

This value is used when setting or getting the remote node ID in the address table or getting the remote node ID from the binding table. It indicates that address or binding table entry is not in use.

Definition at line 166 of file ember-types.h.

#define EMBER_MULTICAST_NODE_ID

A distinguished network ID that will never be assigned to any node. This value is returned when getting the remote node ID from the binding table and the given binding table index refers to a mulicast binding entry.

Definition at line 174 of file ember-types.h.

#define EMBER_UNKNOWN_NODE_ID

A distinguished network ID that will never be assigned to any node. This value is used when getting the remote node ID from the address or binding tables. It indicates that the address or binding table entry is currently in use but the node ID corresponding to the EUI64 in the table is currently unknown.

Definition at line 183 of file ember-types.h.

#define EMBER_DISCOVERY_ACTIVE_NODE_ID

A distinguished network ID that will never be assigned to any node. This value is used when getting the remote node ID from the address or binding tables. It indicates that the address or binding table entry is currently in use and network address discovery is underway.

Definition at line 192 of file ember-types.h.

#define EMBER_NULL_ADDRESS_TABLE_INDEX

A distinguished address table index used to indicate the absence of an address table entry.

Definition at line 198 of file ember-types.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (23 of 54) [10/29/2010 2:42:38 PM]

30

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 31: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

#define EMBER_ZDO_ENDPOINT

The endpoint where the ZigBee Device Object (ZDO) resides.

Definition at line 203 of file ember-types.h.

#define EMBER_BROADCAST_ENDPOINT

The broadcast endpoint, as defined in the ZigBee spec.

Definition at line 208 of file ember-types.h.

#define EMBER_ZDO_PROFILE_ID

The profile ID used by the ZigBee Device Object (ZDO).

Definition at line 213 of file ember-types.h.

#define EMBER_BROADCAST_ADDRESS

Broadcast to all routers.

Definition at line 230 of file ember-types.h.

#define EMBER_RX_ON_WHEN_IDLE_BROADCAST_ADDRESS

Broadcast to all non-sleepy devices.

Definition at line 232 of file ember-types.h.

#define EMBER_SLEEPY_BROADCAST_ADDRESS

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (24 of 54) [10/29/2010 2:42:38 PM]

31

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 32: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

Broadcast to all devices, including sleepy end devices.

Definition at line 234 of file ember-types.h.

#define EMBER_LOW_RAM_CONCENTRATOR

A concentrator with insufficient memory to store source routes for the entire network. Route records are sent to the concentrator prior to every inbound APS unicast.

Definition at line 468 of file ember-types.h.

#define EMBER_HIGH_RAM_CONCENTRATOR

A concentrator with sufficient memory to store source routes for the entire network. Remote nodes stop sending route records once the concentrator has successfully received one.

Definition at line 473 of file ember-types.h.

#define EMBER_JOIN_DECISION_STRINGS

@ brief Defines the CLI enumerations for the EmberJoinDecision enum

Definition at line 501 of file ember-types.h.

#define EMBER_DEVICE_UPDATE_STRINGS

@ brief Defines the CLI enumerations for the EmberDeviceUpdate enum.

Definition at line 536 of file ember-types.h.

#define emberInitializeNetworkParameters ( parameters )

Definition at line 678 of file ember-types.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (25 of 54) [10/29/2010 2:42:39 PM]

32

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 33: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

#define EMBER_COUNTER_STRINGS

@ brief Defines the CLI enumerations for the EmberCounterType enum.

Definition at line 912 of file ember-types.h.

#define EMBER_TX_POWER_MODE_DEFAULT

The application should call emberSetTxPowerMode() with the txPowerMode parameter set to this value to disable all power mode options, resulting in normal power mode and bi-directional RF transmitter output.

Definition at line 1019 of file ember-types.h.

#define EMBER_TX_POWER_MODE_BOOST

The application should call emberSetTxPowerMode() with the txPowerMode parameter set to this value to enable boost power mode.

Definition at line 1023 of file ember-types.h.

#define EMBER_TX_POWER_MODE_ALTERNATE

The application should call emberSetTxPowerMode() with the txPowerMode parameter set to this value to enable the alternate transmitter output.

Definition at line 1028 of file ember-types.h.

#define EMBER_TX_POWER_MODE_BOOST_AND_ALTERNATE

The application should call emberSetTxPowerMode() with the txPowerMode parameter set to this value to enable both boost mode and the alternate transmitter output.

Definition at line 1033 of file ember-types.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (26 of 54) [10/29/2010 2:42:39 PM]

33

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 34: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

#define EMBER_PRIVATE_PROFILE_ID

This is a ZigBee application profile ID that has been assigned to Ember Corporation.

It is used to send for sending messages that have a specific, non-standard interaction with the Ember stack. Its only current use is for alarm messages and stack counters requests.

Definition at line 1057 of file ember-types.h.

#define EMBER_BROADCAST_ALARM_CLUSTER

Alarm messages provide a reliable means for communicating with sleeping end devices.

A messages sent to a sleeping device is normally buffered on the device's parent for a short time (the precise time can be specified using the configuration parameter EMBER_INDIRECT_TRANSMISSION_TIMEOUT). If the child does not poll its parent within that time the message is discarded.

In contrast, alarm messages are buffered by the parent indefinitely. Because of the limited RAM available, alarm messages are necessarily brief. In particular, the parent only stores alarm payloads. The header information in alarm messages is not stored on the parent.

The memory used for buffering alarm messages is allocated statically. The amount of memory set aside for alarms is controlled by two configuration parameters:

● EMBER_BROADCAST_ALARM_DATA_SIZE● EMBER_UNICAST_ALARM_DATA_SIZE

Alarm messages must use the EMBER_PRIVATE_PROFILE_ID as the application profile ID. The source and destination endpoints are ignored.

Broadcast alarms must use EMBER_BROADCAST_ALARM_CLUSTER as the cluster id and messages with this cluster ID must be sent to EMBER_RX_ON_WHEN_IDLE_BROADCAST_ADDRESS. A broadcast alarm may not contain more than EMBER_BROADCAST_ALARM_DATA_SIZE bytes of payload.

Broadcast alarm messages arriving at a node are passed to the application via emberIncomingMessageHandler(). If the receiving node has sleepy end device children, the payload of the alarm is saved and then forwarded to those children when they poll for data. When a sleepy child polls its parent, it receives only the most recently arrived broadcast alarm. If the child has already received the most recent broadcast alarm it is not forwarded again.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (27 of 54) [10/29/2010 2:42:39 PM]

34

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 35: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

Definition at line 1097 of file ember-types.h.

#define EMBER_UNICAST_ALARM_CLUSTER

Unicast alarms must use EMBER_UNICAST_ALARM_CLUSTER as the cluster id and messages with this cluster ID must be unicast.

The payload of a unicast alarm consists of three one-byte length fields followed by three variable length fields.

1. flags length 2. priority length (must be 0 or 1) 3. data length 4. flags 5. priority 6. payload

The three lengths must total EMBER_UNICAST_ALARM_DATA_SIZE or less.

When a unicast alarm message arrives at its destination it is passed to the application via emberIncomingMessageHandler(). When a node receives a unicast alarm message whose destination is a sleepy end device child of that node, the payload of the message is saved until the child polls for data. To conserve memory, the values of the length fields are not saved. The alarm will be forwarded to the child using the EMBER_CACHED_UNICAST_ALARM_CLUSTER cluster ID.

If a unicast alarm arrives when a previous one is still pending, the two payloads are combined. This combining is controlled by the length fields in the arriving message. The incoming flag bytes are or'ed with those of the pending message. If the priority field is not present, or if it is present and the incoming priority value is equal or greater than the pending priority value, the pending data is replaced by the incoming data.

Because the length fields are not saved, the application designer must fix on a set of field lengths that will be used for all unicast alarm message sent to a particular device.

Definition at line 1135 of file ember-types.h.

#define EMBER_CACHED_UNICAST_ALARM_CLUSTER

A unicast alarm that has been cached on the parent of a sleepy end device is delivered to that device using

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (28 of 54) [10/29/2010 2:42:39 PM]

35

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 36: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

the EMBER_CACHED_UNICAST_ALARM_CLUSTER cluster ID. The payload consists of three variable length fields.

1. flags 2. priority 3. payload

The parent will pad the payload out to EMBER_UNICAST_ALARM_DATA_SIZE bytes.

The lengths of the these fields must be fixed by the application designer and must be the same for all unicast alarms sent to a particular device.

Definition at line 1152 of file ember-types.h.

#define EMBER_REPORT_COUNTERS_REQUEST

The cluster id used to request that a node respond with a report of its Ember stack counters. See app/util/counters/counters-ota.h.

Definition at line 1157 of file ember-types.h.

#define EMBER_REPORT_COUNTERS_RESPONSE

The cluster id used to respond to an EMBER_REPORT_COUNTERS_REQUEST.

Definition at line 1160 of file ember-types.h.

#define EMBER_REPORT_AND_CLEAR_COUNTERS_REQUEST

The cluster id used to request that a node respond with a report of its Ember stack counters. The node will also reset its clusters to zero after a successful response. See app/util/counters/counters-ota.h.

Definition at line 1166 of file ember-types.h.

#define EMBER_REPORT_AND_CLEAR_COUNTERS_RESPONSE

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (29 of 54) [10/29/2010 2:42:39 PM]

36

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 37: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

The cluster id used to respond to an EMBER_REPORT_AND_CLEAR_COUNTERS_REQUEST.

Definition at line 1169 of file ember-types.h.

#define EMBER_OTA_CERTIFICATE_UPGRADE_CLUSTER

The cluster id used to send and receive Over-the-air certificate messages. This is used to field upgrade devices with Smart Energy Certificates and other security data.

Definition at line 1175 of file ember-types.h.

#define EMBER_STANDARD_SECURITY_MODE

This is an EmberInitialSecurityBitmask value but it does not actually set anything. It is the default mode used by the Zigbee Pro stack. It is defined here so that no legacy code is broken by referencing it.

Definition at line 1239 of file ember-types.h.

#define EMBER_TRUST_CENTER_NODE_ID

This is the short address of the trust center. It never changes from this value throughout the life of the network.

Definition at line 1244 of file ember-types.h.

#define EMBER_NO_TRUST_CENTER_MODE

This is the legacy name for the Distributed Trust Center Mode.

Definition at line 1342 of file ember-types.h.

#define NETWORK_ADDRESS_REQUEST

Definition at line 1742 of file ember-types.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (30 of 54) [10/29/2010 2:42:39 PM]

37

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 38: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

#define NETWORK_ADDRESS_RESPONSE

Definition at line 1743 of file ember-types.h.

#define IEEE_ADDRESS_REQUEST

Definition at line 1744 of file ember-types.h.

#define IEEE_ADDRESS_RESPONSE

Definition at line 1745 of file ember-types.h.

#define NODE_DESCRIPTOR_REQUEST

Definition at line 1757 of file ember-types.h.

#define NODE_DESCRIPTOR_RESPONSE

Definition at line 1758 of file ember-types.h.

#define POWER_DESCRIPTOR_REQUEST

Definition at line 1770 of file ember-types.h.

#define POWER_DESCRIPTOR_RESPONSE

Definition at line 1771 of file ember-types.h.

#define SIMPLE_DESCRIPTOR_REQUEST

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (31 of 54) [10/29/2010 2:42:39 PM]

38

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 39: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

Definition at line 1787 of file ember-types.h.

#define SIMPLE_DESCRIPTOR_RESPONSE

Definition at line 1788 of file ember-types.h.

#define ACTIVE_ENDPOINTS_REQUEST

Definition at line 1799 of file ember-types.h.

#define ACTIVE_ENDPOINTS_RESPONSE

Definition at line 1800 of file ember-types.h.

#define MATCH_DESCRIPTORS_REQUEST

Definition at line 1814 of file ember-types.h.

#define MATCH_DESCRIPTORS_RESPONSE

Definition at line 1815 of file ember-types.h.

#define DISCOVERY_CACHE_REQUEST

Definition at line 1827 of file ember-types.h.

#define DISCOVERY_CACHE_RESPONSE

Definition at line 1828 of file ember-types.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (32 of 54) [10/29/2010 2:42:39 PM]

39

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 40: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

#define END_DEVICE_ANNOUNCE

Definition at line 1839 of file ember-types.h.

#define END_DEVICE_ANNOUNCE_RESPONSE

Definition at line 1840 of file ember-types.h.

#define SYSTEM_SERVER_DISCOVERY_REQUEST

Definition at line 1854 of file ember-types.h.

#define SYSTEM_SERVER_DISCOVERY_RESPONSE

Definition at line 1855 of file ember-types.h.

#define FIND_NODE_CACHE_REQUEST

Definition at line 1892 of file ember-types.h.

#define FIND_NODE_CACHE_RESPONSE

Definition at line 1893 of file ember-types.h.

#define END_DEVICE_BIND_REQUEST

Definition at line 1906 of file ember-types.h.

#define END_DEVICE_BIND_RESPONSE

Definition at line 1907 of file ember-types.h. file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (33 of 54) [10/29/2010 2:42:39 PM]

40

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 41: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

#define UNICAST_BINDING

Definition at line 1927 of file ember-types.h.

#define UNICAST_MANY_TO_ONE_BINDING

Definition at line 1928 of file ember-types.h.

#define MULTICAST_BINDING

Definition at line 1929 of file ember-types.h.

#define BIND_REQUEST

Definition at line 1931 of file ember-types.h.

#define BIND_RESPONSE

Definition at line 1932 of file ember-types.h.

#define UNBIND_REQUEST

Definition at line 1933 of file ember-types.h.

#define UNBIND_RESPONSE

Definition at line 1934 of file ember-types.h.

#define LQI_TABLE_REQUEST

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (34 of 54) [10/29/2010 2:42:39 PM]

41

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 42: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

Definition at line 1984 of file ember-types.h.

#define LQI_TABLE_RESPONSE

Definition at line 1985 of file ember-types.h.

#define ROUTING_TABLE_REQUEST

Definition at line 2020 of file ember-types.h.

#define ROUTING_TABLE_RESPONSE

Definition at line 2021 of file ember-types.h.

#define BINDING_TABLE_REQUEST

Definition at line 2042 of file ember-types.h.

#define BINDING_TABLE_RESPONSE

Definition at line 2043 of file ember-types.h.

#define LEAVE_REQUEST

Definition at line 2056 of file ember-types.h.

#define LEAVE_RESPONSE

Definition at line 2057 of file ember-types.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (35 of 54) [10/29/2010 2:42:39 PM]

42

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 43: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

#define LEAVE_REQUEST_REMOVE_CHILDREN_FLAG

Definition at line 2059 of file ember-types.h.

#define LEAVE_REQUEST_REJOIN_FLAG

Definition at line 2060 of file ember-types.h.

#define PERMIT_JOINING_REQUEST

Definition at line 2071 of file ember-types.h.

#define PERMIT_JOINING_RESPONSE

Definition at line 2072 of file ember-types.h.

#define NWK_UPDATE_REQUEST

Definition at line 2100 of file ember-types.h.

#define NWK_UPDATE_RESPONSE

Definition at line 2101 of file ember-types.h.

#define COMPLEX_DESCRIPTOR_REQUEST

Definition at line 2107 of file ember-types.h.

#define COMPLEX_DESCRIPTOR_RESPONSE

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (36 of 54) [10/29/2010 2:42:39 PM]

43

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 44: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

Definition at line 2108 of file ember-types.h.

#define USER_DESCRIPTOR_REQUEST

Definition at line 2109 of file ember-types.h.

#define USER_DESCRIPTOR_RESPONSE

Definition at line 2110 of file ember-types.h.

#define DISCOVERY_REGISTER_REQUEST

Definition at line 2111 of file ember-types.h.

#define DISCOVERY_REGISTER_RESPONSE

Definition at line 2112 of file ember-types.h.

#define USER_DESCRIPTOR_SET

Definition at line 2113 of file ember-types.h.

#define USER_DESCRIPTOR_CONFIRM

Definition at line 2114 of file ember-types.h.

#define NETWORK_DISCOVERY_REQUEST

Definition at line 2115 of file ember-types.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (37 of 54) [10/29/2010 2:42:39 PM]

44

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 45: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

#define NETWORK_DISCOVERY_RESPONSE

Definition at line 2116 of file ember-types.h.

#define DIRECT_JOIN_REQUEST

Definition at line 2117 of file ember-types.h.

#define DIRECT_JOIN_RESPONSE

Definition at line 2118 of file ember-types.h.

#define CLUSTER_ID_RESPONSE_MINIMUM

Definition at line 2121 of file ember-types.h.

Typedef Documentation

typedef int8u EmberStatus

Return type for Ember functions.

Definition at line 87 of file ember-types.h.

typedef int8u EmberEUI64[EUI64_SIZE]

EUI 64-bit ID (an IEEE address).

Definition at line 93 of file ember-types.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (38 of 54) [10/29/2010 2:42:39 PM]

45

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 46: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

typedef int8u EmberMessageBuffer

Incoming and outgoing messages are stored in buffers. These buffers are allocated and freed as needed.

Buffers are 32 bytes in length and can be linked together to hold longer messages.

See packet-buffer.h for APIs related to stack and linked buffers.

Definition at line 104 of file ember-types.h.

typedef int16u EmberNodeId

16-bit ZigBee network address.

Definition at line 109 of file ember-types.h.

typedef int16u EmberMulticastId

16-bit ZigBee multicast group identifier.

Definition at line 112 of file ember-types.h.

typedef int16u EmberPanId

802.15.4 PAN ID.

Definition at line 117 of file ember-types.h.

typedef int8u EmberTaskId

brief An identifier for a task

Definition at line 946 of file ember-types.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (39 of 54) [10/29/2010 2:42:39 PM]

46

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 47: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

typedef { ... } EmberEventData

Complete events with a control and a handler procedure.

An application typically creates an array of events along with their handlers. The main loop passes the array to emberRunEvents() in order to call the handlers of any events whose time has arrived.

typedef int8u EmberLibraryStatus

Definition at line 1673 of file ember-types.h.

Enumeration Type Documentation

enum EmberNodeType

Defines the possible types of nodes and the roles that a node might play in a network.

Enumerator: EMBER_UNKNOWN_DEVICE Device is not joined EMBER_COORDINATOR Will relay messages and can act as a parent to other nodes. EMBER_ROUTER Will relay messages and can act as a parent to other nodes. EMBER_END_DEVICE Communicates only with its parent and will not relay messages. EMBER_SLEEPY_END_DEVICE An end device whose radio can be turned off to save power. The application must call emberPollForData() to

receive messages. EMBER_MOBILE_END_DEVICE A sleepy end device that can move through the network.

Definition at line 244 of file ember-types.h.

enum EmberApsOption

Options to use when sending a message.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (40 of 54) [10/29/2010 2:42:39 PM]

47

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 48: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

The discover route, APS retry, and APS indirect options may be used together. Poll response cannot be combined with any other options.

Enumerator: EMBER_APS_OPTION_NONE No options. EMBER_APS_OPTION_DSA_SIGN This signs the application layer message body (APS Frame not included) and

appends the ECDSA signature to the end of the message. Needed by Smart Energy applications. This requires the CBKE and ECC libraries. The emberDsaSignHandler() function is called after DSA signing is complete but before the message has been sent by the APS layer.

EMBER_APS_OPTION_ENCRYPTION Send the message using APS Encryption, using the Link Key shared with the destination node to encrypt the data at the APS Level.

EMBER_APS_OPTION_RETRY Resend the message using the APS retry mechanism. In the mesh stack, this option and the enable route discovery option must be enabled for an existing route to be repaired automatically.

EMBER_APS_OPTION_ENABLE_ROUTE_DISCOVERY Send the message with the NWK 'enable route discovery' flag, which causes a route discovery to be initiated if no route to the destination is known. Note that in the mesh stack, this option and the APS retry option must be enabled an existing route to be repaired automatically.

EMBER_APS_OPTION_FORCE_ROUTE_DISCOVERY Send the message with the NWK 'force route discovery' flag, which causes a route discovery to be initiated even if one is known.

EMBER_APS_OPTION_SOURCE_EUI64 Include the source EUI64 in the network frame. EMBER_APS_OPTION_DESTINATION_EUI64 Include the destination EUI64 in the network frame. EMBER_APS_OPTION_ENABLE_ADDRESS_DISCOVERY Send a ZDO request to discover the node ID of the destination, if it is not already

know. EMBER_APS_OPTION_POLL_RESPONSE This message is being sent in response to a call to emberPollHandler(). It causes

the message to be sent immediately instead of being queued up until the next poll from the (end device) destination.

EMBER_APS_OPTION_ZDO_RESPONSE_REQUIRED This incoming message is a valid ZDO request and the application is responsible for sending a ZDO response. This flag is used only within emberIncomingMessageHandler() when EMBER_APPLICATION_RECEIVES_UNSUPPORTED_ZDO_REQUESTS is defined.

EMBER_APS_OPTION_FRAGMENT This message is part of a fragmented message. This option may only be set for unicasts. The groupId field gives the index of this fragment in the low-order byte. If the low-order byte is zero this is the first fragment and the high-order byte contains the number of fragments in the message.

Definition at line 286 of file ember-types.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (41 of 54) [10/29/2010 2:42:39 PM]

48

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 49: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

enum EmberIncomingMessageType

Defines the possible incoming message types.

Enumerator: EMBER_INCOMING_UNICAST Unicast. EMBER_INCOMING_UNICAST_REPLY Unicast reply. EMBER_INCOMING_MULTICAST Multicast. EMBER_INCOMING_MULTICAST_LOOPBACK Multicast sent by the local device. EMBER_INCOMING_BROADCAST Broadcast. EMBER_INCOMING_BROADCAST_LOOPBACK Broadcast sent by the local

device.

Definition at line 348 of file ember-types.h.

enum EmberOutgoingMessageType

Defines the possible outgoing message types.

Enumerator: EMBER_OUTGOING_DIRECT Unicast sent directly to an EmberNodeId. EMBER_OUTGOING_VIA_ADDRESS_TABLE Unicast sent using an entry in the address table. EMBER_OUTGOING_VIA_BINDING Unicast sent using an entry in the binding table. EMBER_OUTGOING_MULTICAST Multicast message. This value is passed to emberMessageSentHandler() only. It may not be

passed to emberSendUnicast(). EMBER_OUTGOING_BROADCAST Broadcast message. This value is passed to emberMessageSentHandler() only. It may not be

passed to emberSendUnicast().

Definition at line 373 of file ember-types.h.

enum EmberNetworkStatus

Defines the possible join states for a node.

Enumerator: EMBER_NO_NETWORK The node is not associated with a network in any way.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (42 of 54) [10/29/2010 2:42:39 PM]

49

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 50: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

EMBER_JOINING_NETWORK The node is currently attempting to join a network. EMBER_JOINED_NETWORK The node is joined to a network. EMBER_JOINED_NETWORK_NO_PARENT The node is an end device joined to a network but its parent is not

responding. EMBER_LEAVING_NETWORK The node is in the process of leaving its current network.

Definition at line 398 of file ember-types.h.

enum EmberNetworkScanType

Type for a network scan.

Enumerator: EMBER_ENERGY_SCAN An energy scan scans each channel for its RSSI value. EMBER_ACTIVE_SCAN An active scan scans each channel for available

networks.

Definition at line 422 of file ember-types.h.

enum EmberBindingType

Defines binding types.

Enumerator: EMBER_UNUSED_BINDING A binding that is currently not in use. EMBER_UNICAST_BINDING A unicast binding whose 64-bit identifier is the destination EUI64. EMBER_MANY_TO_ONE_BINDING A unicast binding whose 64-bit identifier is the many-to-one destination EUI64. Route discovery should

be disabled when sending unicasts via many-to-one bindings. EMBER_MULTICAST_BINDING A multicast binding whose 64-bit identifier is the group address. A multicast binding can be used to send

messages to the group and to receive messages sent to the group.

Definition at line 439 of file ember-types.h.

enum EmberJoinDecision

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (43 of 54) [10/29/2010 2:42:39 PM]

50

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 51: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

Decision made by the Trust Center when a node attempts to join.

Enumerator: EMBER_USE_PRECONFIGURED_KEY Allow the node to join. The node has the key. EMBER_SEND_KEY_IN_THE_CLEAR Allow the node to join. Send the key to the

node. EMBER_DENY_JOIN Deny join. EMBER_NO_ACTION Take no action.

Definition at line 482 of file ember-types.h.

enum EmberDeviceUpdate

The Status of the Update Device message sent to the Trust Center. The device may have joined or rejoined insecurely, rejoined securely, or left. MAC Security has been deprecated and therefore there is no secure join.

Enumerator: EMBER_STANDARD_SECURITY_SECURED_REJOIN EMBER_STANDARD_SECURITY_UNSECURED_JOIN EMBER_DEVICE_LEFT EMBER_STANDARD_SECURITY_UNSECURED_REJOIN EMBER_HIGH_SECURITY_SECURED_REJOIN EMBER_HIGH_SECURITY_UNSECURED_JOIN EMBER_HIGH_SECURITY_UNSECURED_REJOIN

Definition at line 516 of file ember-types.h.

enum EmberClusterListId

Defines the lists of clusters that must be provided for each endpoint.

Enumerator: EMBER_INPUT_CLUSTER_LIST Input clusters the endpoint will

accept. EMBER_OUTPUT_CLUSTER_LIST Output clusters the endpoint can

send.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (44 of 54) [10/29/2010 2:42:39 PM]

51

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 52: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

Definition at line 550 of file ember-types.h.

enum EmberEventUnits

Either marks an event as inactive or specifies the units for the event execution time.

Enumerator: EMBER_EVENT_INACTIVE The event is not scheduled to run. EMBER_EVENT_MS_TIME The execution time is in approximate milliseconds. EMBER_EVENT_QS_TIME The execution time is in 'binary' quarter seconds (256 approximate milliseconds

each). EMBER_EVENT_MINUTE_TIME The execution time is in 'binary' minutes (65536 approximate milliseconds each). EMBER_EVENT_ZERO_DELAY The event is scheduled to run at the earliest opportunity.

Definition at line 568 of file ember-types.h.

enum EmberJoinMethod

The type of method used for joining.

Enumerator: EMBER_USE_MAC_ASSOCIATION Normally devices use MAC Association to join a network, which respects the "permit joining"

flag in the MAC Beacon. For mobile nodes this value causes the device to use an Ember Mobile Node Join, which is functionally equivalent to a MAC association. This value should be used by default.

EMBER_USE_NWK_REJOIN For those networks where the "permit joining" flag is never turned on, they will need to use a ZigBee NWK Rejoin. This value causes the rejoin to be sent withOUT NWK security and the Trust Center will be asked to send the NWK key to the device. The NWK key sent to the device can be encrypted with the device's corresponding Trust Center link key. That is determined by the EmberJoinDecision on the Trust Center returned by the emberTrustCenterJoinHandler(). For a mobile node this value will cause it to use an Ember Mobile node rejoin, which is functionally equivalent.

EMBER_USE_NWK_REJOIN_HAVE_NWK_KEY EMBER_USE_NWK_COMMISSIONING For those networks where all network and security information is known ahead of time, a

router device may be commissioned such that it does not need to send any messages to begin communicating on the network.

Definition at line 593 of file ember-types.h. file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (45 of 54) [10/29/2010 2:42:39 PM]

52

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 53: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

enum EmberCounterType

Defines the events reported to the application by the emberCounterHandler().

Enumerator: EMBER_COUNTER_MAC_RX_BROADCAST The MAC rececived a broadcast. EMBER_COUNTER_MAC_TX_BROADCAST The MAC transmitted a broadcast. EMBER_COUNTER_MAC_RX_UNICAST The MAC received a unicast. EMBER_COUNTER_MAC_TX_UNICAST_SUCCESS The MAC successfully transmitted a unicast. EMBER_COUNTER_MAC_TX_UNICAST_RETRY The MAC retried a unicast. This is a placeholder and is not used by the

emberCounterHandler() callback. Instead the number of MAC retries are returned in the data parameter of the callback for the EMBER_COUNTER_MAC_TX_UNICAST_SUCCESS and EMBER_COUNTER_MAC_TX_UNICAST_FAILED types.

EMBER_COUNTER_MAC_TX_UNICAST_FAILED The MAC unsuccessfully transmitted a unicast. EMBER_COUNTER_APS_DATA_RX_BROADCAST The APS layer rececived a data broadcast. EMBER_COUNTER_APS_DATA_TX_BROADCAST The APS layer transmitted a data broadcast. EMBER_COUNTER_APS_DATA_RX_UNICAST The APS layer received a data unicast. EMBER_COUNTER_APS_DATA_TX_UNICAST_SUCCESS The APS layer successfully transmitted a data unicast. EMBER_COUNTER_APS_DATA_TX_UNICAST_RETRY The APS layer retried a data unicast. This is a placeholder and is not used by

the emberCounterHandler() callback. Instead the number of APS retries are returned in the data parameter of the callback for the EMBER_COUNTER_APS_DATA_TX_UNICAST_SUCCESS and EMBER_COUNTER_APS_DATA_TX_UNICAST_FAILED types.

EMBER_COUNTER_APS_DATA_TX_UNICAST_FAILED The APS layer unsuccessfully transmitted a data unicast. EMBER_COUNTER_ROUTE_DISCOVERY_INITIATED The network layer successfully submitted a new route discovery to the MAC. EMBER_COUNTER_NEIGHBOR_ADDED An entry was added to the neighbor table. EMBER_COUNTER_NEIGHBOR_REMOVED An entry was removed from the neighbor table. EMBER_COUNTER_NEIGHBOR_STALE A neighbor table entry became stale because it had not been heard from. EMBER_COUNTER_JOIN_INDICATION A node joined or rejoined to the network via this node. EMBER_COUNTER_CHILD_REMOVED An entry was removed from the child table. EMBER_COUNTER_ASH_OVERFLOW_ERROR EZSP-UART only. An overflow error occurred in the UART. EMBER_COUNTER_ASH_FRAMING_ERROR EZSP-UART only. A framing error occurred in the UART. EMBER_COUNTER_ASH_OVERRUN_ERROR EZSP-UART only. An overrun error occurred in the UART. EMBER_COUNTER_NWK_FRAME_COUNTER_FAILURE A message was dropped at the Network layer because the NWK frame

counter was not higher than the last message seen from that source.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (46 of 54) [10/29/2010 2:42:39 PM]

53

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 54: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

EMBER_COUNTER_APS_FRAME_COUNTER_FAILURE A message was dropped at the APS layer because the APS frame counter was not higher than the last message seen from that source.

EMBER_COUNTER_ASH_XOFF EZSP-UART only. An XOFF was transmitted by the UART. EMBER_COUNTER_APS_LINK_KEY_NOT_AUTHORIZED A message was dropped at the APS layer because it had APS encryption but

the key associated with the sender has not been authenticated, and thus the key is not authorized for use in APS data messages.

EMBER_COUNTER_NWK_DECRYPTION_FAILURE A NWK encrypted message was received but dropped because decryption failed.

EMBER_COUNTER_APS_DECRYPTION_FAILURE An APS encrypted message was received but dropped because decryption failed.

EMBER_COUNTER_ALLOCATE_PACKET_BUFFER_FAILURE The number of times we failed to allocate a set of linked packet buffers. This doesn't necessarily mean that the packet buffer count was 0 at the time, but that the number requested was greater than the number free.

EMBER_COUNTER_TYPE_COUNT A placeholder giving the number of Ember counter types.

Definition at line 812 of file ember-types.h.

enum EmberInitialSecurityBitmask

This is the Initial Security Bitmask that controls the use of various security features.

Enumerator: EMBER_DISTRIBUTED_TRUST_CENTER_MODE This enables Distributed Trust Center Mode for the device forming the

network. (Previously known as EMBER_NO_TRUST_CENTER_MODE) EMBER_GLOBAL_LINK_KEY This enables a Global Link Key for the Trust Center. All nodes will share

the same Trust Center Link Key. EMBER_PRECONFIGURED_NETWORK_KEY_MODE This enables devices that perform MAC Association with a pre-configured

Network Key to join the network. It is only set on the Trust Center. EMBER_HAVE_TRUST_CENTER_EUI64 This denotes that the EmberInitialSecurityState::

preconfiguredTrustCenterEui64 has a value in it containing the trust center EUI64. The device will only join a network and accept commands from a trust center with that EUI64. Normally this bit is NOT set, and the EUI64 of the trust center is learned during the join process. When commissioning a device to join onto an existing network that is using a trust center, and without sending any messages, this bit must be set and the field EmberInitialSecurityState::preconfiguredTrustCenterEui64 must be populated with the appropriate EUI64.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (47 of 54) [10/29/2010 2:42:39 PM]

54

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 55: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

EMBER_TRUST_CENTER_USES_HASHED_LINK_KEY This denotes that the EmberInitialSecurityState::preconfiguredKey is not the actual Link Key but a Root Key known only to the Trust Center. It is hashed with the IEEE Address of the destination device in order to create the actual Link Key used in encryption. This is bit is only used by the Trust Center. The joining device need not set this.

EMBER_HAVE_PRECONFIGURED_KEY This denotes that the EmberInitialSecurityState::preconfiguredKey element has valid data that should be used to configure the inital security state.

EMBER_HAVE_NETWORK_KEY This denotes that the EmberInitialSecurityState::networkKey element has valid data that should be used to configure the inital security state.

EMBER_GET_LINK_KEY_WHEN_JOINING This denotes to a joining node that it should attempt to acquire a Trust Center Link Key during joining. This is only necessary if the device does not have a pre-configured key.

EMBER_REQUIRE_ENCRYPTED_KEY This denotes that a joining device should only accept an encrypted network key from the Trust Center (using its pre-configured key). A key sent in-the-clear by the Trust Center will be rejected and the join will fail. This option is only valid when utilizing a pre-configured key.

EMBER_NO_FRAME_COUNTER_RESET This denotes whether the device should NOT reset its outgoing frame counters (both NWK and APS) when emberSetInitialSecurityState() is called. Normally it is advised to reset the frame counter before joining a new network. However in cases where a device is joining to the same network again (but not using emberRejoinNetwork()) it should keep the NWK and APS frame counters stored in its tokens.

EMBER_GET_PRECONFIGURED_KEY_FROM_INSTALL_CODE This denotes that the device should obtain its preconfigured key from an installation code stored in the manufacturing token. The token contains a value that will be hashed to obtain the actual preconfigured key. If that token is not valid than the call to emberSetInitialSecurityState() will fail.

Definition at line 1251 of file ember-types.h.

enum EmberCurrentSecurityBitmask

This is the Current Security Bitmask that details the use of various security features.

Enumerator: EMBER_STANDARD_SECURITY_MODE_ This denotes that the device is running in a network with ZigBee Standard Security. EMBER_DISTRIBUTED_TRUST_CENTER_MODE_ This denotes that the device is running in a network without a centralized Trust

Center.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (48 of 54) [10/29/2010 2:42:39 PM]

55

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 56: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

EMBER_GLOBAL_LINK_KEY_ This denotes that the device has a Global Link Key. The Trust Center Link Key is the same across multiple nodes.

EMBER_HAVE_TRUST_CENTER_LINK_KEY This denotes that the node has a Trust Center Link Key. EMBER_TRUST_CENTER_USES_HASHED_LINK_KEY_ This denotes that the Trust Center is using a Hashed Link Key.

Definition at line 1402 of file ember-types.h.

enum EmberKeyStructBitmask

This bitmask describes the presence of fields within the EmberKeyStruct.

Enumerator: EMBER_KEY_HAS_SEQUENCE_NUMBER This indicates that the key has a sequence number associated with it. (i.e. a Network

Key). EMBER_KEY_HAS_OUTGOING_FRAME_COUNTER This indicates that the key has an outgoing frame counter and the corresponding value

within the EmberKeyStruct has been populated with the data. EMBER_KEY_HAS_INCOMING_FRAME_COUNTER This indicates that the key has an incoming frame counter and the corresponding value

within the EmberKeyStruct has been populated with the data. EMBER_KEY_HAS_PARTNER_EUI64 This indicates that the key has an associated Partner EUI64 address and the

corresponding value within the EmberKeyStruct has been populated with the data. EMBER_KEY_IS_AUTHORIZED This indicates the key is authorized for use in APS data messages. If the key is not

authorized for use in APS data messages it has not yet gone through a key agreement protocol, such as CBKE (i.e. ECC)

Definition at line 1454 of file ember-types.h.

enum EmberKeyType

This denotes the type of security key.

Enumerator: EMBER_TRUST_CENTER_LINK_KEY This denotes that the key is a Trust Center Link Key. EMBER_TRUST_CENTER_MASTER_KEY This denotes that the key is a Trust Center Master

Key. EMBER_CURRENT_NETWORK_KEY This denotes that the key is the Current Network Key. EMBER_NEXT_NETWORK_KEY This denotes that the key is the Next Network Key. EMBER_APPLICATION_LINK_KEY This denotes that the key is an Application Link Key

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (49 of 54) [10/29/2010 2:42:39 PM]

56

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 57: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

EMBER_APPLICATION_MASTER_KEY This denotes that teh key is an Application Master Key

Definition at line 1483 of file ember-types.h.

enum EmberKeyStatus

This denotes the status of an attempt to establish a key with another device.

Enumerator: EMBER_APP_LINK_KEY_ESTABLISHED EMBER_APP_MASTER_KEY_ESTABLISHED EMBER_TRUST_CENTER_LINK_KEY_ESTABLISHED EMBER_KEY_ESTABLISHMENT_TIMEOUT EMBER_KEY_TABLE_FULL EMBER_TC_RESPONDED_TO_KEY_REQUEST EMBER_TC_APP_KEY_SENT_TO_REQUESTER EMBER_TC_RESPONSE_TO_KEY_REQUEST_FAILED EMBER_TC_REQUEST_KEY_TYPE_NOT_SUPPORTED EMBER_TC_NO_LINK_KEY_FOR_REQUESTER EMBER_TC_REQUESTER_EUI64_UNKNOWN EMBER_TC_RECEIVED_FIRST_APP_KEY_REQUEST EMBER_TC_TIMEOUT_WAITING_FOR_SECOND_APP_KEY_REQUEST EMBER_TC_NON_MATCHING_APP_KEY_REQUEST_RECEIVED EMBER_TC_FAILED_TO_SEND_APP_KEYS EMBER_TC_FAILED_TO_STORE_APP_KEY_REQUEST EMBER_TC_REJECTED_APP_KEY_REQUEST

Definition at line 1533 of file ember-types.h.

enum EmberLinkKeyRequestPolicy

This enumeration determines whether or not a Trust Center answers link key requests.

Enumerator: EMBER_DENY_KEY_REQUESTS EMBER_ALLOW_KEY_REQUESTS

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (50 of 54) [10/29/2010 2:42:39 PM]

57

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 58: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

Definition at line 1568 of file ember-types.h.

enum EmberMacPassthroughType

The types of MAC passthrough messages that an application may receive. This is a bitmask.

Enumerator: EMBER_MAC_PASSTHROUGH_NONE No MAC passthrough messages EMBER_MAC_PASSTHROUGH_SE_INTERPAN SE InterPAN messages EMBER_MAC_PASSTHROUGH_EMBERNET EmberNet and first generation (v1) standalone bootloader

messages EMBER_MAC_PASSTHROUGH_EMBERNET_SOURCE EmberNet messages filtered by their source address. EMBER_MAC_PASSTHROUGH_APPLICATION Application-specific passthrough messages.

Definition at line 1655 of file ember-types.h.

enum EmberZdoStatus

Enumerator: EMBER_ZDP_SUCCESS EMBER_ZDP_INVALID_REQUEST_TYPE EMBER_ZDP_DEVICE_NOT_FOUND EMBER_ZDP_INVALID_ENDPOINT EMBER_ZDP_NOT_ACTIVE EMBER_ZDP_NOT_SUPPORTED EMBER_ZDP_TIMEOUT EMBER_ZDP_NO_MATCH EMBER_ZDP_NO_ENTRY EMBER_ZDP_NO_DESCRIPTOR EMBER_ZDP_INSUFFICIENT_SPACE EMBER_ZDP_NOT_PERMITTED EMBER_ZDP_TABLE_FULL EMBER_ZDP_NOT_AUTHORIZED EMBER_NWK_ALREADY_PRESENT EMBER_NWK_TABLE_FULL EMBER_NWK_UNKNOWN_DEVICE

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (51 of 54) [10/29/2010 2:42:39 PM]

58

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 59: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

Definition at line 1686 of file ember-types.h.

enum EmberZdoServerMask

Enumerator: EMBER_ZDP_PRIMARY_TRUST_CENTER EMBER_ZDP_SECONDARY_TRUST_CENTER EMBER_ZDP_PRIMARY_BINDING_TABLE_CACHE EMBER_ZDP_SECONDARY_BINDING_TABLE_CACHE EMBER_ZDP_PRIMARY_DISCOVERY_CACHE EMBER_ZDP_SECONDARY_DISCOVERY_CACHE EMBER_ZDP_NETWORK_MANAGER

Definition at line 1863 of file ember-types.h.

enum EmberZdoConfigurationFlags

Enumerator: EMBER_APP_RECEIVES_SUPPORTED_ZDO_REQUESTS EMBER_APP_HANDLES_UNSUPPORTED_ZDO_REQUESTS EMBER_APP_HANDLES_ZDO_ENDPOINT_REQUESTS EMBER_APP_HANDLES_ZDO_BINDING_REQUESTS

Definition at line 2137 of file ember-types.h.

Function Documentation

int8u* emberKeyContents ( EmberKeyData * key )

This function allows the programmer to gain access to the actual key data bytes of the EmberKeyData struct.

Parameters:

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (52 of 54) [10/29/2010 2:42:39 PM]

59

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 60: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

key A Pointer to an EmberKeyData structure.

Returns:int8u* Returns a pointer to the first byte of the Key data.

int8u* emberCertificateContents ( EmberCertificateData * cert )

This function allows the programmer to gain access to the actual certificate data bytes of the EmberCertificateData struct.

Parameters:cert A Pointer to an EmberCertificateData structure.

Returns:int8u* Returns a pointer to the first byte of the certificate data.

int8u* emberPublicKeyContents ( EmberPublicKeyData * key )

This function allows the programmer to gain access to the actual public key data bytes of the EmberPublicKeyData struct.

Parameters:key A Pointer to an EmberPublicKeyData structure.

Returns:int8u* Returns a pointer to the first byte of the public key data.

int8u* emberPrivateKeyContents ( EmberPrivateKeyData * key )

This function allows the programmer to gain access to the actual private key data bytes of the EmberPrivateKeyData struct.

Parameters:key A Pointer to an EmberPrivateKeyData structure.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (53 of 54) [10/29/2010 2:42:39 PM]

60

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 61: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Common Data Types

Returns:int8u* Returns a pointer to the first byte of the private key data.

int8u* emberSmacContents ( EmberSmacData * key )

This function allows the programmer to gain access to the actual SMAC (Secured Message Authentication Code) data of the EmberSmacData struct.

int8u* emberSignatureContents ( EmberSignatureData * sig )

This function allows the programmer to gain access to the actual ECDSA signature data of the EmberSignatureData struct.

Variable Documentation

EmberEventControl* { ... } control [inherited]

The control structure for the event.

Definition at line 992 of file ember-types.h.

void(* { ... } handler)(void) [inherited]

The procedure to call when the event fires.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ember__types.htm (54 of 54) [10/29/2010 2:42:39 PM]

61

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 62: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Sending and Receiving Messages

Sending and Receiving Messages [Ember Common]

Detailed Description

See also ami-inter-pan.h for source code.

See also ami-inter-pan-host.h for source code.

Data Structures

struct InterPanHeader A struct for keeping track of all of the header info. More...

struct InterPanHeader A struct for keeping track of all of the header info. More...

Defines

#define INTER_PAN_UNICAST#define INTER_PAN_BROADCAST#define INTER_PAN_MULTICAST#define MAX_INTER_PAN_MAC_SIZE#define STUB_NWK_SIZE#define STUB_NWK_FRAME_CONTROL#define MAX_STUB_APS_SIZE#define MAX_INTER_PAN_HEADER_SIZE#define INTER_PAN_UNICAST#define INTER_PAN_BROADCAST#define INTER_PAN_MULTICAST#define MAX_INTER_PAN_MAC_SIZE#define STUB_NWK_SIZE#define STUB_NWK_FRAME_CONTROL#define MAX_STUB_APS_SIZE#define MAX_INTER_PAN_HEADER_SIZE

Functions

EmberMessageBuffer makeInterPanMessage (InterPanHeader *headerData, EmberMessageBuffer payload)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__message.htm (1 of 5) [10/29/2010 2:42:39 PM]

62

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 63: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Sending and Receiving Messages

int8u parseInterPanMessage (EmberMessageBuffer message, int8u startOffset, InterPanHeader *headerData)

int8u makeInterPanMessage (InterPanHeader *headerData, int8u *message, int8u maxLength, int8u *payload, int8u payloadLength)

int8u parseInterPanMessage (int8u *message, int8u messageLength, InterPanHeader *headerData)

Define Documentation

#define INTER_PAN_UNICAST

Definition at line 23 of file ami-inter-pan.h.

#define INTER_PAN_BROADCAST

Definition at line 24 of file ami-inter-pan.h.

#define INTER_PAN_MULTICAST

Definition at line 25 of file ami-inter-pan.h.

#define MAX_INTER_PAN_MAC_SIZE

Definition at line 28 of file ami-inter-pan.h.

#define STUB_NWK_SIZE

Definition at line 32 of file ami-inter-pan.h.

#define STUB_NWK_FRAME_CONTROL

Definition at line 33 of file ami-inter-pan.h.

#define MAX_STUB_APS_SIZE

Definition at line 36 of file ami-inter-pan.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__message.htm (2 of 5) [10/29/2010 2:42:39 PM]

63

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 64: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Sending and Receiving Messages

#define MAX_INTER_PAN_HEADER_SIZE

Definition at line 39 of file ami-inter-pan.h.

#define INTER_PAN_UNICAST

The three types of inter-PAN messages. The values are actually the corresponding APS frame controls. 0x03 is the special interPAN message type. Unicast mode is 0x00, broadcast mode is 0x08, and multicast mode is 0x0C.

Definition at line 21 of file ami-inter-pan-host.h.

#define INTER_PAN_BROADCAST

Definition at line 22 of file ami-inter-pan-host.h.

#define INTER_PAN_MULTICAST

Definition at line 23 of file ami-inter-pan-host.h.

#define MAX_INTER_PAN_MAC_SIZE

Definition at line 27 of file ami-inter-pan-host.h.

#define STUB_NWK_SIZE

Definition at line 31 of file ami-inter-pan-host.h.

#define STUB_NWK_FRAME_CONTROL

Definition at line 32 of file ami-inter-pan-host.h.

#define MAX_STUB_APS_SIZE

Definition at line 35 of file ami-inter-pan-host.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__message.htm (3 of 5) [10/29/2010 2:42:39 PM]

64

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 65: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Sending and Receiving Messages

#define MAX_INTER_PAN_HEADER_SIZE

Definition at line 38 of file ami-inter-pan-host.h.

Function Documentation

EmberMessageBuffer makeInterPanMessage ( InterPanHeader * headerData, EmberMessageBuffer payload

)

Creates an interpan message suitable for passing to emberSendRawMessage().

int8u parseInterPanMessage ( EmberMessageBuffer message, int8u startOffset, InterPanHeader * headerData

)

This is meant to be called on the message and offset values passed to emberMacPassthroughMessageHandler(...). The header is parsed and the various fields are written to the InterPanHeader. The returned value is the offset of the payload in the message, or 0 if the message is not a correctly formed AMI interPAN message.

int8u makeInterPanMessage ( InterPanHeader * headerData, int8u * message, int8u maxLength, int8u * payload, int8u payloadLength

)

Create an interpan message. message needs to have enough space for the message contents. Upon return, the return value will be the length of the message, or 0 in case of error.

int8u parseInterPanMessage ( int8u * message, int8u messageLength, InterPanHeader * headerData

)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__message.htm (4 of 5) [10/29/2010 2:42:39 PM]

65

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 66: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Sending and Receiving Messages

This is meant to be called on the message passed to emberMacPassthroughMessageHandler(...). The header is parsed and the various fields are written to the InterPanHeader. The returned value is the offset of the payload in the message, or 0 if the message is not a correctly formed AMI interPAN message.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__message.htm (5 of 5) [10/29/2010 2:42:39 PM]

66

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 67: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Status Codes

Ember Status Codes [Ember Common]

Detailed Description

Many EmberZNet API functions return an EmberStatus value to indicate the success or failure of the call. Return codes are one byte long. This page documents the possible status codes and their meanings.

See error-def.h for source code.

See also error.h for information on how the values for the return codes are built up from these definitions. The file error-def.h is separated from error.h because utilities will use this file to parse the return codes.

Note:Do not include error-def.h directly. It is included by error.h inside an enum typedef, which is in turn included by ember.h.

Generic Messages

These messages are system wide.

#define EMBER_SUCCESS(x00)#define EMBER_ERR_FATAL(x01)#define EMBER_BAD_ARGUMENT(x02)#define EMBER_EEPROM_MFG_STACK_VERSION_MISMATCH(x04)#define EMBER_INCOMPATIBLE_STATIC_MEMORY_DEFINITIONS(x05)#define EMBER_EEPROM_MFG_VERSION_MISMATCH(x06)#define EMBER_EEPROM_STACK_VERSION_MISMATCH(x07)

Packet Buffer Module Errors

#define EMBER_NO_BUFFERS(x18)

Serial Manager Errors

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__status__codes.htm (1 of 28) [10/29/2010 2:42:43 PM]

67

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 68: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Status Codes

#define EMBER_SERIAL_INVALID_BAUD_RATE(x20)#define EMBER_SERIAL_INVALID_PORT(x21)#define EMBER_SERIAL_TX_OVERFLOW(x22)#define EMBER_SERIAL_RX_OVERFLOW(x23)#define EMBER_SERIAL_RX_FRAME_ERROR(x24)#define EMBER_SERIAL_RX_PARITY_ERROR(x25)#define EMBER_SERIAL_RX_EMPTY(x26)#define EMBER_SERIAL_RX_OVERRUN_ERROR(x27)

MAC Errors

#define EMBER_MAC_TRANSMIT_QUEUE_FULL(x39)#define EMBER_MAC_UNKNOWN_HEADER_TYPE(x3A)#define EMBER_MAC_ACK_HEADER_TYPE(x3B)#define EMBER_MAC_SCANNING(x3D)#define EMBER_MAC_NO_DATA(x31)#define EMBER_MAC_JOINED_NETWORK(x32)#define EMBER_MAC_BAD_SCAN_DURATION(x33)#define EMBER_MAC_INCORRECT_SCAN_TYPE(x34)#define EMBER_MAC_INVALID_CHANNEL_MASK(x35)#define EMBER_MAC_COMMAND_TRANSMIT_FAILURE(x36)#define EMBER_MAC_NO_ACK_RECEIVED(x40)#define EMBER_MAC_INDIRECT_TIMEOUT(x42)

Simulated EEPROM Errors

#define EMBER_SIM_EEPROM_ERASE_PAGE_GREEN(x43)#define EMBER_SIM_EEPROM_ERASE_PAGE_RED(x44)#define EMBER_SIM_EEPROM_FULL(x45)#define EMBER_SIM_EEPROM_INIT_1_FAILED(x48)#define EMBER_SIM_EEPROM_INIT_2_FAILED(x49)#define EMBER_SIM_EEPROM_INIT_3_FAILED(x4A)

Flash Errors

#define EMBER_ERR_FLASH_WRITE_INHIBITED(x46)#define EMBER_ERR_FLASH_VERIFY_FAILED(x47)#define EMBER_ERR_FLASH_PROG_FAIL(x4B)#define EMBER_ERR_FLASH_ERASE_FAIL(x4C)

Bootloader Errors

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__status__codes.htm (2 of 28) [10/29/2010 2:42:43 PM]

68

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 69: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Status Codes

#define EMBER_ERR_BOOTLOADER_TRAP_TABLE_BAD(x58)#define EMBER_ERR_BOOTLOADER_TRAP_UNKNOWN(x59)#define EMBER_ERR_BOOTLOADER_NO_IMAGE(x05A)

Transport Errors

#define EMBER_DELIVERY_FAILED(x66)#define EMBER_BINDING_INDEX_OUT_OF_RANGE(x69)#define EMBER_ADDRESS_TABLE_INDEX_OUT_OF_RANGE(x6A)#define EMBER_INVALID_BINDING_INDEX(x6C)#define EMBER_INVALID_CALL(x70)#define EMBER_COST_NOT_KNOWN(x71)#define EMBER_MAX_MESSAGE_LIMIT_REACHED(x72)#define EMBER_MESSAGE_TOO_LONG(x74)#define EMBER_BINDING_IS_ACTIVE(x75)#define EMBER_ADDRESS_TABLE_ENTRY_IS_ACTIVE(x76)

HAL Module Errors

#define EMBER_ADC_CONVERSION_DONE(x80)#define EMBER_ADC_CONVERSION_BUSY(x81)#define EMBER_ADC_CONVERSION_DEFERRED(x82)#define EMBER_ADC_NO_CONVERSION_PENDING(x84)#define EMBER_SLEEP_INTERRUPTED(x85)

PHY Errors

#define EMBER_PHY_TX_UNDERFLOW(x88)#define EMBER_PHY_TX_INCOMPLETE(x89)#define EMBER_PHY_INVALID_CHANNEL(x8A)#define EMBER_PHY_INVALID_POWER(x8B)#define EMBER_PHY_TX_BUSY(x8C)#define EMBER_PHY_TX_CCA_FAIL(x8D)#define EMBER_PHY_OSCILLATOR_CHECK_FAILED(x8E)#define EMBER_PHY_ACK_RECEIVED(x8F)

Return Codes Passed to emberStackStatusHandler()

See also emberStackStatusHandler().

#define EMBER_NETWORK_UP(x90)#define EMBER_NETWORK_DOWN(x91)#define EMBER_JOIN_FAILED(x94)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__status__codes.htm (3 of 28) [10/29/2010 2:42:43 PM]

69

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 70: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Status Codes

#define EMBER_MOVE_FAILED(x96)#define EMBER_CANNOT_JOIN_AS_ROUTER(x98)#define EMBER_NODE_ID_CHANGED(x99)#define EMBER_PAN_ID_CHANGED(x9A)#define EMBER_CHANNEL_CHANGED(x9B)#define EMBER_NO_BEACONS(xAB)#define EMBER_RECEIVED_KEY_IN_THE_CLEAR(xAC)#define EMBER_NO_NETWORK_KEY_RECEIVED(xAD)#define EMBER_NO_LINK_KEY_RECEIVED(xAE)#define EMBER_PRECONFIGURED_KEY_REQUIRED(xAF)

Security Errors

#define EMBER_KEY_INVALID(xB2)#define EMBER_INVALID_SECURITY_LEVEL(x95)#define EMBER_APS_ENCRYPTION_ERROR(xA6)#define EMBER_TRUST_CENTER_MASTER_KEY_NOT_SET(xA7)#define EMBER_SECURITY_STATE_NOT_SET(xA8)#define EMBER_KEY_TABLE_INVALID_ADDRESS(xB3)#define EMBER_SECURITY_CONFIGURATION_INVALID(xB7)#define EMBER_TOO_SOON_FOR_SWITCH_KEY(xB8)#define EMBER_SIGNATURE_VERIFY_FAILURE(xB9)#define EMBER_KEY_NOT_AUTHORIZED(xBB)

Miscellaneous Network Errors

#define EMBER_NOT_JOINED(x93)#define EMBER_NETWORK_BUSY(xA1)#define EMBER_INVALID_ENDPOINT(xA3)#define EMBER_BINDING_HAS_CHANGED(xA4)#define EMBER_INSUFFICIENT_RANDOM_DATA(xA5)#define EMBER_SOURCE_ROUTE_FAILURE(xA9)#define EMBER_MANY_TO_ONE_ROUTE_FAILURE(xAA)

Miscellaneous Utility Errors

#define EMBER_STACK_AND_HARDWARE_MISMATCH(xB0)#define EMBER_INDEX_OUT_OF_RANGE(xB1)#define EMBER_TABLE_FULL(xB4)#define EMBER_TABLE_ENTRY_ERASED(xB6)#define EMBER_LIBRARY_NOT_PRESENT(xB5)#define EMBER_OPERATION_IN_PROGRESS(xBA)#define EMBER_TRUST_CENTER_EUI_HAS_CHANGED(xBC)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__status__codes.htm (4 of 28) [10/29/2010 2:42:43 PM]

70

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 71: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Status Codes

Application Errors

These error codes are available for application use.

#define EMBER_APPLICATION_ERROR_0(xF0)#define EMBER_APPLICATION_ERROR_1(xF1)#define EMBER_APPLICATION_ERROR_2(xF2)#define EMBER_APPLICATION_ERROR_3(xF3)#define EMBER_APPLICATION_ERROR_4(xF4)#define EMBER_APPLICATION_ERROR_5(xF5)#define EMBER_APPLICATION_ERROR_6(xF6)#define EMBER_APPLICATION_ERROR_7(xF7)#define EMBER_APPLICATION_ERROR_8(xF8)#define EMBER_APPLICATION_ERROR_9(xF9)#define EMBER_APPLICATION_ERROR_10(xFA)#define EMBER_APPLICATION_ERROR_11(xFB)#define EMBER_APPLICATION_ERROR_12(xFC)#define EMBER_APPLICATION_ERROR_13(xFD)#define EMBER_APPLICATION_ERROR_14(xFE)#define EMBER_APPLICATION_ERROR_15(xFF)

Defines

#define DEFINE_ERROR(symbol, value)

Enumerations

enum { EMBER_ERROR_CODE_COUNT }

Define Documentation

#define DEFINE_ERROR ( symbol, value )

Macro used by error-def.h to define all of the return codes.

Parameters:symbol The name of the constant being defined. All Ember returns begin with EMBER_.

For example, EMBER_CONNECTION_OPEN.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__status__codes.htm (5 of 28) [10/29/2010 2:42:43 PM]

71

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 72: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Status Codes

value The value of the return code. For example, 0x61.

Definition at line 35 of file error.h.

#define EMBER_SUCCESS ( x00 )

The generic "no error" message.

Definition at line 43 of file error-def.h.

#define EMBER_ERR_FATAL ( x01 )

The generic "fatal error" message.

Definition at line 53 of file error-def.h.

#define EMBER_BAD_ARGUMENT ( x02 )

An invalid value was passed as an argument to a function.

Definition at line 63 of file error-def.h.

#define EMBER_EEPROM_MFG_STACK_VERSION_MISMATCH ( x04 )

The manufacturing and stack token format in non-volatile memory is different than what the stack expects (returned at initialization).

Definition at line 74 of file error-def.h.

#define EMBER_INCOMPATIBLE_STATIC_MEMORY_DEFINITIONS ( x05 )

The static memory definitions in ember-static-memory.h are incompatible with this stack version.

Definition at line 85 of file error-def.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__status__codes.htm (6 of 28) [10/29/2010 2:42:43 PM]

72

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 73: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Status Codes

#define EMBER_EEPROM_MFG_VERSION_MISMATCH ( x06 )

The manufacturing token format in non-volatile memory is different than what the stack expects (returned at initialization).

Definition at line 96 of file error-def.h.

#define EMBER_EEPROM_STACK_VERSION_MISMATCH ( x07 )

The stack token format in non-volatile memory is different than what the stack expects (returned at initialization).

Definition at line 107 of file error-def.h.

#define EMBER_NO_BUFFERS ( x18 )

There are no more buffers.

Definition at line 124 of file error-def.h.

#define EMBER_SERIAL_INVALID_BAUD_RATE ( x20 )

Specified an invalid baud rate.

Definition at line 140 of file error-def.h.

#define EMBER_SERIAL_INVALID_PORT ( x21 )

Specified an invalid serial port.

Definition at line 150 of file error-def.h.

#define EMBER_SERIAL_TX_OVERFLOW ( x22 )

Tried to send too much data.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__status__codes.htm (7 of 28) [10/29/2010 2:42:43 PM]

73

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 74: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Status Codes

Definition at line 160 of file error-def.h.

#define EMBER_SERIAL_RX_OVERFLOW ( x23 )

There was not enough space to store a received character and the character was dropped.

Definition at line 171 of file error-def.h.

#define EMBER_SERIAL_RX_FRAME_ERROR ( x24 )

Detected a UART framing error.

Definition at line 181 of file error-def.h.

#define EMBER_SERIAL_RX_PARITY_ERROR ( x25 )

Detected a UART parity error.

Definition at line 191 of file error-def.h.

#define EMBER_SERIAL_RX_EMPTY ( x26 )

There is no received data to process.

Definition at line 201 of file error-def.h.

#define EMBER_SERIAL_RX_OVERRUN_ERROR ( x27 )

The receive interrupt was not handled in time, and a character was dropped.

Definition at line 212 of file error-def.h.

#define EMBER_MAC_TRANSMIT_QUEUE_FULL ( x39 )

The MAC transmit queue is full.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__status__codes.htm (8 of 28) [10/29/2010 2:42:43 PM]

74

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 75: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Status Codes

Definition at line 228 of file error-def.h.

#define EMBER_MAC_UNKNOWN_HEADER_TYPE ( x3A )

MAC header FCF error on receive.

Definition at line 239 of file error-def.h.

#define EMBER_MAC_ACK_HEADER_TYPE ( x3B )

MAC ACK header received.

Definition at line 248 of file error-def.h.

#define EMBER_MAC_SCANNING ( x3D )

The MAC can't complete this task because it is scanning.

Definition at line 259 of file error-def.h.

#define EMBER_MAC_NO_DATA ( x31 )

No pending data exists for device doing a data poll.

Definition at line 269 of file error-def.h.

#define EMBER_MAC_JOINED_NETWORK ( x32 )

Attempt to scan when we are joined to a network.

Definition at line 279 of file error-def.h.

#define EMBER_MAC_BAD_SCAN_DURATION ( x33 )

Scan duration must be 0 to 14 inclusive. Attempt was made to scan with an incorrect duration

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__status__codes.htm (9 of 28) [10/29/2010 2:42:43 PM]

75

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 76: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Status Codes

value.

Definition at line 290 of file error-def.h.

#define EMBER_MAC_INCORRECT_SCAN_TYPE ( x34 )

emberStartScan was called with an incorrect scan type.

Definition at line 300 of file error-def.h.

#define EMBER_MAC_INVALID_CHANNEL_MASK ( x35 )

emberStartScan was called with an invalid channel mask.

Definition at line 310 of file error-def.h.

#define EMBER_MAC_COMMAND_TRANSMIT_FAILURE ( x36 )

Failed to scan current channel because we were unable to transmit the relevent MAC command.

Definition at line 321 of file error-def.h.

#define EMBER_MAC_NO_ACK_RECEIVED ( x40 )

We expected to receive an ACK following the transmission, but the MAC level ACK was never received.

Definition at line 332 of file error-def.h.

#define EMBER_MAC_INDIRECT_TIMEOUT ( x42 )

Indirect data message timed out before polled.

Definition at line 342 of file error-def.h.

#define EMBER_SIM_EEPROM_ERASE_PAGE_GREEN ( x43 )

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__status__codes.htm (10 of 28) [10/29/2010 2:42:43 PM]

76

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 77: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Status Codes

The Simulated EEPROM is telling the application that there is at least one flash page to be erased. The GREEN status means the current page has not filled above the ERASE_CRITICAL_THRESHOLD.

The application should call the function halSimEepromErasePage() when it can to erase a page.

Definition at line 365 of file error-def.h.

#define EMBER_SIM_EEPROM_ERASE_PAGE_RED ( x44 )

The Simulated EEPROM is telling the application that there is at least one flash page to be erased. The RED status means the current page has filled above the ERASE_CRITICAL_THRESHOLD.

Due to the shrinking availablity of write space, there is a danger of data loss. The application must call the function halSimEepromErasePage() as soon as possible to erase a page.

Definition at line 381 of file error-def.h.

#define EMBER_SIM_EEPROM_FULL ( x45 )

The Simulated EEPROM has run out of room to write any new data and the data trying to be set has been lost. This error code is the result of ignoring the SIM_EEPROM_ERASE_PAGE_RED error code.

The application must call the function halSimEepromErasePage() to make room for any further calls to set a token.

Definition at line 396 of file error-def.h.

#define EMBER_SIM_EEPROM_INIT_1_FAILED ( x48 )

Attempt 1 to initialize the Simulated EEPROM has failed.

This failure means the information already stored in Flash (or a lack thereof), is fatally incompatible with the token information compiled into the code image being run.

Definition at line 414 of file error-def.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__status__codes.htm (11 of 28) [10/29/2010 2:42:43 PM]

77

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 78: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Status Codes

#define EMBER_SIM_EEPROM_INIT_2_FAILED ( x49 )

Attempt 2 to initialize the Simulated EEPROM has failed.

This failure means Attempt 1 failed, and the token system failed to properly reload default tokens and reset the Simulated EEPROM.

Definition at line 427 of file error-def.h.

#define EMBER_SIM_EEPROM_INIT_3_FAILED ( x4A )

Attempt 3 to initialize the Simulated EEPROM has failed.

This failure means one or both of the tokens TOKEN_MFG_NVDATA_VERSION or TOKEN_STACK_NVDATA_VERSION were incorrect and the token system failed to properly reload default tokens and reset the Simulated EEPROM.

Definition at line 441 of file error-def.h.

#define EMBER_ERR_FLASH_WRITE_INHIBITED ( x46 )

A fatal error has occured while trying to write data to the Flash. The target memory attempting to be programmed is already programmed. The flash write routines were asked to flip a bit from a 0 to 1, which is physically impossible and the write was therefore inhibited. The data in the flash cannot be trusted after this error.

Definition at line 462 of file error-def.h.

#define EMBER_ERR_FLASH_VERIFY_FAILED ( x47 )

A fatal error has occured while trying to write data to the Flash and the write verification has failed. The data in the flash cannot be trusted after this error, and it is possible this error is the result of exceeding the life cycles of the flash.

Definition at line 475 of file error-def.h.

#define EMBER_ERR_FLASH_PROG_FAIL ( x4B )

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__status__codes.htm (12 of 28) [10/29/2010 2:42:43 PM]

78

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 79: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Status Codes

Description:A fatal error has occured while trying to write data to the flash, possibly due to write protection or an invalid address. The data in the flash cannot be trusted after this error, and it is possible this error is the result of exceeding the life cycles of the flash.

Definition at line 488 of file error-def.h.

#define EMBER_ERR_FLASH_ERASE_FAIL ( x4C )

Description:A fatal error has occured while trying to erase flash, possibly due to write protection. The data in the flash cannot be trusted after this error, and it is possible this error is the result of exceeding the life cycles of the flash.

Definition at line 501 of file error-def.h.

#define EMBER_ERR_BOOTLOADER_TRAP_TABLE_BAD ( x58 )

The bootloader received an invalid message (failed attempt to go into bootloader).

Definition at line 520 of file error-def.h.

#define EMBER_ERR_BOOTLOADER_TRAP_UNKNOWN ( x59 )

Bootloader received an invalid message (failed attempt to go into bootloader).

Definition at line 531 of file error-def.h.

#define EMBER_ERR_BOOTLOADER_NO_IMAGE ( x05A )

The bootloader cannot complete the bootload operation because either an image was not found or the image exceeded memory bounds.

Definition at line 542 of file error-def.h.

#define EMBER_DELIVERY_FAILED ( x66 )

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__status__codes.htm (13 of 28) [10/29/2010 2:42:43 PM]

79

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 80: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Status Codes

The APS layer attempted to send or deliver a message, but it failed.

Definition at line 560 of file error-def.h.

#define EMBER_BINDING_INDEX_OUT_OF_RANGE ( x69 )

This binding index is out of range for the current binding table.

Definition at line 570 of file error-def.h.

#define EMBER_ADDRESS_TABLE_INDEX_OUT_OF_RANGE ( x6A )

This address table index is out of range for the current address table.

Definition at line 581 of file error-def.h.

#define EMBER_INVALID_BINDING_INDEX ( x6C )

An invalid binding table index was given to a function.

Definition at line 591 of file error-def.h.

#define EMBER_INVALID_CALL ( x70 )

The API call is not allowed given the current state of the stack.

Definition at line 602 of file error-def.h.

#define EMBER_COST_NOT_KNOWN ( x71 )

The link cost to a node is not known.

Definition at line 612 of file error-def.h.

#define EMBER_MAX_MESSAGE_LIMIT_REACHED ( x72 )

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__status__codes.htm (14 of 28) [10/29/2010 2:42:43 PM]

80

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 81: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Status Codes

The maximum number of in-flight messages (i.e. EMBER_APS_UNICAST_MESSAGE_COUNT) has been reached.

Definition at line 623 of file error-def.h.

#define EMBER_MESSAGE_TOO_LONG ( x74 )

The message to be transmitted is too big to fit into a single over-the-air packet.

Definition at line 633 of file error-def.h.

#define EMBER_BINDING_IS_ACTIVE ( x75 )

The application is trying to delete or overwrite a binding that is in use.

Definition at line 644 of file error-def.h.

#define EMBER_ADDRESS_TABLE_ENTRY_IS_ACTIVE ( x76 )

The application is trying to overwrite an address table entry that is in use.

Definition at line 654 of file error-def.h.

#define EMBER_ADC_CONVERSION_DONE ( x80 )

Conversion is complete.

Definition at line 671 of file error-def.h.

#define EMBER_ADC_CONVERSION_BUSY ( x81 )

Conversion cannot be done because a request is being processed.

Definition at line 682 of file error-def.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__status__codes.htm (15 of 28) [10/29/2010 2:42:43 PM]

81

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 82: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Status Codes

#define EMBER_ADC_CONVERSION_DEFERRED ( x82 )

Conversion is deferred until the current request has been processed.

Definition at line 693 of file error-def.h.

#define EMBER_ADC_NO_CONVERSION_PENDING ( x84 )

No results are pending.

Definition at line 703 of file error-def.h.

#define EMBER_SLEEP_INTERRUPTED ( x85 )

Sleeping (for a duration) has been abnormally interrupted and exited prematurely.

Definition at line 714 of file error-def.h.

#define EMBER_PHY_TX_UNDERFLOW ( x88 )

The transmit hardware buffer underflowed.

Definition at line 731 of file error-def.h.

#define EMBER_PHY_TX_INCOMPLETE ( x89 )

The transmit hardware did not finish transmitting a packet.

Definition at line 741 of file error-def.h.

#define EMBER_PHY_INVALID_CHANNEL ( x8A )

An unsupported channel setting was specified.

Definition at line 751 of file error-def.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__status__codes.htm (16 of 28) [10/29/2010 2:42:43 PM]

82

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 83: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Status Codes

#define EMBER_PHY_INVALID_POWER ( x8B )

An unsupported power setting was specified.

Definition at line 761 of file error-def.h.

#define EMBER_PHY_TX_BUSY ( x8C )

The requested operation cannot be completed because the radio is currently busy, either transmitting a packet or performing calibration.

Definition at line 772 of file error-def.h.

#define EMBER_PHY_TX_CCA_FAIL ( x8D )

The transmit attempt failed because all CCA attempts indicated that the channel was busy.

Definition at line 783 of file error-def.h.

#define EMBER_PHY_OSCILLATOR_CHECK_FAILED ( x8E )

The software installed on the hardware doesn't recognize the hardware radio type.

Definition at line 794 of file error-def.h.

#define EMBER_PHY_ACK_RECEIVED ( x8F )

The expected ACK was received after the last transmission.

Definition at line 804 of file error-def.h.

#define EMBER_NETWORK_UP ( x90 )

The stack software has completed initialization and is ready to send and receive packets over the air.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__status__codes.htm (17 of 28) [10/29/2010 2:42:43 PM]

83

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 84: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Status Codes

Definition at line 823 of file error-def.h.

#define EMBER_NETWORK_DOWN ( x91 )

The network is not operating.

Definition at line 833 of file error-def.h.

#define EMBER_JOIN_FAILED ( x94 )

An attempt to join a network failed.

Definition at line 843 of file error-def.h.

#define EMBER_MOVE_FAILED ( x96 )

After moving, a mobile node's attempt to re-establish contact with the network failed.

Definition at line 854 of file error-def.h.

#define EMBER_CANNOT_JOIN_AS_ROUTER ( x98 )

An attempt to join as a router failed due to a Zigbee versus Zigbee Pro incompatibility. Zigbee devices joining Zigbee Pro networks (or vica versa) must join as End Devices, not Routers.

Definition at line 866 of file error-def.h.

#define EMBER_NODE_ID_CHANGED ( x99 )

The local node ID has changed. The application can obtain the new node ID by calling emberGetNodeId().

Definition at line 876 of file error-def.h.

#define EMBER_PAN_ID_CHANGED ( x9A )

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__status__codes.htm (18 of 28) [10/29/2010 2:42:43 PM]

84

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 85: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Status Codes

The local PAN ID has changed. The application can obtain the new PAN ID by calling emberGetPanId().

Definition at line 886 of file error-def.h.

#define EMBER_CHANNEL_CHANGED ( x9B )

The channel has changed.

Definition at line 894 of file error-def.h.

#define EMBER_NO_BEACONS ( xAB )

An attempt to join or rejoin the network failed because no router beacons could be heard by the joining node.

Definition at line 903 of file error-def.h.

#define EMBER_RECEIVED_KEY_IN_THE_CLEAR ( xAC )

An attempt was made to join a Secured Network using a pre-configured key, but the Trust Center sent back a Network Key in-the-clear when an encrypted Network Key was required. (EMBER_REQUIRE_ENCRYPTED_KEY).

Definition at line 914 of file error-def.h.

#define EMBER_NO_NETWORK_KEY_RECEIVED ( xAD )

An attempt was made to join a Secured Network, but the device did not receive a Network Key.

Definition at line 924 of file error-def.h.

#define EMBER_NO_LINK_KEY_RECEIVED ( xAE )

After a device joined a Secured Network, a Link Key was requested (EMBER_GET_LINK_KEY_WHEN_JOINING) but no response was ever received.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__status__codes.htm (19 of 28) [10/29/2010 2:42:43 PM]

85

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 86: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Status Codes

Definition at line 934 of file error-def.h.

#define EMBER_PRECONFIGURED_KEY_REQUIRED ( xAF )

An attempt was made to join a Secured Network without a pre-configured key, but the Trust Center sent encrypted data using a pre-configured key.

Definition at line 945 of file error-def.h.

#define EMBER_KEY_INVALID ( xB2 )

The passed key data is not valid. A key of all zeros or all F's are reserved values and cannot be used.

Definition at line 961 of file error-def.h.

#define EMBER_INVALID_SECURITY_LEVEL ( x95 )

The chosen security level (the value of EMBER_SECURITY_LEVEL) is not supported by the stack.

Definition at line 971 of file error-def.h.

#define EMBER_APS_ENCRYPTION_ERROR ( xA6 )

There was an error in trying to encrypt at the APS Level.

This could result from either an inability to determine the long address of the recipient from the short address (no entry in the binding table) or there is no link key entry in the table associated with the destination, or there was a failure to load the correct key into the encryption core.

Definition at line 985 of file error-def.h.

#define EMBER_TRUST_CENTER_MASTER_KEY_NOT_SET ( xA7 )

There was an attempt to form a network using High security without setting the Trust Center master key first.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__status__codes.htm (20 of 28) [10/29/2010 2:42:43 PM]

86

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 87: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Status Codes

Definition at line 994 of file error-def.h.

#define EMBER_SECURITY_STATE_NOT_SET ( xA8 )

There was an attempt to form or join a network with security without calling emberSetInitialSecurityState() first.

Definition at line 1003 of file error-def.h.

#define EMBER_KEY_TABLE_INVALID_ADDRESS ( xB3 )

There was an attempt to set an entry in the key table using an invalid long address. An entry cannot be set using either the local device's or Trust Center's IEEE address. Or an entry already exists in the table with the same IEEE address. An Address of all zeros or all F's are not valid addresses in 802.15.4.

Definition at line 1016 of file error-def.h.

#define EMBER_SECURITY_CONFIGURATION_INVALID ( xB7 )

There was an attempt to set a security configuration that is not valid given the other security settings.

Definition at line 1025 of file error-def.h.

#define EMBER_TOO_SOON_FOR_SWITCH_KEY ( xB8 )

There was an attempt to broadcast a key switch too quickly after broadcasting the next network key. The Trust Center must wait at least a period equal to the broadcast timeout so that all routers have a chance to receive the broadcast of the new network key.

Definition at line 1036 of file error-def.h.

#define EMBER_SIGNATURE_VERIFY_FAILURE ( xB9 )

The received signature corresponding to the message that was passed to the CBKE Library failed verification, it is not valid.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__status__codes.htm (21 of 28) [10/29/2010 2:42:43 PM]

87

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 88: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Status Codes

Definition at line 1045 of file error-def.h.

#define EMBER_KEY_NOT_AUTHORIZED ( xBB )

The message could not be sent because the link key corresponding to the destination is not authorized for use in APS data messages. APS Commands (sent by the stack) are allowed. To use it for encryption of APS data messages it must be authorized using a key agreement protocol (such as CBKE).

Definition at line 1057 of file error-def.h.

#define EMBER_NOT_JOINED ( x93 )

The node has not joined a network.

Definition at line 1076 of file error-def.h.

#define EMBER_NETWORK_BUSY ( xA1 )

A message cannot be sent because the network is currently overloaded.

Definition at line 1086 of file error-def.h.

#define EMBER_INVALID_ENDPOINT ( xA3 )

The application tried to send a message using an endpoint that it has not defined.

Definition at line 1097 of file error-def.h.

#define EMBER_BINDING_HAS_CHANGED ( xA4 )

The application tried to use a binding that has been remotely modified and the change has not yet been reported to the application.

Definition at line 1108 of file error-def.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__status__codes.htm (22 of 28) [10/29/2010 2:42:43 PM]

88

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 89: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Status Codes

#define EMBER_INSUFFICIENT_RANDOM_DATA ( xA5 )

An attempt to generate random bytes failed because of insufficient random data from the radio.

Definition at line 1118 of file error-def.h.

#define EMBER_SOURCE_ROUTE_FAILURE ( xA9 )

A ZigBee route error command frame was received indicating that a source routed message from this node failed en route.

Definition at line 1128 of file error-def.h.

#define EMBER_MANY_TO_ONE_ROUTE_FAILURE ( xAA )

A ZigBee route error command frame was received indicating that a message sent to this node along a many-to-one route failed en route. The route error frame was delivered by an ad-hoc search for a functioning route.

Definition at line 1139 of file error-def.h.

#define EMBER_STACK_AND_HARDWARE_MISMATCH ( xB0 )

A critical and fatal error indicating that the version of the stack trying to run does not match with the chip it is running on. The software (stack) on the chip must be replaced with software that is compatible with the chip.

Definition at line 1160 of file error-def.h.

#define EMBER_INDEX_OUT_OF_RANGE ( xB1 )

An index was passed into the function that was larger than the valid range.

Definition at line 1171 of file error-def.h.

#define EMBER_TABLE_FULL ( xB4 )

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__status__codes.htm (23 of 28) [10/29/2010 2:42:43 PM]

89

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 90: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Status Codes

There are no empty entries left in the table.

Definition at line 1180 of file error-def.h.

#define EMBER_TABLE_ENTRY_ERASED ( xB6 )

The requested table entry has been erased and contains no valid data.

Definition at line 1190 of file error-def.h.

#define EMBER_LIBRARY_NOT_PRESENT ( xB5 )

The requested function cannot be executed because the library that contains the necessary functionality is not present.

Definition at line 1200 of file error-def.h.

#define EMBER_OPERATION_IN_PROGRESS ( xBA )

The stack accepted the command and is currently processing the request. The results will be returned via an appropriate handler.

Definition at line 1210 of file error-def.h.

#define EMBER_TRUST_CENTER_EUI_HAS_CHANGED ( xBC )

The EUI of the Trust center has changed due to a successful rejoin. The device may need to perform other authentication to verify the new TC is authorized to take over.

Definition at line 1221 of file error-def.h.

#define EMBER_APPLICATION_ERROR_0 ( xF0 )

This error is reserved for customer application use. This will never be returned from any portion of the network stack or HAL.

Definition at line 1239 of file error-def.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__status__codes.htm (24 of 28) [10/29/2010 2:42:43 PM]

90

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 91: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Status Codes

#define EMBER_APPLICATION_ERROR_1 ( xF1 )

This error is reserved for customer application use. This will never be returned from any portion of the network stack or HAL.

Definition at line 1240 of file error-def.h.

#define EMBER_APPLICATION_ERROR_2 ( xF2 )

This error is reserved for customer application use. This will never be returned from any portion of the network stack or HAL.

Definition at line 1241 of file error-def.h.

#define EMBER_APPLICATION_ERROR_3 ( xF3 )

This error is reserved for customer application use. This will never be returned from any portion of the network stack or HAL.

Definition at line 1242 of file error-def.h.

#define EMBER_APPLICATION_ERROR_4 ( xF4 )

This error is reserved for customer application use. This will never be returned from any portion of the network stack or HAL.

Definition at line 1243 of file error-def.h.

#define EMBER_APPLICATION_ERROR_5 ( xF5 )

This error is reserved for customer application use. This will never be returned from any portion of the network stack or HAL.

Definition at line 1244 of file error-def.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__status__codes.htm (25 of 28) [10/29/2010 2:42:43 PM]

91

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 92: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Status Codes

#define EMBER_APPLICATION_ERROR_6 ( xF6 )

This error is reserved for customer application use. This will never be returned from any portion of the network stack or HAL.

Definition at line 1245 of file error-def.h.

#define EMBER_APPLICATION_ERROR_7 ( xF7 )

This error is reserved for customer application use. This will never be returned from any portion of the network stack or HAL.

Definition at line 1246 of file error-def.h.

#define EMBER_APPLICATION_ERROR_8 ( xF8 )

This error is reserved for customer application use. This will never be returned from any portion of the network stack or HAL.

Definition at line 1247 of file error-def.h.

#define EMBER_APPLICATION_ERROR_9 ( xF9 )

This error is reserved for customer application use. This will never be returned from any portion of the network stack or HAL.

Definition at line 1248 of file error-def.h.

#define EMBER_APPLICATION_ERROR_10 ( xFA )

This error is reserved for customer application use. This will never be returned from any portion of the network stack or HAL.

Definition at line 1249 of file error-def.h.

#define EMBER_APPLICATION_ERROR_11 ( xFB )

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__status__codes.htm (26 of 28) [10/29/2010 2:42:43 PM]

92

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 93: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Status Codes

This error is reserved for customer application use. This will never be returned from any portion of the network stack or HAL.

Definition at line 1250 of file error-def.h.

#define EMBER_APPLICATION_ERROR_12 ( xFC )

This error is reserved for customer application use. This will never be returned from any portion of the network stack or HAL.

Definition at line 1251 of file error-def.h.

#define EMBER_APPLICATION_ERROR_13 ( xFD )

This error is reserved for customer application use. This will never be returned from any portion of the network stack or HAL.

Definition at line 1252 of file error-def.h.

#define EMBER_APPLICATION_ERROR_14 ( xFE )

This error is reserved for customer application use. This will never be returned from any portion of the network stack or HAL.

Definition at line 1253 of file error-def.h.

#define EMBER_APPLICATION_ERROR_15 ( xFF )

This error is reserved for customer application use. This will never be returned from any portion of the network stack or HAL.

Definition at line 1254 of file error-def.h.

Enumeration Type Documentation

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__status__codes.htm (27 of 28) [10/29/2010 2:42:43 PM]

93

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 94: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Ember Status Codes

anonymous enum

Enumerator: EMBER_ERROR_CODE_COUNT Gets defined as a count of all the possible return

codes in the EmberZNet stack API.

Definition at line 39 of file error.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__status__codes.htm (28 of 28) [10/29/2010 2:42:43 PM]

94

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 95: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Smart Energy Security

Smart Energy Security [Ember Common]

Detailed Description

This file describes functionality for Certificate Based Key Exchange (CBKE). This is used by Smart Energy devices to generate and store ephemeral ECC keys, derive the SMACs for the Key establishment protocol, and sign messages using their private key for the Demmand Response Load Control client cluster.

See cbke-crypto-engine.h for source code.

Functions

EmberStatus emberGetCertificate (EmberCertificateData *result)EmberStatus emberGenerateCbkeKeys (void)EmberStatus emberCalculateSmacs (boolean amInitiator, EmberCertificateData *partnerCert,

EmberPublicKeyData *partnerEphemeralPublicKey)EmberStatus emberClearTemporaryDataMaybeStoreLinkKey (boolean storeLinkKey)EmberStatus emberDsaSign (EmberMessageBuffer messageToSign)

void emberGenerateCbkeKeysHandler (EmberStatus status, EmberPublicKeyData *ephemeralPublicKey)

void emberCalculateSmacsHandler (EmberStatus status, EmberSmacData *initiatorSmac, EmberSmacData *responderSmac)

void emberDsaSignHandler (EmberStatus status, EmberMessageBuffer signedMessage)EmberStatus emberSetPreinstalledCbkeData (EmberPublicKeyData *caPublic, EmberCertificateData

*myCert, EmberPrivateKeyData *myKey)boolean emberGetStackCertificateEui64 (EmberEUI64 certEui64)

EmberStatus emberDsaVerify (EmberMessageDigest *digest, EmberCertificateData *signerCertificate, EmberSignatureData *receivedSig)

void emberDsaVerifyHandler (EmberStatus status)

Function Documentation

EmberStatus emberGetCertificate ( EmberCertificateData * result )

Retrieves the implicit certificate stored in the MFG tokens of the device.

Parameters:result A pointer to an EmberCertificateData structure where the retrieved certificate will be stored.

Returns:EMBER_SUCCESS if the certificate was successfully retrieved. EMBER_ERR_FATAL if the token contains uninitialized data.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen...put/API_EM260_forPDF/group__smart__energy__security.htm (1 of 4) [10/29/2010 2:42:44 PM]

95

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 96: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Smart Energy Security

EmberStatus emberGenerateCbkeKeys ( void )

This function begins the process of generating an ephemeral public/private ECC key pair.

If no other ECC operation is going on, it will immediately return with EMBER_OPERATION_IN_PROGRESS. It will delay a period of time to let APS retries take place, but then it will shutdown the radio and consume the CPU processing until the key generation is complete. This may take up to 1 second.

The generated results of the key generation is returned via emberGenerateCbkeKeysHandler().

Returns:EMBER_OPERATION_IN_PROGRESS if the stack has queued up the operation for execution.

EmberStatus emberCalculateSmacs ( boolean amInitiator, EmberCertificateData * partnerCert, EmberPublicKeyData * partnerEphemeralPublicKey

)

This function will begin the process of generating the shared secret, the new link key, and the Secured Message Authentication Code (SMAC).

If no other ECC operation is going on, it will immediately return with EMBER_OPERATION_IN_PROGRESS. It will delay a period of time to let APS retries take place, but then it will shutdown the radio and consume the CPU processing until SMACs calculations are complete. This may take up to 3.5 seconds.

The calculated SMACS are returned via emberCalculateSmacsHandler().

Parameters:amInitiator This boolean indicates whether or not the device is the one that initiated the

CBKE with the remote device, or whether it was the responder to the exchange.

partnerCert A pointer to an EmberCertificateData structure that contains the CBKE partner's implicit certificate.

partnerEphemeralPublicKey A pointer to an EmberPublicKeyData structure that contains the CBKE partner's ephemeral public key.

Returns:EMBER_OPERATION_IN_PROGRESS if the stack has queued up the operation for execution.

EmberStatus emberClearTemporaryDataMaybeStoreLinkKey ( boolean storeLinkKey )

This function should be called when all CBKE operations are done. Any temporary data created during calls to emberGenerateCbkeKeys() or emberCalculateSmacs() is wiped out. If the local device has validated that the partner device has generated the same SMACS as itself, it should set 'storeLinkKey' to TRUE. Otherwise it

file:///C|/dev/perforce/software/v2/tephra-park/doxygen...put/API_EM260_forPDF/group__smart__energy__security.htm (2 of 4) [10/29/2010 2:42:44 PM]

96

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 97: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Smart Energy Security

should pass in FALSE.

Parameters:storeLinkKey This tells the stack whether to store the newly generated link key, or discard it.

Returns:If storeLinkkey is FALSE, then this function returns EMBER_ERR_FATAL always. If storeLinkKey is TRUE, then this function returns the results of whether or not the link key was stored. EMBER_SUCCESS is returned when key was stored successfully.

EmberStatus emberDsaSign ( EmberMessageBuffer messageToSign )

void emberGenerateCbkeKeysHandler ( EmberStatus status, EmberPublicKeyData * ephemeralPublicKey

)

void emberCalculateSmacsHandler ( EmberStatus status, EmberSmacData * initiatorSmac, EmberSmacData * responderSmac

)

void emberDsaSignHandler ( EmberStatus status, EmberMessageBuffer signedMessage

)

EmberStatus emberSetPreinstalledCbkeData ( EmberPublicKeyData * caPublic, EmberCertificateData * myCert, EmberPrivateKeyData * myKey

)

boolean emberGetStackCertificateEui64 ( EmberEUI64 certEui64 )

EmberStatus emberDsaVerify ( EmberMessageDigest * digest, EmberCertificateData * signerCertificate, EmberSignatureData * receivedSig

)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen...put/API_EM260_forPDF/group__smart__energy__security.htm (3 of 4) [10/29/2010 2:42:44 PM]

97

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 98: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Smart Energy Security

void emberDsaVerifyHandler ( EmberStatus status )

file:///C|/dev/perforce/software/v2/tephra-park/doxygen...put/API_EM260_forPDF/group__smart__energy__security.htm (4 of 4) [10/29/2010 2:42:44 PM]

98

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 99: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Configuration

Configuration [Ember Common]

Detailed Description

All configurations have defaults, therefore many applications may not need to do anything special. However, you can override these defaults by creating a CONFIGURATION_HEADER and within this header, defining the appropriate macro to a different size. For example, to reduce the number of allocated packet buffers from 24 (the default) to 8:

#define EMBER_PACKET_BUFFER_COUNT 8

The convenience stubs provided in hal/ember-configuration.c can be overridden by defining the appropriate macro and providing the corresponding callback function. For example, an application with custom debug channel input must implement emberDebugHandler() to process it. Along with the function definition, the application should provide the following line in its CONFIGURATION_HEADER:

#define EMBER_APPLICATION_HAS_DEBUG_HANDLER

See ember-configuration-defaults.h for source code.

See ezsp-host-configuration-defaults.h for source code.

Defines

#define EMBER_API_MAJOR_VERSION#define EMBER_API_MINOR_VERSION#define EMBER_STACK_PROFILE#define EMBER_MAX_END_DEVICE_CHILDREN#define EMBER_SECURITY_LEVEL#define EMBER_CHILD_TABLE_SIZE#define EMBER_KEY_TABLE_SIZE#define EMBER_CERTIFICATE_TABLE_SIZE#define EMBER_MAX_DEPTH#define EMBER_MAX_HOPS#define EMBER_PACKET_BUFFER_COUNT

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__configuration.htm (1 of 13) [10/29/2010 2:42:46 PM]

99

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 100: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Configuration

#define EMBER_MAX_NEIGHBOR_TABLE_SIZE#define EMBER_NEIGHBOR_TABLE_SIZE#define EMBER_INDIRECT_TRANSMISSION_TIMEOUT#define EMBER_MAX_INDIRECT_TRANSMISSION_TIMEOUT#define EMBER_END_DEVICE_POLL_TIMEOUT#define EMBER_END_DEVICE_POLL_TIMEOUT_SHIFT#define EMBER_MOBILE_NODE_POLL_TIMEOUT#define EMBER_APS_UNICAST_MESSAGE_COUNT#define EMBER_BINDING_TABLE_SIZE#define EMBER_ADDRESS_TABLE_SIZE#define EMBER_RESERVED_MOBILE_CHILD_ENTRIES#define EMBER_ROUTE_TABLE_SIZE#define EMBER_DISCOVERY_TABLE_SIZE#define EMBER_MULTICAST_TABLE_SIZE#define EMBER_SOURCE_ROUTE_TABLE_SIZE#define EMBER_BROADCAST_TABLE_SIZE#define EMBER_ASSERT_SERIAL_PORT#define EMBER_MAXIMUM_ALARM_DATA_SIZE#define EMBER_BROADCAST_ALARM_DATA_SIZE#define EMBER_UNICAST_ALARM_DATA_SIZE#define EMBER_FRAGMENT_DELAY_MS#define EMBER_FRAGMENT_MAX_WINDOW_SIZE#define EMBER_FRAGMENT_WINDOW_SIZE#define EMBER_BINDING_TABLE_TOKEN_SIZE#define EMBER_CHILD_TABLE_TOKEN_SIZE#define EMBER_KEY_TABLE_TOKEN_SIZE#define EMBER_REQUEST_KEY_TIMEOUT#define EMBER_END_DEVICE_BIND_TIMEOUT#define EMBER_PAN_ID_CONFLICT_REPORT_THRESHOLD#define EMBER_TASK_COUNT#define EZSP_HOST_SOURCE_ROUTE_TABLE_SIZE#define EZSP_HOST_ASH_RX_POOL_SIZE#define EZSP_HOST_FORM_AND_JOIN_BUFFER_SIZE

Define Documentation

#define EMBER_API_MAJOR_VERSION

The major version number of the Ember stack release that the application is built against.

Definition at line 58 of file ember-configuration-defaults.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__configuration.htm (2 of 13) [10/29/2010 2:42:46 PM]

100

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 101: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Configuration

#define EMBER_API_MINOR_VERSION

The minor version number of the Ember stack release that the application is built against.

Definition at line 65 of file ember-configuration-defaults.h.

#define EMBER_STACK_PROFILE

Specifies the stack profile. The default is Profile 0.

You can set this to Profile 1 (ZigBee) or Profile 2 (ZigBee Pro) in your application's configuration header (.h) file using:

#define EMBER_STACK_PROFILE 1

or

#define EMBER_STACK_PROFILE 2

Definition at line 81 of file ember-configuration-defaults.h.

#define EMBER_MAX_END_DEVICE_CHILDREN

The maximum number of end device children that a router will support. For profile 0 the default value is 6, for profile 1 the value is 14.

Definition at line 98 of file ember-configuration-defaults.h.

#define EMBER_SECURITY_LEVEL

The security level used for security at the MAC and network layers. The supported values are 0 (no security) and 5 (payload is encrypted and a four-byte MIC is used for authentication).

Definition at line 116 of file ember-configuration-defaults.h.

#define EMBER_CHILD_TABLE_SIZE

The maximum number of children that a node may have.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__configuration.htm (3 of 13) [10/29/2010 2:42:46 PM]

101

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 102: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Configuration

For the tree stack this values defaults to the sum of EMBER_MAX_END_DEVICE_CHILDREN and EMBER_MAX_ROUTER_CHILDREN. For the mesh stack this defaults to the value of EMBER_MAX_END_DEVICE_CHILDREN. In the mesh stack router children are not stored in the child table.

Each child table entry requires 4 bytes of RAM and a 10 byte token.

Application definitions for EMBER_CHILD_TABLE_SIZE that are larger than the default value are ignored and the default value used instead.

Definition at line 145 of file ember-configuration-defaults.h.

#define EMBER_KEY_TABLE_SIZE

The maximum number of link and master keys that a node can store, not including the Trust Center Link Key. The stack maintains special storage for the Trust Center Link Key.

For the Trust Center, this controls how many totally unique Trust Center Link Keys may be stored. The rest of the devices in the network will use a global or hashed link key.

For normal nodes, this controls the number of Application Link Keys it can store. The Trust Center Link Key is stored separately from this table.

Definition at line 162 of file ember-configuration-defaults.h.

#define EMBER_CERTIFICATE_TABLE_SIZE

The number of entries for the field upgradeable certificate table. Normally certificates (such as SE certs) are stored in the runtime-unmodifiable MFG area. However for those devices wishing to add new certificates after manufacturing, they will have to use the normal token space. This defines the size of that table. For most devices 0 is appropriate since there is no need to change certificates in the field. For those wishing to field upgrade devices with new certificates, 1 is the correct size. Anything more is simply wasting SimEEPROM.

Definition at line 175 of file ember-configuration-defaults.h.

#define EMBER_MAX_DEPTH

The maximum depth of the tree in ZigBee 2006. This implicitly determines the maximum diameter

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__configuration.htm (4 of 13) [10/29/2010 2:42:46 PM]

102

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 103: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Configuration

of the network (EMBER_MAX_HOPS) if that value is not overridden.

Definition at line 188 of file ember-configuration-defaults.h.

#define EMBER_MAX_HOPS

The maximum number of hops for a message.

When the radius is not supplied by the Application (i.e. 0) or the stack is sending a message, then the default is two times the max depth (EMBER_MAX_DEPTH).

Definition at line 201 of file ember-configuration-defaults.h.

#define EMBER_PACKET_BUFFER_COUNT

The number of Packet Buffers available to the Stack. The default is 24.

Each buffer requires 40 bytes of RAM (32 for the buffer itself plus 8 bytes of overhead).

Definition at line 211 of file ember-configuration-defaults.h.

#define EMBER_MAX_NEIGHBOR_TABLE_SIZE

The maximum number of router neighbors the stack can keep track of.

A neighbor is a node within radio range. The maximum allowed value is 16. End device children are kept track of in the child table, not the neighbor table. The default is 16. Setting this value lower than 8 is not recommended.

Each neighbor table entry consumes 18 bytes of RAM (6 for the table itself and 12 bytes of security data).

Definition at line 225 of file ember-configuration-defaults.h.

#define EMBER_NEIGHBOR_TABLE_SIZE

Definition at line 227 of file ember-configuration-defaults.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__configuration.htm (5 of 13) [10/29/2010 2:42:46 PM]

103

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 104: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Configuration

#define EMBER_INDIRECT_TRANSMISSION_TIMEOUT

The maximum amount of time (in milliseconds) that the MAC will hold a message for indirect transmission to a child.

The default is 3000 milliseconds (3 sec). The maximum value is 30 seconds (30000 milliseconds).larger values will cause rollover confusion.

Definition at line 237 of file ember-configuration-defaults.h.

#define EMBER_MAX_INDIRECT_TRANSMISSION_TIMEOUT

Definition at line 239 of file ember-configuration-defaults.h.

#define EMBER_END_DEVICE_POLL_TIMEOUT

The maximum amount of time, in units determined by EMBER_END_DEVICE_POLL_TIMEOUT_SHIFT, that an EMBER_END_DEVICE or EMBER_SLEEPY_END_DEVICE can wait between polls. The timeout value in seconds is EMBER_END_DEVICE_POLL_TIMEOUT << EMBER_END_DEVICE_POLL_TIMEOUT_SHIFT. If no poll is heard within this time, then the parent removes the end device from its tables. Note: there is a separate EMBER_MOBILE_NODE_POLL_TIMEOUT for mobile end devices.

Using the default values of both EMBER_END_DEVICE_POLL_TIMEOUT and EMBER_END_DEVICE_POLL_TIMEOUT_SHIFT results in a timeout of 320 seconds, or just over five minutes. The maximum value for EMBER_END_DEVICE_POLL_TIMEOUT is 255.

Definition at line 259 of file ember-configuration-defaults.h.

#define EMBER_END_DEVICE_POLL_TIMEOUT_SHIFT

The units used for timing out end devices on their parents. See EMBER_END_DEVICE_POLL_TIMEOUT for an explanation of how this value is used.

The default value of 6 means gives EMBER_END_DEVICE_POLL_TIMEOUT a default unit of 64 seconds, or approximately one minute. The maximum value for EMBER_END_DEVICE_POLL_TIMEOUT_SHIFT is 14.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__configuration.htm (6 of 13) [10/29/2010 2:42:46 PM]

104

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 105: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Configuration

Definition at line 270 of file ember-configuration-defaults.h.

#define EMBER_MOBILE_NODE_POLL_TIMEOUT

The maximum amount of time (in quarter-seconds) that a mobile node can wait between polls. If no poll is heard within this timeout, then the parent removes the mobile node from its tables. The default is 20 quarter seconds (5 seconds). The maximum is 255 quarter seconds.

Definition at line 280 of file ember-configuration-defaults.h.

#define EMBER_APS_UNICAST_MESSAGE_COUNT

The maximum number of APS retried messages that the stack can be transmitting at any time. Here, "transmitting" means the time between the call to emberSendUnicast() and the subsequent callback to emberMessageSentHandler().

Note:A message will typically use one packet buffer for the message header and one or more packet buffers for the payload. The default is 10 messages.

Each APS retried message consumes 6 bytes of RAM, in addition to two or more packet buffers.

Definition at line 296 of file ember-configuration-defaults.h.

#define EMBER_BINDING_TABLE_SIZE

The maximum number of bindings supported by the stack. The default is 0 bindings. Each binding consumes 2 bytes of RAM.

Definition at line 302 of file ember-configuration-defaults.h.

#define EMBER_ADDRESS_TABLE_SIZE

The maximum number of EUI64<->network address associations that the stack can maintain. The default value is 8.

Address table entries are 10 bytes in size.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__configuration.htm (7 of 13) [10/29/2010 2:42:46 PM]

105

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 106: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Configuration

Definition at line 310 of file ember-configuration-defaults.h.

#define EMBER_RESERVED_MOBILE_CHILD_ENTRIES

The number of child table entries reserved for use only by mobile nodes. The default value is 0.

The maximum number of non-mobile children for a parent is EMBER_CHILD_TABLE_SIZE - EMBER_RESERVED_MOBILE_CHILD_ENTRIES.

Definition at line 320 of file ember-configuration-defaults.h.

#define EMBER_ROUTE_TABLE_SIZE

The maximum number of destinations to which a node can route messages. This include both messages originating at this node and those relayed for others. The default value is 16.

Route table entries are 6 bytes in size.

Definition at line 333 of file ember-configuration-defaults.h.

#define EMBER_DISCOVERY_TABLE_SIZE

The number of simultaneous route discoveries that a node will support.

Discovery table entries are 9 bytes in size.

Definition at line 349 of file ember-configuration-defaults.h.

#define EMBER_MULTICAST_TABLE_SIZE

The maximum number of multicast groups that the device may be a member of. The default value is 8.

Multicast table entries are 3 bytes in size.

Definition at line 362 of file ember-configuration-defaults.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__configuration.htm (8 of 13) [10/29/2010 2:42:46 PM]

106

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 107: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Configuration

#define EMBER_SOURCE_ROUTE_TABLE_SIZE

The maximum number of source route table entries supported by the utility code in app/util/source-route.c. The maximum source route table size is 255 entries, since a one-byte index is used, and the index 0xFF is reserved. The default value is 32.

Source route table entries are 4 bytes in size.

Definition at line 372 of file ember-configuration-defaults.h.

#define EMBER_BROADCAST_TABLE_SIZE

The maximum number broadcasts during a single broadcast timeout period. The minimum and default value is 15 and can only be changed only on compatible Ember stacks.

Broadcast table entries are 5 bytes in size.

Definition at line 381 of file ember-configuration-defaults.h.

#define EMBER_ASSERT_SERIAL_PORT

Settings to control if and where assert information will be printed.

The output can be suppressed by defining EMBER_ASSERT_OUTPUT_DISABLED. The serial port to which the output is sent can be changed by defining EMBER_ASSERT_SERIAL_PORT as the desired port.

The default is to have assert output on and sent to serial port 1.

Definition at line 399 of file ember-configuration-defaults.h.

#define EMBER_MAXIMUM_ALARM_DATA_SIZE

The absolute maximum number of payload bytes in an alarm message.

The three length bytes in EMBER_UNICAST_ALARM_CLUSTER messages do not count towards this limit.

EMBER_MAXIMUM_ALARM_DATA_SIZE is defined to be 16.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__configuration.htm (9 of 13) [10/29/2010 2:42:46 PM]

107

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 108: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Configuration

The maximum payload on any particular device is determined by the configuration parameters, EMBER_BROADCAST_ALARM_DATA_SIZE and EMBER_UNICAST_ALARM_DATA_SIZE, neither of which may be greater than MBER_MAXIMUM_ALARM_DATA_SIZE.

Definition at line 415 of file ember-configuration-defaults.h.

#define EMBER_BROADCAST_ALARM_DATA_SIZE

The sizes of the broadcast and unicast alarm buffers in bytes.

Devices have a single broadcast alarm buffer. Routers have one unicast alarm buffer for each child table entry. The total RAM used for alarms is

EMBER_BROADCAST_ALARM_DATA_SIZE + (EMBER_UNICAST_ALARM_DATA_SIZE * EMBER_CHILD_TABLE_SIZE)

EMBER_BROADCAST_ALARM_DATA_SIZE is the size of the alarm broadcast buffer. Broadcast alarms whose length is larger will not be buffered or forwarded to sleepy end device children. This parameter must be in the inclusive range 0 ... EMBER_MAXIMUM_ALARM_DATA_SIZE. The default value is 0.

Definition at line 435 of file ember-configuration-defaults.h.

#define EMBER_UNICAST_ALARM_DATA_SIZE

The size of the unicast alarm buffers allocated for end device children.

Unicast alarms whose length is larger will not be buffered or forwarded to sleepy end device children. This parameter must be in the inclusive range 0 ... EMBER_MAXIMUM_ALARM_DATA_SIZE. The default value is 0.

Definition at line 449 of file ember-configuration-defaults.h.

#define EMBER_FRAGMENT_DELAY_MS

The time the stack will wait (in milliseconds) between sending blocks of a fragmented message.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__configuration.htm (10 of 13) [10/29/2010 2:42:46 PM]

108

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 109: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Configuration

The default value is 0.

Definition at line 458 of file ember-configuration-defaults.h.

#define EMBER_FRAGMENT_MAX_WINDOW_SIZE

The maximum number of blocks of a fragmented message that can be sent in a single window is defined to be 8.

Definition at line 464 of file ember-configuration-defaults.h.

#define EMBER_FRAGMENT_WINDOW_SIZE

The number of blocks of a fragmented message that can be sent in a single window. The maximum is EMBER_FRAGMENT_MAX_WINDOW_SIZE. The default value is 1.

Definition at line 471 of file ember-configuration-defaults.h.

#define EMBER_BINDING_TABLE_TOKEN_SIZE

Definition at line 477 of file ember-configuration-defaults.h.

#define EMBER_CHILD_TABLE_TOKEN_SIZE

Definition at line 480 of file ember-configuration-defaults.h.

#define EMBER_KEY_TABLE_TOKEN_SIZE

Definition at line 483 of file ember-configuration-defaults.h.

#define EMBER_REQUEST_KEY_TIMEOUT

The length of time that the device will wait for an answer to its Application Key Request. For the Trust Center this is the time it will hold the first request and wait for a second matching request. If both arrive within this time period, the Trust Center will reply to both with the new key. If both requests are not received then the Trust Center will discard the request. The time is in minutes.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__configuration.htm (11 of 13) [10/29/2010 2:42:46 PM]

109

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 110: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Configuration

The maximum time is 10 minutes. A value of 0 minutes indicates that the Trust Center will not buffer the request but instead respond immediately. Only 1 outstanding request is supported at a time.

The Zigbee Pro Compliant value is 0.

Definition at line 499 of file ember-configuration-defaults.h.

#define EMBER_END_DEVICE_BIND_TIMEOUT

The time the coordinator will wait (in seconds) for a second end device bind request to arrive. The default value is 60.

Definition at line 508 of file ember-configuration-defaults.h.

#define EMBER_PAN_ID_CONFLICT_REPORT_THRESHOLD

The number of PAN id conflict reports that must be received by the network manager within one minute to trigger a PAN id change. Very rarely, a corrupt beacon can pass the CRC check and trigger a false PAN id conflict. This is more likely to happen in very large dense networks. Setting this value to 2 or 3 dramatically reduces the chances of a spurious PAN id change. The maximum value is 63. The default value is 1.

Definition at line 520 of file ember-configuration-defaults.h.

#define EMBER_TASK_COUNT

The number of event tasks that can be tracked for the purpose of processor idling. The EmberZNet stack requires 1, an application and associated libraries may use additional tasks, though typically no more than 3 are needed for most applications.

Definition at line 529 of file ember-configuration-defaults.h.

#define EZSP_HOST_SOURCE_ROUTE_TABLE_SIZE

The size of the source route table on the EZSP host.

Note:This configuration value sets the size of the source route table on the host, not on the

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__configuration.htm (12 of 13) [10/29/2010 2:42:46 PM]

110

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 111: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Configuration

node. EMBER_SOURCE_ROUTE_TABLE_SIZE sets EZSP_CONFIG_SOURCE_ROUTE_TABLE_SIZE if ezsp-utils.c is used, which sets the size of the source route table on the NCP.

Definition at line 32 of file ezsp-host-configuration-defaults.h.

#define EZSP_HOST_ASH_RX_POOL_SIZE

Define the size of the ASH receive buffer pool on the EZSP host.

The number of receive buffers does not need to be greater than the number of packet buffers available on the ncp, because this in turn is the maximum number of callbacks that could be received between commands. In reality a value of 20 is a generous allocation.

Definition at line 43 of file ezsp-host-configuration-defaults.h.

#define EZSP_HOST_FORM_AND_JOIN_BUFFER_SIZE

The size of the buffer for caching data during scans.

The form and join host library uses a flat buffer to store channel energy, pan ids, and matching networks. The underlying data structure is an int16u[], so the true storage size is twice this value. The library requires the buffer be at least 32 bytes, so the minimum size here is 16. A matching network requires 16 bytes in the buffer, so a multiple of 8 here is most efficient.

Definition at line 56 of file ezsp-host-configuration-defaults.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__configuration.htm (13 of 13) [10/29/2010 2:42:46 PM]

111

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 112: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Debugging Utilities

Debugging Utilities [Ember Common]

Detailed Description

EmberZNet debugging utilities.

See ember-debug.h for source code.

Defines

#define NO_DEBUG#define BASIC_DEBUG#define FULL_DEBUG#define emberDebugInit(port)

Functions

void emberDebugAssert (PGM_P filename, int linenumber)void emberDebugMemoryDump (int8u *start, int8u *end)void emberDebugBinaryPrintf (PGM_P formatString,...)void emDebugSendVuartMessage (int8u *buff, int8u len)void emberDebugError (EmberStatus code)

boolean emberDebugReportOff (void)void emberDebugReportRestore (boolean state)void emberDebugPrintf (PGM_P formatString,...)

Define Documentation

#define NO_DEBUG

Definition at line 20 of file ember-debug.h.

#define BASIC_DEBUG

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__debug.htm (1 of 5) [10/29/2010 2:42:46 PM]

112

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 113: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Debugging Utilities

Definition at line 21 of file ember-debug.h.

#define FULL_DEBUG

Definition at line 22 of file ember-debug.h.

#define emberDebugInit ( port )

This function is obsolete and no longer required to initialize the debug system.

Parameters:port Ignored because the port used for debug communication is automatically determined

for each platform.

Definition at line 30 of file ember-debug.h.

Function Documentation

void emberDebugAssert ( PGM_P filename, int linenumber

)

Prints the filename and line number to the debug serial port.

Parameters:filename The name of the file where the assert occurred.linenumber The line number in the file where the assert

occurred.

void emberDebugMemoryDump ( int8u * start, int8u * end

)

Prints the contents of RAM to the debug serial port.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__debug.htm (2 of 5) [10/29/2010 2:42:46 PM]

113

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 114: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Debugging Utilities

Parameters:start The start address of the block of RAM to dump.end The end address of the block of RAM to dump (address of the last

byte).

void emberDebugBinaryPrintf ( PGM_P formatString, ...

)

Prints binary data to the debug channel.

This function does not use the normal printf format conventions. To print text debug messages, use emberDebugPrintf(). The format string must contain only these conversion specification characters:

● B - int8u value.● W - int16u value, printed least significant byte first.● D - int32u value, printed least significant byte first.● F - pointer to null terminated string in Flash (PGM_P).● xxxp - pointer to RAM, length is xxx (max 255).● lp - pointer to RAM, length is int8u argument.● xxxf - pointer to Flash (PGM_P), length is xxx (max 255).● lf - pointer to Flash (PGM_P), length is int8u argument.● b - EmberMessageBuffer.

Examples:

emberDebugBinaryPrintf("BWD", status, panId, channelMask); emberDebugBinaryPrintf("F8p", "string example", eui64); emberDebugBinaryPrintf("lp64fb", length, bytes, dataTable, buffer);

Parameters:formatString A string of conversion specification characters describing the arguments to

be printed. ... The arguments to be printed.

void emDebugSendVuartMessage ( int8u * buff, int8u len

)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__debug.htm (3 of 5) [10/29/2010 2:42:46 PM]

114

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 115: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Debugging Utilities

internal debug command used by the HAL to send vuart data out the the debug channel

Parameters:buff pointer to the data to sendlen lenght of the data to send

void emberDebugError ( EmberStatus code )

Prints an EmberStatus return code to the serial port.

Parameters:code The EmberStatus code to

print.

boolean emberDebugReportOff ( void )

Turns off all debug output.

Returns:The current state (TRUE for on, FALSE for off).

void emberDebugReportRestore ( boolean state )

Restores the state of the debug output.

Parameters:state The state returned from emberDebugReportOff(). This is done so that debug

output is not blindly turned on.

void emberDebugPrintf ( PGM_P formatString, ...

)

Prints text debug messages.

Parameters:formatString Takes the following:

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__debug.htm (4 of 5) [10/29/2010 2:42:46 PM]

115

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 116: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Debugging Utilities

%% Percent sign

%c Single-byte char

%s RAM string

%p Flash string (does not follow the printf standard)

%u Two-byte unsigned decimal

%d Two-byte signed decimal

%x, %2x, %4x

1-, 2-, 4-byte hex value (always 0 padded; does not follow the printf standard)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__debug.htm (5 of 5) [10/29/2010 2:42:46 PM]

116

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 117: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Hardware Abstraction Layer (HAL) API Reference

Hardware Abstraction Layer (HAL) API Reference

Detailed Description

Atmel Atmega32 Microprocessors

HAL function names have the following prefix conventions:

halCommon: API that is used by the EmberZNet stack and can also be called from an application. This API must be implemented. Custom applications can change the implementation of the API but its functionality must remain the same.

hal: API that is used by sample applications. Custom applications can remove this API or change its implementation as they see fit.

halStack: API used only by the EmberZNet stack. This API must be implemented and should not be directly called from any application. Custom applications can change the implementation of the API, but its functionality must remain the same.

halInternal: API that is internal to the HAL. The EmberZNet stack and applications must never call this API directly. Custom applications can change this API as they see fit. However, be careful not to impact the functionalty of any halStack or halCommon APIs. See also hal.h.

Modules

Common Microcontroller Functions Sample APIs for Peripheral Access System Timer Control HAL Utilities Asynchronous Serial Host (ASH) Framework

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__hal.htm [10/29/2010 2:42:47 PM]

117

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 118: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Common Microcontroller Functions

Common Microcontroller Functions [Hardware Abstraction Layer (HAL) API Reference]

Detailed Description

Many of the supplied example applications use these microcontroller functions. See hal/micro/micro.h for source code.

Note:The term SFD refers to the Start Frame Delimiter.

See also iar.h.

See also 32/micro.h for source code.

See also 32/reserved-ram.h.

See also 128/micro.h.

See also 128/reserved-ram.h.

Defines

#define halGetEm2xxResetInfo()#define MILLISECOND_TICKS_PER_SECOND#define RESET_UNKNOWN#define RESET_EXTERNAL#define RESET_POWERON#define RESET_WATCHDOG#define RESET_BROWNOUT#define RESET_JTAG#define RESET_ASSERT#define RESET_RSTACK#define RESET_CSTACK#define RESET_BOOTLOADER#define RESET_PC_ROLLOVER#define RESET_SOFTWARE

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__micro.htm (1 of 6) [10/29/2010 2:42:48 PM]

118

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 119: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Common Microcontroller Functions

#define RESET_PROTFAULT#define RESET_FLASH_VERIFY_FAIL#define RESET_FLASH_WRITE_INHIBIT#define RESET_BOOTLOADER_IMG_BAD

Functions

void halStackProcessBootCount (void)int8u halGetResetInfo (void)

PGM_P halGetResetString (void)void halInternalAssertFailed (PGM_P filename, int linenumber)void halStackTriggerDebugTimeSyncCapture (void)

Define Documentation

#define halGetEm2xxResetInfo ( )

Calls halGetExtendedResetInfo() and translates the EM35x reset code to the corresponding value used by the EM2XX HAL. EM35x reset codes not present in the EM2XX are returned after being OR'ed with 0x80.

Application Usage:Used by the EZSP host as a platform-independent NCP reset code.

Returns:The EM2XX reset code, or a new EM3xx code if B7 is set.

Definition at line 167 of file micro.h.

#define MILLISECOND_TICKS_PER_SECOND

Definition at line 50 of file avr-atmega/32/micro.h.

#define RESET_UNKNOWN

Defines conditions representing possible reasons for a reset.

Definition at line 56 of file avr-atmega/32/micro.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__micro.htm (2 of 6) [10/29/2010 2:42:48 PM]

119

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 120: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Common Microcontroller Functions

#define RESET_EXTERNAL

Definition at line 57 of file avr-atmega/32/micro.h.

#define RESET_POWERON

Definition at line 58 of file avr-atmega/32/micro.h.

#define RESET_WATCHDOG

Definition at line 59 of file avr-atmega/32/micro.h.

#define RESET_BROWNOUT

Definition at line 60 of file avr-atmega/32/micro.h.

#define RESET_JTAG

Definition at line 61 of file avr-atmega/32/micro.h.

#define RESET_ASSERT

Definition at line 62 of file avr-atmega/32/micro.h.

#define RESET_RSTACK

Definition at line 63 of file avr-atmega/32/micro.h.

#define RESET_CSTACK

Definition at line 64 of file avr-atmega/32/micro.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__micro.htm (3 of 6) [10/29/2010 2:42:48 PM]

120

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 121: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Common Microcontroller Functions

#define RESET_BOOTLOADER

Definition at line 65 of file avr-atmega/32/micro.h.

#define RESET_PC_ROLLOVER

Definition at line 66 of file avr-atmega/32/micro.h.

#define RESET_SOFTWARE

Definition at line 67 of file avr-atmega/32/micro.h.

#define RESET_PROTFAULT

Definition at line 68 of file avr-atmega/32/micro.h.

#define RESET_FLASH_VERIFY_FAIL

Definition at line 69 of file avr-atmega/32/micro.h.

#define RESET_FLASH_WRITE_INHIBIT

Definition at line 70 of file avr-atmega/32/micro.h.

#define RESET_BOOTLOADER_IMG_BAD

Definition at line 71 of file avr-atmega/32/micro.h.

Function Documentation

void halStackProcessBootCount ( void )

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__micro.htm (4 of 6) [10/29/2010 2:42:48 PM]

121

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 122: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Common Microcontroller Functions

Called from emberInit and provides a means for the HAL to increment a boot counter, most commonly in non-volatile memory.

This is useful while debugging to determine the number of resets that might be seen over a period of time. Exposing this functionality allows the application to disable or alter processing of the boot counter if, for example, the application is expecting a lot of resets that could wear out non-volatile storage or some

EmberStack Usage:Called from emberInit only as helpful debugging information. This should be left enabled by default, but this function can also be reduced to a simple return statement if boot counting is not desired.

int8u halGetResetInfo ( void )

Gets information about what caused the microcontroller to reset.

Returns:A code identifying the cause of the reset.

PGM_P halGetResetString ( void )

Calls halGetResetInfo() and supplies a string describing it.

Application Usage:Useful for diagnostic printing of text just after program initialization.

Returns:A pointer to a program space string.

void halInternalAssertFailed ( PGM_P filename, int linenumber

)

Called implicitly through the standard C language assert() macro. An implementation where notification is, for instance, sent over the serial port can provide meaningful and useful debugging information.

Note:Liberal usage of assert() consumes flash space.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__micro.htm (5 of 6) [10/29/2010 2:42:48 PM]

122

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 123: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Common Microcontroller Functions

Parameters:filename Name of the file throwing the assert.linenumber Line number that threw the assert.

void halStackTriggerDebugTimeSyncCapture ( void )

Used by the debug stack to trigger the backchannel timer capture circuitry.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__micro.htm (6 of 6) [10/29/2010 2:42:48 PM]

123

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 124: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Sample APIs for Peripheral Access

Sample APIs for Peripheral Access [Hardware Abstraction Layer (HAL) API Reference]

Detailed Description

These are sample API for accessing peripherals and can be modified as needed for your applications.

Modules

Serial UART Communication ADC Control Button Control Buzzer Control LED Control Carrier Board Control SPI Access

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__peripherals.htm [10/29/2010 2:42:48 PM]

124

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 125: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Serial UART Communication

Serial UART Communication [Sample APIs for Peripheral Access]

Detailed Description

This API contains the HAL interfaces that applications must implement for the high-level serial code.

This header describes the interface between the high-level serial APIs in app/util/serial/serial.h and the low level UART implementation.

Some functions in this file return an EmberStatus value. See error-def.h for definitions of all EmberStatus return values.

See hal/micro/serial.h for source code.

Modules

Hardware-Specific UART

Serial HAL APIs

These functions must be implemented by the HAL in order for the serial code to operate. Only the higher-level serial code uses these functions, so they should not be called directly. The HAL should also implement the appropriate interrupt handlers to drain the TX queues and fill the RX FIFO queue.

EmberStatus halInternalUartInit (int8u port, SerialBaudRate rate, SerialParity parity, int8u stopBits)

void halInternalPowerDownUart (void)void halInternalPowerUpUart (void)void halInternalStartUartTx (int8u port)void halInternalStopUartTx (int8u port)

EmberStatus halInternalForceWriteUartData (int8u port, int8u *data, int8u length)EmberStatus halInternalForceReadUartByte (int8u port, int8u *dataByte)

void halInternalWaitUartTxComplete (int8u port)void halInternalRestartUart (void)

boolean halInternalUart1FlowControlRxIsEnabled (void)boolean halInternalUart1XonRefreshDone (void)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__serial.htm (1 of 24) [10/29/2010 2:42:51 PM]

125

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 126: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Serial UART Communication

boolean halInternalUart1TxIsIdle (void)#define halInternalUartFlowControl(port)#define halInternalUartRxPump(port)

Buffered Serial Utility APIs

The higher-level serial code implements these APIs, which the HAL uses to deal with buffered serial output.

void emSerialBufferNextMessageIsr (EmSerialBufferQueue *q)void emSerialBufferNextBlockIsr (EmSerialBufferQueue *q, int8u port)

Virtual UART API

API used by the stack in debug builds to receive data arriving over the virtual UART.

void halStackReceiveVuartMessage (int8u *buff, int8u len)

Serial Mode Definitions

These are numerical definitions for the possible serial modes so that code can test for the one being used. There may be additional modes defined in the micro-specific micro.h.

#define EMBER_SERIAL_UNUSED#define EMBER_SERIAL_FIFO#define EMBER_SERIAL_BUFFER#define EMBER_SERIAL_LOWLEVEL

FIFO Utility Macros

These macros manipulate the FIFO queue data structures to add and remove data.

#define FIFO_ENQUEUE(queue, data, size)#define FIFO_DEQUEUE(queue, size)

Enumerations

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__serial.htm (2 of 24) [10/29/2010 2:42:51 PM]

126

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 127: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Serial UART Communication

enum SerialBaudRate { DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD,

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__serial.htm (3 of 24) [10/29/2010 2:42:51 PM]

127

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 128: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Serial UART Communication

DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD,

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__serial.htm (4 of 24) [10/29/2010 2:42:51 PM]

128

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 129: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Serial UART Communication

DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD,

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__serial.htm (5 of 24) [10/29/2010 2:42:51 PM]

129

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 130: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Serial UART Communication

DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD,

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__serial.htm (6 of 24) [10/29/2010 2:42:51 PM]

130

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 131: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Serial UART Communication

DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD,

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__serial.htm (7 of 24) [10/29/2010 2:42:51 PM]

131

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 132: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Serial UART Communication

DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD,

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__serial.htm (8 of 24) [10/29/2010 2:42:51 PM]

132

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 133: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Serial UART Communication

DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, CUSTOM }

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__serial.htm (9 of 24) [10/29/2010 2:42:51 PM]

133

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 134: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Serial UART Communication

enum NameOfType { NONE, ODD, EVEN }

Define Documentation

#define EMBER_SERIAL_UNUSED

A numerical definition for a possible serial mode the code can test for.

Definition at line 55 of file hal/micro/serial.h.

#define EMBER_SERIAL_FIFO

A numerical definition for a possible serial mode the code can test for.

Definition at line 56 of file hal/micro/serial.h.

#define EMBER_SERIAL_BUFFER

A numerical definition for a possible serial mode the code can test for.

Definition at line 57 of file hal/micro/serial.h.

#define EMBER_SERIAL_LOWLEVEL

A numerical definition for a possible serial mode the code can test for.

Definition at line 58 of file hal/micro/serial.h.

#define FIFO_ENQUEUE ( queue, data, size )

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__serial.htm (10 of 24) [10/29/2010 2:42:51 PM]

134

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 135: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Serial UART Communication

Macro that enqueues a byte of data in a FIFO queue.

Parameters:queue Pointer to the FIFO queue.data Data byte to be enqueued.size Size used to control the wrap-around of the FIFO

pointers.

Definition at line 233 of file hal/micro/serial.h.

#define FIFO_DEQUEUE ( queue, size )

Macro that de-queues a byte of data from a FIFO queue.

Parameters:queue Pointer to the FIFO queue.size Size used to control the wrap-around of the FIFO

pointers.

Definition at line 255 of file hal/micro/serial.h.

#define halInternalUartFlowControl ( port )

This function is used in FIFO mode when flow control is enabled. It is called from emberSerialReadByte(), and based on the number of bytes used in the uart receive queue, decides when to tell the host it may resume transmission.

Parameters:port Serial port number (0 or 1). (Does nothing for port

0)

Definition at line 424 of file hal/micro/serial.h.

#define halInternalUartRxPump ( port )

This function exists only in Buffer Mode on the EM2xx and in software UART (SOFTUART) mode on the EM3xx. This function is called by emberSerialReadByte(). It is responsible for maintaining synchronization between the emSerialRxQueue and the UART DMA.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__serial.htm (11 of 24) [10/29/2010 2:42:51 PM]

135

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 136: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Serial UART Communication

Parameters:port Serial port number (0 or

1).

Definition at line 437 of file hal/micro/serial.h.

Enumeration Type Documentation

enum SerialBaudRate

Assign numerical values for variables that hold Baud Rate parameters.

Enumerator: DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__serial.htm (12 of 24) [10/29/2010 2:42:51 PM]

136

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 137: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Serial UART Communication

DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__serial.htm (13 of 24) [10/29/2010 2:42:51 PM]

137

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 138: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Serial UART Communication

DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__serial.htm (14 of 24) [10/29/2010 2:42:51 PM]

138

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 139: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Serial UART Communication

DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__serial.htm (15 of 24) [10/29/2010 2:42:51 PM]

139

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 140: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Serial UART Communication

DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__serial.htm (16 of 24) [10/29/2010 2:42:51 PM]

140

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 141: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Serial UART Communication

DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__serial.htm (17 of 24) [10/29/2010 2:42:51 PM]

141

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 142: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Serial UART Communication

DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__serial.htm (18 of 24) [10/29/2010 2:42:51 PM]

142

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 143: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Serial UART Communication

DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__serial.htm (19 of 24) [10/29/2010 2:42:51 PM]

143

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 144: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Serial UART Communication

DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD DEFINE_BAUD CUSTOM

Definition at line 269 of file hal/micro/serial.h.

enum NameOfType

Assign numerical values for the types of parity. Use for variables that hold Parity parameters.

Enumerator: NONE ODD EVEN

Definition at line 309 of file hal/micro/serial.h.

Function Documentation

EmberStatus halInternalUartInit ( int8u port, SerialBaudRate rate, SerialParity parity, int8u stopBits

)

Initializes the UART to the given settings (same parameters as emberSerialInit() ).

Parameters:port Serial port number (0 or 1).rate Baud rate (see SerialBaudRate).parity Parity value (see SerialParity).stopBits Number of stop bits.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__serial.htm (20 of 24) [10/29/2010 2:42:51 PM]

144

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 145: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Serial UART Communication

Returns:An error code if initialization failed (such as invalid baud rate), otherise EMBER_SUCCESS.

void halInternalPowerDownUart ( void )

This function is typically called by halPowerDown() and it is responsible for performing all the work internal to the UART needed to stop the UART before a sleep cycle.

void halInternalPowerUpUart ( void )

This function is typically called by halPowerUp() and it is responsible for performing all the work internal to the UART needed to restart the UART after a sleep cycle.

void halInternalStartUartTx ( int8u port )

Called by serial code whenever anything is queued for transmission to start any interrupt-driven transmission. May be called when transmission is already in progess.

Parameters:port Serial port number (0 or

1).

void halInternalStopUartTx ( int8u port )

Called by serial code to stop any interrupt-driven serial transmission currently in progress.

Parameters:port Serial port number (0 or

1).

EmberStatus halInternalForceWriteUartData ( int8u port, int8u * data, int8u length

)

Directly writes a byte to the UART for transmission, regardless of anything currently queued for

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__serial.htm (21 of 24) [10/29/2010 2:42:51 PM]

145

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 146: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Serial UART Communication

transmission. Should wait for anything currently in the UART hardware registers to finish transmission first, and block until data is finished being sent.

Parameters:port Serial port number (0 or 1).data Pointer to the data to be transmitted.length The length of data to be transmitted

EmberStatus halInternalForceReadUartByte ( int8u port, int8u * dataByte

)

Directly reads a byte from the UART for reception, regardless of anything currently queued for reception. Does not block if a data byte has not been received.

Parameters:port Serial port number (0 or 1).dataByte The byte to receive data

into.

void halInternalWaitUartTxComplete ( int8u port )

Blocks until the UART has finished transmitting any data in its hardware registers.

Parameters:port Serial port number (0 or

1).

void halInternalRestartUart ( void )

This function is typically called by halInternalPowerUpBoard() and it is responsible for performing all the work internal to the UART needed to restart the UART after a sleep cycle. (For example, resyncing the DMA hardware and the serial FIFO.).

boolean halInternalUart1FlowControlRxIsEnabled ( void )

Checks to see if the host is allowed to send serial data to the ncp - i.e., it is not being held off by nCTS or an XOFF. Returns TRUE is the host is able to send.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__serial.htm (22 of 24) [10/29/2010 2:42:51 PM]

146

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 147: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Serial UART Communication

boolean halInternalUart1XonRefreshDone ( void )

When Xon/Xoff flow control is used, returns TRUE if the host is not being held off and XON refreshing is complete.

boolean halInternalUart1TxIsIdle ( void )

Returns true if the uart transmitter is idle, including the transmit shift register.

void emSerialBufferNextMessageIsr ( EmSerialBufferQueue * q )

When new serial transmission is started and bufferQueue->nextByte is equal to NULL, this can be called to set up nextByte and lastByte for the next message.

Parameters:q Pointer to the buffer queue structure for the

port.

void emSerialBufferNextBlockIsr ( EmSerialBufferQueue * q, int8u port

)

When a serial transmission is in progress and bufferQueue->nextByte has been sent and incremented leaving it equal to lastByte, this should be called to set up nextByte and lastByte for the next block.

Parameters:q Pointer to the buffer queue structure for the port.port Serial port number (0 or 1).

void halStackReceiveVuartMessage ( int8u * buff, int8u len

)

When using a debug build with virtual UART support, this API is called by the stack when virtual

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__serial.htm (23 of 24) [10/29/2010 2:42:51 PM]

147

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 148: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Serial UART Communication

UART data has been received over the debug channel.

Parameters:buff Pointer to the the data receivedlen Length of the data received

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__serial.htm (24 of 24) [10/29/2010 2:42:51 PM]

148

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 149: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Hardware-Specific UART

Hardware-Specific UART [Serial UART Communication]

Detailed Description

This contains the prototypes and defines for direct hardware manipulation of UART0. Normally, one would go through Serial UART Communication and the HAL. Use these if you want to break the HAL (that is, save code size) and go straight to the hardware.

Some functions in this file return an EmberStatus value. See stack/include/error-def.h for definitions of all EmberStatus return values.

See uart.h for source code.

UART0 Tinies

UART I/O tiny implementations for UART0.

EmberStatus halUart0ReadByteTimeoutTiny (int8u *dataByte)#define halUart0InitTiny()#define halUart0WriteByteTiny(x)

Define Documentation

#define halUart0InitTiny ( )

Simple hardware initialization of UART0.

BIT(USBS0) is set for 2 stop bits. Remove it for only 1 stop bit. The 25 is for a 9600 baud rate on a system running at 4MHz. The other hard-coded BIT(#)s are for generating 8-bit packets.

Definition at line 89 of file uart.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__uart.htm (1 of 2) [10/29/2010 2:42:52 PM]

149

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 150: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Hardware-Specific UART

#define halUart0WriteByteTiny ( x )

Goes straight to hardware, blocks until the UART is ready, and sets the UART transmit register to the passed parameter for transmission.

Parameters:x The byte to send out on the

UART.

Definition at line 119 of file uart.h.

Function Documentation

EmberStatus halUart0ReadByteTimeoutTiny ( int8u * dataByte )

Goes straight to hardware and reads a byte from UART0.

Waits for the receive flag to become true, copies the received byte to the passed pointer's location, and returns with the UART's error code.

Parameters:dataByte Pointer to where the read byte will end up.

Returns:Returns EMBER_SERIAL_RX_EMPTY if the read times out before any activity occurs on the serial line, within about 80 milliseconds. Otherwise the function returns an error code that corresponds to the error bits for UART0 of an Atmel microcontroller.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__uart.htm (2 of 2) [10/29/2010 2:42:52 PM]

150

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 151: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ADC Control

ADC Control [Sample APIs for Peripheral Access]

Detailed Description

Sample A/D converter driver.

See adc.h for source code.

Note:EM35x ADC driver support is preliminary and essentailly untested - please do not attempt to use this ADC driver on this platform.

Except for the EM35x, the EmberZNet stack does use these functions.

To use the ADC system, include this file and ensure that halInternalInitAdc() is called whenever the microcontroller is started. Call halInternalSleepAdc() to sleep the module and halInternalInitAdc() to wake up the module.

A "user" is a separate thread of execution and usage. That is, internal Ember code is one user and clients are a different user. But a client that is calling the ADC in two different functions constitutes only one user, as long as the ADC access is not interleaved.

Note:This code does not allow access to the continuous reading mode of the ADC, which some clients may require.

Many functions in this file return an EmberStatus value. See error-def.h for definitions of all EmberStatus return values.

Defines

#define NUM_ADC_USERS

Typedefs

typedef int8u ADCChannelType

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__adc.htm (1 of 8) [10/29/2010 2:42:53 PM]

151

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 152: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ADC Control

Enumerations

enum ADCUser { ADC_USER_LQI, ADC_USER_APP, ADC_USER_APP2 }

enum ADCReferenceType { ADC_REF_AREF, ADC_REF_AVCC, ADC_REF_INT }

enum ADCRateType { ADC_CONVERSION_TIME_US_32, ADC_CONVERSION_TIME_US_64, ADC_CONVERSION_TIME_US_128, ADC_CONVERSION_TIME_US_256, ADC_CONVERSION_TIME_US_512, ADC_CONVERSION_TIME_US_1024, ADC_CONVERSION_TIME_US_2048, ADC_CONVERSION_TIME_US_4096 }

enum { ADC_SOURCE_ADC0, ADC_SOURCE_ADC1, ADC_SOURCE_ADC2, ADC_SOURCE_ADC3, ADC_SOURCE_ADC4, ADC_SOURCE_ADC5, ADC_SOURCE_ADC6, ADC_SOURCE_ADC7 }

Functions

void halInternalInitAdc (void)void halInternalSleepAdc (void)

EmberStatus halStartAdcConversion (ADCUser id, ADCReferenceType reference, ADCChannelType channel, ADCRateType rate)

EmberStatus halRequestAdcData (ADCUser id, int16u *value)EmberStatus halReadAdcBlocking (ADCUser id, int16u *value)EmberStatus halAdcCalibrate (ADCUser id)

int16s halConvertValueToVolts (int16u value)void emberCalibrateVref (void)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__adc.htm (2 of 8) [10/29/2010 2:42:53 PM]

152

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 153: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ADC Control

Define Documentation

#define NUM_ADC_USERS

Be sure to update NUM_ADC_USERS if additional users are added to the ADCUser list.

Definition at line 69 of file adc.h.

Typedef Documentation

typedef int8u ADCChannelType

A type for the EM250 channel enumeration (such as ADC_SOURCE_ADC0_GND) and the Atmega single-ended ADC channels (such as ADC_SOURCE_ADC0).

Definition at line 235 of file adc.h.

Enumeration Type Documentation

enum ADCUser

ADC functions employ a user ID to keep different users separate.

Avoid many users because each user requires some amount of state storage.

See also:NUM_ADC_USERS

Enumerator: ADC_USER_LQI LQI User ID. ADC_USER_APP Application User

ID

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__adc.htm (3 of 8) [10/29/2010 2:42:53 PM]

153

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 154: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ADC Control

ADC_USER_APP2 Application User ID

Definition at line 51 of file adc.h.

enum ADCReferenceType

ADC reference voltages for the AVR Atmega microcontrollers.

Enumerator: ADC_REF_AREF AREF pin

reference. ADC_REF_AVCC AVCC pin

reference. ADC_REF_INT Internal reference.

Definition at line 75 of file adc.h.

enum ADCRateType

ADC EM250 rates.

Enumerator: ADC_CONVERSION_TIME_US_32 Rate 32 us, 5 effective bits in ADC_DATA[15:11] ADC_CONVERSION_TIME_US_64 Rate 64 us, 6 effective bits in ADC_DATA[15:10] ADC_CONVERSION_TIME_US_128 Rate 128 us, 7 effective bits in ADC_DATA[15:9] ADC_CONVERSION_TIME_US_256 Rate 256 us, 8 effective bits in ADC_DATA[15:8] ADC_CONVERSION_TIME_US_512 Rate 512 us, 9 effective bits in ADC_DATA[15:7] ADC_CONVERSION_TIME_US_1024 Rate 1024 us, 10 effective bits in ADC_DATA

[15:6] ADC_CONVERSION_TIME_US_2048 Rate 2048 us, 11 effective bits in ADC_DATA

[15:5] ADC_CONVERSION_TIME_US_4096 Rate 4096 us, 12 effective bits in ADC_DATA

[15:4]

Definition at line 94 of file adc.h.

anonymous enum

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__adc.htm (4 of 8) [10/29/2010 2:42:53 PM]

154

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 155: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ADC Control

Atmega single-ended ADC channel values for ADCChannelType.

Enumerator: ADC_SOURCE_ADC0 Channel 0 :

ADC0 ADC_SOURCE_ADC1 Channel 1 :

ADC1 ADC_SOURCE_ADC2 Channel 2 :

ADC2 ADC_SOURCE_ADC3 Channel 3 :

ADC3 ADC_SOURCE_ADC4 Channel 4 :

ADC4 ADC_SOURCE_ADC5 Channel 5 :

ADC5 ADC_SOURCE_ADC6 Channel 5 :

ADC6 ADC_SOURCE_ADC7 Channel 7 :

ADC7

Definition at line 211 of file adc.h.

Function Documentation

void halInternalInitAdc ( void )

Initializes and powers-up the ADC. Should also be called to wake from sleep. The ADC is required for EM250 stack operation so this function must be called from halInit.

void halInternalSleepAdc ( void )

Shuts down the voltage reference and ADC system to minimize power consumption in sleep.

EmberStatus halStartAdcConversion ( ADCUser id, ADCReferenceType reference, ADCChannelType channel, ADCRateType rate

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__adc.htm (5 of 8) [10/29/2010 2:42:53 PM]

155

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 156: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ADC Control

)

Starts an ADC conversion for the user specified by id.

Application Usage:The application must set reference to the voltage reference desired (see the ADC references enum, fixed at ADC_REF_INT for the em250), set channel to the channel number required (see the ADC channel enum), and set rate to reflect the number of bits of accuracy desired (see the ADC rates enum, fixed at ADC_CONVERSION_TIME_US_256 for the Atmega).

Parameters:id An ADC user.reference Voltage reference to use, chosen from enum ADCReferenceType (fixed at

ADC_REF_INT for the EM250).channel Microprocessor channel number. For EM250 channels, see the EM250 ADC

channels enum. For basic, single-ended Atmel channels, see the Atmega single-ended ADC channels enum. For more complex measurements on Atmels (differential and amped channel numbers), see the Atmel datasheet for your micro.

rate EM250 rate number (see the ADC EM250 rate enum). Fixed at ADC_CONVERSION_TIME_US_256 for AVR Atmega.

Returns:One of the following:

�❍ EMBER_ADC_CONVERSION_DEFERRED if the conversion is still waiting to start.�❍ EMBER_ADC_CONVERSION_BUSY if the conversion is currently taking place.�❍ EMBER_ERR_FATAL if a passed parameter is invalid.

EmberStatus halRequestAdcData ( ADCUser id, int16u * value

)

Returns the status of a pending conversion previously started by halStartAdcConversion(). If the conversion is complete, writes the raw register value of the conversion (the unaltered value taken directly from the ADC's data register) into value.

Parameters:id An ADC user.value Pointer to an int16u to be loaded with the new value. Take note that the Atmel's

ADC only generates 8-bit values which are loaded into the lower 8 bits of value.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__adc.htm (6 of 8) [10/29/2010 2:42:53 PM]

156

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 157: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ADC Control

Returns:One of the following:

�❍ EMBER_ADC_CONVERSION_DONE if the conversion is complete.�❍ EMBER_ADC_CONVERSION_DEFERRED if the conversion is still waiting to

start.�❍ EMBER_ADC_CONVERSION_BUSY if the conversion is currently taking place.�❍ EMBER_ADC_NO_CONVERSION_PENDING if id does not have a pending

conversion.

EmberStatus halReadAdcBlocking ( ADCUser id, int16u * value

)

Waits for the user's request to complete and then, if a conversion was done, writes the raw register value of the conversion (the unaltered value taken directly from the ADC's data register) into value and returns EMBER_ADC_CONVERSION_DONE, or immediately returns EMBER_ADC_NO_CONVERSION_PENDING.

Parameters:id An ADC user.value Pointer to an int16u to be loaded with the new value. Take note that the Atmel's

ADC only generates 8-bit values which are loaded into the lower 8 bits of value.

Returns:One of the following:

�❍ EMBER_ADC_CONVERSION_DONE if the conversion is complete.�❍ EMBER_ADC_NO_CONVERSION_PENDING if id does not have a pending

conversion.

EmberStatus halAdcCalibrate ( ADCUser id )

Calibrates or recalibrates the ADC system.

Application Usage:Use this function to (re)calibrate as needed. This function is intended for the EM250 microcontroller, which requires proper calibration to calculate a human readible value (a value in volts). If the app does not call this function, the first time (and only the first time) the function halConvertValueToVolts() is called, this function is invoked. To maintain accurate volt calculations, the application should call this whenever it expects the temperature of the micro to change.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__adc.htm (7 of 8) [10/29/2010 2:42:53 PM]

157

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 158: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ADC Control

Parameters:id An ADC user.

Returns:One of the following:

�❍ EMBER_ADC_CONVERSION_DONE if the calibration is complete.�❍ EMBER_ERR_FATAL if the calibration failed.

int16s halConvertValueToVolts ( int16u value )

Convert the raw register value (the unaltered value taken directly from the ADC's data register) into a signed fixed point value with units 10^-4 Volts. The returned value will be in the range -12000 to +12000 (-1.2000 volts to +1.2000 volts).

Application Usage:Use this function to get a human useful value.

Parameters:value An int16u to be converted.

Returns:Volts as signed fixed point with units 10^-4 Volts.

void emberCalibrateVref ( void )

Calibrates Vref to be 1.2V +/-10mV.

Application Usage:This function must be called from halInternalInitAdc() before making ADC readings. This function is not intended to be called from any function other than halInternalInitAdc(). This function ensures that the master cell voltage and current bias values are calibrated before calibrating Vref.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__adc.htm (8 of 8) [10/29/2010 2:42:53 PM]

158

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 159: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Button Control

Button Control [Sample APIs for Peripheral Access]

Detailed Description

Sample API functions for using push-buttons.

See button.h for source code.

Button State Definitions

A set of numerical definitions for use with the button APIs indicating the state of a button.

#define BUTTON_PRESSED#define BUTTON_RELEASED

Functions

void halInternalInitButton (void)int8u halButtonState (int8u button)int8u halButtonPinState (int8u button)

void halButtonIsr (int8u button, int8u state)

Define Documentation

#define BUTTON_PRESSED

Button state is pressed.

Definition at line 24 of file button.h.

#define BUTTON_RELEASED

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__button.htm (1 of 3) [10/29/2010 2:42:54 PM]

159

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 160: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Button Control

Button state is released.

Definition at line 28 of file button.h.

Function Documentation

void halInternalInitButton ( void )

Initializes the buttons. This function is automatically called by halInit().

int8u halButtonState ( int8u button )

Returns the current state (pressed or released) of a button.

Note:This function is correlated with halButtonIsr() and so returns the shadow state rather than reading the actual state of the pin.

Parameters:button The button being queried, either BUTTON0 or BUTTON1 as defined in the

appropriate BOARD_HEADER.

Returns:BUTTON_PRESSED if the button is pressed or BUTTON_RELEASED if the button is not pressed.

int8u halButtonPinState ( int8u button )

Returns the current state (pressed or released) of the pin associated with a button.

This reads the actual state of the pin and can be used on startup to determine the initial position of the buttons.

Parameters:button The button being queried, either BUTTON0 or BUTTON1 as defined in the

appropriate BOARD_HEADER.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__button.htm (2 of 3) [10/29/2010 2:42:54 PM]

160

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 161: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Button Control

Returns:BUTTON_PRESSED if the button is pressed or BUTTON_RELEASED if the button is not pressed.

void halButtonIsr ( int8u button, int8u state

)

A callback called in interrupt context whenever a button changes its state.

Application Usage:Must be implemented by the application. This function should contain the functionality to be executed in response to changes of state in each of the buttons, or callbacks to the appropriate functionality.

Parameters:button The button which has changed state, either BUTTON0 or BUTTON1 as defined in

the appropriate BOARD_HEADER.state The new state of the button referenced by the button parameter, either

BUTTON_PRESSED if the button has been pressed or BUTTON_RELEASED if the button has been released.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__button.htm (3 of 3) [10/29/2010 2:42:54 PM]

161

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 162: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Buzzer Control

Buzzer Control [Sample APIs for Peripheral Access]

Detailed Description

Sample API functions for playing tunes on a piezo buzzer.

See buzzer.h for source code.

Note Definitions

Flats are used instead of sharps because # is a special character.

#define NOTE_C3#define NOTE_Db3#define NOTE_D3#define NOTE_Eb3#define NOTE_E3#define NOTE_F3#define NOTE_Gb3#define NOTE_G3#define NOTE_Ab3#define NOTE_A3#define NOTE_Bb3#define NOTE_B3#define NOTE_C4#define NOTE_Db4#define NOTE_D4#define NOTE_Eb4#define NOTE_E4#define NOTE_F4#define NOTE_Gb4#define NOTE_G4#define NOTE_Ab4#define NOTE_A4#define NOTE_Bb4#define NOTE_B4

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__buzzer.htm (1 of 9) [10/29/2010 2:42:55 PM]

162

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 163: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Buzzer Control

#define NOTE_C5#define NOTE_Db5#define NOTE_D5#define NOTE_Eb5#define NOTE_E5#define NOTE_F5#define NOTE_Gb5#define NOTE_G5#define NOTE_Ab5#define NOTE_A5#define NOTE_Bb5#define NOTE_B5

Functions

void halPlayTune_P (int8u PGM *tune, boolean bkg)void halStackIndicatePresence (void)

Define Documentation

#define NOTE_C3

A note which can be used in tune structure definitions.

Definition at line 23 of file buzzer.h.

#define NOTE_Db3

A note which can be used in tune structure definitions.

Definition at line 24 of file buzzer.h.

#define NOTE_D3

A note which can be used in tune structure definitions.

Definition at line 25 of file buzzer.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__buzzer.htm (2 of 9) [10/29/2010 2:42:55 PM]

163

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 164: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Buzzer Control

#define NOTE_Eb3

A note which can be used in tune structure definitions.

Definition at line 26 of file buzzer.h.

#define NOTE_E3

A note which can be used in tune structure definitions.

Definition at line 27 of file buzzer.h.

#define NOTE_F3

A note which can be used in tune structure definitions.

Definition at line 28 of file buzzer.h.

#define NOTE_Gb3

A note which can be used in tune structure definitions.

Definition at line 29 of file buzzer.h.

#define NOTE_G3

A note which can be used in tune structure definitions.

Definition at line 30 of file buzzer.h.

#define NOTE_Ab3

A note which can be used in tune structure definitions.

Definition at line 31 of file buzzer.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__buzzer.htm (3 of 9) [10/29/2010 2:42:55 PM]

164

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 165: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Buzzer Control

#define NOTE_A3

A note which can be used in tune structure definitions.

Definition at line 32 of file buzzer.h.

#define NOTE_Bb3

A note which can be used in tune structure definitions.

Definition at line 33 of file buzzer.h.

#define NOTE_B3

A note which can be used in tune structure definitions.

Definition at line 34 of file buzzer.h.

#define NOTE_C4

A note which can be used in tune structure definitions.

Definition at line 35 of file buzzer.h.

#define NOTE_Db4

A note which can be used in tune structure definitions.

Definition at line 36 of file buzzer.h.

#define NOTE_D4

A note which can be used in tune structure definitions.

Definition at line 37 of file buzzer.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__buzzer.htm (4 of 9) [10/29/2010 2:42:55 PM]

165

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 166: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Buzzer Control

#define NOTE_Eb4

A note which can be used in tune structure definitions.

Definition at line 38 of file buzzer.h.

#define NOTE_E4

A note which can be used in tune structure definitions.

Definition at line 39 of file buzzer.h.

#define NOTE_F4

A note which can be used in tune structure definitions.

Definition at line 40 of file buzzer.h.

#define NOTE_Gb4

A note which can be used in tune structure definitions.

Definition at line 41 of file buzzer.h.

#define NOTE_G4

A note which can be used in tune structure definitions.

Definition at line 42 of file buzzer.h.

#define NOTE_Ab4

A note which can be used in tune structure definitions.

Definition at line 43 of file buzzer.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__buzzer.htm (5 of 9) [10/29/2010 2:42:55 PM]

166

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 167: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Buzzer Control

#define NOTE_A4

A note which can be used in tune structure definitions.

Definition at line 44 of file buzzer.h.

#define NOTE_Bb4

A note which can be used in tune structure definitions.

Definition at line 45 of file buzzer.h.

#define NOTE_B4

A note which can be used in tune structure definitions.

Definition at line 46 of file buzzer.h.

#define NOTE_C5

A note which can be used in tune structure definitions.

Definition at line 47 of file buzzer.h.

#define NOTE_Db5

A note which can be used in tune structure definitions.

Definition at line 48 of file buzzer.h.

#define NOTE_D5

A note which can be used in tune structure definitions.

Definition at line 49 of file buzzer.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__buzzer.htm (6 of 9) [10/29/2010 2:42:55 PM]

167

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 168: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Buzzer Control

#define NOTE_Eb5

A note which can be used in tune structure definitions.

Definition at line 50 of file buzzer.h.

#define NOTE_E5

A note which can be used in tune structure definitions.

Definition at line 51 of file buzzer.h.

#define NOTE_F5

A note which can be used in tune structure definitions.

Definition at line 52 of file buzzer.h.

#define NOTE_Gb5

A note which can be used in tune structure definitions.

Definition at line 53 of file buzzer.h.

#define NOTE_G5

A note which can be used in tune structure definitions.

Definition at line 54 of file buzzer.h.

#define NOTE_Ab5

A note which can be used in tune structure definitions.

Definition at line 55 of file buzzer.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__buzzer.htm (7 of 9) [10/29/2010 2:42:55 PM]

168

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 169: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Buzzer Control

#define NOTE_A5

A note which can be used in tune structure definitions.

Definition at line 56 of file buzzer.h.

#define NOTE_Bb5

A note which can be used in tune structure definitions.

Definition at line 57 of file buzzer.h.

#define NOTE_B5

A note which can be used in tune structure definitions.

Definition at line 58 of file buzzer.h.

Function Documentation

void halPlayTune_P ( int8u PGM * tune, boolean bkg

)

Plays a tune on the piezo buzzer.

The tune is played in the background if bkg is TRUE. Otherwise, the API blocks until the playback of the tune is complete.

Parameters:tune A pointer to tune to play.bkg Determines whether the tune plays in the background. If TRUE, tune plays in

background; if FALSE, tune plays in foreground.

A tune is implemented as follows:

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__buzzer.htm (8 of 9) [10/29/2010 2:42:55 PM]

169

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 170: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Buzzer Control

int8u PGM hereIamTune[] = { //All tunes are stored in flash. NOTE_B4, 1, //Plays the note B4 for 100 milliseconds. 0, 1, //Pause for 100 milliseconds. NOTE_B5, 5, //Plays the note B5 for 500 milliseconds. 0, 0 //NULL terminates the tune. };

void halStackIndicatePresence ( void )

Causes something to happen on a node (such as playing a tune on the buzzer) that can be used to indicate where it physically is.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__buzzer.htm (9 of 9) [10/29/2010 2:42:55 PM]

170

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 171: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: LED Control

LED Control [Sample APIs for Peripheral Access]

Detailed Description

Sample API funtions for controlling LEDs.

When specifying an LED to use, always use the BOARDLEDx definitions that are defined within the BOARD_HEADER.

See led.h for source code.

Typedefs

typedef enum HalBoardLedPins HalBoardLed

Functions

void halInternalInitLed (void)void halToggleLed (HalBoardLed led)void halSetLed (HalBoardLed led)void halClearLed (HalBoardLed led)void halStackIndicateActivity (boolean turnOn)

Typedef Documentation

typedef enum HalBoardLedPins HalBoardLed

Ensures that the definitions from the BOARD_HEADER are always used as parameters to the LED functions.

Definition at line 30 of file led.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__led.htm (1 of 3) [10/29/2010 2:42:55 PM]

171

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 172: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: LED Control

Function Documentation

void halInternalInitLed ( void )

Configures GPIOs pertaining to the control of LEDs.

void halToggleLed ( HalBoardLed led )

Atomically wraps an XOR or similar operation for a single GPIO pin attached to an LED.

Parameters:led Identifier (from BOARD_HEADER) for the LED to be

toggled.

void halSetLed ( HalBoardLed led )

Turns on (sets) a GPIO pin connected to an LED so that the LED turns on.

Parameters:led Identifier (from BOARD_HEADER) for the LED to turn

on.

void halClearLed ( HalBoardLed led )

Turns off (clears) a GPIO pin connected to an LED, which turns off the LED.

Parameters:led Identifier (from BOARD_HEADER) for the LED to turn

off.

void halStackIndicateActivity ( boolean turnOn )

Called by the stack to indicate activity over the radio (for both transmission and reception). It is called once with turnOn TRUE and shortly thereafter with turnOn FALSE.

Typically does something interesting, such as change the state of an LED.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__led.htm (2 of 3) [10/29/2010 2:42:55 PM]

172

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 173: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: LED Control

Parameters:turnOn See

Usage.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__led.htm (3 of 3) [10/29/2010 2:42:55 PM]

173

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 174: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Carrier Board Control

Carrier Board Control [Sample APIs for Peripheral Access]

Detailed Description

See host.h for source code.

See also dev0470.h for the code.

See also dev0473.h for the code.

LED Definitions

The following are used to aid in the abstraction with the LED connections. The names and ports/pins used below are intended to match with a schematic of the system to provide the abstraction.

The BOARDLEDn macros should always be used when manipulating the state of LEDs.

BOARDLED_MASK should be set to a mask with a bit set for each pin to an LED is connected

enum HalBoardLedPins { BOARDLED0, BOARDLED1, BOARDLED2, BOARDLED3, BOARDLED4, BOARDLED5, BOARD_ACTIVITY_LED, BOARD_HEARTBEAT_LED, BOARDLED0, BOARDLED1, BOARD_ACTIVITY_LED, BOARD_HEARTBEAT_LED, BOARDLED0, BOARDLED1, BOARD_ACTIVITY_LED, BOARD_HEARTBEAT_LED }

#define BOARDLED_MASK

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__board.htm (1 of 23) [10/29/2010 2:42:58 PM]

174

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 175: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Carrier Board Control

#define LED_DDR#define LED_PORT

LED Definitions

The following are used to aid in the abstraction with the LED connections. The microcontroller-specific sources use these definitions so they are able to work across a variety of boards which could have different connections. The names and ports/pins used below are intended to match with a schematic of the system to provide the abstraction.

The BOARDLEDn enum values should always be used when manipulating the state of LEDs, as they directly refer to the pins to which the LEDs are connected

BOARDLED_MASK should be set to a mask with a bit set for each pin to an LED is connected

enum HalBoardLedPins { BOARDLED0, BOARDLED1, BOARDLED2, BOARDLED3, BOARDLED4, BOARDLED5, BOARD_ACTIVITY_LED, BOARD_HEARTBEAT_LED, BOARDLED0, BOARDLED1, BOARD_ACTIVITY_LED, BOARD_HEARTBEAT_LED, BOARDLED0, BOARDLED1, BOARD_ACTIVITY_LED, BOARD_HEARTBEAT_LED }

#define BOARDLED_MASK#define LED_DDR#define LED_PORT

SPI Protocol Parameters

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__board.htm (2 of 23) [10/29/2010 2:42:58 PM]

175

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 176: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Carrier Board Control

The following are used to aid in the abstraction with the SPI Protocl. The HAL uses these definitions so it is able to work across a variety of speeds as well as allow the developer to tweak parameters as desired.

The values used here are based upon an ATmega32L Host operating at 3.6864MHz which generates a 17.361us tick.

#define TCCR1B_CONFIGURATION#define WAIT_SECTION_TIMEOUT#define INTER_COMMAND_SPACING#define WAKE_HANDSHAKE_TIMEOUT#define STARTUP_TIMEOUT_SINGLE#define STARTUP_TIMEOUT_COUNT

SPI Protocol Connection Items

The following are used to aid in the abstraction with the SPI Protocol. The HAL uses these definitions so it is able to work across a variety of boards which could have different connections. The names and ports/pins used below are intended to match with a schematic of the system to provide the abstraction.

#define SPIP_nSSEL_PORT#define SPIP_nSSEL_DDR#define SPIP_nSSEL#define SPIP_MOSI_PORT#define SPIP_MOSI_DDR#define SPIP_MOSI#define SPIP_MISO_PORT#define SPIP_MISO_DDR#define SPIP_MISO#define SPIP_SCLK_PORT#define SPIP_SCLK_DDR#define SPIP_SCLK#define SPIP_nHOST_INT_PORT#define SPIP_nHOST_INT_DDR#define SPIP_nHOST_INT_PIN#define SPIP_nHOST_INT#define SPIP_nWAKE_PORT#define SPIP_nWAKE_DDR#define SPIP_nWAKE#define SPIP_nRESET_PORT#define SPIP_nRESET_DDR#define SPIP_nRESET

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__board.htm (3 of 23) [10/29/2010 2:42:58 PM]

176

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 177: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Carrier Board Control

Button Definitions

The following are used to aid in the abstraction with the Button connections. The names and ports/pins used below are intended to match with a schematic of the system to provide the abstraction.

The BUTTONn macros should always be used with manipulating the buttons as they directly refer to the pins to which the buttons are connected.

#define BUTTON0#define BUTTON0_PORT#define BUTTON0_DDR#define BUTTON0_PIN#define BUTTON0_INT#define BUTTON0_INT_VECT#define BUTTON0_CONFIG_FALLING_EDGE()#define BUTTON0_CONFIG_RISING_EDGE()#define BUTTON1#define BUTTON1_PORT#define BUTTON1_DDR#define BUTTON1_PIN#define BUTTON1_INT#define BUTTON1_INT_VECT#define BUTTON1_CONFIG_FALLING_EDGE()#define BUTTON1_CONFIG_RISING_EDGE()

Temperature sensor ADC channel

Define the analog input channel connected to the LM-20 temperature sensor. The scale factor compensates for different platform input ranges. PA0/ADC0 must be an input. PA1 must be an output and set to a high level to power the sensor.

#define TEMP_SENSOR_ADC_CHANNEL#define TEMP_SENSOR_SCALE_FACTOR

Board Specific Functions

The following macros exist to aid in the initialization, power up from sleep, and power down to sleep operations. These macros are responsible for either initializing directly, or calling initialization functions for any peripherals that are specific to this board implementation. These macros are called from halInit, halPowerDown, and halPowerUp respectively.

#define halInternalInitBoard()#define halInternalPowerDownBoard()

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__board.htm (4 of 23) [10/29/2010 2:42:58 PM]

177

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 178: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Carrier Board Control

#define halInternalPowerUpBoard()

SPI Protocol Parameters

The following are used to aid in the abstraction with the SPI Protocl. The HAL uses these definitions so it is able to work across a variety of speeds as well as allow the developer to tweak parameters as desired.

The values used here are based upon an ATmega128L Host operating at 8MHz which generates a 32us tick.

#define TCCR1B_CONFIGURATION#define WAIT_SECTION_TIMEOUT#define INTER_COMMAND_SPACING#define WAKE_HANDSHAKE_TIMEOUT#define STARTUP_TIMEOUT_SINGLE#define STARTUP_TIMEOUT_COUNT

SPI Protocol Connection Items

The following are used to aid in the abstraction with the SPI Protocol. The HAL uses these definitions so it is able to work across a variety of boards which could have different connections. The names and ports/pins used below are intended to match with a schematic of the system to provide the abstraction.

#define SPIP_nSSEL_PORT#define SPIP_nSSEL_DDR#define SPIP_nSSEL#define SPIP_MOSI_PORT#define SPIP_MOSI_DDR#define SPIP_MOSI#define SPIP_MISO_PORT#define SPIP_MISO_DDR#define SPIP_MISO#define SPIP_SCLK_PORT#define SPIP_SCLK_DDR#define SPIP_SCLK#define SPIP_nHOST_INT_PORT#define SPIP_nHOST_INT_DDR#define SPIP_nHOST_INT_PIN#define SPIP_nHOST_INT#define SPIP_nWAKE_PORT#define SPIP_nWAKE_DDR#define SPIP_nWAKE

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__board.htm (5 of 23) [10/29/2010 2:42:58 PM]

178

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 179: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Carrier Board Control

#define SPIP_nRESET_PORT#define SPIP_nRESET_DDR#define SPIP_nRESET

Button Definitions

The following are used to aid in the abstraction with the Button connections. The names and ports/pins used below are intended to match with a schematic of the system to provide the abstraction.

The BUTTONn macros should always be used with manipulating the buttons as they directly refer to the pins to which the buttons are connected.

#define BUTTON0#define BUTTON0_PORT#define BUTTON0_DDR#define BUTTON0_PIN#define BUTTON0_INT#define BUTTON0_INT_VECT#define BUTTON0_CONFIG_FALLING_EDGE()#define BUTTON0_CONFIG_RISING_EDGE()#define BUTTON1#define BUTTON1_PORT#define BUTTON1_DDR#define BUTTON1_PIN#define BUTTON1_INT#define BUTTON1_INT_VECT#define BUTTON1_CONFIG_FALLING_EDGE()#define BUTTON1_CONFIG_RISING_EDGE()

Temperature sensor ADC channel

Define the analog input channel connected to the LM-20 temperature sensor. The scale factor compensates for different platform input ranges. PF1/ADC1 must be an input. PC7 must be an output and set to a high level to power the sensor.

#define TEMP_SENSOR_ADC_CHANNEL#define TEMP_SENSOR_SCALE_FACTOR

Board Specific Functions

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__board.htm (6 of 23) [10/29/2010 2:42:58 PM]

179

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 180: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Carrier Board Control

The following macros exist to aid in the initialization, power up from sleep, and power down to sleep operations. These macros are responsible for either initializing directly, or calling initialization functions for any peripherals that are specific to this board implementation. These macros are called from halInit, halPowerDown, and halPowerUp respectively.

#define halInternalInitBoard()#define halInternalPowerDownBoard()#define halInternalPowerUpBoard()

Defines

#define halInternalInitBoard()#define halInternalPowerDownBoard()#define halInternalPowerUpBoard()#define BUTTON0#define BUTTON1#define TEMP_SENSOR_ADC_CHANNEL#define TEMP_SENSOR_SCALE_FACTOR

Enumerations

enum HalBoardLedPins { BOARDLED0, BOARDLED1, BOARDLED2, BOARDLED3, BOARDLED4, BOARDLED5, BOARD_ACTIVITY_LED, BOARD_HEARTBEAT_LED, BOARDLED0, BOARDLED1, BOARD_ACTIVITY_LED, BOARD_HEARTBEAT_LED, BOARDLED0, BOARDLED1, BOARD_ACTIVITY_LED, BOARD_HEARTBEAT_LED }

Define Documentation

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__board.htm (7 of 23) [10/29/2010 2:42:58 PM]

180

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 181: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Carrier Board Control

#define halInternalInitBoard ( )

Definition at line 16 of file host.h.

#define halInternalPowerDownBoard ( )

Definition at line 21 of file host.h.

#define halInternalPowerUpBoard ( )

Definition at line 26 of file host.h.

#define BUTTON0

Definition at line 41 of file host.h.

#define BUTTON1

Definition at line 42 of file host.h.

#define TEMP_SENSOR_ADC_CHANNEL

Definition at line 43 of file host.h.

#define TEMP_SENSOR_SCALE_FACTOR

Definition at line 44 of file host.h.

#define TCCR1B_CONFIGURATION

Definition at line 38 of file dev0470.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__board.htm (8 of 23) [10/29/2010 2:42:58 PM]

181

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 182: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Carrier Board Control

#define WAIT_SECTION_TIMEOUT

Definition at line 39 of file dev0470.h.

#define INTER_COMMAND_SPACING

Definition at line 40 of file dev0470.h.

#define WAKE_HANDSHAKE_TIMEOUT

Definition at line 41 of file dev0470.h.

#define STARTUP_TIMEOUT_SINGLE

Definition at line 42 of file dev0470.h.

#define STARTUP_TIMEOUT_COUNT

Definition at line 45 of file dev0470.h.

#define SPIP_nSSEL_PORT

Definition at line 59 of file dev0470.h.

#define SPIP_nSSEL_DDR

Definition at line 60 of file dev0470.h.

#define SPIP_nSSEL

Definition at line 61 of file dev0470.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__board.htm (9 of 23) [10/29/2010 2:42:58 PM]

182

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 183: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Carrier Board Control

#define SPIP_MOSI_PORT

Definition at line 62 of file dev0470.h.

#define SPIP_MOSI_DDR

Definition at line 63 of file dev0470.h.

#define SPIP_MOSI

Definition at line 64 of file dev0470.h.

#define SPIP_MISO_PORT

Definition at line 65 of file dev0470.h.

#define SPIP_MISO_DDR

Definition at line 66 of file dev0470.h.

#define SPIP_MISO

Definition at line 67 of file dev0470.h.

#define SPIP_SCLK_PORT

Definition at line 68 of file dev0470.h.

#define SPIP_SCLK_DDR

Definition at line 69 of file dev0470.h.

#define SPIP_SCLK

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__board.htm (10 of 23) [10/29/2010 2:42:58 PM]

183

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 184: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Carrier Board Control

Definition at line 70 of file dev0470.h.

#define SPIP_nHOST_INT_PORT

Definition at line 71 of file dev0470.h.

#define SPIP_nHOST_INT_DDR

Definition at line 72 of file dev0470.h.

#define SPIP_nHOST_INT_PIN

Definition at line 73 of file dev0470.h.

#define SPIP_nHOST_INT

Definition at line 74 of file dev0470.h.

#define SPIP_nWAKE_PORT

Definition at line 75 of file dev0470.h.

#define SPIP_nWAKE_DDR

Definition at line 76 of file dev0470.h.

#define SPIP_nWAKE

Definition at line 77 of file dev0470.h.

#define SPIP_nRESET_PORT

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__board.htm (11 of 23) [10/29/2010 2:42:58 PM]

184

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 185: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Carrier Board Control

Definition at line 78 of file dev0470.h.

#define SPIP_nRESET_DDR

Definition at line 79 of file dev0470.h.

#define SPIP_nRESET

Definition at line 80 of file dev0470.h.

#define BOARDLED_MASK

Definition at line 103 of file dev0470.h.

#define LED_DDR

Definition at line 105 of file dev0470.h.

#define LED_PORT

Definition at line 106 of file dev0470.h.

#define BUTTON0

Definition at line 123 of file dev0470.h.

#define BUTTON0_PORT

Definition at line 124 of file dev0470.h.

#define BUTTON0_DDR

Definition at line 125 of file dev0470.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__board.htm (12 of 23) [10/29/2010 2:42:58 PM]

185

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 186: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Carrier Board Control

#define BUTTON0_PIN

Definition at line 126 of file dev0470.h.

#define BUTTON0_INT

Definition at line 127 of file dev0470.h.

#define BUTTON0_INT_VECT

Definition at line 128 of file dev0470.h.

#define BUTTON0_CONFIG_FALLING_EDGE ( )

Definition at line 129 of file dev0470.h.

#define BUTTON0_CONFIG_RISING_EDGE ( )

Definition at line 134 of file dev0470.h.

#define BUTTON1

Definition at line 140 of file dev0470.h.

#define BUTTON1_PORT

Definition at line 141 of file dev0470.h.

#define BUTTON1_DDR

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__board.htm (13 of 23) [10/29/2010 2:42:58 PM]

186

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 187: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Carrier Board Control

Definition at line 142 of file dev0470.h.

#define BUTTON1_PIN

Definition at line 143 of file dev0470.h.

#define BUTTON1_INT

Definition at line 144 of file dev0470.h.

#define BUTTON1_INT_VECT

Definition at line 145 of file dev0470.h.

#define BUTTON1_CONFIG_FALLING_EDGE ( )

Definition at line 146 of file dev0470.h.

#define BUTTON1_CONFIG_RISING_EDGE ( )

Definition at line 150 of file dev0470.h.

#define TEMP_SENSOR_ADC_CHANNEL

Definition at line 166 of file dev0470.h.

#define TEMP_SENSOR_SCALE_FACTOR

Definition at line 167 of file dev0470.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__board.htm (14 of 23) [10/29/2010 2:42:58 PM]

187

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 188: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Carrier Board Control

#define halInternalInitBoard ( )

Definition at line 180 of file dev0470.h.

#define halInternalPowerDownBoard ( )

Definition at line 216 of file dev0470.h.

#define halInternalPowerUpBoard ( )

Definition at line 237 of file dev0470.h.

#define TCCR1B_CONFIGURATION

Definition at line 39 of file dev0473.h.

#define WAIT_SECTION_TIMEOUT

Definition at line 40 of file dev0473.h.

#define INTER_COMMAND_SPACING

Definition at line 41 of file dev0473.h.

#define WAKE_HANDSHAKE_TIMEOUT

Definition at line 42 of file dev0473.h.

#define STARTUP_TIMEOUT_SINGLE

Definition at line 43 of file dev0473.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__board.htm (15 of 23) [10/29/2010 2:42:58 PM]

188

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 189: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Carrier Board Control

#define STARTUP_TIMEOUT_COUNT

Definition at line 46 of file dev0473.h.

#define SPIP_nSSEL_PORT

Definition at line 60 of file dev0473.h.

#define SPIP_nSSEL_DDR

Definition at line 61 of file dev0473.h.

#define SPIP_nSSEL

Definition at line 62 of file dev0473.h.

#define SPIP_MOSI_PORT

Definition at line 63 of file dev0473.h.

#define SPIP_MOSI_DDR

Definition at line 64 of file dev0473.h.

#define SPIP_MOSI

Definition at line 65 of file dev0473.h.

#define SPIP_MISO_PORT

Definition at line 66 of file dev0473.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__board.htm (16 of 23) [10/29/2010 2:42:58 PM]

189

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 190: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Carrier Board Control

#define SPIP_MISO_DDR

Definition at line 67 of file dev0473.h.

#define SPIP_MISO

Definition at line 68 of file dev0473.h.

#define SPIP_SCLK_PORT

Definition at line 69 of file dev0473.h.

#define SPIP_SCLK_DDR

Definition at line 70 of file dev0473.h.

#define SPIP_SCLK

Definition at line 71 of file dev0473.h.

#define SPIP_nHOST_INT_PORT

Definition at line 72 of file dev0473.h.

#define SPIP_nHOST_INT_DDR

Definition at line 73 of file dev0473.h.

#define SPIP_nHOST_INT_PIN

Definition at line 74 of file dev0473.h.

#define SPIP_nHOST_INT

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__board.htm (17 of 23) [10/29/2010 2:42:58 PM]

190

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 191: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Carrier Board Control

Definition at line 75 of file dev0473.h.

#define SPIP_nWAKE_PORT

Definition at line 76 of file dev0473.h.

#define SPIP_nWAKE_DDR

Definition at line 77 of file dev0473.h.

#define SPIP_nWAKE

Definition at line 78 of file dev0473.h.

#define SPIP_nRESET_PORT

Definition at line 79 of file dev0473.h.

#define SPIP_nRESET_DDR

Definition at line 80 of file dev0473.h.

#define SPIP_nRESET

Definition at line 81 of file dev0473.h.

#define BOARDLED_MASK

Definition at line 108 of file dev0473.h.

#define LED_DDR

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__board.htm (18 of 23) [10/29/2010 2:42:58 PM]

191

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 192: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Carrier Board Control

Definition at line 110 of file dev0473.h.

#define LED_PORT

Definition at line 111 of file dev0473.h.

#define BUTTON0

Definition at line 128 of file dev0473.h.

#define BUTTON0_PORT

Definition at line 129 of file dev0473.h.

#define BUTTON0_DDR

Definition at line 130 of file dev0473.h.

#define BUTTON0_PIN

Definition at line 131 of file dev0473.h.

#define BUTTON0_INT

Definition at line 132 of file dev0473.h.

#define BUTTON0_INT_VECT

Definition at line 133 of file dev0473.h.

#define BUTTON0_CONFIG_FALLING_EDGE ( )

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__board.htm (19 of 23) [10/29/2010 2:42:58 PM]

192

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 193: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Carrier Board Control

Definition at line 134 of file dev0473.h.

#define BUTTON0_CONFIG_RISING_EDGE ( )

Definition at line 139 of file dev0473.h.

#define BUTTON1

Definition at line 145 of file dev0473.h.

#define BUTTON1_PORT

Definition at line 146 of file dev0473.h.

#define BUTTON1_DDR

Definition at line 147 of file dev0473.h.

#define BUTTON1_PIN

Definition at line 148 of file dev0473.h.

#define BUTTON1_INT

Definition at line 149 of file dev0473.h.

#define BUTTON1_INT_VECT

Definition at line 150 of file dev0473.h.

#define BUTTON1_CONFIG_FALLING_EDGE ( )

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__board.htm (20 of 23) [10/29/2010 2:42:58 PM]

193

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 194: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Carrier Board Control

Definition at line 151 of file dev0473.h.

#define BUTTON1_CONFIG_RISING_EDGE ( )

Definition at line 156 of file dev0473.h.

#define TEMP_SENSOR_ADC_CHANNEL

Definition at line 173 of file dev0473.h.

#define TEMP_SENSOR_SCALE_FACTOR

Definition at line 174 of file dev0473.h.

#define halInternalInitBoard ( )

Definition at line 187 of file dev0473.h.

#define halInternalPowerDownBoard ( )

Definition at line 223 of file dev0473.h.

#define halInternalPowerUpBoard ( )

Definition at line 244 of file dev0473.h.

Enumeration Type Documentation

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__board.htm (21 of 23) [10/29/2010 2:42:58 PM]

194

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 195: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Carrier Board Control

enum HalBoardLedPins

Enumerator: BOARDLED0 BOARDLED1 BOARDLED2 BOARDLED3 BOARDLED4 BOARDLED5 BOARD_ACTIVITY_LED BOARD_HEARTBEAT_LED BOARDLED0 BOARDLED1 BOARD_ACTIVITY_LED BOARD_HEARTBEAT_LED BOARDLED0 BOARDLED1 BOARD_ACTIVITY_LED BOARD_HEARTBEAT_LED

Definition at line 30 of file host.h.

enum HalBoardLedPins

Enumerator: BOARDLED0 BOARDLED1 BOARDLED2 BOARDLED3 BOARDLED4 BOARDLED5 BOARD_ACTIVITY_LED BOARD_HEARTBEAT_LED BOARDLED0 BOARDLED1 BOARD_ACTIVITY_LED BOARD_HEARTBEAT_LED BOARDLED0 BOARDLED1 BOARD_ACTIVITY_LED

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__board.htm (22 of 23) [10/29/2010 2:42:58 PM]

195

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 196: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Carrier Board Control

BOARD_HEARTBEAT_LED

Definition at line 97 of file dev0470.h.

enum HalBoardLedPins

Enumerator: BOARDLED0 BOARDLED1 BOARDLED2 BOARDLED3 BOARDLED4 BOARDLED5 BOARD_ACTIVITY_LED BOARD_HEARTBEAT_LED BOARDLED0 BOARDLED1 BOARD_ACTIVITY_LED BOARD_HEARTBEAT_LED BOARDLED0 BOARDLED1 BOARD_ACTIVITY_LED BOARD_HEARTBEAT_LED

Definition at line 102 of file dev0473.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__board.htm (23 of 23) [10/29/2010 2:42:58 PM]

196

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 197: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: SPI Access

SPI Access [Sample APIs for Peripheral Access]

Detailed Description

This file contains the prototypes and defines for direct SPI access. These functions are generic.

See spi.h for source code.

These functions are suitable for use by any module, but are entirely dependant upon appropriate sharing of the SPI bus through chip selects and hold lines.

Some functions in this file return an EmberStatus value. See error-def.h for definitions of all EmberStatus return values.

See also spi-protocol.h for source code.

For complete documentation of the SPI Protocol, refer to the EM260 Datasheet.

SPI Protocol Interface

int8u * halNcpFrameint8u halNcpSpipErrorByte

void halNcpSerialInit (void)void halNcpSerialPowerup (void)void halNcpSerialPowerdown (void)

EzspStatus halNcpHardReset (void)EzspStatus halNcpHardResetReqBootload (boolean requestBootload)

void halNcpWakeUp (void)void halNcpSendCommand (void)void halNcpSendRawCommand (void)

EzspStatus halNcpPollForResponse (void)void halNcpIsAwakeIsr (boolean isAwake)

boolean halNcpHasData (void)boolean halNcpVerifySpiProtocolVersion (void)boolean halNcpVerifySpiProtocolActive (void)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__spi.htm (1 of 6) [10/29/2010 2:42:59 PM]

197

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 198: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: SPI Access

SPI Protocol Test Function

void spipTest (int16u test, int16u params)

Functions

void halCommonInitSpi (void)void halCommonSpiWrite (int8u data)

int8u halCommonSpiRead (void)int8u halCommonSpiReadWrite (int8u data)

Function Documentation

void halCommonInitSpi ( void )

Configures the relavent pins and initializes the USART0 module for operation at 8-bits, master mode, 3-pin, maximum speed (2MHz).

void halCommonSpiWrite ( int8u data )

Writes a byte over the SPI.

Parameters:data The byte to be sent out over the

SPI.

int8u halCommonSpiRead ( void )

Reads a byte over the SPI without changing the mode.

Returns:The byte read.

int8u halCommonSpiReadWrite ( int8u data )

Reads and writes a byte over the SPI.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__spi.htm (2 of 6) [10/29/2010 2:42:59 PM]

198

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 199: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: SPI Access

Parameters:data The byte to be sent out over the SPI.

Returns:The byte read.

void halNcpSerialInit ( void )

Initializes the SPI Protocol.

void halNcpSerialPowerup ( void )

Reinitializes the SPI Protocol when coming out of sleep (powerdown).

void halNcpSerialPowerdown ( void )

Shuts down the SPI Protocol when entering sleep (powerdown).

EzspStatus halNcpHardReset ( void )

Forcefully resets the EM260 by pulling on the nRESET line; waits for the EM260 to boot; verifies that is has booted; verifies the EM260 is active; verifies the SPI Protocol version. When this function returns, the EM260 is ready to accept all commands.

This function is the same as halNcpHardResetReqBootload(), except that the EM260 cannot be told to enter bootload mode through the nWAKE signal.

Returns:A EzspStatus value indicating the success or failure of the command.

EzspStatus halNcpHardResetReqBootload ( boolean requestBootload )

Forcefully resets the EM260 by pulling on the nRESET line; sets the nWAKE signal based upon the state of the requestBootload boolean; waits for the EM260 to boot; verifies that is has booted; verifies the EM260 is active; verifies the SPI Protocol version. When this function returns, the EM260 is ready to accept all commands.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__spi.htm (3 of 6) [10/29/2010 2:42:59 PM]

199

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 200: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: SPI Access

This function is the same as halNcpHardReset(), except that the ability to request the EM260 enter bootload mode through the nWAKE signal is made available.

Returns:A EzspStatus value indicating the success or failure of the command.

void halNcpWakeUp ( void )

If the Host thinks that the EM260 is sleeping and wants to wake it up, the EZSP calls halNcpWakeUp().

Waking up can take some time (milliseconds) so halNcpWakeUp() returns immediately and the SPI Protocol calls halNcpIsAwakeIsr() once the wakeup handshaking is complete and the EM260 is ready to accept commands.

void halNcpSendCommand ( void )

The EZSP writes a command into the command buffer and then calls halNcpSendCommand().

This function assumes the command being sent is an EZSP frame and therefore sets the SPI Byte for an EZSP Frame. If sending a command other than EZSP, use halNcpSendRawCommand(). This function returns immediately after transmission of the Command has completed and the transaction has entered the Wait section. The EZSP must now call halNcpPollForResponse() until the Response is received.

void halNcpSendRawCommand ( void )

The upper layer writes a command into the command buffer and then calls halNcpSendRawCommand().

This function makes no assumption about the data in the SpipBuffer, it will just faithly try to perform the transaction. This function returns immediately after transmission of the Command has completed and the transaction has entered the Wait section. The upper layer must now call halNcpPollForResponse() until the the Response is received.

EzspStatus halNcpPollForResponse ( void )

After sending a Command with halNcpSendCommand(), the upper layer repeatedly calls this

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__spi.htm (4 of 6) [10/29/2010 2:42:59 PM]

200

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 201: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: SPI Access

function until the SPI Protocol has finished reception of a Response.

Returns:A EzspStatus value indicating the success or failure of the command.

void halNcpIsAwakeIsr ( boolean isAwake )

The SPI Protocol calls halNcpIsAwakeIsr() once the wakeup handshaking is complete and the EM260 is ready to accept a command.

Parameters:isAwake TRUE if the wake handshake completed and the EM260 is awake. FALSE is the

wake handshake failed and the EM260 is unresponsive.

boolean halNcpHasData ( void )

If the Host wants to find out whether the EM260 has a pending callback, the EZSP calls halNcpHasData(). If this function returns TRUE then the EZSP will send a callback command.

boolean halNcpVerifySpiProtocolVersion ( void )

Transmits the SPI Protocol Version Command and checks the response against a literal value to verify the SPI Protocol version.

Returns:TRUE if the SPI Protocol Version used in this function matches the version returned by the EM260. FALSE is the versions do not match.

boolean halNcpVerifySpiProtocolActive ( void )

Transmits the SPI Status Command and checks the response against a literal value to verify the SPI Protocol is active.

Returns:TRUE if the SPI Protocol is active. FALSE if the SPI Protocol is not active.

void spipTest ( int16u test,

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__spi.htm (5 of 6) [10/29/2010 2:42:59 PM]

201

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 202: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: SPI Access

int16u params )

A collection of code for use in testing pieces of the SPI Protocol.

The tests available here undocumented and unused by a formal application. They can be called from any test application or used as inspiration or a template for further testing. To invoke a test, simply call spipTest() with the desired parameters. (For example, this function can be accessed through a user driven interface to provide a convenient method for invoking a test or set of tests.)

Parameters:test The number provided here invokes a specific piece of the test code. For example,

'1' loads the Command buffer with the SPI Protocol Version Commmand and '0' initiates a transaction with whatever data is in buffer.

params The parameters passed into a given test. For example, test 'A' simply write a byte on the SPI. The byte written is provided by params.

Variable Documentation

int8u* halNcpFrame

A pointer to the length byte at the start of the Payload. Upper layers will write the command to this location before starting a transaction. The upper layer will read the response from this location after a transaction completes. This pointer is the upper layers' primary access into the command/response buffer.

int8u halNcpSpipErrorByte

This error byte is the third byte found in a special SPI Protocol error case. It provides more detail concerning the error. Refer to the EM260 Datasheet for a more detailed description of this byte. The application does not need to work with this byte, but it can be useful information when developing.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__spi.htm (6 of 6) [10/29/2010 2:42:59 PM]

202

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 203: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: System Timer Control

System Timer Control [Hardware Abstraction Layer (HAL) API Reference]

Detailed Description

Functions that provide access to the system clock.

A single system tick (as returned by halCommonGetInt16uMillisecondTick() and halCommonGetInt32uMillisecondTick() ) is approximately 1 millisecond.

● When used with a 32.768kHz crystal, the system tick is 0.976 milliseconds.

● When used with a 3.6864MHz crystal, the system tick is 1.111 milliseconds.

A single quarter-second tick (as returned by halCommonGetInt16uQuarterSecondTick() ) is approximately 0.25 seconds.

The values used by the time support functions will wrap after an interval. The length of the interval depends on the length of the tick and the number of bits in the value. However, there is no issue when comparing time deltas of less than half this interval with a subtraction, if all data types are the same.

See system-timer.h for source code.

See also 32/system-timer.c for source code.

See also 128/system-timer.c for source code.

Defines

#define halIdleForMilliseconds(duration)

Functions

int16u halInternalStartSystemTimer (void)int16u halCommonGetInt16uMillisecondTick (void)int32u halCommonGetInt32uMillisecondTick (void)int16u halCommonGetInt16uQuarterSecondTick (void)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__system__timer.htm (1 of 6) [10/29/2010 2:43:00 PM]

203

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 204: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: System Timer Control

EmberStatus halSleepForQuarterSeconds (int32u *duration)EmberStatus halSleepForMilliseconds (int32u *duration)EmberStatus halCommonIdleForMilliseconds (int32u *duration)

void halCommonSetSystemTime (int32u time)

Define Documentation

#define halIdleForMilliseconds ( duration )

Definition at line 203 of file system-timer.h.

Function Documentation

int16u halInternalStartSystemTimer ( void )

Initializes the system tick.

Returns:Time to update the async registers after RTC is started (units of 100 microseconds).

int16u halCommonGetInt16uMillisecondTick ( void )

Returns the current system time in system ticks, as a 16-bit value.

Returns:The least significant 16 bits of the current system time, in system ticks.

int32u halCommonGetInt32uMillisecondTick ( void )

Returns the current system time in system ticks, as a 32-bit value.

EmberStack Usage:Unused, implementation optional.

Returns:

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__system__timer.htm (2 of 6) [10/29/2010 2:43:00 PM]

204

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 205: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: System Timer Control

The least significant 32 bits of the current system time, in system ticks.

int16u halCommonGetInt16uQuarterSecondTick ( void )

Returns the current system time in quarter second ticks, as a 16-bit value.

EmberStack Usage:Unused, implementation optional.

Returns:The least significant 16 bits of the current system time, in system ticks multiplied by 256.

EmberStatus halSleepForQuarterSeconds ( int32u * duration )

Uses the system timer to enter SLEEPMODE_WAKETIMER for approximately the specified amount of time (provided in quarter seconds).

This function returns EMBER_SUCCESS and the duration parameter is decremented to 0 after sleeping for the specified amount of time. If an interrupt occurs that brings the chip out of sleep, the function returns EMBER_SLEEP_INTERRUPTED and the duration parameter reports the amount of time remaining out of the original request.

Note:This routine always enables interrupts.

The maximum sleep time of the hardware is limited on AVR-based platforms to 8 seconds, on EM2XX-based platforms to 64 seconds, and on EM35x platforms to 48.5 days. Any sleep duration greater than this limit will wake up briefly (e.g. 16 microseconds) to reenable another sleep cycle.

The EM2xx has a 16 bit sleep timer, which normally runs at 1024Hz. In order to support long sleep durations, the chip will periodically wake up to manage a larger timer in software. This periodic wakeup is normally triggered once every 32 seconds. However, this period can be extended to once every 2.275 hours by building with ENABLE_LONG_SLEEP_CYCLES defined. This definition enables the use of a prescaler when sleeping for more than 63 seconds at a time. However, this define also imposes the following limitations:

1. The chip may only wake up from the sleep timer. (External GPIO wake events may not be used) 2. Each time a sleep cycle is performed, a loss of accuracy up to +/-750ms will be observed in the system timer.

EmberStack Usage:

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__system__timer.htm (3 of 6) [10/29/2010 2:43:00 PM]

205

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 206: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: System Timer Control

Unused, implementation optional.

Parameters:duration The amount of time, expressed in quarter seconds, that the micro should be

placed into SLEEPMODE_WAKETIMER. When the function returns, this parameter provides the amount of time remaining out of the original sleep time request (normally the return value will be 0).

Returns:An EmberStatus value indicating the success or failure of the command.

EmberStatus halSleepForMilliseconds ( int32u * duration )

Uses the system timer to enter SLEEPMODE_WAKETIMER for approximately the specified amount of time (provided in milliseconds). Note that since the system timer ticks at a rate of 1024Hz, a second is comprised of 1024 milliseconds in this function.

This function returns EMBER_SUCCESS and the duration parameter is decremented to 0 after sleeping for the specified amount of time. If an interrupt occurs that brings the chip out of sleep, the function returns EMBER_SLEEP_INTERRUPTED and the duration parameter reports the amount of time remaining out of the original request.

Note:This routine always enables interrupts.

This function is not implemented on AVR-based platforms.

Sleep durations less than 3 milliseconds are not allowed on on EM2XX-based platforms. Any attempt to sleep for less than 3 milliseconds on EM2XX-based platforms will cause the function to immediately exit without sleeping and return EMBER_SLEEP_INTERRUPTED.

The maximum sleep time of the hardware is limited on EM2XX-based platforms to 32 seconds. Any sleep duration greater than this limit will wake up briefly (e.g. 16 microseconds) to reenable another sleep cycle. Due to this limitation, this function should not be used with durations within 3 milliseconds of a multiple 32 seconds. The short sleep cycle that results from such durations is not handled reliably by the system timer on EM2XX-based platforms. If a sleep duration within 3 milliseconds of a multiple of 32 seconds is desired, halSleepForQuarterSeconds should be used.

EmberStack Usage:Unused, implementation optional.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__system__timer.htm (4 of 6) [10/29/2010 2:43:00 PM]

206

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 207: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: System Timer Control

Parameters:duration The amount of time, expressed in milliseconds (1024 milliseconds = 1 second),

that the micro should be placed into SLEEPMODE_WAKETIMER. When the function returns, this parameter provides the amount of time remaining out of the original sleep time request (normally the return value will be 0).

Returns:An EmberStatus value indicating the success or failure of the command.

EmberStatus halCommonIdleForMilliseconds ( int32u * duration )

Uses the system timer to enter SLEEPMODE_IDLE for approximately the specified amount of time (provided in milliseconds).

This function returns EMBER_SUCCESS and the duration parameter is decremented to 0 after idling for the specified amount of time. If an interrupt occurs that brings the chip out of idle, the function returns EMBER_SLEEP_INTERRUPTED and the duration parameter reports the amount of time remaining out of the original request.

Note:This routine always enables interrupts.

EmberStack Usage:Unused, implementation optional.

Parameters:duration The amount of time, expressed in milliseconds, that the micro should be placed

into SLEEPMODE_IDLE. When the function returns, this parameter provides the amount of time remaining out of the original idle time request (normally the return value will be 0).

Returns:An EmberStatus value indicating the success or failure of the command.

void halCommonSetSystemTime ( int32u time )

Set the current system time.

Parameters:time A 32 bit value, expressed in milliseconds, that will become the current system

time.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__system__timer.htm (5 of 6) [10/29/2010 2:43:00 PM]

207

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 208: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: System Timer Control

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__system__timer.htm (6 of 6) [10/29/2010 2:43:00 PM]

208

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 209: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: HAL Utilities

HAL Utilities [Hardware Abstraction Layer (HAL) API Reference]

Modules

Cyclic Redundancy Code (CRC) Random Number Generation

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__hal__util.htm [10/29/2010 2:43:00 PM]

209

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 210: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Cyclic Redundancy Code (CRC)

Cyclic Redundancy Code (CRC) [HAL Utilities]

Detailed Description

Functions that provide access to cyclic redundancy code (CRC) calculation. See crc.h for source code.

Defines

#define INITIAL_CRC#define CRC32_START#define CRC32_END

Functions

int16u halCommonCrc16 (int8u newByte, int16u prevResult)int32u halCommonCrc32 (int8u newByte, int32u prevResult)

Define Documentation

#define INITIAL_CRC

Definition at line 49 of file crc.h.

#define CRC32_START

Definition at line 50 of file crc.h.

#define CRC32_END

Definition at line 51 of file crc.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__crc.htm (1 of 3) [10/29/2010 2:43:01 PM]

210

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 211: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Cyclic Redundancy Code (CRC)

Function Documentation

int16u halCommonCrc16 ( int8u newByte, int16u prevResult

)

Calculates 16-bit cyclic redundancy code (CITT CRC 16).

Applies the standard CITT CRC 16 polynomial to a single byte. It should support being called first with an initial value, then repeatedly until all data is processed.

Parameters:newByte The new byte to be run through CRC.prevResult The previous CRC result.

Returns:The new CRC result.

int32u halCommonCrc32 ( int8u newByte, int32u prevResult

)

Calculates 32-bit cyclic redundancy code.

Note:On some radios or micros, the CRC for error detection on packet data is calculated in hardware.

Applies a CRC32 polynomial to a single byte. It should support being called first with an initial value, then repeatedly until all data is processed.

Parameters:newByte The new byte to be run through CRC.prevResult The previous CRC result.

Returns:The new CRC result.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__crc.htm (2 of 3) [10/29/2010 2:43:01 PM]

211

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 212: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Cyclic Redundancy Code (CRC)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__crc.htm (3 of 3) [10/29/2010 2:43:01 PM]

212

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 213: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Random Number Generation

Random Number Generation [HAL Utilities]

Detailed Description

Functions that provide access to random numbers.

These functions may be hardware accelerated, though often are not.

See random.h for source code.

Functions

void halStackSeedRandom (int32u seed)int16u halCommonGetRandom (void)

Function Documentation

void halStackSeedRandom ( int32u seed )

Seeds the halCommonGetRandom() pseudorandom number generator.

Called by the stack during initialization with a seed from the radio.

Parameters:seed A seed for the pseudorandom number

generator.

int16u halCommonGetRandom ( void )

Runs a standard LFSR to generate pseudorandom numbers.

Called by the MAC in the stack to choose random backoff slots.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__random.htm (1 of 2) [10/29/2010 2:43:01 PM]

213

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 214: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Random Number Generation

Complicated implementations may improve the MAC's ability to avoid collisions in large networks, but it is critical to implement this function to return quickly.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__random.htm (2 of 2) [10/29/2010 2:43:01 PM]

214

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 215: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Asynchronous Serial Host (ASH) Framework

Asynchronous Serial Host (ASH) Framework [Hardware Abstraction Layer (HAL) API Reference]

Detailed Description

Use the Asynchronous Serial Host (ASH) Framework interfaces on a host microcontroller when it communicates with an Ember chip via EZSP-UART.

See ash-common.h for source code.

See ash-protocol.h for source code.

Defines

#define ashStopAckTimer(void)#define ashAckTimerIsRunning()#define ashAckTimerIsNotRunning()#define ashSetAckPeriod(msec)#define ashGetAckPeriod()#define ashSetAndStartAckTimer(msec)#define ASH_NR_TIMER_BIT#define ashStopNrTimer()#define ashNrTimerIsNotRunning()#define ASH_VERSION#define ASH_FLAG#define ASH_ESC#define ASH_XON#define ASH_XOFF#define ASH_SUB#define ASH_CAN#define ASH_WAKE#define ASH_FLIP#define ASH_MIN_DATA_FIELD_LEN#define ASH_MAX_DATA_FIELD_LEN#define ASH_MIN_DATA_FRAME_LEN#define ASH_MIN_FRAME_LEN#define ASH_MAX_FRAME_LEN

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ash.htm (1 of 15) [10/29/2010 2:43:03 PM]

215

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 216: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Asynchronous Serial Host (ASH) Framework

#define ASH_CRC_LEN#define ASH_MIN_FRAME_WITH_CRC_LEN#define ASH_MAX_FRAME_WITH_CRC_LEN#define ASH_NCP_SHFRAME_RX_LEN#define ASH_NCP_SHFRAME_TX_LEN#define ASH_HOST_SHFRAME_RX_LEN#define ASH_HOST_SHFRAME_TX_LEN#define ASH_DFRAME_MASK#define ASH_CONTROL_DATA#define ASH_SHFRAME_MASK#define ASH_CONTROL_ACK#define ASH_CONTROL_NAK#define ASH_CONTROL_RST#define ASH_CONTROL_RSTACK#define ASH_CONTROL_ERROR#define ASH_ACKNUM_MASK#define ASH_ACKNUM_BIT#define ASH_RFLAG_MASK#define ASH_RFLAG_BIT#define ASH_NFLAG_MASK#define ASH_NFLAG_BIT#define ASH_PFLAG_MASK#define ASH_PFLAG_BIT#define ASH_FRMNUM_MASK#define ASH_FRMNUM_BIT#define ASH_GET_RFLAG(ctl)#define ASH_GET_NFLAG(ctl)#define ASH_GET_FRMNUM(ctl)#define ASH_GET_ACKNUM(ctl)#define ASH_FRAME_LEN_DATA_MIN#define ASH_FRAME_LEN_ACK#define ASH_FRAME_LEN_NAK#define ASH_FRAME_LEN_RST#define ASH_FRAME_LEN_RSTACK#define ASH_FRAME_LEN_ERROR#define MOD8(n)#define INC8(n)#define WITHIN_RANGE(lo, n, hi)

Functions

int8u ashEncodeByte (int8u len, int8u byte, int8u *offset)EzspStatus ashDecodeByte (int8u byte, int8u *out, int8u *outLen)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ash.htm (2 of 15) [10/29/2010 2:43:03 PM]

216

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 217: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Asynchronous Serial Host (ASH) Framework

int8u ashRandomizeArray (int8u seed, int8u *buf, int8u len)void ashStartAckTimer (void)

boolean ashAckTimerHasExpired (void)void ashAdjustAckPeriod (boolean expired)void ashStartNrTimer (void)

boolean ashNrTimerHasExpired (void)

Variables

boolean ashDecodeInProgressint16u ashAckTimerint16u ashAckPeriod

int8u ashNrTimer

Define Documentation

void ashStopAckTimer ( void )

Stops and clears ashAckTimer.

Definition at line 98 of file ash-common.h.

#define ashAckTimerIsRunning ( )

Indicates whether or not ashAckTimer is currently running. The timer may be running even if expired.

Definition at line 104 of file ash-common.h.

#define ashAckTimerIsNotRunning ( )

Indicates whether or not ashAckTimer is currently running. The timer may be running even if expired.

Definition at line 110 of file ash-common.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ash.htm (3 of 15) [10/29/2010 2:43:03 PM]

217

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 218: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Asynchronous Serial Host (ASH) Framework

#define ashSetAckPeriod ( msec )

Sets the acknowledgement timer period (in msec) and stops the timer.

Definition at line 140 of file ash-common.h.

#define ashGetAckPeriod ( )

Returns the acknowledgement timer period (in msec).

Definition at line 146 of file ash-common.h.

#define ashSetAndStartAckTimer ( msec )

Sets the acknowledgement timer period (in msec), and starts the timer running.

Definition at line 151 of file ash-common.h.

#define ASH_NR_TIMER_BIT

Definition at line 155 of file ash-common.h.

#define ashStopNrTimer ( )

Stops the Not Ready timer.

Definition at line 168 of file ash-common.h.

#define ashNrTimerIsNotRunning ( )

Indicates whether or not ashNrTimer is currently running.

Definition at line 180 of file ash-common.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ash.htm (4 of 15) [10/29/2010 2:43:03 PM]

218

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 219: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Asynchronous Serial Host (ASH) Framework

#define ASH_VERSION

Definition at line 21 of file ash-protocol.h.

#define ASH_FLAG

frame delimiter

Definition at line 25 of file ash-protocol.h.

#define ASH_ESC

byte stuffing escape byte

Definition at line 26 of file ash-protocol.h.

#define ASH_XON

flow control byte - means resume transmission

Definition at line 27 of file ash-protocol.h.

#define ASH_XOFF

flow control byte - means suspend transmission

Definition at line 28 of file ash-protocol.h.

#define ASH_SUB

replaces bytes w framing, overrun or overflow errors

Definition at line 29 of file ash-protocol.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ash.htm (5 of 15) [10/29/2010 2:43:03 PM]

219

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 220: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Asynchronous Serial Host (ASH) Framework

#define ASH_CAN

frame cancel byte

Definition at line 30 of file ash-protocol.h.

#define ASH_WAKE

wake signal byte (also means NCP data pending)

Definition at line 34 of file ash-protocol.h.

#define ASH_FLIP

XOR mask used in byte stuffing

Definition at line 37 of file ash-protocol.h.

#define ASH_MIN_DATA_FIELD_LEN

Definition at line 41 of file ash-protocol.h.

#define ASH_MAX_DATA_FIELD_LEN

Definition at line 42 of file ash-protocol.h.

#define ASH_MIN_DATA_FRAME_LEN

Definition at line 43 of file ash-protocol.h.

#define ASH_MIN_FRAME_LEN

Definition at line 44 of file ash-protocol.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ash.htm (6 of 15) [10/29/2010 2:43:03 PM]

220

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 221: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Asynchronous Serial Host (ASH) Framework

#define ASH_MAX_FRAME_LEN

Definition at line 45 of file ash-protocol.h.

#define ASH_CRC_LEN

Definition at line 46 of file ash-protocol.h.

#define ASH_MIN_FRAME_WITH_CRC_LEN

Definition at line 47 of file ash-protocol.h.

#define ASH_MAX_FRAME_WITH_CRC_LEN

Definition at line 48 of file ash-protocol.h.

#define ASH_NCP_SHFRAME_RX_LEN

longest non-data frame received

Definition at line 51 of file ash-protocol.h.

#define ASH_NCP_SHFRAME_TX_LEN

longest non-data frame sent

Definition at line 52 of file ash-protocol.h.

#define ASH_HOST_SHFRAME_RX_LEN

longest non-data frame received

Definition at line 53 of file ash-protocol.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ash.htm (7 of 15) [10/29/2010 2:43:03 PM]

221

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 222: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Asynchronous Serial Host (ASH) Framework

#define ASH_HOST_SHFRAME_TX_LEN

longest non-data frame sent

Definition at line 54 of file ash-protocol.h.

#define ASH_DFRAME_MASK

Definition at line 75 of file ash-protocol.h.

#define ASH_CONTROL_DATA

Definition at line 76 of file ash-protocol.h.

#define ASH_SHFRAME_MASK

Definition at line 78 of file ash-protocol.h.

#define ASH_CONTROL_ACK

Definition at line 79 of file ash-protocol.h.

#define ASH_CONTROL_NAK

Definition at line 80 of file ash-protocol.h.

#define ASH_CONTROL_RST

Definition at line 81 of file ash-protocol.h.

#define ASH_CONTROL_RSTACK

Definition at line 82 of file ash-protocol.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ash.htm (8 of 15) [10/29/2010 2:43:03 PM]

222

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 223: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Asynchronous Serial Host (ASH) Framework

#define ASH_CONTROL_ERROR

Definition at line 83 of file ash-protocol.h.

#define ASH_ACKNUM_MASK

acknowledge frame number

Definition at line 85 of file ash-protocol.h.

#define ASH_ACKNUM_BIT

Definition at line 86 of file ash-protocol.h.

#define ASH_RFLAG_MASK

retransmitted frame flag

Definition at line 87 of file ash-protocol.h.

#define ASH_RFLAG_BIT

Definition at line 88 of file ash-protocol.h.

#define ASH_NFLAG_MASK

receiver not ready flag

Definition at line 89 of file ash-protocol.h.

#define ASH_NFLAG_BIT

Definition at line 90 of file ash-protocol.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ash.htm (9 of 15) [10/29/2010 2:43:03 PM]

223

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 224: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Asynchronous Serial Host (ASH) Framework

#define ASH_PFLAG_MASK

flag reserved for future use

Definition at line 91 of file ash-protocol.h.

#define ASH_PFLAG_BIT

Definition at line 92 of file ash-protocol.h.

#define ASH_FRMNUM_MASK

DATA frame number

Definition at line 93 of file ash-protocol.h.

#define ASH_FRMNUM_BIT

Definition at line 94 of file ash-protocol.h.

#define ASH_GET_RFLAG ( ctl )

Definition at line 95 of file ash-protocol.h.

#define ASH_GET_NFLAG ( ctl )

Definition at line 96 of file ash-protocol.h.

#define ASH_GET_FRMNUM ( ctl )

Definition at line 97 of file ash-protocol.h.

#define ASH_GET_ACKNUM ( ctl )

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ash.htm (10 of 15) [10/29/2010 2:43:03 PM]

224

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 225: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Asynchronous Serial Host (ASH) Framework

Definition at line 98 of file ash-protocol.h.

#define ASH_FRAME_LEN_DATA_MIN

Definition at line 102 of file ash-protocol.h.

#define ASH_FRAME_LEN_ACK

Definition at line 103 of file ash-protocol.h.

#define ASH_FRAME_LEN_NAK

Definition at line 104 of file ash-protocol.h.

#define ASH_FRAME_LEN_RST

Definition at line 105 of file ash-protocol.h.

#define ASH_FRAME_LEN_RSTACK

Definition at line 106 of file ash-protocol.h.

#define ASH_FRAME_LEN_ERROR

Definition at line 107 of file ash-protocol.h.

#define MOD8 ( n )

mask to frame number modulus

Definition at line 110 of file ash-protocol.h.

#define INC8 ( n )

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ash.htm (11 of 15) [10/29/2010 2:43:03 PM]

225

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 226: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Asynchronous Serial Host (ASH) Framework

increment in frame number modulus

Definition at line 111 of file ash-protocol.h.

#define WITHIN_RANGE ( lo, n, hi )

Definition at line 113 of file ash-protocol.h.

Function Documentation

int8u ashEncodeByte ( int8u len, int8u byte, int8u * offset

)

Builds an ASH frame. Byte stuffs the control and data fields as required, computes and appends the CRC and adds the ending flag byte. Called with the next byte to encode, this function may return several output bytes before it's ready for the next byte.

Parameters:len new frame flag / length of the frame to be encoded. A non-zero value begins a new

frame, so all subsequent calls must use zero. The length includes control byte and data field, but not the flag or crc. This function does not validate the length.

byte the next byte of data to add to the frame. Note that in general the same byte of data may have to be passed more than once as escape bytes, the CRC and the end flag byte are output.

offset pointer to the offset of the next input byte. (If the frame data is the array data[], the next byte would be data[offset].) Is set to 0 when starting a new frame (ie, len is non-zero). Is set to 0xFF when the last byte of the frame is returned.

Returns:next encoded output byte in frame.

EzspStatus ashDecodeByte ( int8u byte,

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ash.htm (12 of 15) [10/29/2010 2:43:03 PM]

226

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 227: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Asynchronous Serial Host (ASH) Framework

int8u * out, int8u * outLen

)

Decodes and validates an ASH frame. Data is passed to it one byte at a time. Decodes byte stuffing, checks crc, finds the end flag and (if enabled) terminates the frame early on CAN or SUB bytes. The number of bytes output will not exceed the max valid frame length, which does not include the flag or the crc.

Parameters:byte the next byte of data to add to the frameout pointer to where to write an output byteoutLen number of bytes output so far

Returns:status of frame decoding

�❍ EZSP_SUCCESS�❍ EZSP_ASH_IN_PROGRESS�❍ EZSP_ASH_CANCELLED�❍ EZSP_ASH_BAD_CRC�❍ EZSP_ASH_COMM_ERROR�❍ EZSP_ASH_TOO_SHORT�❍ EZSP_ASH_TOO_LONG

int8u ashRandomizeArray ( int8u seed, int8u * buf, int8u len

)

Randomizes array contents by XORing with an 8-bit pseudo random sequence. This reduces the likelihood that byte-stuffing will greatly increase the size of the payload. (This could happen if a DATA frame contained repeated instances of the same reserved byte value.).

Parameters:seed zero initializes the random sequence a non-zero value continues from a previous

invocationbuf pointer to the array whose contents will be randomizedlen number of bytes in the array to modify

Returns:last value of the sequence. If a buffer is processed in two or more chunks, as with linked

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ash.htm (13 of 15) [10/29/2010 2:43:03 PM]

227

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 228: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Asynchronous Serial Host (ASH) Framework

buffers, this value should be passed back as the value of the seed argument

void ashStartAckTimer ( void )

Sets ashAckTimer to the specified period and starts it running.

boolean ashAckTimerHasExpired ( void )

Indicates whether or not ashAckTimer has expired. If the timer is stopped then it is not expired.

void ashAdjustAckPeriod ( boolean expired )

Adapts the acknowledgement timer period to the observed ACK delay. If the timer is not running, it does nothing. If the timer has expired, the timeourt period is doubled. If the timer has not expired, the elapsed time is fed into simple IIR filter: T[n+1] = (7*T[n] + elapsedTime) / 8 The timeout period, ashAckPeriod, is limited such that: ASH_xxx_TIME_DATA_MIN <= ashAckPeriod <= ASH_xxx_TIME_DATA_MAX, where xxx is either HOST or NCP.

The acknowledgement timer is always stopped by this function.

Parameters:expired TRUE if timer has

expired

void ashStartNrTimer ( void )

Starts the Not Ready timer.

On the host, this times nFlag refreshing when the host doesn't have room for callbacks for a prolonged period.

On the NCP, if this times out the NCP resumes sending callbacks.

boolean ashNrTimerHasExpired ( void )

Tests whether the Not Ready timer has expired or has stopped. If expired, it is stopped.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ash.htm (14 of 15) [10/29/2010 2:43:03 PM]

228

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 229: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Asynchronous Serial Host (ASH) Framework

Returns:TRUE if the Not Ready timer has expired or stopped

Variable Documentation

boolean ashDecodeInProgress

int16u ashAckTimer

int16u ashAckPeriod

int8u ashNrTimer

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ash.htm (15 of 15) [10/29/2010 2:43:03 PM]

229

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 230: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Application Utilities API Reference

Application Utilities API Reference

Modules

Forming and Joining Networks Bootloading Command Interpreter ZigBee Device Object (ZDO) Information Message Fragmentation Network Manager Serial Communication ASH Application Utility

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__apputil.htm [10/29/2010 2:43:03 PM]

230

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 231: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Forming and Joining Networks

Forming and Joining Networks [Application Utilities API Reference]

Detailed Description

Functions for finding an existing network to join and for finding an unused PAN id with which to form a network.

Summary of application requirements:

For the SOC:

● Define EMBER_APPLICATION_HAS_ENERGY_SCAN_RESULT_HANDLER in the configuration header.● Call emberFormAndJoinTick() regularly in the main loop.● Include form-and-join.c and form-and-join-node-adapter.c in the build.● Optionally include form-and-join-node-callbacks.c in the build.● If processor idling is desired: -- Call emberFormAndJoinTaskInit() to initialize the form and join task -- Call

emberFormAndJoinRunTask() regularly in the main loop instead of emberFormAndJoinTick()

For an EZSP Host:

● Define EZSP_APPLICATION_HAS_ENERGY_SCAN_RESULT_HANDLER in the configuration header.● Include form-and-join.c and form-and-join-host-adapter.c in the build.● Optionally include form-and-join-host-callbacks.c in the build.

For either platform, the application can omit the form-and-join-*-callback.c file from the build and implement the callbacks itself if necessary. In this case the appropriate form-and-join callback function must be called from within each callback, as is done within the form-and-join-*-callback.c files.

This library improves upon the form-and-join library from EmberZNet 3.2 and prior. The old library (form-and-join3_2) was removed from the release. The currently provided library is able to resume scanning for joinable networks from where it left off, via a call to emberScanForNextJoinableNetwork(). Thus if the first joinable network found is not the correct one, the application can continue scanning without starting from the beginning and without finding the same network that it has already rejected. The new library can also be used on the host processor.

For EZSP-based applications, this library is only needed if the image being used on the network coprocessor (eg EM260) does not implement the form-and-join EZSP commands for flash reasons. If implemented, the EZSP frames for the equivalent form-and-join functionality are as follows:

For joining networks:

● scanForJoinableNetwork● startScan with scanType EZSP_NEXT_JOINABLE_NETWORK_SCAN● results via networkFoundHandler callback● errors via scanErrorHandler callback

For forming networks:

● startScan with scanType EZSP_UNUSED_PAN_ID_SCAN

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__networks.htm (1 of 6) [10/29/2010 2:43:04 PM]

231

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 232: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Forming and Joining Networks

● results via unusedPanIdFoundHandler● errors via scanErrorHandler callback

Functions

EmberStatus emberScanForUnusedPanId (int32u channelMask, int8u duration)EmberStatus emberScanForJoinableNetwork (int32u channelMask, int8u *extendedPanId)EmberStatus emberScanForNextJoinableNetwork (void)

boolean emberFormAndJoinIsScanning (void)void emberUnusedPanIdFoundHandler (EmberPanId panId, int8u channel)void emberJoinableNetworkFoundHandler (EmberZigbeeNetwork *networkFound, int8u lqi, int8s rssi)void emberScanErrorHandler (EmberStatus status)

boolean emberFormAndJoinScanCompleteHandler (int8u channel, EmberStatus status)boolean emberFormAndJoinNetworkFoundHandler (EmberZigbeeNetwork *networkFound, int8u lqi, int8s rssi)boolean emberFormAndJoinEnergyScanResultHandler (int8u channel, int8s maxRssiValue)

void emberFormAndJoinTick (void)void emberFormAndJoinTaskInit (void)void emberFormAndJoinRunTask (void)

Variables

boolean emberEnableDualChannelScan

Function Documentation

EmberStatus emberScanForUnusedPanId ( int32u channelMask, int8u duration

)

Find an unused PAN id.

Does an energy scan on the indicated channels and randomly chooses one from amongst those with the least average energy. Then picks a short PAN id that does not appear during an active scan on the chosen channel. The chosen PAN id and channel are returned via the emberUnusedPanIdFoundHandler() callback. If an error occurs, the application is informed via the emberScanErrorHandler().

Parameters:channelMask duration The duration of the energy scan. See the documentation for emberStartScan() in stack/include/

network-formation.h for information on duration values.

Returns:EMBER_LIBRARY_NOT_PRESENT if the form and join library is not available.

EmberStatus emberScanForJoinableNetwork ( int32u channelMask, int8u * extendedPanId

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__networks.htm (2 of 6) [10/29/2010 2:43:04 PM]

232

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 233: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Forming and Joining Networks

)

Finds a joinable network.

Performs an active scan on the specified channels looking for networks that:

1. currently permit joining,2. match the stack profile of the application,3. match the extended PAN id argument if it is not NULL.

Upon finding a matching network, the application is notified via the emberJoinableNetworkFoundHandler() callback, and scanning stops. If an error occurs during the scanning process, the application is informed via the emberScanErrorHandler(), and scanning stops.

If the application determines that the discovered network is not the correct one, it may call emberScanForNextJoinableNetwork() to continue the scanning process where it was left off and find a different joinable network. If the next network is not the correct one, the application can continue to call emberScanForNextJoinableNetwork(). Each call must occur within 30 seconds of the previous one, otherwise the state of the scan process is deleted to free up memory. Calling emberScanForJoinableNetwork() causes any old state to be forgotten and starts scanning from the beginning.

Parameters:channelMask extendedPanId

Returns:EMBER_LIBRARY_NOT_PRESENT if the form and join library is not available.

EmberStatus emberScanForNextJoinableNetwork ( void )

See emberScanForJoinableNetwork().

boolean emberFormAndJoinIsScanning ( void )

Returns true if and only if the form and join library is in the process of scanning and is therefore expecting scan results to be passed to it from the application.

void emberUnusedPanIdFoundHandler ( EmberPanId panId, int8u channel

)

A callback the application needs to implement.

Notifies the application of the PAN id and channel found following a call to emberScanForUnusedPanId().

Parameters:panId

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__networks.htm (3 of 6) [10/29/2010 2:43:04 PM]

233

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 234: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Forming and Joining Networks

channel

void emberJoinableNetworkFoundHandler ( EmberZigbeeNetwork * networkFound, int8u lqi, int8s rssi

)

A callback the application needs to implement.

Notifies the application of the network found after a call to emberScanForJoinableNetwork() or emberScanForNextJoinableNetwork().

Parameters:networkFound lqi The lqi value of the received beacon. rssi The rssi value of the received

beacon.

void emberScanErrorHandler ( EmberStatus status )

A callback the application needs to implement.

If an error occurs while scanning, this function is called and the scan effort is aborted.

Possible return status values are:

● EMBER_INVALID_CALL: if emberScanForNextJoinableNetwork() is called more than 30 seconds after a previous call to emberScanForJoinableNetwork() or emberScanForNextJoinableNetwork().

● EMBER_NO_BUFFERS: if there is not enough memory to start a scan. ● EMBER_NO_BEACONS: if no joinable beacons are found. ● EMBER_MAC_SCANNING: if a scan is already in progress.

Parameters:status

boolean emberFormAndJoinScanCompleteHandler ( int8u channel, EmberStatus status

)

The application must call this function from within its emberScanCompleteHandler() (on the node) or ezspScanCompleteHandler() (on an EZSP host). Default callback implementations are provided in the form-and-join-*-callbacks.c files.

Returns:TRUE iff the library made use of the call.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__networks.htm (4 of 6) [10/29/2010 2:43:04 PM]

234

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 235: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Forming and Joining Networks

boolean emberFormAndJoinNetworkFoundHandler ( EmberZigbeeNetwork * networkFound, int8u lqi, int8s rssi

)

The application must call this function from within its emberNetworkFoundHandler() (on the node) or ezspNetworkFoundHandler() (on an EZSP host). Default callback implementations are provided in the form-and-join-*-callbacks.c files.

Returns:TRUE iff the library made use of the call.

boolean emberFormAndJoinEnergyScanResultHandler ( int8u channel, int8s maxRssiValue

)

The application must call this function from within its emberEnergyScanResultHandler() (on the node) or ezspEnergyScanResultHandler() (on an EZSP host). Default callback implementations are provided in the form-and-join-*-callbacks.c files.

Returns:TRUE iff the library made use of the call.

void emberFormAndJoinTick ( void )

Used by the form and join code on the node to time out a joinable scan after 30 seconds of inactivity. The application must call emberFormAndJoinTick() regularly. This function does not exist for the EZSP host library.

void emberFormAndJoinTaskInit ( void )

When processor idling is desired on the SOC, this must be called to properly initialize the form and join library.

void emberFormAndJoinRunTask ( void )

When processor idling is desired on the SOC, this should be called regularly instead of emberFormAndJoinTick().

Variable Documentation

boolean emberEnableDualChannelScan

With some board layouts, the EM250 and EM260 are susceptible to a dual channel issue in which packets from 12

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__networks.htm (5 of 6) [10/29/2010 2:43:04 PM]

235

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 236: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Forming and Joining Networks

channels above or below can sometimes be heard faintly. This affects channels 11 - 14 and 23 - 26. Hardware reference designs EM250_REF_DES_LAT, version C0 and EM250_REF_DES_CER, version B0 solve the problem.

Setting the emberEnableDualChannelScan variable to TRUE enables a software workaround to the dual channel issue which can be used with vulnerable boards. After emberScanForJoinableNetwork() discovers a network on one of the susceptible channels, the channel number that differs by 12 is also scanned. If the same network can be heard there, the true channel is determined by comparing the link quality of the received beacons. The default value of emberEnableDualChannelScan is TRUE for the EM250 and EM260. It is not used on other platforms.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__networks.htm (6 of 6) [10/29/2010 2:43:04 PM]

236

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 237: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Bootloading

Bootloading [Application Utilities API Reference]

Detailed Description

For a thorough discussion of bootloading, see the Bootloading chapter of the EmberZNet Application Developer’s Guide. There are three forms of the bootloading API.

Modules

Stand-Alone Bootloader Interface Stand-Alone Bootloader for EZSP Stand-Alone Bootloader Library

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__util__bootload.htm [10/29/2010 2:43:05 PM]

237

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 238: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Stand-Alone Bootloader Interface

Stand-Alone Bootloader Interface [Bootloading]

Detailed Description

Definition of the standalone bootloader interface.

Some functions in this file return an EmberStatus value. See error-def.h for definitions of all EmberStatus return values.

See bootloader-interface-standalone.h for source code.

See bootloader-interface-standalone-v1.h for source code.

Defines

#define NO_BOOTLOADER_MODE#define STANDALONE_BOOTLOADER_NORMAL_MODE#define STANDALONE_BOOTLOADER_RECOVERY_MODE#define BOOTLOADER_TYPE_STANDALONE#define halBootloadAppStart(space, segment, ramPtr)#define halBootloadAdjustFlash(space, segment, ramPtr)

Enumerations

enum { BOOTLOADER_MODE_MENU, BOOTLOADER_MODE_PASSTHROUGH, BOOTLOADER_MODE_CLONE, BOOTLOADER_MODE_CLONE_RECOVERY, BOOTLOADER_MODE_PASSTHROUGH_RECOVERY }

Functions

int16u halGetStandaloneBootloaderVersion (void)EmberStatus halLaunchStandaloneBootloader (int8u mode)EmberStatus halInternalStandaloneBootloaderTrap (int16u assumedBootloaderType, int8u trapNumber,...)

void halInternalAdjustFlashBlock (int16u *dst, int16u *src, int8u size)EmberStatus halLaunchStandaloneBootloaderV1 (int8u mode, int8u *eui64)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__alone__bootload.htm (1 of 5) [10/29/2010 2:43:06 PM]

238

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 239: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Stand-Alone Bootloader Interface

Define Documentation

#define NO_BOOTLOADER_MODE

Define a numerical value for NO BOOTLOADER mode. In other words, the bootloader should not be run.

Definition at line 33 of file bootloader-interface-standalone.h.

#define STANDALONE_BOOTLOADER_NORMAL_MODE

Define a numerical value for the normal bootloader mode.

Definition at line 37 of file bootloader-interface-standalone.h.

#define STANDALONE_BOOTLOADER_RECOVERY_MODE

Define a numerical value for the recovery bootloader mode.

Definition at line 41 of file bootloader-interface-standalone.h.

#define BOOTLOADER_TYPE_STANDALONE

A "signature" to identify the bootloader type and help catch any app/bootloader mismatch.

Definition at line 26 of file bootloader-interface-standalone-v1.h.

#define halBootloadAppStart ( space, segment, ramPtr )

Trap for accessing bootloadAppStart().

Parameters:space Size of block, in words. Must be 0 to 128.segment Byte address pointer. Must be an even address and within the first 64k bytes of flash

address space. Usually use to point to the beginning of a flash block.ramPtr Byte address pointer. Must be within the first 64k bytes of flash address space.

Returns:EMBER_ERR_BOOTLOADER_TRAP_TABLE_BAD if the trap table is corrupt or if the application bootloader API is not installed. EMBER_SUCCESS if the segment is written.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__alone__bootload.htm (2 of 5) [10/29/2010 2:43:06 PM]

239

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 240: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Stand-Alone Bootloader Interface

Definition at line 127 of file bootloader-interface-standalone-v1.h.

#define halBootloadAdjustFlash ( space, segment, ramPtr )

Trap for accessing halInternalAdjustFlashBlock().

Parameters:space Size of block, in words. Must be 0 to 128.segment Byte address pointer. Must be an even address and within the first 64k bytes of flash

address space. Usually use to point to the beginning of a flash block.ramPtr Byte address pointer. Must be within the first 64k bytes of flash address space.

Returns:EMBER_ERR_BOOTLOADER_TRAP_TABLE_BAD if the trap table is corrupt or if the application bootloader API is not installed. EMBER_SUCCESS if the segment is written.

Definition at line 167 of file bootloader-interface-standalone-v1.h.

Enumeration Type Documentation

anonymous enum

Enumerator: BOOTLOADER_MODE_MENU BOOTLOADER_MODE_PASSTHROUGH BOOTLOADER_MODE_CLONE BOOTLOADER_MODE_CLONE_RECOVERY BOOTLOADER_MODE_PASSTHROUGH_RECOVERY

Definition at line 182 of file bootloader-interface-standalone-v1.h.

Function Documentation

int16u halGetStandaloneBootloaderVersion ( void )

Detects if the standalone bootloader is installed, and if so returns the installed version.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__alone__bootload.htm (3 of 5) [10/29/2010 2:43:06 PM]

240

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 241: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Stand-Alone Bootloader Interface

A returned version of 0x1234 would indicate version 1.2 build 34

Returns:BOOTLOADER_INVALID_VERSION if the standalone bootloader is not present, or the version of the installed standalone bootloader.

EmberStatus halLaunchStandaloneBootloader ( int8u mode )

Quits the current application and launches the standalone bootloader (if installed). The function returns an error if the standalone bootloader is not present.

Parameters:mode Controls the mode in which the standalone bootloader will run. See the bootloader Application

Note for full details. Options are:�❍ STANDALONE_BOOTLOADER_NORMAL_MODE Will listen for an over-the-air

image transfer on the current channel with current power settings.�❍ STANDALONE_BOOTLOADER_RECOVERY_MODE Will listen for an over-the-

air image transfer on the default channel with default power settings.Both modes also allow an image transfer to begin via serial xmodem.

Returns:An EmberStatus error if the standalone bootloader is not present, or EMBER_SUCCESS.

EmberStatus halInternalStandaloneBootloaderTrap ( int16u assumedBootloaderType, int8u trapNumber, ...

)

Calls the bootloader trap functions and may be used for either the stand-alone or application bootloader. Each trap function has a wrapper macro in hal/micro/.../.../micro.h. Use the wrapper functions under normal circumstances because they improve readability and automatically check for bootloader type.

Parameters:assumedBootloaderType There are different traps for the stand-alone and application bootloaders.

This guards against calling a trap from the wrong bootloader type.trapNumber Trap identifier.... Parameter list corresponding to the trap.

Returns:An error if the trap identifier is invalid, or EMBER_SUCCESS.

void halInternalAdjustFlashBlock ( int16u * dst, int16u * src,

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__alone__bootload.htm (4 of 5) [10/29/2010 2:43:06 PM]

241

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 242: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Stand-Alone Bootloader Interface

int8u size )

Modifies a block of flash without losing existing data.

Note:dst and size may be set so that they span multiple pages. Any remaining portion of those pages will remain unchanged other than having been erased and rewritten.

Parameters:dst Byte address pointer. Must be an even address and within the first 64k bytes of flash address

space. Usually use to point to the beginning of a flash block.src Byte address pointer. Must be within the first 64k bytes of flash address space.size Size of block, in words. Must be 0 to 128.

EmberStatus halLaunchStandaloneBootloaderV1 ( int8u mode, int8u * eui64

)

Quits the current application and launches the stand-alone bootloader (if installed) in a non-over-the-air mode (usually the serial port). The function returns an error if the stand-alone bootloader is not present.

Parameters:mode Controls the mode in which the standalone bootloader will run. See the app. note for full

details. Options are:�❍ BOOTLOADER_MODE_MENU: Allow user to upload an image via XMODEM, either

to the current node or via single hop over the air passthrough mode.�❍ BOOTLOADER_MODE_PASSTHROUGH_RECOVERY: Special mode to allow

uploading an image over the air to a node that has been lost as a result of an unsuccessful bootload.

�❍ BOOTLOADER_MODE_CLONE: Upload the current node image to the new node.�❍ BOOTLOADER_MODE_CLONE_RECOVERY: Special mode to allow cloning of

the current node's image to a node that has been lost as a result of an unsuccessful bootload.

eui64 For BOOTLOADER_MODE_CLONE and BOOTLOADER_MODE_MENU, this parameter specifies the EUI64 of the other node for single hop over the air bootloading.

Returns:An error if the stand-alone bootloader is not present, or EMBER_SUCCESS.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__alone__bootload.htm (5 of 5) [10/29/2010 2:43:06 PM]

242

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 243: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Stand-Alone Bootloader for EZSP

Stand-Alone Bootloader for EZSP [Bootloading]

Detailed Description

All functions and variables defined here can be used by applications. See bootload-ezsp-utils.h for source code.

Defines

#define TICKS_PER_QUARTER_SECOND

Functions

boolean hostBootloadUtilLaunchRequestHandler (int8u lqi, int8s rssi, int16u manufacturerId, int8u *hardwareTag, EmberEUI64 sourceEui)

void hostBootloadUtilQueryResponseHandler (int8u lqi, int8s rssi, boolean bootloaderActive, int16u manufacturerId, int8u *hardwareTag, EmberEUI64 targetEui, int8u bootloaderCapabilities, int8u platform, int8u micro, int8u phy, int16u blVersion)

void hostBootloadReinitHandler (void)boolean isTheSameEui64 (EmberEUI64 sourceEui, EmberEUI64 targetEui)

void printLittleEndianEui64 (int8u port, EmberEUI64 eui64)void printBigEndianEui64 (int8u port, EmberEUI64 eui64)

EmberStatus debugPrintf (int8u port, PGM_P formatString,...)

Variables

int16u nodeBlVersionint8u nodePlatint8u nodeMicroint8u nodePhy

EzspStatus bootloadEzspLastErrorEzspStatus ignoreNextEzspError

Define Documentation

#define TICKS_PER_QUARTER_SECOND

Definition at line 23 of file bootload-ezsp-utils.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxyg...PI_EM260_forPDF/group__Standalone__bootload__EZSP.htm (1 of 5) [10/29/2010 2:43:07 PM]

243

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 244: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Stand-Alone Bootloader for EZSP

Function Documentation

boolean hostBootloadUtilLaunchRequestHandler ( int8u lqi, int8s rssi, int16u manufacturerId, int8u * hardwareTag, EmberEUI64 sourceEui

)

A callback function invoked by bootload-ezsp-utils when a bootload launch request message is received.

The application may choose whether or not to enter the bootloader by checking the manufacturerId, hardwareTag, and sourceEui. If the application chooses to launch the bootloader, the bootloader will launch after successful completion of the bootloader launch authentication protocol.

Parameters:lqi The link quality from the node that generated this bootload launch request.rssi The energy level (in units of dBm) observed during the reception.manufacturerId The manufacturer specification (vendor specific) of the sending node.hardwareTag The hardware specification (vendor specific) of the sending node.sourceEui The EUI64 of the sending node.

Returns:TRUE if the application wishes to launch the bootloader, FALSE if the application does not wish to launch the bootloader.

void hostBootloadUtilQueryResponseHandler ( int8u lqi, int8s rssi, boolean bootloaderActive, int16u manufacturerId, int8u * hardwareTag, EmberEUI64 targetEui, int8u bootloaderCapabilities, int8u platform, int8u micro, int8u phy, int16u blVersion

file:///C|/dev/perforce/software/v2/tephra-park/doxyg...PI_EM260_forPDF/group__Standalone__bootload__EZSP.htm (2 of 5) [10/29/2010 2:43:07 PM]

244

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 245: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Stand-Alone Bootloader for EZSP

)

A callback function invoked by bootload-ezsp-utils when a bootload query response message is received.

This is particularly useful when the application needs to decide which node to bootload. Several attributes of the responding node are provided to the application. The application can use these attributes to decide whether to bootload or how to bootload a given node.

Parameters:lqi The link quality from the node that generated this bootload query response.rssi The energy level (in units of dBm) observed during the reception.bootloaderActive TRUE if the responding node is running the bootloader, FALSE if not.manufacturerId The manufacturer specification (vendor specific) of the responding node.hardwareTag The hardware specification (vendor specific) of the responding node.targetEui The EUI64 of the responding node.bootloaderCapabilities If the lsb is 1, the bootloader on the responding node supports encrypted

bootloader message payloads.platform The type of platform of the responding node. 1 is avr-atmega, 2 is xap2b.micro The type of microcontroller on the responding node. Value depends on

platform. 1 is the avr-atmega 64, 2 is the avr-atmega 128, 1 is the xap2b em250.

phy The type of phy of the responding node. 1 is em2420, 2 is em250.blVersion The version of standalone bootloader of the responding node. This is a 2

byte field. The high byte is the version and the low byte is the build. A value of 0xFFFF means unknown. For example, a version field of 0x1234 is version 1.2, build 34.

void hostBootloadReinitHandler ( void )

A callback function invoked by bootload-ezsp-utils when a NCP has finished being bootloaded.

The application can handle this as simply as calling on halReboot() or as complex as needed.

boolean isTheSameEui64 ( EmberEUI64 sourceEui, EmberEUI64 targetEui

)

A function to compare EUI64s.

Compare two EUI64s.

Parameters:sourceEui The EUI64 of the sending node.targetEui The EUI64 of the responding node.

file:///C|/dev/perforce/software/v2/tephra-park/doxyg...PI_EM260_forPDF/group__Standalone__bootload__EZSP.htm (3 of 5) [10/29/2010 2:43:07 PM]

245

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 246: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Stand-Alone Bootloader for EZSP

Returns:TRUE if the EUI64s are the same. FALSE if the EUI64s are different.

void printLittleEndianEui64 ( int8u port, EmberEUI64 eui64

)

A function to display an EUI64.

Display an EUI64 in little endian format.

Parameters:port The serial port to use. 0 for Mega128 port. 0 or 1 for Linux ports.eui64 The EUI64 to display.

void printBigEndianEui64 ( int8u port, EmberEUI64 eui64

)

A function to display an EUI64.

Display an EUI64 in big endian format.

Parameters:port The serial port to use. 0 for Mega128 port. 0 or 1 for Linux ports.eui64 The EUI64 to display.

EmberStatus debugPrintf ( int8u port, PGM_P formatString, ...

)

A function to simular to emberSerialPrintf().

Output to local ports.

Parameters:port The serial port to use. 0 for Mega128 port. 0 or 1 for Linux ports.formatString The string to print.... Format specifiers.

file:///C|/dev/perforce/software/v2/tephra-park/doxyg...PI_EM260_forPDF/group__Standalone__bootload__EZSP.htm (4 of 5) [10/29/2010 2:43:07 PM]

246

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 247: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Stand-Alone Bootloader for EZSP

Returns:One of the following (see the Main Page):

�❍ EMBER_SERIAL_TX_OVERFLOW indicates that data was dropped.�❍ EMBER_NO_BUFFERS indicates that there was an insufficient number of available stack

buffers.�❍ EMBER_SUCCESS.

Variable Documentation

int16u nodeBlVersion

int8u nodePlat

int8u nodeMicro

int8u nodePhy

EzspStatus bootloadEzspLastError

EzspStatus ignoreNextEzspError

file:///C|/dev/perforce/software/v2/tephra-park/doxyg...PI_EM260_forPDF/group__Standalone__bootload__EZSP.htm (5 of 5) [10/29/2010 2:43:07 PM]

247

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 248: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Stand-Alone Bootloader Library

Stand-Alone Bootloader Library [Bootloading]

Detailed Description

All functions and variables defined here can be used by applications. See bootload-utils.h for source code.

Applications can use this stand-alone bootload library to:

1. Load a new (application) image on itself via serial bootload through uart port 1 using the xmodem protocol.2. Load a new image on a remote node over-the-air (OTA) from a host (PC), also known as a passthru bootload.3. Recover a node that failed during the bootloading process, also known as a recovery bootload.

Note from the diagrams below that with over-the-air bootloading the source node (node transmitting bootload packets) and the target node (node being loaded with a new image) need to be one hop away because bootload packets are IEEE 802.15.4 packets.

In case of recovery, the source (recovery) node does not need to be part of the network since all recovery packets are 802.15.4 packets.

A diagram for typical serial bootloading:

[host pc] --(RS232 or Ethernet/IP network)-- {uart1 or port 4901}[node]

A diagram for typical passthru bootloading:

[host pc] --(RS232 or Ethernet)-- [source node]--(OTA)--[target node]

A diagram for typical recovery bootloading:

[source node] --(OTA)--[target node]

Note:Applications that use the bootload utilities need to #define EMBER_APPLICATION_HAS_BOOTLOAD_HANDLERS within their CONFIGURATION_HEADER .

Bootload State Variables

Used to check whether a bootloading process is currently happening.

bootloadState blState#define IS_BOOTLOADING

Authentication Challenge and Response

The authentication challenge and response must be the same size. The size is chosen to be evenly divisible by the size of a 128-bit AES block.

#define BOOTLOAD_AUTH_COMMON_SIZE#define BOOTLOAD_AUTH_CHALLENGE_SIZE#define BOOTLOAD_AUTH_RESPONSE_SIZE

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__Standalone__bootload.htm (1 of 6) [10/29/2010 2:43:08 PM]

248

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 249: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Stand-Alone Bootloader Library

Defines

#define BOOTLOAD_HARDWARE_TAG_SIZE

Enumerations

enum bootloadMode { BOOTLOAD_MODE_NONE, BOOTLOAD_MODE_PASSTHRU }

enum bootloadState { BOOTLOAD_STATE_NORMAL, BOOTLOAD_STATE_QUERY, BOOTLOAD_STATE_WAIT_FOR_AUTH_CHALLENGE, BOOTLOAD_STATE_WAIT_FOR_AUTH_RESPONSE, BOOTLOAD_STATE_DELAY_BEFORE_START, BOOTLOAD_STATE_START_UNICAST_BOOTLOAD, BOOTLOAD_STATE_START_BROADCAST_BOOTLOAD, BOOTLOAD_STATE_START_SENDING_IMAGE, BOOTLOAD_STATE_SENDING_IMAGE, BOOTLOAD_STATE_WAIT_FOR_IMAGE_ACK, BOOTLOAD_STATE_WAIT_FOR_COMPLETE_ACK, BOOTLOAD_STATE_DONE }

Functions

void bootloadUtilInit (int8u appPort, int8u bootloadPort)EmberStatus bootloadUtilSendRequest (EmberEUI64 targetEui, int16u mfgId, int8u hardwareTag

[BOOTLOAD_HARDWARE_TAG_SIZE], int8u encryptKey[BOOTLOAD_AUTH_COMMON_SIZE], bootloadMode mode)void bootloadUtilSendQuery (EmberEUI64 target)void bootloadUtilStartBootload (EmberEUI64 target, bootloadMode mode)void bootloadUtilTick (void)

boolean bootloadUtilLaunchRequestHandler (int16u manufacturerId, int8u hardwareTag[BOOTLOAD_HARDWARE_TAG_SIZE], EmberEUI64 sourceEui)

void bootloadUtilQueryResponseHandler (boolean bootloaderActive, int16u manufacturerId, int8u hardwareTag[BOOTLOAD_HARDWARE_TAG_SIZE], EmberEUI64 targetEui, int8u bootloaderCapabilities, int8u platform, int8u micro, int8u phy, int16u blVersion)

void bootloadUtilSendAuthResponse (EmberEUI64 target)

Define Documentation

#define BOOTLOAD_AUTH_COMMON_SIZE

Definition at line 66 of file bootload-utils.h.

#define BOOTLOAD_AUTH_CHALLENGE_SIZE

Definition at line 67 of file bootload-utils.h.

#define BOOTLOAD_AUTH_RESPONSE_SIZE

Definition at line 68 of file bootload-utils.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__Standalone__bootload.htm (2 of 6) [10/29/2010 2:43:08 PM]

249

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 250: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Stand-Alone Bootloader Library

#define BOOTLOAD_HARDWARE_TAG_SIZE

Size of hardware tag which is an array of int8u.

Definition at line 76 of file bootload-utils.h.

#define IS_BOOTLOADING

Definition at line 300 of file bootload-utils.h.

Enumeration Type Documentation

enum bootloadMode

Bootload modes supported by the bootload utility library.

Enumerator: BOOTLOAD_MODE_NONE Used when we are not currently doing any bootloading. BOOTLOAD_MODE_PASSTHRU Used when doing normal and recovery passthru

bootload.

Definition at line 82 of file bootload-utils.h.

enum bootloadState

A bootload state is a value that an application can check to see if bootloading is in progress.

This is necessary because we want the application to be aware that bootloading is going on and it needs to limit its activities. For example, when passthru bootloading is going on, do not print anything to a serial port because it may violate the XModem protocol. Also, try to limit radio activities to a minimum to avoid any interruptions to bootload progress. Used in a bootload state machine.

Enumerator: BOOTLOAD_STATE_NORMAL Start state BOOTLOAD_STATE_QUERY After send query message BOOTLOAD_STATE_WAIT_FOR_AUTH_CHALLENGE Wait for authentication challenge BOOTLOAD_STATE_WAIT_FOR_AUTH_RESPONSE Wait for authentication response BOOTLOAD_STATE_DELAY_BEFORE_START Delay state before start new action BOOTLOAD_STATE_START_UNICAST_BOOTLOAD After start unicast bootloading BOOTLOAD_STATE_START_BROADCAST_BOOTLOAD After start broadcast bootloading BOOTLOAD_STATE_START_SENDING_IMAGE Need to start XMODEM code BOOTLOAD_STATE_SENDING_IMAGE During sending OTA data

messages BOOTLOAD_STATE_WAIT_FOR_IMAGE_ACK Wait for OTA data ack BOOTLOAD_STATE_WAIT_FOR_COMPLETE_ACK Wait for OTA end transmission ack BOOTLOAD_STATE_DONE Finish bootloading

Definition at line 106 of file bootload-utils.h.

Function Documentation

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__Standalone__bootload.htm (3 of 6) [10/29/2010 2:43:08 PM]

250

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 251: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Stand-Alone Bootloader Library

void bootloadUtilInit ( int8u appPort, int8u bootloadPort

)

Bootload library initialization.

The application needs to define the ports to be used for printing information and for a (passthru) bootload.

Note:Generally it's a good idea to use different ports for the application and for bootloading because when doing passthru bootloading, we do not want to print any additional data that can cause an XModem transaction to fail.

Parameters:appPort Port used for printing information. bootloadPort Port used for passthru

bootloading.

EmberStatus bootloadUtilSendRequest ( EmberEUI64 targetEui, int16u mfgId, int8u hardwareTag[BOOTLOAD_HARDWARE_TAG_SIZE], int8u encryptKey[BOOTLOAD_AUTH_COMMON_SIZE], bootloadMode mode

)

Start the bootload process on a remote node that is currently running stack/application.

The source node sends a bootload request message to initiate the bootload authentication process. The source node then enters a state waiting for the target node to send an authentication challenge, which it will encrypt and send back as a response. MfgId and harwareTag information is sent over the air to the target node to verify whether to go into bootload mode. The encryption key is saved on the source node for later authentication. The mode indicates the bootload mode that the source will be using.

Parameters:targetEui Node to be bootloaded. mfgId Manufacturer ID (vendor specific). hardwareTag Hardware ID, such as a board (vendor

specific). encryptKey Key used in the authentication process. mode Bootload mode to be used is passthru (0x01).

Returns:EMBER_SUCESS if successful, or EMBER_NO_BUFFERS, or EMBER_ERR_FATAL if the function was called too soon after a previous call to it.

void bootloadUtilSendQuery ( EmberEUI64 target )

A function to send query message to gather basic information about the node(s).

There are two types of query messages: broadcast and unicast. Broadcast query is generally used to gather information regarding a neighboring node, especially the eui64 of the node. Unicast query is used when we already know the eui64 of the target node that we needs information from.

Parameters:

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__Standalone__bootload.htm (4 of 6) [10/29/2010 2:43:08 PM]

251

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 252: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Stand-Alone Bootloader Library

target The node we want to gather information from. If the value is NULL, that means we want to do a broadcast query.

void bootloadUtilStartBootload ( EmberEUI64 target, bootloadMode mode

)

Start the bootload process on a remote node that is already running in bootload mode.

This is generally to recover a node that failed during bootload. The failure can be caused by the source node resetting, the network being too busy, a software reset, and so on. However, the failure is not caused by a target node losing power. After the failure, the node stays in bootload mode on the same (current) channel.

Parameters:target remote node to be bootloaded. If the value is NULL, that means we do not know the eui64 of the target node. A

broadcast (start bootload) packet is sent and the first node that replies will be bootloaded. mode bootload mode to be used, such as passthru (0x01).

void bootloadUtilTick ( void )

A function in the application's heartbeat or tick function that contains basic bootloading state machine and also manages the bootload timer.

boolean bootloadUtilLaunchRequestHandler ( int16u manufacturerId, int8u hardwareTag[BOOTLOAD_HARDWARE_TAG_SIZE], EmberEUI64 sourceEui

)

A callback function invoked by bootload-utils when a bootload request message is received.

The application may choose whether or not to enter the bootloader by checking the manufacturerId, hardwareTag, and sourceEui. If the application chooses to launch the bootloader, the bootloader will launch after successful completion of the bootloader launch authentication protocol.

Parameters:manufacturerId The manufacturer specification (vendor specific) of the sending

node. hardwareTag The hardware specification (vendor specific) of the sending node. sourceEui The EUI64 of the sending node.

Returns:TRUE if the application wishes to launch the bootloader, FALSE if the application does not wish to launch the bootloader.

void bootloadUtilQueryResponseHandler ( boolean bootloaderActive, int16u manufacturerId, int8u hardwareTag[BOOTLOAD_HARDWARE_TAG_SIZE], EmberEUI64 targetEui, int8u bootloaderCapabilities, int8u platform, int8u micro, int8u phy,

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__Standalone__bootload.htm (5 of 6) [10/29/2010 2:43:08 PM]

252

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 253: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Stand-Alone Bootloader Library

int16u blVersion )

A callback function invoked by bootload-utils when a bootload query response message is received.

This is particularly useful when the application needs to decide which node to bootload. Several attributes of the responding node are provided to the application. The application can use these attributes to decide whether to bootload or how to bootload a given node.

Parameters:bootloaderActive TRUE if the responding node is running the bootloader, FALSE if not. manufacturerId The manufacturer specification (vendor specific) of the responding node. hardwareTag The hardware specification (vendor specific) of the responding node. targetEui The EUI64 of the responding node. bootloaderCapabilities If the lsb is 1, the bootloader on the responding node supports encrypted bootloader message payloads. platform The type of platform of the responding node. 1 is avr-atmega, 2 is xap2b. micro The type of microcontroller on the responding node. Value depends on platform. 1 is the avr-atmega 64, 2

is the avr-atmega 128, 1 is the xap2b em250. phy The type of phy of the responding node. 1 is em2420, 2 is em250. blVersion The version of standalone bootloader of the responding node. This is a 2 byte field. The high byte is the

version and the low byte is the build. A value of 0xFFFF means unknown. For example, a version field of 0x1234 is version 1.2, build 34.

void bootloadUtilSendAuthResponse ( EmberEUI64 target )

A function called by a parent node to send an authentication response message to the sleepy or mobile end-device target node.

The message is sent as a Just-In-Time (JIT) message, hence, the end-device target needs to poll for the message.

The bootload utility library will call this function automatically if bootloading the router node.

Parameters:target The end-device target node being

bootloaded.

Variable Documentation

bootloadState blState

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__Standalone__bootload.htm (6 of 6) [10/29/2010 2:43:08 PM]

253

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 254: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Command Interpreter

Command Interpreter [Application Utilities API Reference]

Detailed Description

Interpret serial port commands. See command-interpreter.h for source code.

See the following application usage example followed by a brief explanation.

static EmberCommandEntry commands[] = { { "integers", integersCommand, "u1u2s1s2", "integers"}, { "intlist", intListCommand, "u1*", "intlist"}, { "stringlist", stringListCommand, "bb*", "stringlist"}, { NULL, NULL, NULL, NULL}}; // NULL action makes this a terminator

static void commandErrorHandler(EmberCommandState *state) { // ... }

ArgTypeU arguments[4]; EmberCommandState testState = { commands, commandErrorHandler, arguments, 4, // maximum command arguments 10 // integer base };

emberCommandReaderInit(&testState);

1. Applications specify the commands that can be interpreted by defining a commands table of type EmberCommandEntry. The table includes the following information for each command:

a. The full command name.b. Your application's function name that implements the command.c. An EmberCommandEntry::argumentTypes string specifies the number and types of

arguments the command accepts. See argumentTypes for details.d. A description string explains the command.

2. Applications also need to define a command error handler to deal with incorrect command input.3. The command table, the error handler, and other command interpreter state information are bundled

into an EmberCommandState structure. Using a structure allows commands to be read from

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__commands.htm (1 of 6) [10/29/2010 2:43:09 PM]

254

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 255: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Command Interpreter

multiple sources.4. The application provides an instance of the EmberCommandState structure to the interpreter by

calling emberCommandReaderInit().

Data Structures

struct EmberCommandEntry Command entry for a command table. More...

struct EmberCommandStateS

The command state structure. Using a structure allows commands to be read from multiple sources. More...

Command Table Settings

#define EMBER_COMMENT_CHARACTER#define EMBER_MAX_COMMAND_LENGTH

Macros to Retrieve Arguments

Use the following macros in your functions that process commands to retrieve arguments from the command interpreter state object. These macros pull out unsigned integers, signed integers, and buffers.

#define emberUnsignedCommandArgument(state, index)#define emberSignedCommandArgument(state, index)#define emberBufferCommandArgument(state, index)

Defines

#define TEMP_GREATER_THAN_MAX_ARG_SIZE#define PERFORM_BOUNDS_CHECKING#define emberProcessCommandInput(state, port)#define emberCommandName(state)

Typedefs

typedef int16u ArgTypeUtypedef void(*) CommandAction (struct EmberCommandStateS *state)

typedef EmberCommandStateS EmberCommandState

Enumerations

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__commands.htm (2 of 6) [10/29/2010 2:43:09 PM]

255

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 256: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Command Interpreter

enum EmberCommandStatus { EMBER_CMD_SUCCESS, EMBER_CMD_ERR_PORT_PROBLEM, EMBER_CMD_ERR_NO_BUFFER_AVAILABLE, EMBER_CMD_ERR_NO_SUCH_COMMAND, EMBER_CMD_ERR_WRONG_COMMAND_ARGUMENTS, EMBER_CMD_ERR_TOO_MANY_COMMAND_ARGUMENTS, EMBER_CMD_ERR_ARGUMENT_OUT_OF_RANGE, EMBER_CMD_ERR_ARGUMENT_SYNTAX_ERROR, EMBER_CMD_ERR_STRING_TOO_LONG, EMBER_CMD_ERR_NO_BINARY_STRING_TERMINATOR }

Functions

void emberCommandReaderInit (EmberCommandState *state)boolean emberProcessCommandString (EmberCommandState *state, int8u

*input, int8u size)

Variables

PGM_NO_CONST PGM_P emberCommandErrorNames []

Define Documentation

#define EMBER_COMMENT_CHARACTER

The command table's comment indicator. A comment consists of a '#' followed by any characters up to an end-of-line.

Definition at line 72 of file command-interpreter.h.

#define EMBER_MAX_COMMAND_LENGTH

The maximum number of characters in a command.

Definition at line 78 of file command-interpreter.h.

#define TEMP_GREATER_THAN_MAX_ARG_SIZE

Definition at line 94 of file command-interpreter.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__commands.htm (3 of 6) [10/29/2010 2:43:09 PM]

256

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 257: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Command Interpreter

#define PERFORM_BOUNDS_CHECKING

Definition at line 95 of file command-interpreter.h.

#define emberUnsignedCommandArgument ( state, index )

Definition at line 229 of file command-interpreter.h.

#define emberSignedCommandArgument ( state, index )

Definition at line 232 of file command-interpreter.h.

#define emberBufferCommandArgument ( state, index )

Definition at line 235 of file command-interpreter.h.

#define emberProcessCommandInput ( state, port )

A macro that parses any input coming in on the serial port, which returns when no more input is available. This is a wrapper for emberProcessCommandString() with a null string and the port passed in as the string size.

void emberProcessCommandInput(EmberCommandState *state, int8u port);

Definition at line 263 of file command-interpreter.h.

#define emberCommandName ( state )

Return a pointer to the command name being executed.

Parameters:state The command state

structure.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__commands.htm (4 of 6) [10/29/2010 2:43:09 PM]

257

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 258: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Command Interpreter

Definition at line 269 of file command-interpreter.h.

Typedef Documentation

typedef int16u ArgTypeU

// END name group

Definition at line 93 of file command-interpreter.h.

typedef void(*) CommandAction(struct EmberCommandStateS *state)

Definition at line 100 of file command-interpreter.h.

typedef struct EmberCommandStateS EmberCommandState

The command state structure. Using a structure allows commands to be read from multiple sources.

Enumeration Type Documentation

enum EmberCommandStatus

Command error states.

If you change this list, ensure you also change the strings that describe these errors in the array emberCommandErrorNames[] in command-interpreter.c.

Enumerator: EMBER_CMD_SUCCESS no error EMBER_CMD_ERR_PORT_PROBLEM serial port error EMBER_CMD_ERR_NO_BUFFER_AVAILABLE command processor busy EMBER_CMD_ERR_NO_SUCH_COMMAND no such command EMBER_CMD_ERR_WRONG_COMMAND_ARGUMENTS incorrect command arguments EMBER_CMD_ERR_TOO_MANY_COMMAND_ARGUMENTS too many command arguments EMBER_CMD_ERR_ARGUMENT_OUT_OF_RANGE integer argument out of range EMBER_CMD_ERR_ARGUMENT_SYNTAX_ERROR argument syntax error

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__commands.htm (5 of 6) [10/29/2010 2:43:09 PM]

258

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 259: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Command Interpreter

EMBER_CMD_ERR_STRING_TOO_LONG message too long EMBER_CMD_ERR_NO_BINARY_STRING_TERMINATOR missing binary message

terminator

Definition at line 151 of file command-interpreter.h.

Function Documentation

void emberCommandReaderInit ( EmberCommandState * state )

Initialize a command state.

Parameters:state The command state

structure.

boolean emberProcessCommandString ( EmberCommandState * state, int8u * input, int8u size

)

Parses 'size' characters from 'input'.

Returns:TRUE if an end of line character was read. If the application uses a command line prompt, this indeicates it is time to print the prompt.

Variable Documentation

PGM_NO_CONST PGM_P emberCommandErrorNames[]

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__commands.htm (6 of 6) [10/29/2010 2:43:09 PM]

259

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 260: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ZigBee Device Object (ZDO) Information

ZigBee Device Object (ZDO) Information [Application Utilities API Reference]

Detailed Description

For getting information about nodes of a ZigBee network via a ZigBee Device Object (ZDO). See zigbee-device-host.h and zigbee-device-common.h for source code.

The ZDO library provides functions that construct and send several common ZDO requests. It also provides a function for extracting the two addresses from a ZDO address response. The format of all the ZDO requests and responses that the stack supports is described in stack/include/zigbee-device-stack.h. Since the library doesn't handle all of these requests and responses, the application must construct any other requests it wishes to send and decode any other responses it wishes to receive.

The request sending functions do the following:

1. Construct a correctly formatted payload buffer.2. Fill in the APS frame with the correct values.3. Send the message by calling either ezspSendBroadcast() or ezspSendUnicast().

The result of the send is reported to the application as normal via ezspMessageSentHandler().

The following code shows an example of an application's use of emberSimpleDescriptorRequest(). The command interpreter would call this function and supply the arguments.

void sendSimpleDescriptorRequest(EmberCommandState *state) { EmberNodeId target = emberUnsignedCommandArgument(state, 0); int8u targetEndpoint = emberUnsignedCommandArgument(state, 1); if (emberSimpleDescriptorRequest(target, targetEndpoint, EMBER_APS_OPTION_NONE) != EMBER_SUCCESS) { emberSerialPrintf(SERIAL_PORT, "emberSimpleDescriptorRequest failed\r\n"); } }

The following code shows an example of an application's use of ezspDecodeAddressResponse().

void ezspIncomingMessageHandler(EmberIncomingMessageType type, EmberApsFrame *apsFrame, int8u lastHopLqi, int8s lastHopRssi,

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__util__zdo.htm (1 of 13) [10/29/2010 2:43:11 PM]

260

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 261: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ZigBee Device Object (ZDO) Information

EmberNodeId sender, int8u bindingIndex, int8u addressIndex, int8u messageLength, int8u *messageContents) { if (apsFrame->profileId == EMBER_ZDO_PROFILE_ID) { switch (apsFrame->clusterId) { case NETWORK_ADDRESS_RESPONSE: case IEEE_ADDRESS_RESPONSE: { EmberEUI64 eui64; EmberNodeId nodeId = ezspDecodeAddressResponse(messageContents, eui64); // Use nodeId and eui64 here. break; } default: // Handle other incoming ZDO responses here. } } else { // Handle incoming application messages here. } }

Modules

ZigBee Device Object

Device Discovery Functions

EmberStatus emberNetworkAddressRequest (EmberEUI64 target, boolean reportKids, int8u childStartIndex)

EmberStatus emberIeeeAddressRequest (EmberNodeId target, boolean reportKids, int8u childStartIndex, EmberApsOption options)

Service Discovery Functions

EmberStatus ezspMatchDescriptorsRequest (EmberNodeId target, int16u profile, int8u inCount, int8u outCount, int16u *inClusters, int16u *outClusters, EmberApsOption options)

Binding Manager Functions

EmberStatus ezspEndDeviceBindRequest (EmberNodeId localNodeId, EmberEUI64 localEui64, int8u endpoint, int16u profile, int8u inCount, int8u outCount, int16u *inClusters, int16u *outClusters, EmberApsOption options)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__util__zdo.htm (2 of 13) [10/29/2010 2:43:11 PM]

261

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 262: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ZigBee Device Object (ZDO) Information

Function to Decode Address Response Messages

EmberNodeId ezspDecodeAddressResponse (int8u *response, EmberEUI64 eui64Return)

Service Discovery Functions

EmberStatus emberNodeDescriptorRequest (EmberNodeId target, EmberApsOption options)EmberStatus emberPowerDescriptorRequest (EmberNodeId target, EmberApsOption options)EmberStatus emberSimpleDescriptorRequest (EmberNodeId target, int8u targetEndpoint,

EmberApsOption options)EmberStatus emberActiveEndpointsRequest (EmberNodeId target, EmberApsOption options)

Binding Manager Functions

EmberStatus emberBindRequest (EmberNodeId target, EmberEUI64 source, int8u sourceEndpoint, int16u clusterId, int8u type, EmberEUI64 destination, EmberMulticastId groupAddress, int8u destinationEndpoint, EmberApsOption options)

EmberStatus emberUnbindRequest (EmberNodeId target, EmberEUI64 source, int8u sourceEndpoint, int16u clusterId, int8u type, EmberEUI64 destination, EmberMulticastId groupAddress, int8u destinationEndpoint, EmberApsOption options)

Node Manager Functions

EmberStatus emberLqiTableRequest (EmberNodeId target, int8u startIndex, EmberApsOption options)EmberStatus emberRoutingTableRequest (EmberNodeId target, int8u startIndex, EmberApsOption

options)EmberStatus emberBindingTableRequest (EmberNodeId target, int8u startIndex, EmberApsOption

options)EmberStatus emberLeaveRequest (EmberNodeId target, EmberEUI64 deviceAddress, int8u

leaveRequestFlags, EmberApsOption options)EmberStatus emberPermitJoiningRequest (EmberNodeId target, int8u duration, int8u authentication,

EmberApsOption options)void emberSetZigDevRequestRadius (int8u radius)

int8u emberGetZigDevRequestRadius (void)int8u emberGetLastZigDevRequestSequence (void)

Defines

#define ZDO_MESSAGE_OVERHEAD

Define Documentation

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__util__zdo.htm (3 of 13) [10/29/2010 2:43:11 PM]

262

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 263: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ZigBee Device Object (ZDO) Information

#define ZDO_MESSAGE_OVERHEAD

ZDO messages start with a sequence number.

Definition at line 16 of file zigbee-device-common.h.

Function Documentation

EmberStatus emberNetworkAddressRequest ( EmberEUI64 target, boolean reportKids, int8u childStartIndex

)

Request the 16 bit network address of a node whose EUI64 is known.

Parameters:target The EUI64 of the node. reportKids TRUE to request that the target list their children in the response. childStartIndex The index of the first child to list in the response. Ignored if reportKids is

FALSE.

Returns:An EmberStatus value.

�❍ EMBER_SUCCESS - The request was transmitted successfully.�❍ EMBER_NO_BUFFERS - Insuffient message buffers were available to construct the

request.�❍ EMBER_NETWORK_DOWN - The node is not part of a network.�❍ EMBER_NETWORK_BUSY - Transmission of the request failed.

EmberStatus emberIeeeAddressRequest ( EmberNodeId target, boolean reportKids, int8u childStartIndex, EmberApsOption options

)

Request the EUI64 of a node whose 16 bit network address is known.

Parameters:

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__util__zdo.htm (4 of 13) [10/29/2010 2:43:11 PM]

263

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 264: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ZigBee Device Object (ZDO) Information

target The network address of the node. reportKids TRUE to request that the target list their children in the response. childStartIndex The index of the first child to list in the response. Ignored if reportKids is FALSE. options The options to use when sending the request. See emberSendUnicast() for a

description.

Returns:An EmberStatus value.

�❍ EMBER_SUCCESS�❍ EMBER_NO_BUFFERS�❍ EMBER_NETWORK_DOWN�❍ EMBER_NETWORK_BUSY

EmberStatus ezspMatchDescriptorsRequest ( EmberNodeId target, int16u profile, int8u inCount, int8u outCount, int16u * inClusters, int16u * outClusters, EmberApsOption options

)

Request the specified node to send a list of its endpoints that match the specified application profile and, optionally, lists of input and/or output clusters.

Parameters:target The node whose matching endpoints are desired. The request can be broadcast by

using a broadcast address (0xFFFC/0xFFFD/0xFFFF). Any node that has matching endpoints will send a response.

profile The application profile to match. inCount The number of input clusters. To not match any input clusters, set this value to 0. outCount The number of output clusters. To not match any output clusters, set this value to 0. inClusters The list of input clusters. outClusters The list of output clusters. options The options to use when sending the unicast request. See emberSendUnicast() for

a description. This parameter is ignored if the target is a broadcast address.

Returns:An EmberStatus value. EMBER_SUCCESS, EMBER_NO_BUFFERS, EMBER_NETWORK_DOWN or EMBER_NETWORK_BUSY.

EmberStatus ezspEndDeviceBindRequest ( EmberNodeId localNodeId,

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__util__zdo.htm (5 of 13) [10/29/2010 2:43:11 PM]

264

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 265: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ZigBee Device Object (ZDO) Information

EmberEUI64 localEui64, int8u endpoint, int16u profile, int8u inCount, int8u outCount, int16u * inClusters, int16u * outClusters, EmberApsOption options

)

An end device bind request to the coordinator. If the coordinator receives a second end device bind request then a binding is created for every matching cluster.

Parameters:localNodeId The node ID of the local device. localEui64 The EUI64 of the local device. endpoint The endpoint to be bound. profile The application profile of the endpoint. inCount The number of input clusters. outCount The number of output clusters. inClusters The list of input clusters. outClusters The list of output clusters. options The options to use when sending the request. See emberSendUnicast() for a

description.

Returns:An EmberStatus value. EMBER_SUCCESS, EMBER_NO_BUFFERS, EMBER_NETWORK_DOWN or EMBER_NETWORK_BUSY.

EmberNodeId ezspDecodeAddressResponse ( int8u * response, EmberEUI64 eui64Return

)

Extracts the EUI64 and the node ID from an address response message.

Parameters:response The received ZDO message with cluster ID NETWORK_ADDRESS_RESPONSE

or IEEE_ADDRESS_RESPONSE. eui64Return The EUI64 from the response is copied here.

Returns:Returns the node ID from the response if the response status was EMBER_ZDP_SUCCESS.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__util__zdo.htm (6 of 13) [10/29/2010 2:43:11 PM]

265

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 266: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ZigBee Device Object (ZDO) Information

Otherwise, returns EMBER_NULL_NODE_ID.

EmberStatus emberNodeDescriptorRequest ( EmberNodeId target, EmberApsOption options

)

Request the specified node to send its node descriptor. The node descriptor contains information about the capabilities of the ZigBee node. It describes logical type, APS flags, frequency band, MAC capabilities flags, manufacturer code and maximum buffer size. It is defined in the ZigBee Application Framework Specification.

Parameters:target The node whose node descriptor is desired. options The options to use when sending the request. See emberSendUnicast() for a

description.

Returns:An EmberStatus value. EMBER_SUCCESS, EMBER_NO_BUFFERS, EMBER_NETWORK_DOWN or EMBER_NETWORK_BUSY.

EmberStatus emberPowerDescriptorRequest ( EmberNodeId target, EmberApsOption options

)

Request the specified node to send its power descriptor. The power descriptor gives a dynamic indication of the power status of the node. It describes current power mode, available power sources, current power source and current power source level. It is defined in the ZigBee Application Framework Specification.

Parameters:target The node whose power descriptor is desired. options The options to use when sending the request. See emberSendUnicast() for a

description.

Returns:An EmberStatus value. EMBER_SUCCESS, EMBER_NO_BUFFERS, EMBER_NETWORK_DOWN or EMBER_NETWORK_BUSY.

EmberStatus emberSimpleDescriptorRequest ( EmberNodeId target, int8u targetEndpoint, EmberApsOption options

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__util__zdo.htm (7 of 13) [10/29/2010 2:43:11 PM]

266

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 267: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ZigBee Device Object (ZDO) Information

)

Request the specified node to send the simple descriptor for the specified endpoint. The simple descriptor contains information specific to a single endpoint. It describes the application profile identifier, application device identifier, application device version, application flags, application input clusters and application output clusters. It is defined in the ZigBee Application Framework Specification.

Parameters:target The node of interest. targetEndpoint The endpoint on the target node whose simple descriptor is desired. options The options to use when sending the request. See emberSendUnicast() for a

description.

Returns:An EmberStatus value. EMBER_SUCCESS, EMBER_NO_BUFFERS, EMBER_NETWORK_DOWN or EMBER_NETWORK_BUSY.

EmberStatus emberActiveEndpointsRequest ( EmberNodeId target, EmberApsOption options

)

Request the specified node to send a list of its active endpoints. An active endpoint is one for which a simple descriptor is available.

Parameters:target The node whose active endpoints are desired. options The options to use when sending the request. See emberSendUnicast() for a

description.

Returns:An EmberStatus value. EMBER_SUCCESS, EMBER_NO_BUFFERS, EMBER_NETWORK_DOWN or EMBER_NETWORK_BUSY.

EmberStatus emberBindRequest ( EmberNodeId target, EmberEUI64 source, int8u sourceEndpoint, int16u clusterId, int8u type, EmberEUI64 destination, EmberMulticastId groupAddress, int8u destinationEndpoint,

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__util__zdo.htm (8 of 13) [10/29/2010 2:43:11 PM]

267

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 268: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ZigBee Device Object (ZDO) Information

EmberApsOption options )

Send a request to create a binding entry with the specified contents on the specified node.

Parameters:target The node on which the binding will be created. source The source EUI64 in the binding entry. sourceEndpoint The source endpoint in the binding entry. clusterId The cluster ID in the binding entry. type The type of binding, either UNICAST_BINDING,

MULTICAST_BINDING, or UNICAST_MANY_TO_ONE_BINDING. UNICAST_MANY_TO_ONE_BINDING is an Ember-specific extension and should be used only when the target is an Ember device.

destination The destination EUI64 in the binding entry for UNICAST_BINDING or UNICAST_MANY_TO_ONE_BINDING.

groupAddress The group address for the MULTICAST_BINDING. destinationEndpoint The destination endpoint in the binding entry for the UNICAST_BINDING

or UNICAST_MANY_TO_ONE_BINDING. options The options to use when sending the request. See emberSendUnicast() for

a description.

Returns:An EmberStatus value. EMBER_SUCCESS, EMBER_NO_BUFFERS, EMBER_NETWORK_DOWN or EMBER_NETWORK_BUSY.

EmberStatus emberUnbindRequest ( EmberNodeId target, EmberEUI64 source, int8u sourceEndpoint, int16u clusterId, int8u type, EmberEUI64 destination, EmberMulticastId groupAddress, int8u destinationEndpoint, EmberApsOption options

)

Send a request to remove a binding entry with the specified contents from the specified node.

Parameters:target The node on which the binding will be removed.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__util__zdo.htm (9 of 13) [10/29/2010 2:43:11 PM]

268

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 269: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ZigBee Device Object (ZDO) Information

source The source EUI64 in the binding entry. sourceEndpoint The source endpoint in the binding entry. clusterId The cluster ID in the binding entry. type The type of binding, either UNICAST_BINDING,

MULTICAST_BINDING, or UNICAST_MANY_TO_ONE_BINDING. UNICAST_MANY_TO_ONE_BINDING is an Ember-specific extension and should be used only when the target is an Ember device.

destination The destination EUI64 in the binding entry for the UNICAST_BINDING or UNICAST_MANY_TO_ONE_BINDING.

groupAddress The group address for the MULTICAST_BINDING. destinationEndpoint The destination endpoint in the binding entry for the UNICAST_BINDING

or UNICAST_MANY_TO_ONE_BINDING. options The options to use when sending the request. See emberSendUnicast() for

a description.

Returns:An EmberStatus value.

�❍ EMBER_SUCCESS�❍ EMBER_NO_BUFFERS _ EMBER_NETWORK_DOWN�❍ EMBER_NETWORK_BUSY

EmberStatus emberLqiTableRequest ( EmberNodeId target, int8u startIndex, EmberApsOption options

)

Request the specified node to send its LQI (neighbor) table. The response gives PAN ID, EUI64, node ID and cost for each neighbor. The EUI64 is only available if security is enabled. The other fields in the response are set to zero. The response format is defined in the ZigBee Device Profile Specification.

Parameters:target The node whose LQI table is desired. startIndex The index of the first neighbor to include in the response. options The options to use when sending the request. See emberSendUnicast() for a

description.

Returns:An EmberStatus value. EMBER_SUCCESS, EMBER_NO_BUFFERS, EMBER_NETWORK_DOWN or EMBER_NETWORK_BUSY.

EmberStatus emberRoutingTableRequest ( EmberNodeId target, int8u startIndex,

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__util__zdo.htm (10 of 13) [10/29/2010 2:43:11 PM]

269

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 270: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ZigBee Device Object (ZDO) Information

EmberApsOption options )

Request the specified node to send its routing table. The response gives destination node ID, status and many-to-one flags, and the next hop node ID. The response format is defined in the ZigBee Device Profile Specification.

Parameters:target The node whose routing table is desired. startIndex The index of the first route entry to include in the response. options The options to use when sending the request. See emberSendUnicast() for a

description.

Returns:An EmberStatus value. EMBER_SUCCESS, EMBER_NO_BUFFERS, EMBER_NETWORK_DOWN or EMBER_NETWORK_BUSY.

EmberStatus emberBindingTableRequest ( EmberNodeId target, int8u startIndex, EmberApsOption options

)

Request the specified node to send its nonvolatile bindings. The response gives source address, source endpoint, cluster ID, destination address and destination endpoint for each binding entry. The response format is defined in the ZigBee Device Profile Specification. Note that bindings that have the Ember-specific UNICAST_MANY_TO_ONE_BINDING type are reported as having the standard UNICAST_BINDING type.

Parameters:target The node whose binding table is desired. startIndex The index of the first binding entry to include in the response. options The options to use when sending the request. See emberSendUnicast() for a

description.

Returns:An EmberStatus value. EMBER_SUCCESS, EMBER_NO_BUFFERS, EMBER_NETWORK_DOWN or EMBER_NETWORK_BUSY.

EmberStatus emberLeaveRequest ( EmberNodeId target, EmberEUI64 deviceAddress, int8u leaveRequestFlags,

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__util__zdo.htm (11 of 13) [10/29/2010 2:43:11 PM]

270

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 271: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ZigBee Device Object (ZDO) Information

EmberApsOption options )

Request the specified node to remove the specified device from the network. The device to be removed must be the node to which the request is sent or one of its children.

Parameters:target The node which will remove the device. deviceAddress All zeros if the target is to remove itself from the network or the EUI64 of a

child of the target device to remove that child. leaveRequestFlags A bitmask of leave options. Include

LEAVE_REQUEST_REMOVE_CHILDREN_FLAG if the target is to remove their children and/or LEAVE_REQUEST_REJOIN_FLAG if the target is to rejoin the network immediately after leaving.

options The options to use when sending the request. See emberSendUnicast() for a description.

Returns:An EmberStatus value. EMBER_SUCCESS, EMBER_NO_BUFFERS, EMBER_NETWORK_DOWN or EMBER_NETWORK_BUSY.

EmberStatus emberPermitJoiningRequest ( EmberNodeId target, int8u duration, int8u authentication, EmberApsOption options

)

Request the specified node to allow or disallow association.

Parameters:target The node which will allow or disallow association. The request can be broadcast

by using a broadcast address (0xFFFC/0xFFFD/0xFFFF). No response is sent if the request is broadcast.

duration A value of 0x00 disables joining. A value of 0xFF enables joining. Any other value enables joining for that number of seconds.

authentication Controls Trust Center authentication behavior. options The options to use when sending the request. See emberSendUnicast() for a

description. This parameter is ignored if the target is a broadcast address.

Returns:An EmberStatus value. EMBER_SUCCESS, EMBER_NO_BUFFERS, EMBER_NETWORK_DOWN or EMBER_NETWORK_BUSY.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__util__zdo.htm (12 of 13) [10/29/2010 2:43:11 PM]

271

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 272: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ZigBee Device Object (ZDO) Information

void emberSetZigDevRequestRadius ( int8u radius )

Change the default radius for broadcast ZDO requests.

Parameters:radius The radius to be used for future ZDO request

broadcasts.

int8u emberGetZigDevRequestRadius ( void )

Retrieve the default radius for broadcast ZDO requests.

Returns:The radius to be used for future ZDO request broadcasts.

int8u emberGetLastZigDevRequestSequence ( void )

Provide access to the ZDO transaction sequence number for last request.

Returns:Last ZDO transaction sequence number used

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__util__zdo.htm (13 of 13) [10/29/2010 2:43:11 PM]

272

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 273: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ZigBee Device Object

ZigBee Device Object [ZigBee Device Object (ZDO) Information]

Detailed Description

See zigbee-device-stack.h for source code.

Functions

EmberStatus emberNetworkAddressRequest (EmberEUI64 target, boolean reportKids, int8u childStartIndex)

EmberStatus emberIeeeAddressRequest (EmberNodeId target, boolean reportKids, int8u childStartIndex, EmberApsOption options)

EmberStatus emberEnergyScanRequest (EmberNodeId target, int32u scanChannels, int8u scanDuration, int16u scanCount)

EmberStatus emberSetNetworkManagerRequest (EmberNodeId networkManager, int32u activeChannels)EmberStatus emberChannelChangeRequest (int8u channel)EmberStatus emberSendDeviceAnnouncement (void)

Function Documentation

EmberStatus emberNetworkAddressRequest ( EmberEUI64 target, boolean reportKids, int8u childStartIndex

)

Request the 16 bit network address of a node whose EUI64 is known.

Parameters:target The EUI64 of the node. reportKids TRUE to request that the target list their children in the response. childStartIndex The index of the first child to list in the response. Ignored if reportKids is

FALSE.

Returns:An EmberStatus value.

�❍ EMBER_SUCCESS - The request was transmitted successfully.�❍ EMBER_NO_BUFFERS - Insuffient message buffers were available to construct the

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__zdo.htm (1 of 4) [10/29/2010 2:43:12 PM]

273

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 274: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ZigBee Device Object

request.�❍ EMBER_NETWORK_DOWN - The node is not part of a network.�❍ EMBER_NETWORK_BUSY - Transmission of the request failed.

EmberStatus emberIeeeAddressRequest ( EmberNodeId target, boolean reportKids, int8u childStartIndex, EmberApsOption options

)

Request the EUI64 of a node whose 16 bit network address is known.

Parameters:target The network address of the node. reportKids TRUE to request that the target list their children in the response. childStartIndex The index of the first child to list in the response. Ignored if reportKids is FALSE. options The options to use when sending the request. See emberSendUnicast() for a

description.

Returns:An EmberStatus value.

�❍ EMBER_SUCCESS�❍ EMBER_NO_BUFFERS�❍ EMBER_NETWORK_DOWN�❍ EMBER_NETWORK_BUSY

EmberStatus emberEnergyScanRequest ( EmberNodeId target, int32u scanChannels, int8u scanDuration, int16u scanCount

)

Request that an energy scan be performed and its results returned. This request may only be sent by the current network manager and must be unicast, not broadcast.

Parameters:target The network address of the node to perform the scan. scanChannels A mask of the channels to be scanned. scanDuration How long to scan on each channel. Allowed values are 0..5, with the scan times as

specified by 802.15.4 (0 = 31ms, 1 = 46ms, 2 = 77 ms, 3 = 138ms, 4 = 261ms, 5 = 507ms).

scanCount The number of scans to be performed on each channel (1 .. 8).

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__zdo.htm (2 of 4) [10/29/2010 2:43:12 PM]

274

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 275: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ZigBee Device Object

Returns:An EmberStatus value.

�❍ EMBER_SUCCESS�❍ EMBER_NO_BUFFERS�❍ EMBER_NETWORK_DOWN�❍ EMBER_NETWORK_BUSY

EmberStatus emberSetNetworkManagerRequest ( EmberNodeId networkManager, int32u activeChannels

)

Broadcasts a request to set the identity of the network manager and the active channel mask. The mask is used when scanning for the network after missing a channel update.

Parameters:networkManager The network address of the network

manager. activeChannels The new active channel mask.

Returns:An EmberStatus value.

�❍ EMBER_SUCCESS�❍ EMBER_NO_BUFFERS�❍ EMBER_NETWORK_DOWN�❍ EMBER_NETWORK_BUSY

EmberStatus emberChannelChangeRequest ( int8u channel )

Broadcasts a request to change the channel. This request may only be sent by the current network manager. There is a delay of several seconds from receipt of the broadcast to changing the channel, to allow time for the broadcast to propagate.

Parameters:channel The channel to change to.

Returns:An EmberStatus value.

�❍ EMBER_SUCCESS�❍ EMBER_NO_BUFFERS�❍ EMBER_NETWORK_DOWN�❍ EMBER_NETWORK_BUSY

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__zdo.htm (3 of 4) [10/29/2010 2:43:12 PM]

275

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 276: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ZigBee Device Object

EmberStatus emberSendDeviceAnnouncement ( void )

Sends a broadcast for a ZDO Device announcement. Normally it is NOT required to call this as the stack automatically sends a device announcement during joining or rejoing, as per the spec. However if the device wishes to re-send its device announcement they can use this call.

Returns:An EmberStatus value.

�❍ EMBER_SUCCESS�❍ EMBER_INVALID_CALL

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__zdo.htm (4 of 4) [10/29/2010 2:43:12 PM]

276

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 277: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Message Fragmentation

Message Fragmentation [Application Utilities API Reference]

Detailed Description

Fragmented message support for EZSP Hosts. Splits long messages into smaller blocks for transmission and reassembles received blocks. See fragment-host.c for source code.

EZSP_CONFIG_FRAGMENT_WINDOW_SIZE controls how many blocks are sent at a time. EZSP_CONFIG_FRAGMENT_DELAY_MS controls the spacing between blocks.

Before calling any of the other functions listed here, the application must call ezspFragmentInit().

To send a long message, the application calls ezspFragmentSendUnicast(). The application must add a call to ezspFragmentMessageSent() at the start of its ezspMessageSentHandler(). If ezspFragmentMessageSent() returns TRUE, the fragmentation code has handled the event and the application must not process it further. The fragmentation code calls the application-defined ezspFragmentMessageSentHandler() when it has finished sending the long message.

To receive a long message, the application must add a call to ezspFragmentIncomingMessage() at the start of its ezspIncomingMessageHandler(). If ezspFragmentIncomingMessage() returns TRUE, the fragmentation code has handled the message and the application must not process it further. The application must also call ezspFragmentTick() regularly.

Initialization

void ezspFragmentInit (int16u receiveBufferLength, int8u *receiveBuffer)

Transmitting

EmberStatus ezspFragmentSendUnicast (EmberOutgoingMessageType type, int16u indexOrDestination, EmberApsFrame *apsFrame, int8u maxFragmentSize, int16u messageLength, int8u *messageContents)

EmberStatus ezspFragmentSourceRouteHandler (void)boolean ezspFragmentMessageSent (EmberApsFrame *apsFrame, EmberStatus status)

void ezspFragmentMessageSentHandler (EmberStatus status)

Receiving

boolean ezspFragmentIncomingMessage (EmberApsFrame *apsFrame, EmberNodeId sender, int16u *messageLength, int8u **messageContents)

void ezspFragmentTick (void)

Function Documentation

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__fragment.htm (1 of 4) [10/29/2010 2:43:13 PM]

277

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 278: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Message Fragmentation

void ezspFragmentInit ( int16u receiveBufferLength, int8u * receiveBuffer

)

Initialize variables and buffers used for sending and receiving long messages. This functions reads the values of EZSP_CONFIG_MAX_HOPS and EZSP_CONFIG_FRAGMENT_WINDOW_SIZE. The application must set these values before calling this function.

Parameters:receiveBufferLength The length of receiveBuffer. Incoming messages longer than this will be dropped. receiveBuffer The buffer used to reassemble incoming long messages. Once the message is complete,

this buffer will be passed back to the application by ezspFragmentIncomingMessage().

EmberStatus ezspFragmentSendUnicast ( EmberOutgoingMessageType type, int16u indexOrDestination, EmberApsFrame * apsFrame, int8u maxFragmentSize, int16u messageLength, int8u * messageContents

)

Sends a long message by splitting it into blocks. Only one long message can be sent at a time. Calling this function a second time aborts the first message.

Parameters:type Specifies the outgoing message type. Must be one of EMBER_OUTGOING_DIRECT,

EMBER_OUTGOING_VIA_ADDRESS_TABLE, or EMBER_OUTGOING_VIA_BINDING.

indexOrDestination Depending on the type of addressing used, this is either the EmberNodeId of the destination, an index into the address table, or an index into the binding table.

apsFrame The APS frame for the message. maxFragmentSize The message will be broken into blocks no larger than this. messageLength The length of the messageContents parameter in bytes. messageContents The long message to be sent.

Returns:An EmberStatus value.

�❍ EMBER_SUCCESS�❍ EMBER_MESSAGE_TOO_LONG�❍ EMBER_NETWORK_DOWN�❍ EMBER_NETWORK_BUSY�❍ EMBER_INVALID_CALL is returned if messageLength is zero or if the window size

(EZSP_CONFIG_FRAGMENT_WINDOW_SIZE) is zero.

EmberStatus ezspFragmentSourceRouteHandler ( void )

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__fragment.htm (2 of 4) [10/29/2010 2:43:13 PM]

278

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 279: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Message Fragmentation

A callback invoked just before each block of the current long message is sent. If the message is to be source routed, the application must define this callback and call ezspSetSourceRoute() in it.

The application must define EZSP_APPLICATION_HAS_FRAGMENT_SOURCE_ROUTE_HANDLER in its configuration header if it defines this callback.

Returns:EMBER_SUCCESS if the source route has been set. Any other value will abort transmission of the current long message.

boolean ezspFragmentMessageSent ( EmberApsFrame * apsFrame, EmberStatus status

)

The application must call this function at the start of its ezspMessageSentHandler(). If it returns TRUE, the fragmentation code has handled the event and the application must not process it further.

Parameters:apsFrame The APS frame passed to ezspMessageSentHandler

(). status The status passed to ezspMessageSentHandler().

Returns:TRUE if the sent message was a block of a long message. The fragmentation code has handled the event so the application must return immediately from its ezspMessageSentHandler(). Returns FALSE otherwise. The fragmentation code has not handled the event so the application must continue to process it.

void ezspFragmentMessageSentHandler ( EmberStatus status )

The fragmentation code calls this application-defined handler when it finishes sending a long message.

Parameters:status EMBER_SUCCESS if all the blocks of the long message were delivered to the destination, otherwise

EMBER_DELIVERY_FAILED, EMBER_NETWORK_DOWN or EMBER_NETWORK_BUSY.

boolean ezspFragmentIncomingMessage ( EmberApsFrame * apsFrame, EmberNodeId sender, int16u * messageLength, int8u ** messageContents

)

The application must call this function at the start of its ezspIncomingMessageHandler(). If it returns TRUE, the fragmentation code has handled the message and the application must not process it further. When the final block of a long message is received, this function replaces the message with the reassembled long message and returns FALSE so that the application processes it.

Parameters:

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__fragment.htm (3 of 4) [10/29/2010 2:43:13 PM]

279

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 280: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Message Fragmentation

apsFrame The APS frame passed to ezspIncomingMessageHandler(). sender The sender passed to ezspIncomingMessageHandler(). messageLength A pointer to the message length passed to ezspIncomingMessageHandler(). messageContents A pointer to the message contents passed to ezspIncomingMessageHandler().

Returns:TRUE if the incoming message was a block of an incomplete long message. The fragmentation code has handled the message so the application must return immediately from its ezspIncomingMessageHandler(). Returns FALSE if the incoming message was not part of a long message. The fragmentation code has not handled the message so the application must continue to process it. Returns FALSE if the incoming message was a block that completed a long message. The fragmentation code replaces the message with the reassembled long message so the application must continue to process it.

void ezspFragmentTick ( void )

Used by the fragmentation code to time incoming blocks. The application must call this function regularly.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__fragment.htm (4 of 4) [10/29/2010 2:43:13 PM]

280

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 281: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Network Manager

Network Manager [Application Utilities API Reference]

Detailed Description

The network manager is an optional function of one device in the ZigBee network. Devices on the network send unsolicited ZDO energy scan reports to the network manager when more than 25% of unicasts fail within a rolling window, but no more than once every 15 minutes.

See network-manager.h for source code.

The network manager is the coordinator by default but can be changed via emberSetNetworkManagerRequest(). It processes the energy scan reports from the devices on the network, and is responsible for determining if the network should change channels in an attempt to resolve reliability problems that might be caused by RF interference.

Note that EmberZNet networks are quite robust to many interferers such as 802.11 (WiFi), and the presence of interferers does not necessarily degrade application performance or require a channel change. Because changing channels is disruptive to network operation, channel changes should not be done solely because of observed higher noise levels, as the noise may not be causing any problem.

Also note that receipt of unsolicited scan reports is only an indication of unicast failures in the network. These might be caused by RF interference, or for some other reason such as a device failure. In addition, only the application can tell whether the delivery failures caused an actual problem for the application. In general, it is difficult to automatically determine with certainty that network problems are caused by RF interference. Channel changes should therefore be done sparingly and with careful application design.

The stack provides three APIs in include/zigbee-device-stack.h:

● emberEnergyScanRequest● emberSetNetworkManagerRequest● emberChannelChangeRequest

This library provides some additional functions:

● nmUtilProcessIncomingMessage● nmUtilWarningHandler● nmUtilChangeChannelRequest

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__network__manager.htm (1 of 4) [10/29/2010 2:43:14 PM]

281

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 282: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Network Manager

An application implementing network manager functionality using this library should pass all incoming messages to nmUtilProcessIncomingMessage, which will return TRUE if the message was processed as a ZDO energy scan report. The application should not make any calls to emberEnergyScanRequest(), as the library assumes all incoming scan reports are unsolicited and indicate unicast failures.

When NM_WARNING_LIMIT reports have been processed within NM_WINDOW_SIZE minutes, the nmUtilWarningHandler callback, which must be implemented by the application, is invoked. The default values for these parameters are set in network-manager.h and may be modified using #defines within the application configuration header.

The application may use the nmUtilWarningHandler callback, along with other application-specific information, to decide if and when to change the channel by calling nmUtilChangeChannelRequest. This function chooses a new channel from the NM_CHANNEL_MASK parameter using information gathered over time.

In the event of a network-wide channel change, it is possible that some devices, especially sleepy end devices, do not receive the broadcast and remain on the old channel. Devices should use the API emberFindAndRejoinNetwork to get back to the right channel.

Two implementations of this library are provided: network-manager.c, and network-manager-lite.c. The former keeps track of the mean and deviation of the energy on each channel and uses these stats to choose the channel to change to. This consumes a fair amount of RAM. The latter takes the simpler (and possibly more effective) approach of just avoiding past bad channels. Application developers are encouraged to use and modify either of these solutions to take into account their own application-specific needs.

Defines

#define NM_WARNING_LIMIT#define NM_WINDOW_SIZE#define NM_CHANNEL_MASK#define NM_WATCHLIST_SIZE

Functions

void nmUtilWarningHandler (void)boolean nmUtilProcessIncoming (EmberApsFrame *apsFrame, int8u messageLength, int8u

*message)EmberStatus nmUtilChangeChannelRequest (void)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__network__manager.htm (2 of 4) [10/29/2010 2:43:14 PM]

282

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 283: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Network Manager

Define Documentation

#define NM_WARNING_LIMIT

Definition at line 97 of file network-manager.h.

#define NM_WINDOW_SIZE

Definition at line 101 of file network-manager.h.

#define NM_CHANNEL_MASK

Definition at line 107 of file network-manager.h.

#define NM_WATCHLIST_SIZE

Definition at line 113 of file network-manager.h.

Function Documentation

void nmUtilWarningHandler ( void )

callback called when unsolicited scan reports hit limit. This callback must be implemented by the application. It is called when the number of unsolicited scan reports received within NM_WINDOW_LIMIT minutes reaches NM_WARNING_LIMIT.

boolean nmUtilProcessIncoming ( EmberApsFrame * apsFrame, int8u messageLength, int8u * message

)

Called from the app in emberIncomingMessageHandler. Returns TRUE if and only if the library processed the message.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__network__manager.htm (3 of 4) [10/29/2010 2:43:14 PM]

283

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 284: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Network Manager

Parameters:apsFrame messageLength message

EmberStatus nmUtilChangeChannelRequest ( void )

Chooses a new channel and broadcasts a ZDO channel change request.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__network__manager.htm (4 of 4) [10/29/2010 2:43:14 PM]

284

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 285: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Serial Communication

Serial Communication [Application Utilities API Reference]

Detailed Description

Unless otherwise noted, the EmberNet stack does not use these functions, and therefore the HAL is not required to implement them. However, many of the supplied example applications do use them. On some platforms, they are also required by DEBUG builds of the stack

Many of these functions return an EmberStatus value. See stack/include/error-defs.h for definitions of all EmberStatus return values. See app/util/serial/serial.h for source code. To use these serial routines, they must be properly configured.

If the Ember serial library is built using EMBER_SERIAL_USE_STDIO, then the Ember serial code will redirect to stdio.h. EMBER_SERIAL_USE_STDIO will not consume any of the usual Ember serial library buffers and does not require use of any of the other EMBER_SERIALx definitions described here. In this mode, the only required lower layers are:

● putchar()● getchar()● fflush(stdout)● halInternalUartInit()● halInternalPrintfWriteAvailable()● halInternalPrintfReadAvailable()● halInternalForcePrintf()

The functions can work in two ways, depending on how messages waiting for transmission are stored:

● Buffered mode: Uses stack linked buffers. This method can be more efficient if many messages received over the air also need to be transmitted over the serial interface.

● FIFO mode: Uses a statically allocated queue of bytes, and data to be transmitted is copied into the queue.

(These modes deal only with data transmission. Data reception always occurs in a FIFO mode.)

The current version of these sources provides support for as many as two serial ports, but it can be easily extended. The ports are numbered 0 and 1 and should be accessed using those numbers. The ports can be set up independently of each other.

To enable a port, a Use mode (buffered or FIFO) and a Queue Size must be declared on the port. In FIFO mode, the Queue Size is the size of the FIFO and represents the number of bytes that can be waiting for transmission at any given time. In buffered mode, the Queue Size represents the number of whole messages that can be waiting for transmission at any given time. A single message is created for each call to any of the serial APIs.

To specify a Use mode and Queue Size, place declarations in the compiler preprocessor options when building your application:

● Use Mode:�❍ EMBER_SERIAL0_MODE=EMBER_SERIAL_BUFFER or EMBER_SERIAL_FIFO�❍ EMBER_SERIAL1_MODE=EMBER_SERIAL_BUFFER or EMBER_SERIAL_FIFO

● Queue Size:�❍ EMBER_SERIAL0_TX_QUEUE_SIZE=2�❍ EMBER_SERIAL0_RX_QUEUE_SIZE=4�❍ EMBER_SERIAL1_TX_QUEUE_SIZE=8�❍ EMBER_SERIAL1_RX_QUEUE_SIZE=16

Note the following:

● If buffered mode is declared, emberSerialBufferTick() should be called in the application's main event loop.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__serial__comm.htm (1 of 10) [10/29/2010 2:43:16 PM]

285

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 286: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Serial Communication

● If buffered mode is declared, the Tx queue size MUST be <= 255● On the AVR platform, Rx & Tx queue sizes are limited to powers of 2 <= 128● By default, both ports are unused.

You can also use declarations to specify what should be done if an attempt is made to send more data than the queue can accommodate:

● EMBER_SERIAL0_BLOCKING● EMBER_SERIAL1_BLOCKING

Be aware that since blocking spins in a loop, doing nothing until space is available, it can adversely affect any code that has tight timing requirements.

If EMBER_SERIAL0_BLOCKING or EMBER_SERIAL1_BLOCKING is defined, then the call to the port will block until space is available, guaranteeing that the entire message is sent. Note that in buffered mode, even if blocking mode is in effect entire messages may be dropped if insufficient stack buffers are available to hold them. When this happens, EMBER_NO_BUFFERS is returned.

If no blocking mode is defined, the serial code defaults to non-blocking mode. In this event, when the queue is too short, the data that don't fit are dropped. In FIFO mode, this may result bytes being dropped, starting in the middle of message. In buffered mode, the entire message is dropped. When data is dropped, EMBER_SERIALTX_OVERFLOW is returned.

To minimize code size, very little error checking is done on the given parameters. Specifying an invalid or unused serial port may result in unexplained behavior. In some cases EMBER_ERR_FATAL may be returned.

Printf Prototypes

These prototypes are for the internal printf implementation, in case it is desired to use it elsewhere. See the code for emberSerialPrintf() for an example of printf usage.

typedef EmberStatus( emPrintfFlushHandler )(int8u flushVar, int8u *contents, int8u length)int8u emPrintfInternal (emPrintfFlushHandler handler, int8u port, PGM_P buff, va_list list)

Defines

#define emberSerialWriteUsed(port)#define SERIAL_PORT_RAW#define SERIAL_PORT_CLI

Functions

EmberStatus emberSerialInit (int8u port, SerialBaudRate rate, SerialParity parity, int8u stopBits)int16u emberSerialReadAvailable (int8u port)

EmberStatus emberSerialReadByte (int8u port, int8u *dataByte)EmberStatus emberSerialReadLine (int8u port, char *data, int8u max)EmberStatus emberSerialReadPartialLine (int8u port, char *data, int8u max, int8u *index)

int16u emberSerialWriteAvailable (int8u port)EmberStatus emberSerialWriteByte (int8u port, int8u dataByte)EmberStatus emberSerialWriteHex (int8u port, int8u dataByte)EmberStatus emberSerialWriteString (int8u port, PGM_P string)

XAP2B_PAGEZERO_ON EmberStatus emberSerialPrintf (int8u port, PGM_P formatString,...)XAP2B_PAGEZERO_OFF XAP2B_PAGEZERO_ON

EmberStatus emberSerialPrintfLine (int8u port, PGM_P formatString,...)XAP2B_PAGEZERO_OFF XAP2B_PAGEZERO_ON

EmberStatus emberSerialPrintCarriageReturn (int8u port)XAP2B_PAGEZERO_OFF EmberStatus emberSerialPrintfVarArg (int8u port, PGM_P formatString, va_list ap)

EmberStatus emberSerialWriteData (int8u port, int8u *data, int8u length)EmberStatus emberSerialWriteBuffer (int8u port, EmberMessageBuffer buffer, int8u start, int8u length)

XAP2B_PAGEZERO_ON EmberStatus emberSerialWaitSend (int8u port)XAP2B_PAGEZERO_OFF EmberStatus emberSerialGuaranteedPrintf (int8u port, PGM_P formatString,...)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__serial__comm.htm (2 of 10) [10/29/2010 2:43:16 PM]

286

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 287: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Serial Communication

void emberSerialBufferTick (void)void emberSerialFlushRx (int8u port)void emberSerialSetPrompt (const char *thePrompt)void emberSerialCleanup (void)

int emberSerialGetInputFd (int8u port)void emberSerialCommandCompletionInit (EmberCommandEntry *listOfCommands)void emberSerialCommandCompletionInitCli (cliSerialCmdEntry *cliCmdList, int cliCmdListLength)

Define Documentation

#define emberSerialWriteUsed ( port )

Returns the number of bytes (in FIFO mode) or messages (in buffered mode) that are currently queued and still being sent.

Parameters:port A serial port number (0 or 1).

Returns:The number of bytes or messages available for queueing.

Definition at line 227 of file app/util/serial/serial.h.

#define SERIAL_PORT_RAW

Definition at line 17 of file linux-serial.h.

#define SERIAL_PORT_CLI

Definition at line 18 of file linux-serial.h.

Typedef Documentation

typedef EmberStatus( emPrintfFlushHandler)(int8u flushVar, int8u *contents, int8u length)

Typedefine to cast a function into the appropriate format to be used inside the emPrintfInternal function below, for performing the actual flushing of a formatted string to a destination such as a serial port.

Parameters:flushVar,: The destination of the flush, most commonly a serial port number (0 or 1).contents A pointer to the string to flush.length The number of bytes to flush.

Returns:The EmberStatus value of the typedefined function.

Definition at line 466 of file app/util/serial/serial.h.

Function Documentation

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__serial__comm.htm (3 of 10) [10/29/2010 2:43:16 PM]

287

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 288: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Serial Communication

EmberStatus emberSerialInit ( int8u port, SerialBaudRate rate, SerialParity parity, int8u stopBits

)

Initializes a serial port to a specific baud rate, parity, and number of stop bits. Eight data bits are always used.

Parameters:port A serial port number (0 or 1).rate The baud rate (see SerialBaudRate).parity The parity value (see SerialParity).stopBits The number of stop bits.

Returns:An error code if initialization failed (such as invalid baudrate), or EMBER_SUCCESS.

int16u emberSerialReadAvailable ( int8u port )

Returns the number of bytes currently available for reading in the specified RX queue.

Parameters:port A serial port number (0 or 1).

Returns:The number of bytes available.

EmberStatus emberSerialReadByte ( int8u port, int8u * dataByte

)

Reads a byte from the specified RX queue. If an error is returned, the dataByte should be ignored. For errors other than EMBER_SERIAL_RX_EMPTY multiple bytes of data may have been lost and serial protocols should attempt to resynchronize.

Parameters:port A serial port number (0 or 1).dataByte A pointer to storage location for the byte.

Returns:One of the following (see the Main Page):

�❍ EMBER_SERIAL_RX_EMPTY if no data is available�❍ EMBER_SERIAL_RX_OVERFLOW if the serial receive fifo was out of space�❍ EMBER_SERIAL_RX_FRAME_ERROR if a framing error was received�❍ EMBER_SERIAL_RX_PARITY_ERROR if a parity error was received�❍ EMBER_SERIAL_RX_OVERRUN_ERROR if the hardware fifo was out of space�❍ EMBER_SUCCESS if a data byte is returned

EmberStatus emberSerialReadLine ( int8u port, char * data, int8u max

)

Simulates a terminal interface, reading a line of characters at a time. Supports backspace. Always converts to

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__serial__comm.htm (4 of 10) [10/29/2010 2:43:16 PM]

288

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 289: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Serial Communication

uppercase. Blocks until a line has been read or max has been exceeded. Calls on halResetWatchdog().

Parameters:port A serial port number (0 or 1).data A pointer to storage location for the read line. There must be max contiguous bytes available at this location.max The maximum number of bytes to read.

Returns:EMBER_SUCCESS

EmberStatus emberSerialReadPartialLine ( int8u port, char * data, int8u max, int8u * index

)

Simulates a partial terminal interface, reading a line of characters at a time. Supports backspace. Always converts to uppercase. returns EMBER_SUCCESS when a line has been read or max has been exceeded. Must initialize the index variable to 0 to start a line.

Parameters:port A serial port number (0 or 1).data A pointer to storage location for the read line. There must be max contiguous bytes available at this location.max The maximum number of bytes to read.index The address of a variable that holds the place in the data to continue. Set to 0 to start a line read.

Returns:One of the following (see the Main Page):

�❍ EMBER_SERIAL_RX_EMPTY if a partial line is in progress.�❍ EMBER_SERIAL_RX_OVERFLOW if the serial receive fifo was out of space.�❍ EMBER_SERIAL_RX_FRAME_ERROR if a framing error was received.�❍ EMBER_SERIAL_RX_PARITY_ERROR if a parity error was received.�❍ EMBER_SERIAL_RX_OVERRUN_ERROR if the hardware fifo was out of space.�❍ EMBER_SUCCESS if a full ine is ready.

int16u emberSerialWriteAvailable ( int8u port )

Returns the number of bytes (in FIFO mode) or messages (in buffered mode) that can currently be queued to send without blocking or dropping.

Parameters:port A serial port number (0 or 1).

Returns:The number of bytes or messages available for queueing.

EmberStatus emberSerialWriteByte ( int8u port, int8u dataByte

)

Queues a single byte of data for transmission on the specified port.

Parameters:port A serial port number (0 or 1).

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__serial__comm.htm (5 of 10) [10/29/2010 2:43:16 PM]

289

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 290: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Serial Communication

dataByte The byte to be queued.

Returns:One of the following (see the Main Page):

�❍ EMBER_SERIAL_TX_OVERFLOW indicates that data was dropped.�❍ EMBER_NO_BUFFERS indicates that there was an insufficient number of available stack buffers.�❍ EMBER_SUCCESS.

EmberStatus emberSerialWriteHex ( int8u port, int8u dataByte

)

Converts a given byte of data to its two-character ASCII hex representation and queues it for transmission on the specified port. Values less than 0xF are always zero padded and queued as "0F".

Parameters:port A serial port number (0 or 1).dataByte The byte to be converted.

Returns:One of the following (see the Main Page):

�❍ EMBER_SERIAL_TX_OVERFLOW indicates that data was dropped.�❍ EMBER_NO_BUFFERS indicates that there was an insufficient number of available stack buffers.�❍ EMBER_SUCCESS.

EmberStatus emberSerialWriteString ( int8u port, PGM_P string

)

Queues a string for transmission on the specified port.

Parameters:port A serial port number (0 or 1).string The string to be queued.

Returns:One of the following (see the Main Page):

�❍ EMBER_SERIAL_TX_OVERFLOW indicates that data was dropped.�❍ EMBER_NO_BUFFERS indicates that there was an insufficient number of available stack buffers.�❍ EMBER_SUCCESS.

XAP2B_PAGEZERO_ON EmberStatus emberSerialPrintf ( int8u port, PGM_P formatString, ...

)

Printf for printing on a specified port. Supports the following format specifiers:

● %% percent sign● c single-byte character● s RAM string● p flash string (nonstandard specifier)● u 2-byte unsigned decimal● d 2-byte signed decimal● l 4-byte signed decimal● x 2x 4x 1-, 2-, 4-byte hex value (always 0 padded) (nonstandard specifier).

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__serial__comm.htm (6 of 10) [10/29/2010 2:43:16 PM]

290

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 291: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Serial Communication

Parameters:port A serial port number (0 or 1).formatString The string to print.... Format specifiers.

Returns:One of the following (see the Main Page):

�❍ EMBER_SERIAL_TX_OVERFLOW indicates that data was dropped.�❍ EMBER_NO_BUFFERS indicates that there was an insufficient number of available stack buffers.�❍ EMBER_SUCCESS.

XAP2B_PAGEZERO_OFF XAP2B_PAGEZERO_ON EmberStatus emberSerialPrintfLine ( int8u port, PGM_P formatString, ...

)

Printf for printing on a specified port. Same as emberSerialPrintf() except it prints a carriage return at the the end of the text.

Parameters:port A serial port number (0 or 1).formatString The string to print.... Format specifiers.

Returns:One of the following (see the Main Page):

�❍ EMBER_SERIAL_TX_OVERFLOW indicates that data was dropped.�❍ EMBER_NO_BUFFERS indicates that there was an insufficient number of available stack buffers.�❍ EMBER_SUCCESS.

XAP2B_PAGEZERO_OFF XAP2B_PAGEZERO_ON EmberStatus emberSerialPrintCarriageReturn ( int8u port )

Prints "\r\n" to the specified serial port.

Parameters:port A serial port number (0 or 1).

Returns:One of the following (see the Main Page):

�❍ EMBER_SERIAL_TX_OVERFLOW indicates that data was dropped.�❍ EMBER_NO_BUFFERS indicates that there was an insufficient number of available stack buffers.�❍ EMBER_SUCCESS.

XAP2B_PAGEZERO_OFF EmberStatus emberSerialPrintfVarArg ( int8u port, PGM_P formatString, va_list ap

)

Prints a format string with a variable argument list.

Parameters:port A serial port number (0 or

1). formatString A printf style format string.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__serial__comm.htm (7 of 10) [10/29/2010 2:43:16 PM]

291

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 292: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Serial Communication

ap A variable argument list.

Returns:One of the following (see the Main Page):

�❍ EMBER_SERIAL_TX_OVERFLOW indicates that data was dropped.�❍ EMBER_NO_BUFFERS indicates that there was an insufficient number of available stack buffers.�❍ EMBER_SUCCESS.

EmberStatus emberSerialWriteData ( int8u port, int8u * data, int8u length

)

Queues an arbitrary chunk of data for transmission on a specified port.

Parameters:port A serial port number (0 or 1).data A pointer to data.length The number of bytes to queue.

Returns:One of the following (see the Main Page):

�❍ EMBER_SERIAL_TX_OVERFLOW indicates that data was dropped.�❍ EMBER_NO_BUFFERS indicates that there was an insufficient number of available stack buffers.�❍ EMBER_SUCCESS.

EmberStatus emberSerialWriteBuffer ( int8u port, EmberMessageBuffer buffer, int8u start, int8u length

)

Queues data contained in linked stack buffers for transmission on a specified port. Can specify an arbitrary initial offset within the linked buffer chain.

Parameters:port A serial port number (0 or 1).buffer The starting buffer in linked buffer chain.start The offset from first buffer in chain.length The number of bytes to queue.

Returns:One of the following (see the Main Page):

�❍ EMBER_SERIAL_TX_OVERFLOW indicates that data was dropped.�❍ EMBER_NO_BUFFERS indicates that there was an insufficient number of available stack buffers.�❍ EMBER_SUCCESS.

XAP2B_PAGEZERO_ON EmberStatus emberSerialWaitSend ( int8u port )

Waits for all data currently queued on the specified port to be transmitted before returning. Note: Call this function before serial reinitialization to ensure that transmission is complete.

Parameters:port A serial port number (0 or 1).

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__serial__comm.htm (8 of 10) [10/29/2010 2:43:16 PM]

292

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 293: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Serial Communication

Returns:One of the following (see the Main Page):

�❍ EMBER_SERIAL_TX_OVERFLOW indicates that data was dropped.�❍ EMBER_NO_BUFFERS indicates that there was an insufficient number of available stack buffers.�❍ EMBER_SUCCESS.

XAP2B_PAGEZERO_OFF EmberStatus emberSerialGuaranteedPrintf ( int8u port, PGM_P formatString, ...

)

A printf routine that takes over the specified serial port and immediately transmits the given data regardless of what is currently queued. Does not return until the transmission is complete.

Application Usage:Useful for fatal situations (such as asserts) where the node will be reset, but information on the cause for the reset needs to be transmitted first.

Parameters:port A serial port number (0 or 1).formatString The string to print.... Formatting specifiers. See emberSerialPrintf() for arguments.

Returns:One of the following (see the Main Page):

�❍ EMBER_SERIAL_TX_OVERFLOW indicates that data was dropped.�❍ EMBER_NO_BUFFERS indicates that there was an insufficient number of available stack buffers.�❍ EMBER_SUCCESS.

void emberSerialBufferTick ( void )

When a serial port is used in buffered mode, this must be called in an application's main event loop, similar to emberTick(). It frees buffers that are used to queue messages. Note: This function has no effect if FIFO mode is being used.

void emberSerialFlushRx ( int8u port )

Flushes the receive buffer in case none of the incoming serial data is wanted.

Parameters:port A serial port number (0 or

1).

int8u emPrintfInternal ( emPrintfFlushHandler handler, int8u port, PGM_P buff, va_list list

)

The internal printf function, which scans the string for the format specifiers and appropriately implants the passed data into the string.

Parameters:

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__serial__comm.htm (9 of 10) [10/29/2010 2:43:16 PM]

293

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 294: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Serial Communication

handler,: The name of an internal function, which has parameters matching the function emPrintfFlushHandler above, responsible for flushing a string formatted by this function, emPrintfInternal, to the appropriate buffer or function that performs the actual transmission.

port The destination of the flush performed above, most commonly serial port number (0 or 1).buff The string to print.list The list of arguments for the format specifiers.

Returns:The number of characters written.

void emberSerialSetPrompt ( const char * thePrompt )

void emberSerialCleanup ( void )

int emberSerialGetInputFd ( int8u port )

void emberSerialCommandCompletionInit ( EmberCommandEntry * listOfCommands )

void emberSerialCommandCompletionInitCli ( cliSerialCmdEntry * cliCmdList, int cliCmdListLength

)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__serial__comm.htm (10 of 10) [10/29/2010 2:43:16 PM]

294

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 295: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ASH Application Utility

ASH Application Utility [Application Utilities API Reference]

Detailed Description

See also Asynchronous Serial Host (ASH) Framework.

See ash-host.h.

See ash-host-io.h.

See ash-host-queues.h.

See ash-host-ui.h.

See ash-host-priv.h.

Data Structures

struct AshHostConfig

Configuration parameters: values must be defined before calling ashResetNcp() or ashStart(). Note that all times are in milliseconds. More...

struct AshCountstruct ashBuffer

Buffer to hold a DATA frame. More... struct AshQueue

Simple queue (singly-linked list). More... struct AshFreeList

Simple free list (singly-linked list). More...

Defines

#define ASH_MAX_TIMEOUTS#define ASH_MAX_WAKE_TIME#define ASH_PORT_LEN#define TRACE_FRAMES_BASIC

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ash__util.htm (1 of 22) [10/29/2010 2:43:19 PM]

295

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 296: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ASH Application Utility

#define TRACE_FRAMES_VERBOSE#define TRACE_EVENTS#define TRACE_EZSP#define TRACE_EZSP_VERBOSE#define ASH_RESET_METHOD_RST#define ASH_RESET_METHOD_DTR#define ASH_RESET_METHOD_CUSTOM#define ASH_RESET_METHOD_NONE#define ASH_NCP_TYPE_EM2XX_EM3XX#define ASH_HOST_CONFIG_EM2XX_EM3XX_115200_RTSCTS#define ASH_HOST_CONFIG_EM2XX_EM3XX_57600_XONXOFF#define ashReadConfig(member)#define ashReadConfigOrDefault(member, defval)#define ashWriteConfig(member, value)#define BUMP_HOST_COUNTER(mbr)#define ADD_HOST_COUNTER(op, mbr)#define DEBUG_STREAM#define ashDebugPrintf(...)#define ashDebugVfprintf(format, argPointer)#define TX_POOL_BUFFERS#define RX_FREE_LWM#define RX_FREE_HWM#define BUMP_HOST_COUNTER(mbr)#define ADD_HOST_COUNTER(op, mbr)

Typedefs

typedef ashBuffer AshBuffer

Functions

EzspStatus ashSelectHostConfig (int8u config)EzspStatus ashStart (void)

void ashStop (void)EzspStatus ashSend (int8u len, const int8u *inptr)EzspStatus ashResetNcp (void)EzspStatus ashWakeUpNcp (boolean init)

boolean ashIsConnected (void)void ashSendExec (void)

EzspStatus ashReceiveExec (void)EzspStatus ashReceive (int8u *len, int8u *buffer)

boolean ashOkToSleep (void)EzspStatus ashSerialInit (void)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ash__util.htm (2 of 22) [10/29/2010 2:43:19 PM]

296

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 297: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ASH Application Utility

void ashSerialClose (void)void ashResetDtr (void)void ashResetCustom (void)

EzspStatus ashSerialWriteAvailable (void)void ashSerialWriteByte (int8u byte)void ashSerialWriteFlush (void)

EzspStatus ashSerialReadByte (int8u *byte)EzspStatus ashSerialReadAvailable (int16u *count)

void ashSerialReadFlush (void)void ashDebugFlush (void)

int ashSerialGetFd (void)boolean ashSerialOutputIsIdle (void)

void ashInitQueues (void)void ashFreeBuffer (AshFreeList *list, AshBuffer *buffer)

AshBuffer * ashAllocBuffer (AshFreeList *list)AshBuffer * ashRemoveQueueHead (AshQueue *queue)AshBuffer * ashQueueHead (AshQueue *queue)AshBuffer * ashQueueNthEntry (AshQueue *queue, int8u n)AshBuffer * ashQueuePrecedingEntry (AshQueue *queue, AshBuffer *buffer)AshBuffer * ashRemoveQueueEntry (AshQueue *queue, AshBuffer *buffer)

int8u ashQueueLength (AshQueue *queue)int8u ashFreeListLength (AshFreeList *list)

void ashAddQueueTail (AshQueue *queue, AshBuffer *buffer)boolean ashQueueIsEmpty (AshQueue *queue)

void ashPrintUsage (char *name)boolean ashProcessCommandOptions (int argc, char *argv[])

void ashTraceEvent (const char *string)void ashPrintCounters (AshCount *counters, boolean clear)void ashClearCounters (AshCount *counters)

const int8u * ashErrorString (int8u error)const int8u * ashEzspErrorString (int8u error)

void ashTraceFrame (boolean sent)void ashTraceEventRecdFrame (const char *string)void ashTraceEventTime (const char *string)void ashTraceDisconnected (int8u error)void ashTraceArray (int8u *name, int8u len, int8u *data)void ashTraceEzspFrameId (const char *message, int8u *ezspFrame)void ashTraceEzspVerbose (char *format,...)void ashCountFrame (boolean sent)

int8u readTxControl (void)int8u readRxControl (void)int8u readAckRx (void)int8u readAckTx (void)int8u readFrmTx (void)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ash__util.htm (3 of 22) [10/29/2010 2:43:19 PM]

297

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 298: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ASH Application Utility

int8u readFrmReTx (void)int8u readFrmRx (void)int8u readAshTimeouts (void)

Variables

EzspStatus ashErrorEzspStatus ncpError

AshHostConfig ashHostConfigAshCount ashCount

boolean ncpSleepEnabledAshQueue txQueueAshQueue reTxQueueAshQueue rxQueue

AshFreeList txFreeAshFreeList rxFree

Define Documentation

#define ASH_MAX_TIMEOUTS

timeouts before link is judged down

Definition at line 19 of file ash-host.h.

#define ASH_MAX_WAKE_TIME

max time in msecs for ncp to wake

Definition at line 20 of file ash-host.h.

#define ASH_PORT_LEN

length of serial port name string

Definition at line 22 of file ash-host.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ash__util.htm (4 of 22) [10/29/2010 2:43:19 PM]

298

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 299: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ASH Application Utility

#define TRACE_FRAMES_BASIC

frames sent and received

Definition at line 25 of file ash-host.h.

#define TRACE_FRAMES_VERBOSE

basic frames + internal variables

Definition at line 26 of file ash-host.h.

#define TRACE_EVENTS

events

Definition at line 27 of file ash-host.h.

#define TRACE_EZSP

EZSP commands, responses and callbacks

Definition at line 28 of file ash-host.h.

#define TRACE_EZSP_VERBOSE

additional EZSP information

Definition at line 29 of file ash-host.h.

#define ASH_RESET_METHOD_RST

send RST frame

Definition at line 32 of file ash-host.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ash__util.htm (5 of 22) [10/29/2010 2:43:19 PM]

299

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 300: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ASH Application Utility

#define ASH_RESET_METHOD_DTR

reset using DTR

Definition at line 33 of file ash-host.h.

#define ASH_RESET_METHOD_CUSTOM

hook for user-defined reset

Definition at line 34 of file ash-host.h.

#define ASH_RESET_METHOD_NONE

no reset - for testing

Definition at line 35 of file ash-host.h.

#define ASH_NCP_TYPE_EM2XX_EM3XX

EM2XX or EM3XX

Definition at line 38 of file ash-host.h.

#define ASH_HOST_CONFIG_EM2XX_EM3XX_115200_RTSCTS

Definition at line 41 of file ash-host.h.

#define ASH_HOST_CONFIG_EM2XX_EM3XX_57600_XONXOFF

Definition at line 42 of file ash-host.h.

#define ashReadConfig ( member )

Definition at line 69 of file ash-host.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ash__util.htm (6 of 22) [10/29/2010 2:43:19 PM]

300

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 301: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ASH Application Utility

#define ashReadConfigOrDefault ( member, defval )

Definition at line 72 of file ash-host.h.

#define ashWriteConfig ( member, value )

Definition at line 75 of file ash-host.h.

#define BUMP_HOST_COUNTER ( mbr )

Definition at line 78 of file ash-host.h.

#define ADD_HOST_COUNTER ( op, mbr )

Definition at line 79 of file ash-host.h.

#define DEBUG_STREAM

Prints ASH ACSII trace information.

Definition at line 99 of file ash-host-io.h.

#define ashDebugPrintf ( ... )

Definition at line 104 of file ash-host-io.h.

#define ashDebugVfprintf ( format, argPointer )

Definition at line 107 of file ash-host-io.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ash__util.htm (7 of 22) [10/29/2010 2:43:19 PM]

301

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 302: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ASH Application Utility

#define TX_POOL_BUFFERS

The number of transmit buffers must be set to the number of receive buffers -- to hold the immediate ACKs sent for each callabck frame received -- plus 3 buffers for the retransmit queue and one each for an automatic ACK (due to data flow control) and a command.

Definition at line 24 of file ash-host-queues.h.

#define RX_FREE_LWM

Define the limits used to decide if the host will hold off the ncp from sending normal priority frames.

Definition at line 29 of file ash-host-queues.h.

#define RX_FREE_HWM

Definition at line 30 of file ash-host-queues.h.

#define BUMP_HOST_COUNTER ( mbr )

Definition at line 75 of file ash-host-ui.h.

#define ADD_HOST_COUNTER ( op, mbr )

Definition at line 76 of file ash-host-ui.h.

Typedef Documentation

typedef struct ashBuffer AshBuffer

Buffer to hold a DATA frame.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ash__util.htm (8 of 22) [10/29/2010 2:43:19 PM]

302

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 303: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ASH Application Utility

Function Documentation

EzspStatus ashSelectHostConfig ( int8u config )

Selects a set of host configuration parameters. To select a configuration other than the default, must be called before ashStart().

Parameters:config one of the following:

�❍ ASH_HOST_CONFIG_EM2XX_EM3XX_115200_RTSCTS (default)�❍ ASH_HOST_CONFIG_EM2XX_EM3XX_57600_XONXOFF

Returns:�❍ EZSP_SUCCESS _ EZSP_ASH_HOST_FATAL_ERROR

EzspStatus ashStart ( void )

Initializes the ASH protocol, and waits until the NCP finishes rebooting, or a non-recoverable error occurs.

Returns:�❍ EZSP_SUCCESS�❍ EZSP_ASH_HOST_FATAL_ERROR�❍ EZSP_ASH_NCP_FATAL_ERROR

void ashStop ( void )

Stops the ASH protocol - flushes and closes the serial port, clears all queues, stops timers, etc. Does not affect any host configuration parameters.

EzspStatus ashSend ( int8u len, const int8u * inptr

)

Adds a DATA frame to the transmit queue to send to the NCP. Frames that are too long or too

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ash__util.htm (9 of 22) [10/29/2010 2:43:19 PM]

303

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 304: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ASH Application Utility

short will not be sent, and frames will not be added to the queue if the host is not in the Connected state, or the NCP is not ready to receive a DATA frame or if there is no room in the queue;.

Parameters:len length of data fieldinptr pointer to array containing the data to be sent

Returns:�❍ EZSP_SUCCESS�❍ EZSP_ASH_NO_TX_SPACE�❍ EZSP_ASH_DATA_FRAME_TOO_SHORT�❍ EZSP_ASH_DATA_FRAME_TOO_LONG�❍ EZSP_ASH_NOT_CONNECTED

EzspStatus ashResetNcp ( void )

Initializes the ASH serial port and (if enabled) resets the NCP. The method used to do the reset is specified by the the host configuration parameter resetMethod.

When the reset method is sending a RST frame, the caller should retry NCP resets a few times if it fails.

Returns:�❍ EZSP_SUCCESS�❍ EZSP_ASH_HOST_FATAL_ERROR�❍ EZSP_ASH_NCP_FATAL_ERROR

EzspStatus ashWakeUpNcp ( boolean init )

Wakes up the NCP by sending two 0xFF bytes. When the NCP wakes, it sends back an 0xFF byte.

Parameters:init set TRUE on the first call to this function, starts timer

Returns:�❍ EZSP_ASH_IN_PROGRESS NCP is not yet awake, but has not timed out�❍ EZSP_SUCCESS NCP is swake�❍ EZSP_ASH_HOST_FATAL_ERROR NCP did not wake within

ASH_MAX_WAKE_TIME

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ash__util.htm (10 of 22) [10/29/2010 2:43:19 PM]

304

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 305: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ASH Application Utility

boolean ashIsConnected ( void )

Indicates if the host is in the Connected state. If not, the host and NCP cannot exchange DATA frames. Note that this function does not actively confirm that communication with NCP is healthy, but simply returns its last known status.

Returns:�❍ TRUE host and NCP can exchange DATA frames�❍ FALSE host and NCP cannot now exchange DATA frames

void ashSendExec ( void )

Manages outgoing communication to the NCP, including DATA frames as well as the frames used for initialization and error detection and recovery.

EzspStatus ashReceiveExec ( void )

Processes all received frames. Received DATA frames are appended to the receive queue if there is room.

Returns:�❍ EZSP_SUCCESS�❍ EZSP_ASH_IN_PROGRESS�❍ EZSP_ASH_NO_RX_DATA�❍ EZSP_ASH_NO_RX_SPACE�❍ EZSP_ASH_HOST_FATAL_ERROR�❍ EZSP_ASH_NCP_FATAL_ERROR

EzspStatus ashReceive ( int8u * len, int8u * buffer

)

Returns the next DATA frame received, if there is one. To be more precise, the head of the receive queue is copied into the specified buffer and then freed.

Parameters:len length of the DATA frame if one was returnndbuffer array into which the DATA frame should be copied

Returns:

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ash__util.htm (11 of 22) [10/29/2010 2:43:19 PM]

305

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 306: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ASH Application Utility

�❍ EZSP_SUCCESS�❍ EZSP_ASH_NO_RX_DATA�❍ EZSP_ASH_NOT_CONNECTED

boolean ashOkToSleep ( void )

Returns TRUE if the host can sleep without causing errors in the ASH protocol.

EzspStatus ashSerialInit ( void )

Initializes the serial port for use by ASH. The port number, baud rate, stop bits, and flow control method are specifed by the by the ashHostConfig structure.

Returns:�❍ EZSP_SUCCESS�❍ EZSP_ASH_HOST_FATAL_ERROR

void ashSerialClose ( void )

If the serial port is open, discards all I/O data and closes the port.

void ashResetDtr ( void )

Resets the ncp by deasserting and asserting DTR. This requires a conenction between DTR and nRESET, as there is on the EM260 breakout board when the on-board USB interface is used.

void ashResetCustom ( void )

Custom method for resetting the ncp which must be defined by the user for their specific hardware and interconect. As shipped, this function does nothing.

EzspStatus ashSerialWriteAvailable ( void )

Checks to see if there is space available in the serial write buffer. If the buffer is full, it is output to the serial port and it return a "no space indication".

Returns:

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ash__util.htm (12 of 22) [10/29/2010 2:43:19 PM]

306

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 307: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ASH Application Utility

�❍ EZSP_SUCCESS _ EZSP_ASH_NO_TX_SPACE

void ashSerialWriteByte ( int8u byte )

Writes a byte to the serial output buffer.

Parameters:byte byte to

write

void ashSerialWriteFlush ( void )

Writes all data the write output buffer to the serial port and calls fsync(). This is called when a complete frame to be sent to the ncp has been created.

EzspStatus ashSerialReadByte ( int8u * byte )

Reads a byte from the serial port, if one is available.

Parameters:byte pointer to a variable where the byte read will be output

Returns:�❍ EZSP_SUCCESS�❍ EZSP_ASH_NO_RX_DATA

EzspStatus ashSerialReadAvailable ( int16u * count )

Returns number of the bytes available to read from the serial port.

Parameters:count pointer to a variable where the byte count will be written

Returns:�❍ EZSP_SUCCESS�❍ EZSP_ASH_NO_RX_DATA

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ash__util.htm (13 of 22) [10/29/2010 2:43:19 PM]

307

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 308: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ASH Application Utility

void ashSerialReadFlush ( void )

Discards input data from the serial port until there is none left.

void ashDebugFlush ( void )

Flushes the ASH ASCII trace output stream.

int ashSerialGetFd ( void )

Returns the file descriptor associated with the serial port.

boolean ashSerialOutputIsIdle ( void )

tests to see if all serial transmit data has actually been shifted out the host's serial port transmit data pin. As shipped this is a stub function that must be edited to match the actual operating system and/or UART hardware.

Returns:TRUE if all data has been shifted out.

void ashInitQueues ( void )

Initializes all queues and free lists. All receive buffers are put into rxFree, and rxQueue is empty. All transmit buffers are put into txFree, and txQueue and reTxQueue are empty.

void ashFreeBuffer ( AshFreeList * list, AshBuffer * buffer

)

Add a buffer to the free list.

Parameters:list pointer to the free

list buffer pointer to the buffer

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ash__util.htm (14 of 22) [10/29/2010 2:43:19 PM]

308

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 309: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ASH Application Utility

AshBuffer* ashAllocBuffer ( AshFreeList * list )

Get a buffer from the free list.

Parameters:list pointer to the free list

Returns:pointer to the buffer allocated, NULL if free list was empty

AshBuffer* ashRemoveQueueHead ( AshQueue * queue )

Remove the buffer at the head of a queue. The queue must not be empty.

Parameters:queue pointer to the queue

Returns:pointer to the buffer that had been the head of the queue

AshBuffer* ashQueueHead ( AshQueue * queue )

Get a pointer to the buffer at the head of the queue. The queue must not be empty.

Parameters:queue pointer to the queue

Returns:pointer to the buffer at the nead of the queue

AshBuffer* ashQueueNthEntry ( AshQueue * queue, int8u n

)

Get a pointer to the Nth entry in a queue. The tail is entry number 1, and if the queue has N entries, the head is entry number N. The queue must not be empty.

Parameters:

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ash__util.htm (15 of 22) [10/29/2010 2:43:19 PM]

309

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 310: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ASH Application Utility

queue pointer to the queue n number of the entry to which a pointer will be returned

Returns:pointer to the Nth queue entry

AshBuffer* ashQueuePrecedingEntry ( AshQueue * queue, AshBuffer * buffer

)

Get a pointer to the queue entry before (closer to the tail) than the specified entry. If the entry specified is the tail, NULL is returned. If the entry specifed is NULL, a pointer to the head is returned.

Parameters:queue pointer to the queue buffer pointer to the buffer whose predecessor is wanted

Returns:pointer to the buffer before that specifed, or NULL if none

AshBuffer* ashRemoveQueueEntry ( AshQueue * queue, AshBuffer * buffer

)

Removes the buffer from the queue, and returns a pointer to its predecssor, if there is one, otherwise it returns NULL.

Parameters:queue pointer to the queue buffer pointer to the buffer to be removed

Returns:pointer to the buffer before that removed, or NULL if none

int8u ashQueueLength ( AshQueue * queue )

Returns the number of entries in the queue.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ash__util.htm (16 of 22) [10/29/2010 2:43:19 PM]

310

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 311: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ASH Application Utility

Parameters:queue pointer to the queue

Returns:number of entries in the queue

int8u ashFreeListLength ( AshFreeList * list )

Returns the number of entries in the free list.

Parameters:list pointer to the free list

Returns:number of entries in the free list

void ashAddQueueTail ( AshQueue * queue, AshBuffer * buffer

)

Add a buffer to the tail of the queue.

Parameters:queue pointer to the

queue buffer pointer to the

buffer

boolean ashQueueIsEmpty ( AshQueue * queue )

Returns TRUE if the queue is empty.

Parameters:queue pointer to the queue

Returns:TRUE if the queue is empty

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ash__util.htm (17 of 22) [10/29/2010 2:43:19 PM]

311

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 312: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ASH Application Utility

void ashPrintUsage ( char * name )

Prints usage instructions to stderr.

Parameters:name program name (usually argv

[0])

boolean ashProcessCommandOptions ( int argc, char * argv[]

)

Sets host configuration values from command line options.

Parameters:argc number of command line tokensargv array of pointer to command line tokens

Returns:TRUE if no errors were detected in the command line

void ashTraceEvent ( const char * string )

Writes a debug trace message, if enabled.

Parameters:string pointer to message string

Returns:�❍ EZSP_SUCCESS�❍ EZSP_ASH_NO_RX_DATA

void ashPrintCounters ( AshCount * counters, boolean clear

)

Prints host counter data.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ash__util.htm (18 of 22) [10/29/2010 2:43:19 PM]

312

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 313: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ASH Application Utility

Parameters:counters pointer to counters structureclear if TRUE clears counters

void ashClearCounters ( AshCount * counters )

Clears host counter data.

Parameters:counters pointer to counters

structure

const int8u* ashErrorString ( int8u error )

Converts ASH reset/error code to a string.

Parameters:error error or reset code (from ashError or ncpError)

Returns:pointer to the string

const int8u* ashEzspErrorString ( int8u error )

Converts EZSP-ASH error code to a string.

Parameters:error error code

Returns:pointer to the string

void ashTraceFrame ( boolean sent )

void ashTraceEventRecdFrame ( const char * string )

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ash__util.htm (19 of 22) [10/29/2010 2:43:19 PM]

313

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 314: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ASH Application Utility

void ashTraceEventTime ( const char * string )

void ashTraceDisconnected ( int8u error )

void ashTraceArray ( int8u * name, int8u len, int8u * data

)

void ashTraceEzspFrameId ( const char * message, int8u * ezspFrame

)

void ashTraceEzspVerbose ( char * format, ...

)

void ashCountFrame ( boolean sent )

int8u readTxControl ( void )

int8u readRxControl ( void )

int8u readAckRx ( void )

int8u readAckTx ( void )

int8u readFrmTx ( void )

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ash__util.htm (20 of 22) [10/29/2010 2:43:19 PM]

314

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 315: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ASH Application Utility

int8u readFrmReTx ( void )

int8u readFrmRx ( void )

int8u readAshTimeouts ( void )

Variable Documentation

EzspStatus ashError

EzspStatus ncpError

AshHostConfig ashHostConfig

AshCount ashCount

boolean ncpSleepEnabled

AshQueue txQueue

AshQueue reTxQueue

AshQueue rxQueue

AshFreeList txFree

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ash__util.htm (21 of 22) [10/29/2010 2:43:19 PM]

315

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 316: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ASH Application Utility

AshFreeList rxFree

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__ash__util.htm (22 of 22) [10/29/2010 2:43:19 PM]

316

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 317: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Deprecated

Deprecated

form-and-join3_2.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/group__deprecated.htm [10/29/2010 2:43:19 PM]

317

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 318: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Structures

EmberZNet API Reference: For the EM260 Co-Processor Data Structures

Here are the data structures with brief descriptions:ashBuffer Buffer to hold a DATA frame

AshCount

AshFreeList Simple free list (singly-linked list)

AshHostConfigConfiguration parameters: values must be defined before calling ashResetNcp() or ashStart(). Note that all times are in milliseconds

AshQueue Simple queue (singly-linked list)

EmberAesMmoHashContext This data structure contains the context data when calculating an AES MMO hash (message digest)

EmberApsFrame An in-memory representation of a ZigBee APS frame of an incoming or outgoing message

EmberBindingTableEntry Defines an entry in the binding table

EmberCertificateData This data structure contains the certificate data that is used for Certificate Based Key Exchange (CBKE)

EmberCommandEntry Command entry for a command table

EmberCommandStateS The command state structure. Using a structure allows commands to be read from multiple sources

EmberCurrentSecurityState This describes the security features used by the stack for a joined device

EmberEventControl Control structure for events

EmberInitialSecurityState This describes the Initial Security features and requirements that will be used when forming or joining the network

EmberKeyData This data structure contains the key data that is pasesd into various other functions

EmberKeyStruct This describes a one of several different types of keys and its associated data

EmberMessageDigest This data structure contains an AES-MMO Hash (the message digest)

EmberMulticastTableEntry Defines an entry in the multicast table

EmberNeighborTableEntry Defines an entry in the neighbor table

EmberNetworkParameters Holds network parameters

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/annotated.htm (1 of 2) [10/29/2010 2:43:20 PM]

318

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 319: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Structures

EmberPrivateKeyData This data structure contains the private key data tha is used for Certificate Based Key Exchange (CBKE)

EmberPublicKeyData This data structure contains the public key data tha is used for Certificate Based Key Exchange (CBKE)

EmberRouteTableEntry Defines an entry in the route table

EmberSignatureData This data structure contains a DSA signature. It is the bit concatenantion of the 'r' and 's' components of the signature

EmberSmacDataThis data structure contains the Shared Message Authentication Code (SMAC) data that is used for Certificate Based Key Exchange (CBKE)

EmberTaskControl Control structure for tasks

EmberZigbeeNetwork Defines a ZigBee network and the associated parameters

InterPanHeader A struct for keeping track of all of the header info

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/annotated.htm (2 of 2) [10/29/2010 2:43:20 PM]

319

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 320: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ashBuffer Struct Reference

ashBuffer Struct Reference [ASH Application Utility]

#include <ash-host-queues.h>

Detailed Description

Buffer to hold a DATA frame.

Definition at line 34 of file ash-host-queues.h.

Data Fields

ashBuffer * linkint8u lenint8u data [ASH_MAX_DATA_FIELD_LEN]

Field Documentation

struct ashBuffer* ashBuffer::link

Definition at line 35 of file ash-host-queues.h.

int8u ashBuffer::len

Definition at line 36 of file ash-host-queues.h.

int8u ashBuffer::data[ASH_MAX_DATA_FIELD_LEN]

Definition at line 37 of file ash-host-queues.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structashBuffer.htm (1 of 2) [10/29/2010 2:43:20 PM]

320

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 321: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ashBuffer Struct Reference

The documentation for this struct was generated from the following file:

● ash-host-queues.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structashBuffer.htm (2 of 2) [10/29/2010 2:43:20 PM]

321

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 322: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: AshCount Struct Reference

AshCount Struct Reference [ASH Application Utility]

#include <ash-host.h>

Detailed Description

Definition at line 81 of file ash-host.h.

Data Fields

int32u txBytesint32u txBlocksint32u txDataint32u txAllFramesint32u txDataFramesint32u txAckFramesint32u txNakFramesint32u txReDataFramesint32u txN0Framesint32u txN1Framesint32u txCancelledint32u rxBytesint32u rxBlocksint32u rxDataint32u rxAllFramesint32u rxDataFramesint32u rxAckFramesint32u rxNakFramesint32u rxReDataFramesint32u rxN0Framesint32u rxN1Framesint32u rxCancelledint32u rxCrcErrorsint32u rxCommErrorsint32u rxTooShortint32u rxTooLong

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structAshCount.htm (1 of 8) [10/29/2010 2:43:21 PM]

322

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 323: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: AshCount Struct Reference

int32u rxBadControlint32u rxBadLengthint32u rxBadAckNumberint32u rxNoBufferint32u rxDuplicatesint32u rxOutOfSequenceint32u rxAckTimeouts

Field Documentation

int32u AshCount::txBytes

total bytes transmitted

Definition at line 83 of file ash-host.h.

int32u AshCount::txBlocks

blocks transmitted

Definition at line 84 of file ash-host.h.

int32u AshCount::txData

DATA frame data fields bytes transmitted

Definition at line 85 of file ash-host.h.

int32u AshCount::txAllFrames

frames of all types transmitted

Definition at line 86 of file ash-host.h.

int32u AshCount::txDataFrames

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structAshCount.htm (2 of 8) [10/29/2010 2:43:21 PM]

323

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 324: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: AshCount Struct Reference

DATA frames transmitted

Definition at line 87 of file ash-host.h.

int32u AshCount::txAckFrames

ACK frames transmitted

Definition at line 88 of file ash-host.h.

int32u AshCount::txNakFrames

NAK frames transmitted

Definition at line 89 of file ash-host.h.

int32u AshCount::txReDataFrames

DATA frames retransmitted

Definition at line 90 of file ash-host.h.

int32u AshCount::txN0Frames

ACK and NAK frames with nFlag 0 transmitted

Definition at line 91 of file ash-host.h.

int32u AshCount::txN1Frames

ACK and NAK frames with nFlag 1 transmitted

Definition at line 92 of file ash-host.h.

int32u AshCount::txCancelled

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structAshCount.htm (3 of 8) [10/29/2010 2:43:21 PM]

324

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 325: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: AshCount Struct Reference

frames cancelled (with ASH_CAN byte)

Definition at line 93 of file ash-host.h.

int32u AshCount::rxBytes

total bytes received

Definition at line 95 of file ash-host.h.

int32u AshCount::rxBlocks

blocks received

Definition at line 96 of file ash-host.h.

int32u AshCount::rxData

DATA frame data fields bytes received

Definition at line 97 of file ash-host.h.

int32u AshCount::rxAllFrames

frames of all types received

Definition at line 98 of file ash-host.h.

int32u AshCount::rxDataFrames

DATA frames received

Definition at line 99 of file ash-host.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structAshCount.htm (4 of 8) [10/29/2010 2:43:21 PM]

325

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 326: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: AshCount Struct Reference

int32u AshCount::rxAckFrames

ACK frames received

Definition at line 100 of file ash-host.h.

int32u AshCount::rxNakFrames

NAK frames received

Definition at line 101 of file ash-host.h.

int32u AshCount::rxReDataFrames

retransmitted DATA frames received

Definition at line 102 of file ash-host.h.

int32u AshCount::rxN0Frames

ACK and NAK frames with nFlag 0 received

Definition at line 103 of file ash-host.h.

int32u AshCount::rxN1Frames

ACK and NAK frames with nFlag 1 received

Definition at line 104 of file ash-host.h.

int32u AshCount::rxCancelled

frames cancelled (with ASH_CAN byte)

Definition at line 105 of file ash-host.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structAshCount.htm (5 of 8) [10/29/2010 2:43:21 PM]

326

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 327: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: AshCount Struct Reference

int32u AshCount::rxCrcErrors

frames with CRC errors

Definition at line 107 of file ash-host.h.

int32u AshCount::rxCommErrors

frames with comm errors (with ASH_SUB byte)

Definition at line 108 of file ash-host.h.

int32u AshCount::rxTooShort

frames shorter than minimum

Definition at line 109 of file ash-host.h.

int32u AshCount::rxTooLong

frames longer than maximum

Definition at line 110 of file ash-host.h.

int32u AshCount::rxBadControl

frames with illegal control byte

Definition at line 111 of file ash-host.h.

int32u AshCount::rxBadLength

frames with illegal length for type of frame

Definition at line 112 of file ash-host.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structAshCount.htm (6 of 8) [10/29/2010 2:43:21 PM]

327

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 328: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: AshCount Struct Reference

int32u AshCount::rxBadAckNumber

frames with bad ACK numbers

Definition at line 113 of file ash-host.h.

int32u AshCount::rxNoBuffer

DATA frames discarded due to lack of buffers

Definition at line 114 of file ash-host.h.

int32u AshCount::rxDuplicates

duplicate retransmitted DATA frames

Definition at line 115 of file ash-host.h.

int32u AshCount::rxOutOfSequence

DATA frames received out of sequence

Definition at line 116 of file ash-host.h.

int32u AshCount::rxAckTimeouts

received ACK timeouts

Definition at line 117 of file ash-host.h.

The documentation for this struct was generated from the following file:

● ash-host.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structAshCount.htm (7 of 8) [10/29/2010 2:43:21 PM]

328

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 329: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: AshCount Struct Reference

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structAshCount.htm (8 of 8) [10/29/2010 2:43:21 PM]

329

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 330: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: AshFreeList Struct Reference

AshFreeList Struct Reference [ASH Application Utility]

#include <ash-host-queues.h>

Detailed Description

Simple free list (singly-linked list).

Definition at line 48 of file ash-host-queues.h.

Data Fields

AshBuffer * link

Field Documentation

AshBuffer* AshFreeList::link

Definition at line 49 of file ash-host-queues.h.

The documentation for this struct was generated from the following file:

● ash-host-queues.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structAshFreeList.htm [10/29/2010 2:43:21 PM]

330

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 331: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: AshHostConfig Struct Reference

AshHostConfig Struct Reference [ASH Application Utility]

#include <ash-host.h>

Detailed Description

Configuration parameters: values must be defined before calling ashResetNcp() or ashStart(). Note that all times are in milliseconds.

Definition at line 47 of file ash-host.h.

Data Fields

char serialPort [ASH_PORT_LEN]int32u baudRate

int8u stopBitsint8u rtsCts

int16u outBlockLenint16u inBlockLen

int8u traceFlagsint8u txKint8u randomize

int16u ackTimeInitint16u ackTimeMinint16u ackTimeMaxint16u timeRst

int8u nrLowLimitint8u nrHighLimit

int16u nrTimeint8u resetMethodint8u ncpType

Field Documentation

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structAshHostConfig.htm (1 of 5) [10/29/2010 2:43:22 PM]

331

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 332: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: AshHostConfig Struct Reference

char AshHostConfig::serialPort[ASH_PORT_LEN]

serial port name

Definition at line 49 of file ash-host.h.

int32u AshHostConfig::baudRate

baud rate (bits/second)

Definition at line 50 of file ash-host.h.

int8u AshHostConfig::stopBits

stop bits

Definition at line 51 of file ash-host.h.

int8u AshHostConfig::rtsCts

TRUE enables RTS/CTS flow control, FALSE XON/XOFF

Definition at line 52 of file ash-host.h.

int16u AshHostConfig::outBlockLen

max bytes to buffer before writing to serial port

Definition at line 53 of file ash-host.h.

int16u AshHostConfig::inBlockLen

max bytes to read ahead from serial port

Definition at line 54 of file ash-host.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structAshHostConfig.htm (2 of 5) [10/29/2010 2:43:22 PM]

332

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 333: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: AshHostConfig Struct Reference

int8u AshHostConfig::traceFlags

trace output control bit flags

Definition at line 55 of file ash-host.h.

int8u AshHostConfig::txK

max frames sent without being ACKed (1-7)

Definition at line 56 of file ash-host.h.

int8u AshHostConfig::randomize

enables randomizing DATA frame payloads

Definition at line 57 of file ash-host.h.

int16u AshHostConfig::ackTimeInit

adaptive rec'd ACK timeout initial value

Definition at line 58 of file ash-host.h.

int16u AshHostConfig::ackTimeMin

adaptive rec'd ACK timeout minimum value

Definition at line 59 of file ash-host.h.

int16u AshHostConfig::ackTimeMax

adaptive rec'd ACK timeout maximum value

Definition at line 60 of file ash-host.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structAshHostConfig.htm (3 of 5) [10/29/2010 2:43:22 PM]

333

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 334: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: AshHostConfig Struct Reference

int16u AshHostConfig::timeRst

time allowed to receive RSTACK after ncp is reset

Definition at line 61 of file ash-host.h.

int8u AshHostConfig::nrLowLimit

if free buffers < limit, host receiver isn't ready

Definition at line 62 of file ash-host.h.

int8u AshHostConfig::nrHighLimit

if free buffers > limit, host receiver is ready

Definition at line 63 of file ash-host.h.

int16u AshHostConfig::nrTime

time until a set nFlag must be resent (max 2032)

Definition at line 64 of file ash-host.h.

int8u AshHostConfig::resetMethod

method used to reset ncp

Definition at line 65 of file ash-host.h.

int8u AshHostConfig::ncpType

type of ncp processor

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structAshHostConfig.htm (4 of 5) [10/29/2010 2:43:22 PM]

334

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 335: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: AshHostConfig Struct Reference

Definition at line 66 of file ash-host.h.

The documentation for this struct was generated from the following file:

● ash-host.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structAshHostConfig.htm (5 of 5) [10/29/2010 2:43:22 PM]

335

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 336: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: AshQueue Struct Reference

AshQueue Struct Reference [ASH Application Utility]

#include <ash-host-queues.h>

Detailed Description

Simple queue (singly-linked list).

Definition at line 42 of file ash-host-queues.h.

Data Fields

AshBuffer * tail

Field Documentation

AshBuffer* AshQueue::tail

Definition at line 43 of file ash-host-queues.h.

The documentation for this struct was generated from the following file:

● ash-host-queues.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structAshQueue.htm [10/29/2010 2:43:22 PM]

336

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 337: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberAesMmoHashContext Struct Reference

EmberAesMmoHashContext Struct Reference [Ember Common Data Types]

#include <ember-types.h>

Detailed Description

This data structure contains the context data when calculating an AES MMO hash (message digest).

Definition at line 1228 of file ember-types.h.

Data Fields

int8u result [EMBER_AES_HASH_BLOCK_SIZE]int32u length

Field Documentation

int8u EmberAesMmoHashContext::result[EMBER_AES_HASH_BLOCK_SIZE]

Definition at line 1229 of file ember-types.h.

int32u EmberAesMmoHashContext::length

Definition at line 1230 of file ember-types.h.

The documentation for this struct was generated from the following file:

● ember-types.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structEmberAesMmoHashContext.htm [10/29/2010 2:43:23 PM]

337

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 338: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberApsFrame Struct Reference

EmberApsFrame Struct Reference [Ember Common Data Types]

#include <ember-types.h>

Detailed Description

An in-memory representation of a ZigBee APS frame of an incoming or outgoing message.

Definition at line 687 of file ember-types.h.

Data Fields

int16u profileIdint16u clusterId

int8u sourceEndpointint8u destinationEndpoint

EmberApsOption optionsint16u groupId

int8u sequence

Field Documentation

int16u EmberApsFrame::profileId

The application profile ID that describes the format of the message.

Definition at line 689 of file ember-types.h.

int16u EmberApsFrame::clusterId

The cluster ID for this message.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structEmberApsFrame.htm (1 of 3) [10/29/2010 2:43:23 PM]

338

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 339: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberApsFrame Struct Reference

Definition at line 691 of file ember-types.h.

int8u EmberApsFrame::sourceEndpoint

The source endpoint.

Definition at line 693 of file ember-types.h.

int8u EmberApsFrame::destinationEndpoint

The destination endpoint.

Definition at line 695 of file ember-types.h.

EmberApsOption EmberApsFrame::options

A bitmask of options from the enumeration above.

Definition at line 697 of file ember-types.h.

int16u EmberApsFrame::groupId

The group ID for this message, if it is multicast mode.

Definition at line 699 of file ember-types.h.

int8u EmberApsFrame::sequence

The sequence number.

Definition at line 701 of file ember-types.h.

The documentation for this struct was generated from the following file:

● ember-types.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structEmberApsFrame.htm (2 of 3) [10/29/2010 2:43:23 PM]

339

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 340: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberApsFrame Struct Reference

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structEmberApsFrame.htm (3 of 3) [10/29/2010 2:43:23 PM]

340

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 341: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberBindingTableEntry Struct Reference

EmberBindingTableEntry Struct Reference [Ember Common Data Types]

#include <ember-types.h>

Detailed Description

Defines an entry in the binding table.

A binding entry specifies a local endpoint, a remote endpoint, a cluster ID and either the destination EUI64 (for unicast bindings) or the 64-bit group address (for multicast bindings).

Definition at line 711 of file ember-types.h.

Data Fields

EmberBindingType typeint8u local

int16u clusterIdint8u remote

EmberEUI64 identifier

Field Documentation

EmberBindingType EmberBindingTableEntry::type

The type of binding.

Definition at line 713 of file ember-types.h.

int8u EmberBindingTableEntry::local

The endpoint on the local node.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen...utput/API_EM260_forPDF/structEmberBindingTableEntry.htm (1 of 2) [10/29/2010 2:43:24 PM]

341

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 342: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberBindingTableEntry Struct Reference

Definition at line 715 of file ember-types.h.

int16u EmberBindingTableEntry::clusterId

A cluster ID that matches one from the local endpoint's simple descriptor. This cluster ID is set by the provisioning application to indicate which part an endpoint's functionality is bound to this particular remote node and is used to distinguish between unicast and multicast bindings. Note that a binding can be used to to send messages with any cluster ID, not just that listed in the binding.

Definition at line 723 of file ember-types.h.

int8u EmberBindingTableEntry::remote

The endpoint on the remote node (specified by identifier).

Definition at line 725 of file ember-types.h.

EmberEUI64 EmberBindingTableEntry::identifier

A 64-bit identifier. This is either:

● The destination EUI64, for unicasts● A 16-bit multicast group address, for multicasts

Definition at line 730 of file ember-types.h.

The documentation for this struct was generated from the following file:

● ember-types.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen...utput/API_EM260_forPDF/structEmberBindingTableEntry.htm (2 of 2) [10/29/2010 2:43:24 PM]

342

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 343: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberCertificateData Struct Reference

EmberCertificateData Struct Reference [Ember Common Data Types]

#include <ember-types.h>

Detailed Description

This data structure contains the certificate data that is used for Certificate Based Key Exchange (CBKE).

Definition at line 1189 of file ember-types.h.

Data Fields

int8u contents [EMBER_CERTIFICATE_SIZE]

Field Documentation

int8u EmberCertificateData::contents[EMBER_CERTIFICATE_SIZE]

Definition at line 1191 of file ember-types.h.

The documentation for this struct was generated from the following file:

● ember-types.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structEmberCertificateData.htm [10/29/2010 2:43:24 PM]

343

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 344: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberCommandEntry Struct Reference

EmberCommandEntry Struct Reference [Command Interpreter]

#include <command-interpreter.h>

Detailed Description

Command entry for a command table.

Definition at line 106 of file command-interpreter.h.

Data Fields

PGM_P longNameCommandAction action

PGM_P argumentTypesPGM_P description

Field Documentation

PGM_P EmberCommandEntry::longName

Use letters, digits, and underscores, '_', for the long command name. Command names are case-sensitive.

Definition at line 113 of file command-interpreter.h.

CommandAction EmberCommandEntry::action

A reference to a function in the application that implements the command.

Definition at line 117 of file command-interpreter.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structEmberCommandEntry.htm (1 of 2) [10/29/2010 2:43:25 PM]

344

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 345: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberCommandEntry Struct Reference

PGM_P EmberCommandEntry::argumentTypes

String that specifies the number and types of arguments the command accepts. The argument specifiers are:

● b: buffer● u1: one-byte unsigned● u2: two-byte unsigned● u4: four-byte unsigned (32 bit platforms only)● s1: one-byte signed● s2: two-byte signed● *: zero or more of the previous type. If used, this must be the last specifier.

Buffer arguments are given as a string "...". There is currently no way for including quote characters ',"",' in buffer arguments. Buffer arguments can also be given as a hex digit string using curly braces: {1A2B3C}. The hex digits are converted to bytes in pairs.

Integer arguments can be either decimal or hexidecimal. If the integerBase field of the command state is 16 then all integers are read as hexidecimal. If integerBase is 10 then a decimal is the default and a 0x prefix indicates a hexidecimal integer.

Definition at line 139 of file command-interpreter.h.

PGM_P EmberCommandEntry::description

A description of the command.

Definition at line 142 of file command-interpreter.h.

The documentation for this struct was generated from the following file:

● command-interpreter.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structEmberCommandEntry.htm (2 of 2) [10/29/2010 2:43:25 PM]

345

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 346: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberCommandStateS Struct Reference

EmberCommandStateS Struct Reference [Command Interpreter]

#include <command-interpreter.h>

Detailed Description

The command state structure. Using a structure allows commands to be read from multiple sources.

Definition at line 174 of file command-interpreter.h.

Data Fields

EmberCommandEntry * commandsvoid(* errorHandler )(struct EmberCommandStateS *state)

ArgTypeU * argumentsint8u maximumArgumentsint8u integerBaseint8u argumentCountint8u stateint8u errorint8u command [EMBER_MAX_COMMAND_LENGTH+1]

int16u commandIndexPGM_P argumentSpecs

int8u stringLengthint8u binaryLength

EmberMessageBuffer stringBufferArgTypeU integerValue

int8u integerSignint8u currentIntegerBase

EmberCommandEntry * currentCommands

Field Documentation

EmberCommandEntry* EmberCommandStateS::commands

The table of commands created in the application.

Definition at line 177 of file command-interpreter.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structEmberCommandStateS.htm (1 of 4) [10/29/2010 2:43:25 PM]

346

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 347: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberCommandStateS Struct Reference

void(* EmberCommandStateS::errorHandler)(struct EmberCommandStateS *state)

ArgTypeU* EmberCommandStateS::arguments

Arguments filled in by the interpreter.

Definition at line 180 of file command-interpreter.h.

int8u EmberCommandStateS::maximumArguments

Definition at line 182 of file command-interpreter.h.

int8u EmberCommandStateS::integerBase

Determines whether integers are parsed using base 10 or base 16. Valid values are only 10 or 16.

Definition at line 186 of file command-interpreter.h.

int8u EmberCommandStateS::argumentCount

Set by the interpreter for use by the command function.

Definition at line 188 of file command-interpreter.h.

int8u EmberCommandStateS::state

Finite-state machine's current state.

Definition at line 193 of file command-interpreter.h.

int8u EmberCommandStateS::error

First error found in this command.

Definition at line 195 of file command-interpreter.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structEmberCommandStateS.htm (2 of 4) [10/29/2010 2:43:25 PM]

347

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 348: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberCommandStateS Struct Reference

int8u EmberCommandStateS::command[EMBER_MAX_COMMAND_LENGTH+1]

For reading in and remembering the current command. The "+ 1" is for the trailing null.

Definition at line 199 of file command-interpreter.h.

int16u EmberCommandStateS::commandIndex

Definition at line 201 of file command-interpreter.h.

PGM_P EmberCommandStateS::argumentSpecs

Stepped forward as arguments are read.

Definition at line 203 of file command-interpreter.h.

int8u EmberCommandStateS::stringLength

Bytes read in so far.

Definition at line 205 of file command-interpreter.h.

int8u EmberCommandStateS::binaryLength

Remaining bytes in the binary block.

Definition at line 207 of file command-interpreter.h.

EmberMessageBuffer EmberCommandStateS::stringBuffer

Definition at line 209 of file command-interpreter.h.

ArgTypeU EmberCommandStateS::integerValue

Definition at line 211 of file command-interpreter.h.

int8u EmberCommandStateS::integerSign

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structEmberCommandStateS.htm (3 of 4) [10/29/2010 2:43:25 PM]

348

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 349: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberCommandStateS Struct Reference

Valid values are '+' or '-'.

Definition at line 213 of file command-interpreter.h.

int8u EmberCommandStateS::currentIntegerBase

Definition at line 215 of file command-interpreter.h.

EmberCommandEntry* EmberCommandStateS::currentCommands

Used for pointing to a table of subcommands.

Definition at line 218 of file command-interpreter.h.

The documentation for this struct was generated from the following file:

● command-interpreter.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structEmberCommandStateS.htm (4 of 4) [10/29/2010 2:43:25 PM]

349

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 350: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberCurrentSecurityState Struct Reference

EmberCurrentSecurityState Struct Reference [Ember Common Data Types]

#include <ember-types.h>

Detailed Description

This describes the security features used by the stack for a joined device.

Definition at line 1439 of file ember-types.h.

Data Fields

EmberCurrentSecurityBitmask bitmaskEmberEUI64 trustCenterLongAddress

Field Documentation

EmberCurrentSecurityBitmask EmberCurrentSecurityState::bitmask

This bitmask indicates the security features currently in use on this node.

Definition at line 1442 of file ember-types.h.

EmberEUI64 EmberCurrentSecurityState::trustCenterLongAddress

This indicates the EUI64 of the Trust Center. It will be all zeroes if the Trust Center Address is not known (i.e. the device is in a Distributed Trust Center network).

Definition at line 1446 of file ember-types.h.

The documentation for this struct was generated from the following file:

file:///C|/dev/perforce/software/v2/tephra-park/doxygen...ut/API_EM260_forPDF/structEmberCurrentSecurityState.htm (1 of 2) [10/29/2010 2:43:26 PM]

350

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 351: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberCurrentSecurityState Struct Reference

● ember-types.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen...ut/API_EM260_forPDF/structEmberCurrentSecurityState.htm (2 of 2) [10/29/2010 2:43:26 PM]

351

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 352: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberEventControl Struct Reference

EmberEventControl Struct Reference [Ember Common Data Types]

#include <ember-types.h>

Detailed Description

Control structure for events.

This structure should not be accessed directly. This holds the event status (one of the EMBER_EVENT_ values) and the time left before the event fires.

Definition at line 955 of file ember-types.h.

Data Fields

EmberEventUnits statusEmberTaskId taskid

int32u timeToExecute

Field Documentation

EmberEventUnits EmberEventControl::status

The event's status, either inactive or the units for timeToExecute.

Definition at line 957 of file ember-types.h.

EmberTaskId EmberEventControl::taskid

The id of the task this event belongs to.

Definition at line 959 of file ember-types.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structEmberEventControl.htm (1 of 2) [10/29/2010 2:43:26 PM]

352

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 353: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberEventControl Struct Reference

int32u EmberEventControl::timeToExecute

How long before the event fires. Units are always in milliseconds

Definition at line 963 of file ember-types.h.

The documentation for this struct was generated from the following file:

● ember-types.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structEmberEventControl.htm (2 of 2) [10/29/2010 2:43:26 PM]

353

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 354: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberInitialSecurityState Struct Reference

EmberInitialSecurityState Struct Reference [Ember Common Data Types]

#include <ember-types.h>

Detailed Description

This describes the Initial Security features and requirements that will be used when forming or joining the network.

Definition at line 1359 of file ember-types.h.

Data Fields

int16u bitmaskEmberKeyData preconfiguredKeyEmberKeyData networkKey

int8u networkKeySequenceNumberEmberEUI64 preconfiguredTrustCenterEui64

Field Documentation

int16u EmberInitialSecurityState::bitmask

This bitmask enumerates which security features should be used, as well as the presence of valid data within other elements of the EmberInitialSecurityState data structure. For more details see the EmberInitialSecurityBitmask.

Definition at line 1364 of file ember-types.h.

EmberKeyData EmberInitialSecurityState::preconfiguredKey

This is the pre-configured key that can used by devices when joining the network if the Trust Center does not send the initial security data in-the-clear. For the Trust Center, it will be the global

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/...put/API_EM260_forPDF/structEmberInitialSecurityState.htm (1 of 3) [10/29/2010 2:43:27 PM]

354

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 355: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberInitialSecurityState Struct Reference

link key and must be set regardless of whether joining devices are expected to have a pre-configured Link Key. This parameter will only be used if the EmberInitialSecurityState::bitmask sets the bit indicating EMBER_HAVE_PRECONFIGURED_KEY

Definition at line 1373 of file ember-types.h.

EmberKeyData EmberInitialSecurityState::networkKey

This is the Network Key used when initially forming the network. This must be set on the Trust Center. It is not needed for devices joining the network. This parameter will only be used if the EmberInitialSecurityState::bitmask sets the bit indicating EMBER_HAVE_NETWORK_KEY.

Definition at line 1379 of file ember-types.h.

int8u EmberInitialSecurityState::networkKeySequenceNumber

This is the sequence number associated with the network key. It must be set if the Network Key is set. It is used to indicate a particular of the network key for updating and swtiching. This parameter will only be used if the EMBER_HAVE_NETWORK_KEY is set. Generally it should be set to 0 when forming the network; joining devices can ignore this value.

Definition at line 1386 of file ember-types.h.

EmberEUI64 EmberInitialSecurityState::preconfiguredTrustCenterEui64

This is the long address of the trust center on the network that will be joined. It is usually NOT set prior to joining the network and instead it is learned during the joining message exchange. This field is only examined if EMBER_HAVE_TRUST_CENTER_EUI64 is set in the EmberInitialSecurityState::bitmask. Most devices should clear that bit and leave this field alone. This field must be set when using commissioning mode. It is required to be in little-endian format.

Definition at line 1394 of file ember-types.h.

The documentation for this struct was generated from the following file:

● ember-types.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/...put/API_EM260_forPDF/structEmberInitialSecurityState.htm (2 of 3) [10/29/2010 2:43:27 PM]

355

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 356: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberInitialSecurityState Struct Reference

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/...put/API_EM260_forPDF/structEmberInitialSecurityState.htm (3 of 3) [10/29/2010 2:43:27 PM]

356

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 357: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberKeyData Struct Reference

EmberKeyData Struct Reference [Ember Common Data Types]

#include <ember-types.h>

Detailed Description

This data structure contains the key data that is pasesd into various other functions.

Definition at line 1182 of file ember-types.h.

Data Fields

int8u contents [EMBER_ENCRYPTION_KEY_SIZE]

Field Documentation

int8u EmberKeyData::contents[EMBER_ENCRYPTION_KEY_SIZE]

This is the key byte data.

Definition at line 1184 of file ember-types.h.

The documentation for this struct was generated from the following file:

● ember-types.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structEmberKeyData.htm [10/29/2010 2:43:27 PM]

357

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 358: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberKeyStruct Struct Reference

EmberKeyStruct Struct Reference [Ember Common Data Types]

#include <ember-types.h>

Detailed Description

This describes a one of several different types of keys and its associated data.

Definition at line 1506 of file ember-types.h.

Data Fields

EmberKeyStructBitmask bitmaskEmberKeyType typeEmberKeyData key

int32u outgoingFrameCounterint32u incomingFrameCounter

int8u sequenceNumberEmberEUI64 partnerEUI64

Field Documentation

EmberKeyStructBitmask EmberKeyStruct::bitmask

This bitmask indicates whether various fields in the structure contain valid data.

Definition at line 1509 of file ember-types.h.

EmberKeyType EmberKeyStruct::type

This indicates the type of the security key.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structEmberKeyStruct.htm (1 of 3) [10/29/2010 2:43:27 PM]

358

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 359: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberKeyStruct Struct Reference

Definition at line 1511 of file ember-types.h.

EmberKeyData EmberKeyStruct::key

This is the actual key data.

Definition at line 1513 of file ember-types.h.

int32u EmberKeyStruct::outgoingFrameCounter

This is the outgoing frame counter associated with the key. It will contain valid data based on the EmberKeyStructBitmask.

Definition at line 1516 of file ember-types.h.

int32u EmberKeyStruct::incomingFrameCounter

This is the incoming frame counter associated with the key. It will contain valid data based on the EmberKeyStructBitmask.

Definition at line 1519 of file ember-types.h.

int8u EmberKeyStruct::sequenceNumber

This is the sequence number associated with the key. It will contain valid data based on the EmberKeyStructBitmask.

Definition at line 1522 of file ember-types.h.

EmberEUI64 EmberKeyStruct::partnerEUI64

This is the Partner EUI64 associated with the key. It will contain valid data based on the EmberKeyStructBitmask.

Definition at line 1525 of file ember-types.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structEmberKeyStruct.htm (2 of 3) [10/29/2010 2:43:27 PM]

359

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 360: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberKeyStruct Struct Reference

The documentation for this struct was generated from the following file:

● ember-types.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structEmberKeyStruct.htm (3 of 3) [10/29/2010 2:43:27 PM]

360

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 361: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberMessageDigest Struct Reference

EmberMessageDigest Struct Reference [Ember Common Data Types]

#include <ember-types.h>

Detailed Description

This data structure contains an AES-MMO Hash (the message digest).

Definition at line 1221 of file ember-types.h.

Data Fields

int8u contents [EMBER_AES_HASH_BLOCK_SIZE]

Field Documentation

int8u EmberMessageDigest::contents[EMBER_AES_HASH_BLOCK_SIZE]

Definition at line 1222 of file ember-types.h.

The documentation for this struct was generated from the following file:

● ember-types.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structEmberMessageDigest.htm [10/29/2010 2:43:28 PM]

361

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 362: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberMulticastTableEntry Struct Reference

EmberMulticastTableEntry Struct Reference [Ember Common Data Types]

#include <ember-types.h>

Detailed Description

Defines an entry in the multicast table.

A multicast table entry indicates that a particular endpoint is a member of a particular multicast group. Only devices with an endpoint in a multicast group will receive messages sent to that multicast group.

Definition at line 798 of file ember-types.h.

Data Fields

EmberMulticastId multicastIdint8u endpoint

Field Documentation

EmberMulticastId EmberMulticastTableEntry::multicastId

The multicast group ID.

Definition at line 800 of file ember-types.h.

int8u EmberMulticastTableEntry::endpoint

The endpoint that is a member, or 0 if this entry is not in use (the ZDO is not a member of any multicast groups).

Definition at line 804 of file ember-types.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen...put/API_EM260_forPDF/structEmberMulticastTableEntry.htm (1 of 2) [10/29/2010 2:43:28 PM]

362

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 363: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberMulticastTableEntry Struct Reference

The documentation for this struct was generated from the following file:

● ember-types.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen...put/API_EM260_forPDF/structEmberMulticastTableEntry.htm (2 of 2) [10/29/2010 2:43:28 PM]

363

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 364: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberNeighborTableEntry Struct Reference

EmberNeighborTableEntry Struct Reference [Ember Common Data Types]

#include <ember-types.h>

Detailed Description

Defines an entry in the neighbor table.

A neighbor table entry stores information about the reliability of RF links to and from neighboring nodes.

Definition at line 739 of file ember-types.h.

Data Fields

int16u shortIdint8u averageLqiint8u inCostint8u outCostint8u age

EmberEUI64 longId

Field Documentation

int16u EmberNeighborTableEntry::shortId

The neighbor's two byte network id.

Definition at line 741 of file ember-types.h.

int8u EmberNeighborTableEntry::averageLqi

An exponentially weighted moving average of the link quality values of incoming packets from this

file:///C|/dev/perforce/software/v2/tephra-park/doxygen...tput/API_EM260_forPDF/structEmberNeighborTableEntry.htm (1 of 3) [10/29/2010 2:43:29 PM]

364

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 365: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberNeighborTableEntry Struct Reference

neighbor as reported by the PHY.

Definition at line 744 of file ember-types.h.

int8u EmberNeighborTableEntry::inCost

The incoming cost for this neighbor, computed from the average LQI. Values range from 1 for a good link to 7 for a bad link.

Definition at line 747 of file ember-types.h.

int8u EmberNeighborTableEntry::outCost

The outgoing cost for this neighbor, obtained from the most recently received neighbor exchange message from the neighbor. A value of zero means that a neighbor exchange message from the neighbor has not been received recently enough, or that our id was not present in the most recently received one. EmberZNet Pro only.

Definition at line 754 of file ember-types.h.

int8u EmberNeighborTableEntry::age

In EmberZNet Pro, the number of aging periods elapsed since a neighbor exchange message was last received from this neighbor. In stack profile 1, the number of aging periods since any packet was received. An entry with an age greater than 3 is considered stale and may be reclaimed. The aging period is 16 seconds.

Definition at line 760 of file ember-types.h.

EmberEUI64 EmberNeighborTableEntry::longId

The 8 byte EUI64 of the neighbor.

Definition at line 762 of file ember-types.h.

The documentation for this struct was generated from the following file:

file:///C|/dev/perforce/software/v2/tephra-park/doxygen...tput/API_EM260_forPDF/structEmberNeighborTableEntry.htm (2 of 3) [10/29/2010 2:43:29 PM]

365

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 366: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberNeighborTableEntry Struct Reference

● ember-types.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen...tput/API_EM260_forPDF/structEmberNeighborTableEntry.htm (3 of 3) [10/29/2010 2:43:29 PM]

366

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 367: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberNetworkParameters Struct Reference

EmberNetworkParameters Struct Reference [Ember Common Data Types]

#include <ember-types.h>

Detailed Description

Holds network parameters.

For information about power settings and radio channels, see the technical specification for the RF communication module in your Developer Kit.

Definition at line 642 of file ember-types.h.

Data Fields

int8u extendedPanId [8]int16u panId

int8s radioTxPowerint8u radioChannel

EmberJoinMethod joinMethodEmberNodeId nwkManagerId

int8u nwkUpdateIdint32u channels

Field Documentation

int8u EmberNetworkParameters::extendedPanId[8]

The network's extended PAN identifier.

Definition at line 644 of file ember-types.h.

int16u EmberNetworkParameters::panId

file:///C|/dev/perforce/software/v2/tephra-park/doxyge...tput/API_EM260_forPDF/structEmberNetworkParameters.htm (1 of 3) [10/29/2010 2:43:29 PM]

367

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 368: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberNetworkParameters Struct Reference

The network's PAN identifier.

Definition at line 646 of file ember-types.h.

int8s EmberNetworkParameters::radioTxPower

A power setting, in dBm.

Definition at line 648 of file ember-types.h.

int8u EmberNetworkParameters::radioChannel

A radio channel. Be sure to specify a channel supported by the radio.

Definition at line 650 of file ember-types.h.

EmberJoinMethod EmberNetworkParameters::joinMethod

Join method: The protocol messages used to establish an initial parent. It is ignored when forming a ZigBee network, or when querying the stack for its network parameters.

Definition at line 655 of file ember-types.h.

EmberNodeId EmberNetworkParameters::nwkManagerId

NWK Manager ID. The ID of the network manager in the current network. This may only be set at joining when using EMBER_USE_NWK_COMMISSIONING as the join method.

Definition at line 661 of file ember-types.h.

int8u EmberNetworkParameters::nwkUpdateId

NWK Update ID. The value of the ZigBee nwkUpdateId known by the stack. This is used to determine the newest instance of the network after a PAN ID or channel change. This may only be set at joining when using EMBER_USE_NWK_COMMISSIONING as the join method.

file:///C|/dev/perforce/software/v2/tephra-park/doxyge...tput/API_EM260_forPDF/structEmberNetworkParameters.htm (2 of 3) [10/29/2010 2:43:29 PM]

368

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 369: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberNetworkParameters Struct Reference

Definition at line 667 of file ember-types.h.

int32u EmberNetworkParameters::channels

NWK channel mask. The list of preferred channels that the NWK manager has told this device to use when searching for the network. This may only be set at joining when using EMBER_USE_NWK_COMMISSIONING as the join method.

Definition at line 673 of file ember-types.h.

The documentation for this struct was generated from the following file:

● ember-types.h

file:///C|/dev/perforce/software/v2/tephra-park/doxyge...tput/API_EM260_forPDF/structEmberNetworkParameters.htm (3 of 3) [10/29/2010 2:43:29 PM]

369

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 370: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberPrivateKeyData Struct Reference

EmberPrivateKeyData Struct Reference [Ember Common Data Types]

#include <ember-types.h>

Detailed Description

This data structure contains the private key data tha is used for Certificate Based Key Exchange (CBKE).

Definition at line 1202 of file ember-types.h.

Data Fields

int8u contents [EMBER_PRIVATE_KEY_SIZE]

Field Documentation

int8u EmberPrivateKeyData::contents[EMBER_PRIVATE_KEY_SIZE]

Definition at line 1203 of file ember-types.h.

The documentation for this struct was generated from the following file:

● ember-types.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structEmberPrivateKeyData.htm [10/29/2010 2:43:30 PM]

370

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 371: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberPublicKeyData Struct Reference

EmberPublicKeyData Struct Reference [Ember Common Data Types]

#include <ember-types.h>

Detailed Description

This data structure contains the public key data tha is used for Certificate Based Key Exchange (CBKE).

Definition at line 1196 of file ember-types.h.

Data Fields

int8u contents [EMBER_PUBLIC_KEY_SIZE]

Field Documentation

int8u EmberPublicKeyData::contents[EMBER_PUBLIC_KEY_SIZE]

Definition at line 1197 of file ember-types.h.

The documentation for this struct was generated from the following file:

● ember-types.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structEmberPublicKeyData.htm [10/29/2010 2:43:30 PM]

371

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 372: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberRouteTableEntry Struct Reference

EmberRouteTableEntry Struct Reference [Ember Common Data Types]

#include <ember-types.h>

Detailed Description

Defines an entry in the route table.

A route table entry stores information about the next hop along the route to the destination.

Definition at line 770 of file ember-types.h.

Data Fields

int16u destinationint16u nextHop

int8u statusint8u ageint8u concentratorTypeint8u routeRecordState

Field Documentation

int16u EmberRouteTableEntry::destination

The short id of the destination.

Definition at line 772 of file ember-types.h.

int16u EmberRouteTableEntry::nextHop

The short id of the next hop to this destination.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structEmberRouteTableEntry.htm (1 of 2) [10/29/2010 2:43:30 PM]

372

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 373: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberRouteTableEntry Struct Reference

Definition at line 774 of file ember-types.h.

int8u EmberRouteTableEntry::status

Indicates whether this entry is active (0), being discovered (1), or unused (3).

Definition at line 777 of file ember-types.h.

int8u EmberRouteTableEntry::age

The number of seconds since this route entry was last used to send a packet.

Definition at line 780 of file ember-types.h.

int8u EmberRouteTableEntry::concentratorType

Indicates whether this destination is a High RAM Concentrator (2), a Low RAM Concentrator (1), or not a concentrator (0).

Definition at line 783 of file ember-types.h.

int8u EmberRouteTableEntry::routeRecordState

For a High RAM Concentrator, indicates whether a route record is needed (2), has been sent (1), or is no long needed (0) because a source routed message from the concentrator has been received.

Definition at line 788 of file ember-types.h.

The documentation for this struct was generated from the following file:

● ember-types.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structEmberRouteTableEntry.htm (2 of 2) [10/29/2010 2:43:30 PM]

373

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 374: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberSignatureData Struct Reference

EmberSignatureData Struct Reference [Ember Common Data Types]

#include <ember-types.h>

Detailed Description

This data structure contains a DSA signature. It is the bit concatenantion of the 'r' and 's' components of the signature.

Definition at line 1215 of file ember-types.h.

Data Fields

int8u contents [EMBER_SIGNATURE_SIZE]

Field Documentation

int8u EmberSignatureData::contents[EMBER_SIGNATURE_SIZE]

Definition at line 1216 of file ember-types.h.

The documentation for this struct was generated from the following file:

● ember-types.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structEmberSignatureData.htm [10/29/2010 2:43:31 PM]

374

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 375: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberSmacData Struct Reference

EmberSmacData Struct Reference [Ember Common Data Types]

#include <ember-types.h>

Detailed Description

This data structure contains the Shared Message Authentication Code (SMAC) data that is used for Certificate Based Key Exchange (CBKE).

Definition at line 1208 of file ember-types.h.

Data Fields

int8u contents [EMBER_SMAC_SIZE]

Field Documentation

int8u EmberSmacData::contents[EMBER_SMAC_SIZE]

Definition at line 1209 of file ember-types.h.

The documentation for this struct was generated from the following file:

● ember-types.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structEmberSmacData.htm [10/29/2010 2:43:31 PM]

375

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 376: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberTaskControl Struct Reference

EmberTaskControl Struct Reference [Ember Common Data Types]

#include <ember-types.h>

Detailed Description

Control structure for tasks.

This structure should not be accessed directly.

Definition at line 1001 of file ember-types.h.

Data Fields

int32u nextEventTimeEmberEventData * events

boolean busy

Field Documentation

int32u EmberTaskControl::nextEventTime

Definition at line 1003 of file ember-types.h.

EmberEventData* EmberTaskControl::events

Definition at line 1005 of file ember-types.h.

boolean EmberTaskControl::busy

Definition at line 1007 of file ember-types.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structEmberTaskControl.htm (1 of 2) [10/29/2010 2:43:31 PM]

376

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 377: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberTaskControl Struct Reference

The documentation for this struct was generated from the following file:

● ember-types.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structEmberTaskControl.htm (2 of 2) [10/29/2010 2:43:31 PM]

377

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 378: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberZigbeeNetwork Struct Reference

EmberZigbeeNetwork Struct Reference [Ember Common Data Types]

#include <ember-types.h>

Detailed Description

Defines a ZigBee network and the associated parameters.

Definition at line 269 of file ember-types.h.

Data Fields

int8u channelint16u panId

int8u extendedPanId [8]boolean allowingJoin

int8u stackProfileint8u nwkUpdateId

Field Documentation

int8u EmberZigbeeNetwork::channel

Definition at line 270 of file ember-types.h.

int16u EmberZigbeeNetwork::panId

Definition at line 271 of file ember-types.h.

int8u EmberZigbeeNetwork::extendedPanId[8]

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structEmberZigbeeNetwork.htm (1 of 2) [10/29/2010 2:43:32 PM]

378

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 379: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: EmberZigbeeNetwork Struct Reference

Definition at line 272 of file ember-types.h.

boolean EmberZigbeeNetwork::allowingJoin

Definition at line 273 of file ember-types.h.

int8u EmberZigbeeNetwork::stackProfile

Definition at line 274 of file ember-types.h.

int8u EmberZigbeeNetwork::nwkUpdateId

Definition at line 275 of file ember-types.h.

The documentation for this struct was generated from the following file:

● ember-types.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structEmberZigbeeNetwork.htm (2 of 2) [10/29/2010 2:43:32 PM]

379

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 380: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: InterPanHeader Struct Reference

InterPanHeader Struct Reference [Sending and Receiving Messages, Sending and

Receiving Messages]

#include <ami-inter-pan.h>

Detailed Description

A struct for keeping track of all of the header info.

Definition at line 45 of file ami-inter-pan.h.

Data Fields

int8u messageTypeint16u panId

boolean hasLongAddressEmberNodeId shortAddressEmberEUI64 longAddress

int16u profileIdint16u clusterIdint16u groupId

Field Documentation

int8u InterPanHeader::messageType

Definition at line 46 of file ami-inter-pan.h.

int16u InterPanHeader::panId

Definition at line 51 of file ami-inter-pan.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structInterPanHeader.htm (1 of 2) [10/29/2010 2:43:32 PM]

380

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 381: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: InterPanHeader Struct Reference

boolean InterPanHeader::hasLongAddress

Definition at line 52 of file ami-inter-pan.h.

EmberNodeId InterPanHeader::shortAddress

Definition at line 53 of file ami-inter-pan.h.

EmberEUI64 InterPanHeader::longAddress

Definition at line 54 of file ami-inter-pan.h.

int16u InterPanHeader::profileId

Definition at line 57 of file ami-inter-pan.h.

int16u InterPanHeader::clusterId

Definition at line 58 of file ami-inter-pan.h.

int16u InterPanHeader::groupId

Definition at line 59 of file ami-inter-pan.h.

The documentation for this struct was generated from the following files:

● ami-inter-pan.h● ami-inter-pan-host.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/structInterPanHeader.htm (2 of 2) [10/29/2010 2:43:32 PM]

381

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 382: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: File Index

EmberZNet API Reference: For the EM260 Co-Processor File List

Here is a list of all files with brief descriptions:

_EM260_API.top [code]Starting page for the Ember API documentation for the EM260 exclusively for building documentation

adc.h [code] Header for A/D converter

ami-inter-pan-host.h [code]Utilities for sending and receiving ZigBee AMI InterPAN messages. See Sending and Receiving Messages for documentation

ami-inter-pan.h [code]Utilities for sending and receiving ZigBee AMI InterPAN messages. See Sending and Receiving Messages for documentation

ash-common.h [code] Header for ASH common functions

ash-host-io.h [code] Header for ASH host I/O functions

ash-host-priv.h [code] Private header for ASH Host functions

ash-host-queues.h [code] Header for ASH host queue functions

ash-host-ui.h [code] Header for ASH Host user interface functions

ash-host.h [code] Header for ASH Host functions

ash-protocol.h [code] ASH protocol header

bootload-ezsp-utils.h [code]Utilities used for performing stand-alone bootloading over EZSP. See Bootloading for documentation

bootload-utils.h [code]Utilities used for performing stand-alone bootloading. See Bootloading for documentation

bootloader-interface-standalone-v1.h [code]

Definition of the interface to the standalone bootloader

bootloader-interface-standalone.h [code]

bootloader.h [code] Micro-specific functions used in conjunction with either bootloader

button.h [code]

buzzer.h [code]

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/files.htm (1 of 3) [10/29/2010 2:43:33 PM]

382

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 383: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: File Index

cbke-crypto-engine.h [code] EmberZNet Smart Energy security API. See Smart Energy Security for documention

command-interpreter.h [code]Processes commands coming from the serial port. See Command Interpreter for documentation

crc.h [code]

dev0470.h [code] Functions specific to the dev0470 breakout board

dev0473.h [code] Functions specific to the dev0473 breakout board (ATmega128L-EM260)

ember-configuration-defaults.h [code] User-configurable stack memory allocation defaults

ember-debug.h [code]

ember-types.h [code] Ember data type definitions

error-def.h [code] Return-code definitions for EmberZNet stack API functions

error.h [code] Return codes for Ember API functions and module definitions

ezsp-host-configuration-defaults.h [code]

User-configurable parameters for host applications

form-and-join.h [code] Utilities for forming and joining networks

form-and-join3_2.h [code]Utilities for forming and joining networks. Deprecated and will be removed from a future release. Use form-and-join.h instead

fragment-host.h [code]

Fragmented message support for EZSP Hosts. Splits long messages into smaller blocks for transmission and reassembles received blocks. See Message Fragmentation for documentation

hal.h [code] Generic set of HAL includes for all platforms

host.h [code] Sample API functions

iar.h [code] Compiler/platform-specific definitions and typedefs for the IAR AVR C compiler

led.h [code]

linux-serial.h [code] Ember serial functionality specific to a PC with Unix library support

micro.h [code]Full HAL functions common across all microcontroller-specific files. See Common Microcontroller Functions for documentation

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/files.htm (2 of 3) [10/29/2010 2:43:33 PM]

383

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 384: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: File Index

avr-atmega/32/micro.h [code]Utility and convenience functions for ATmega32 microcontroller See Common Microcontroller Functions for documentation

avr-atmega/128/micro.h [code] Utility and convenience functions for ATmega128 microcontroller

network-manager.h [code] Utilities for use by the ZigBee network manager. See Network Manager for documentation

random.h [code]

32/reserved-ram.h [code]Memory allocations that allow for data sharing between the normally running application and bootloader

128/reserved-ram.h [code]

hal/micro/serial.h [code]Serial hardware abstraction layer interfaces. See Serial UART Communication for documentation

app/util/serial/serial.h [code] High-level serial communication functions

spi-protocol.h [code] Example AVR SPI Protocol implementation for interfacing with EM260

spi.h [code] Generic SPI manipulation routines

system-timer.h [code]

avr-atmega/32/system-timer.h [code] Functions that provide access to the system clock for ATmega32 microcontroller

avr-atmega/128/system-timer.h [code] Functions that provide access to the system clock for ATmega128 microcontroller

uart.h [code] Prototypes and defines for the hardware-specific UARTs

zigbee-device-common.h [code]ZigBee Device Object (ZDO) functions available on all platforms. See ZigBee Device Object (ZDO) Information for documentation

zigbee-device-host.h [code]ZigBee Device Object (ZDO) functions not provided by the stack. See ZigBee Device Object (ZDO) Information for documentation

zigbee-device-stack.h [code] ZigBee Device Object (ZDO) functions included in the stack

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/files.htm (3 of 3) [10/29/2010 2:43:33 PM]

384

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 385: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: _EM260_API.top File Reference

_EM260_API.top File Reference

Detailed Description

Starting page for the Ember API documentation for the EM260 exclusively for building documentation.

This file is used by Doxygen to generate the main page for the Ember API documentation, EM260.

Definition in file _EM260_API.top.

Go to the source code of this file.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/__EM260__API_8top.htm [10/29/2010 2:43:33 PM]

385

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 386: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: adc.h File Reference

hal » micro

adc.h File Reference

Detailed Description

Header for A/D converter.

See ADC Control for documentation.

Definition in file adc.h.

Go to the source code of this file.

Defines

#define NUM_ADC_USERS

Typedefs

typedef int8u ADCChannelType

Enumerations

enum ADCUser { ADC_USER_LQI, ADC_USER_APP, ADC_USER_APP2 }

enum ADCReferenceType { ADC_REF_AREF, ADC_REF_AVCC, ADC_REF_INT }

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/adc_8h.htm (1 of 2) [10/29/2010 2:43:34 PM]

386

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 387: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: adc.h File Reference

enum ADCRateType { ADC_CONVERSION_TIME_US_32, ADC_CONVERSION_TIME_US_64, ADC_CONVERSION_TIME_US_128, ADC_CONVERSION_TIME_US_256, ADC_CONVERSION_TIME_US_512, ADC_CONVERSION_TIME_US_1024, ADC_CONVERSION_TIME_US_2048, ADC_CONVERSION_TIME_US_4096 }

enum { ADC_SOURCE_ADC0, ADC_SOURCE_ADC1, ADC_SOURCE_ADC2, ADC_SOURCE_ADC3, ADC_SOURCE_ADC4, ADC_SOURCE_ADC5, ADC_SOURCE_ADC6, ADC_SOURCE_ADC7 }

Functions

void halInternalInitAdc (void)void halInternalSleepAdc (void)

EmberStatus halStartAdcConversion (ADCUser id, ADCReferenceType reference, ADCChannelType channel, ADCRateType rate)

EmberStatus halRequestAdcData (ADCUser id, int16u *value)EmberStatus halReadAdcBlocking (ADCUser id, int16u *value)EmberStatus halAdcCalibrate (ADCUser id)

int16s halConvertValueToVolts (int16u value)void emberCalibrateVref (void)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/adc_8h.htm (2 of 2) [10/29/2010 2:43:34 PM]

387

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 388: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ami-inter-pan-host.h File Reference

app » util » zigbee-framework

ami-inter-pan-host.h File Reference

Detailed Description

Utilities for sending and receiving ZigBee AMI InterPAN messages. See Sending and Receiving Messages for documentation.

Definition in file ami-inter-pan-host.h.

Go to the source code of this file.

Data Structures

struct InterPanHeader A struct for keeping track of all of the header info. More...

Defines

#define INTER_PAN_UNICAST#define INTER_PAN_BROADCAST#define INTER_PAN_MULTICAST#define MAX_INTER_PAN_MAC_SIZE#define STUB_NWK_SIZE#define STUB_NWK_FRAME_CONTROL#define MAX_STUB_APS_SIZE#define MAX_INTER_PAN_HEADER_SIZE

Functions

int8u makeInterPanMessage (InterPanHeader *headerData, int8u *message, int8u maxLength, int8u *payload, int8u payloadLength)

int8u parseInterPanMessage (int8u *message, int8u messageLength, InterPanHeader *headerData)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ami-inter-pan-host_8h.htm [10/29/2010 2:43:34 PM]

388

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 389: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ami-inter-pan.h File Reference

app » util » zigbee-framework

ami-inter-pan.h File Reference

Detailed Description

Utilities for sending and receiving ZigBee AMI InterPAN messages. See Sending and Receiving Messages for documentation.

Definition in file ami-inter-pan.h.

Go to the source code of this file.

Data Structures

struct InterPanHeader A struct for keeping track of all of the header info. More...

Defines

#define INTER_PAN_UNICAST#define INTER_PAN_BROADCAST#define INTER_PAN_MULTICAST#define MAX_INTER_PAN_MAC_SIZE#define STUB_NWK_SIZE#define STUB_NWK_FRAME_CONTROL#define MAX_STUB_APS_SIZE#define MAX_INTER_PAN_HEADER_SIZE

Functions

EmberMessageBuffer makeInterPanMessage (InterPanHeader *headerData, EmberMessageBuffer payload)

int8u parseInterPanMessage (EmberMessageBuffer message, int8u startOffset, InterPanHeader *headerData)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ami-inter-pan_8h.htm [10/29/2010 2:43:35 PM]

389

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 390: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ash-common.h File Reference

hal » micro » generic

ash-common.h File Reference

Detailed Description

Header for ASH common functions.

See Asynchronous Serial Host (ASH) Framework for documentation.

Definition in file ash-common.h.

Go to the source code of this file.

Defines

#define ashStopAckTimer(void)#define ashAckTimerIsRunning()#define ashAckTimerIsNotRunning()#define ashSetAckPeriod(msec)#define ashGetAckPeriod()#define ashSetAndStartAckTimer(msec)#define ASH_NR_TIMER_BIT#define ashStopNrTimer()#define ashNrTimerIsNotRunning()

Functions

int8u ashEncodeByte (int8u len, int8u byte, int8u *offset)EzspStatus ashDecodeByte (int8u byte, int8u *out, int8u *outLen)

int8u ashRandomizeArray (int8u seed, int8u *buf, int8u len)void ashStartAckTimer (void)

boolean ashAckTimerHasExpired (void)void ashAdjustAckPeriod (boolean expired)void ashStartNrTimer (void)

boolean ashNrTimerHasExpired (void)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ash-common_8h.htm (1 of 2) [10/29/2010 2:43:35 PM]

390

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 391: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ash-common.h File Reference

Variables

boolean ashDecodeInProgressint16u ashAckTimerint16u ashAckPeriod

int8u ashNrTimer

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ash-common_8h.htm (2 of 2) [10/29/2010 2:43:35 PM]

391

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 392: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ash-host-io.h File Reference

app » ezsp-uart-host

ash-host-io.h File Reference

Detailed Description

Header for ASH host I/O functions.

See ASH Application Utility for documentation.

Definition in file ash-host-io.h.

Go to the source code of this file.

Defines

#define DEBUG_STREAM#define ashDebugPrintf(...)#define ashDebugVfprintf(format, argPointer)

Functions

EzspStatus ashSerialInit (void)void ashSerialClose (void)void ashResetDtr (void)void ashResetCustom (void)

EzspStatus ashSerialWriteAvailable (void)void ashSerialWriteByte (int8u byte)void ashSerialWriteFlush (void)

EzspStatus ashSerialReadByte (int8u *byte)EzspStatus ashSerialReadAvailable (int16u *count)

void ashSerialReadFlush (void)void ashDebugFlush (void)

int ashSerialGetFd (void)boolean ashSerialOutputIsIdle (void)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ash-host-io_8h.htm [10/29/2010 2:43:35 PM]

392

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 393: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ash-host-priv.h File Reference

app » ezsp-uart-host

ash-host-priv.h File Reference

Detailed Description

Private header for ASH Host functions.

This file should be included only by ash-host-ui.c and ash-host.c.

See ASH Application Utility for documentation.

Definition in file ash-host-priv.h.

Go to the source code of this file.

Functions

void ashTraceFrame (boolean sent)void ashTraceEventRecdFrame (const char *string)void ashTraceEventTime (const char *string)void ashTraceDisconnected (int8u error)void ashTraceArray (int8u *name, int8u len, int8u *data)void ashTraceEzspFrameId (const char *message, int8u *ezspFrame)void ashTraceEzspVerbose (char *format,...)void ashCountFrame (boolean sent)

int8u readTxControl (void)int8u readRxControl (void)int8u readAckRx (void)int8u readAckTx (void)int8u readFrmTx (void)int8u readFrmReTx (void)int8u readFrmRx (void)int8u readAshTimeouts (void)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ash-host-priv_8h.htm [10/29/2010 2:43:36 PM]

393

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 394: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ash-host-queues.h File Reference

app » ezsp-uart-host

ash-host-queues.h File Reference

Detailed Description

Header for ASH host queue functions.

See ASH Application Utility for documentation.

Definition in file ash-host-queues.h.

Go to the source code of this file.

Data Structures

struct ashBuffer Buffer to hold a DATA frame. More...

struct AshQueue Simple queue (singly-linked list). More...

struct AshFreeList Simple free list (singly-linked list). More...

Defines

#define TX_POOL_BUFFERS#define RX_FREE_LWM#define RX_FREE_HWM

Typedefs

typedef ashBuffer AshBuffer

Functions

void ashInitQueues (void)void ashFreeBuffer (AshFreeList *list, AshBuffer *buffer)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ash-host-queues_8h.htm (1 of 2) [10/29/2010 2:43:36 PM]

394

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 395: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ash-host-queues.h File Reference

AshBuffer * ashAllocBuffer (AshFreeList *list)AshBuffer * ashRemoveQueueHead (AshQueue *queue)AshBuffer * ashQueueHead (AshQueue *queue)AshBuffer * ashQueueNthEntry (AshQueue *queue, int8u n)AshBuffer * ashQueuePrecedingEntry (AshQueue *queue, AshBuffer *buffer)AshBuffer * ashRemoveQueueEntry (AshQueue *queue, AshBuffer *buffer)

int8u ashQueueLength (AshQueue *queue)int8u ashFreeListLength (AshFreeList *list)

void ashAddQueueTail (AshQueue *queue, AshBuffer *buffer)boolean ashQueueIsEmpty (AshQueue *queue)

Variables

AshQueue txQueueAshQueue reTxQueueAshQueue rxQueue

AshFreeList txFreeAshFreeList rxFree

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ash-host-queues_8h.htm (2 of 2) [10/29/2010 2:43:36 PM]

395

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 396: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ash-host-ui.h File Reference

app » ezsp-uart-host

ash-host-ui.h File Reference

Detailed Description

Header for ASH Host user interface functions.

See ASH Application Utility for documentation.

Definition in file ash-host-ui.h.

Go to the source code of this file.

Defines

#define BUMP_HOST_COUNTER(mbr)#define ADD_HOST_COUNTER(op, mbr)

Functions

void ashPrintUsage (char *name)boolean ashProcessCommandOptions (int argc, char *argv[])

void ashTraceEvent (const char *string)void ashPrintCounters (AshCount *counters, boolean clear)void ashClearCounters (AshCount *counters)

const int8u * ashErrorString (int8u error)const int8u * ashEzspErrorString (int8u error)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ash-host-ui_8h.htm [10/29/2010 2:43:37 PM]

396

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 397: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ash-host.h File Reference

app » ezsp-uart-host

ash-host.h File Reference

Detailed Description

Header for ASH Host functions.

See ASH Application Utility for documentation.

Definition in file ash-host.h.

Go to the source code of this file.

Data Structures

struct AshHostConfig

Configuration parameters: values must be defined before calling ashResetNcp() or ashStart(). Note that all times are in milliseconds. More...

struct AshCount

Defines

#define ASH_MAX_TIMEOUTS#define ASH_MAX_WAKE_TIME#define ASH_PORT_LEN#define TRACE_FRAMES_BASIC#define TRACE_FRAMES_VERBOSE#define TRACE_EVENTS#define TRACE_EZSP#define TRACE_EZSP_VERBOSE#define ASH_RESET_METHOD_RST#define ASH_RESET_METHOD_DTR#define ASH_RESET_METHOD_CUSTOM#define ASH_RESET_METHOD_NONE#define ASH_NCP_TYPE_EM2XX_EM3XX#define ASH_HOST_CONFIG_EM2XX_EM3XX_115200_RTSCTS#define ASH_HOST_CONFIG_EM2XX_EM3XX_57600_XONXOFF

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ash-host_8h.htm (1 of 2) [10/29/2010 2:43:37 PM]

397

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 398: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ash-host.h File Reference

#define ashReadConfig(member)#define ashReadConfigOrDefault(member, defval)#define ashWriteConfig(member, value)#define BUMP_HOST_COUNTER(mbr)#define ADD_HOST_COUNTER(op, mbr)

Functions

EzspStatus ashSelectHostConfig (int8u config)EzspStatus ashStart (void)

void ashStop (void)EzspStatus ashSend (int8u len, const int8u *inptr)EzspStatus ashResetNcp (void)EzspStatus ashWakeUpNcp (boolean init)

boolean ashIsConnected (void)void ashSendExec (void)

EzspStatus ashReceiveExec (void)EzspStatus ashReceive (int8u *len, int8u *buffer)

boolean ashOkToSleep (void)

Variables

EzspStatus ashErrorEzspStatus ncpError

AshHostConfig ashHostConfigAshCount ashCount

boolean ncpSleepEnabled

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ash-host_8h.htm (2 of 2) [10/29/2010 2:43:37 PM]

398

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 399: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ash-protocol.h File Reference

hal » micro » generic

ash-protocol.h File Reference

Detailed Description

ASH protocol header.

See Asynchronous Serial Host (ASH) Framework for documentation.

Definition in file ash-protocol.h.

#include "app/util/ezsp/ezsp-protocol.h"

Go to the source code of this file.

Defines

#define ASH_VERSION#define ASH_FLAG#define ASH_ESC#define ASH_XON#define ASH_XOFF#define ASH_SUB#define ASH_CAN#define ASH_WAKE#define ASH_FLIP#define ASH_MIN_DATA_FIELD_LEN#define ASH_MAX_DATA_FIELD_LEN#define ASH_MIN_DATA_FRAME_LEN#define ASH_MIN_FRAME_LEN#define ASH_MAX_FRAME_LEN#define ASH_CRC_LEN#define ASH_MIN_FRAME_WITH_CRC_LEN#define ASH_MAX_FRAME_WITH_CRC_LEN#define ASH_NCP_SHFRAME_RX_LEN#define ASH_NCP_SHFRAME_TX_LEN#define ASH_HOST_SHFRAME_RX_LEN

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ash-protocol_8h.htm (1 of 2) [10/29/2010 2:43:38 PM]

399

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 400: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ash-protocol.h File Reference

#define ASH_HOST_SHFRAME_TX_LEN#define ASH_DFRAME_MASK#define ASH_CONTROL_DATA#define ASH_SHFRAME_MASK#define ASH_CONTROL_ACK#define ASH_CONTROL_NAK#define ASH_CONTROL_RST#define ASH_CONTROL_RSTACK#define ASH_CONTROL_ERROR#define ASH_ACKNUM_MASK#define ASH_ACKNUM_BIT#define ASH_RFLAG_MASK#define ASH_RFLAG_BIT#define ASH_NFLAG_MASK#define ASH_NFLAG_BIT#define ASH_PFLAG_MASK#define ASH_PFLAG_BIT#define ASH_FRMNUM_MASK#define ASH_FRMNUM_BIT#define ASH_GET_RFLAG(ctl)#define ASH_GET_NFLAG(ctl)#define ASH_GET_FRMNUM(ctl)#define ASH_GET_ACKNUM(ctl)#define ASH_FRAME_LEN_DATA_MIN#define ASH_FRAME_LEN_ACK#define ASH_FRAME_LEN_NAK#define ASH_FRAME_LEN_RST#define ASH_FRAME_LEN_RSTACK#define ASH_FRAME_LEN_ERROR#define MOD8(n)#define INC8(n)#define WITHIN_RANGE(lo, n, hi)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ash-protocol_8h.htm (2 of 2) [10/29/2010 2:43:38 PM]

400

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 401: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: bootload-ezsp-utils.h File Reference

app » util » bootload

bootload-ezsp-utils.h File Reference

Detailed Description

Utilities used for performing stand-alone bootloading over EZSP. See Bootloading for documentation.

Definition in file bootload-ezsp-utils.h.

Go to the source code of this file.

Defines

#define TICKS_PER_QUARTER_SECOND

Functions

boolean hostBootloadUtilLaunchRequestHandler (int8u lqi, int8s rssi, int16u manufacturerId, int8u *hardwareTag, EmberEUI64 sourceEui)

void hostBootloadUtilQueryResponseHandler (int8u lqi, int8s rssi, boolean bootloaderActive, int16u manufacturerId, int8u *hardwareTag, EmberEUI64 targetEui, int8u bootloaderCapabilities, int8u platform, int8u micro, int8u phy, int16u blVersion)

void hostBootloadReinitHandler (void)boolean isTheSameEui64 (EmberEUI64 sourceEui, EmberEUI64 targetEui)

void printLittleEndianEui64 (int8u port, EmberEUI64 eui64)void printBigEndianEui64 (int8u port, EmberEUI64 eui64)

EmberStatus debugPrintf (int8u port, PGM_P formatString,...)

Variables

int16u nodeBlVersionint8u nodePlatint8u nodeMicroint8u nodePhy

EzspStatus bootloadEzspLastError

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/bootload-ezsp-utils_8h.htm (1 of 2) [10/29/2010 2:43:38 PM]

401

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 402: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: bootload-ezsp-utils.h File Reference

EzspStatus ignoreNextEzspError

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/bootload-ezsp-utils_8h.htm (2 of 2) [10/29/2010 2:43:38 PM]

402

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 403: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: bootload-utils.h File Reference

app » util » bootload

bootload-utils.h File Reference

Detailed Description

Utilities used for performing stand-alone bootloading. See Bootloading for documentation.

Definition in file bootload-utils.h.

Go to the source code of this file.

Authentication Challenge and Response

The authentication challenge and response must be the same size. The size is chosen to be evenly divisible by the size of a 128-bit AES block.

#define BOOTLOAD_AUTH_COMMON_SIZE#define BOOTLOAD_AUTH_CHALLENGE_SIZE#define BOOTLOAD_AUTH_RESPONSE_SIZE

Bootload State Variables

Used to check whether a bootloading process is currently happening.

#define IS_BOOTLOADINGbootloadState blState

Defines

#define BOOTLOAD_HARDWARE_TAG_SIZE

Enumerations

enum bootloadMode { BOOTLOAD_MODE_NONE, BOOTLOAD_MODE_PASSTHRU }

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/bootload-utils_8h.htm (1 of 2) [10/29/2010 2:43:39 PM]

403

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 404: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: bootload-utils.h File Reference

enum bootloadState { BOOTLOAD_STATE_NORMAL, BOOTLOAD_STATE_QUERY, BOOTLOAD_STATE_WAIT_FOR_AUTH_CHALLENGE, BOOTLOAD_STATE_WAIT_FOR_AUTH_RESPONSE, BOOTLOAD_STATE_DELAY_BEFORE_START, BOOTLOAD_STATE_START_UNICAST_BOOTLOAD, BOOTLOAD_STATE_START_BROADCAST_BOOTLOAD, BOOTLOAD_STATE_START_SENDING_IMAGE, BOOTLOAD_STATE_SENDING_IMAGE, BOOTLOAD_STATE_WAIT_FOR_IMAGE_ACK, BOOTLOAD_STATE_WAIT_FOR_COMPLETE_ACK, BOOTLOAD_STATE_DONE }

Functions

void bootloadUtilInit (int8u appPort, int8u bootloadPort)EmberStatus bootloadUtilSendRequest (EmberEUI64 targetEui, int16u mfgId, int8u

hardwareTag[BOOTLOAD_HARDWARE_TAG_SIZE], int8u encryptKey[BOOTLOAD_AUTH_COMMON_SIZE], bootloadMode mode)

void bootloadUtilSendQuery (EmberEUI64 target)void bootloadUtilStartBootload (EmberEUI64 target, bootloadMode mode)void bootloadUtilTick (void)

boolean bootloadUtilLaunchRequestHandler (int16u manufacturerId, int8u hardwareTag[BOOTLOAD_HARDWARE_TAG_SIZE], EmberEUI64 sourceEui)

void bootloadUtilQueryResponseHandler (boolean bootloaderActive, int16u manufacturerId, int8u hardwareTag[BOOTLOAD_HARDWARE_TAG_SIZE], EmberEUI64 targetEui, int8u bootloaderCapabilities, int8u platform, int8u micro, int8u phy, int16u blVersion)

void bootloadUtilSendAuthResponse (EmberEUI64 target)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/bootload-utils_8h.htm (2 of 2) [10/29/2010 2:43:39 PM]

404

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 405: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: bootloader-interface-standalone-v1.h File Reference

hal » micro » avr-atmega

bootloader-interface-standalone-v1.h File Reference

Detailed Description

Definition of the interface to the standalone bootloader.

See Stand-Alone Bootloader Interface for documentation.

Some functions in this file return an EmberStatus value. See error-def.h for definitions of all EmberStatus return values.

Definition in file bootloader-interface-standalone-v1.h.

Go to the source code of this file.

Defines

#define BOOTLOADER_TYPE_STANDALONE#define halBootloadAppStart(space, segment, ramPtr)#define halBootloadAdjustFlash(space, segment, ramPtr)

Enumerations

enum { BOOTLOADER_MODE_MENU, BOOTLOADER_MODE_PASSTHROUGH, BOOTLOADER_MODE_CLONE, BOOTLOADER_MODE_CLONE_RECOVERY, BOOTLOADER_MODE_PASSTHROUGH_RECOVERY }

Functions

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/...I_EM260_forPDF/bootloader-interface-standalone-v1_8h.htm (1 of 2) [10/29/2010 2:43:39 PM]

405

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 406: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: bootloader-interface-standalone-v1.h File Reference

EmberStatus halInternalStandaloneBootloaderTrap (int16u assumedBootloaderType, int8u trapNumber,...)

void halInternalAdjustFlashBlock (int16u *dst, int16u *src, int8u size)EmberStatus halLaunchStandaloneBootloaderV1 (int8u mode, int8u *eui64)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/...I_EM260_forPDF/bootloader-interface-standalone-v1_8h.htm (2 of 2) [10/29/2010 2:43:39 PM]

406

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 407: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: bootloader-interface-standalone.h File Reference

hal » micro

bootloader-interface-standalone.h File Reference

Detailed Description

See Stand-Alone Bootloader Interface for documentation.

Definition in file bootloader-interface-standalone.h.

Go to the source code of this file.

Defines

#define NO_BOOTLOADER_MODE#define STANDALONE_BOOTLOADER_NORMAL_MODE#define STANDALONE_BOOTLOADER_RECOVERY_MODE

Functions

int16u halGetStandaloneBootloaderVersion (void)EmberStatus halLaunchStandaloneBootloader (int8u mode)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/bootloader-interface-standalone_8h.htm [10/29/2010 2:43:39 PM]

407

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 408: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: bootloader.h File Reference

hal » micro » avr-atmega » 128

bootloader.h File Reference

Detailed Description

Micro-specific functions used in conjunction with either bootloader.

Unless otherwise noted, the EmberNet stack does not use these functions, and therefore the HAL is not required to implement them. However, many of the supplied example applications do use them.

Some functions in this file return an EmberStatus value. See error-def.h for definitions of all EmberStatus return values.

Definition in file bootloader.h.

Go to the source code of this file.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/bootloader_8h.htm [10/29/2010 2:43:40 PM]

408

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 409: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: button.h File Reference

hal » micro

button.h File Reference

Detailed Description

See Button Control for documentation.

Definition in file button.h.

Go to the source code of this file.

Button State Definitions

A set of numerical definitions for use with the button APIs indicating the state of a button.

#define BUTTON_PRESSED#define BUTTON_RELEASED

Functions

void halInternalInitButton (void)int8u halButtonState (int8u button)int8u halButtonPinState (int8u button)

void halButtonIsr (int8u button, int8u state)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/button_8h.htm [10/29/2010 2:43:40 PM]

409

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 410: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: buzzer.h File Reference

hal » micro

buzzer.h File Reference

Detailed Description

See Buzzer Control for documentation.

Definition in file buzzer.h.

Go to the source code of this file.

Note Definitions

Flats are used instead of sharps because # is a special character.

#define NOTE_C3#define NOTE_Db3#define NOTE_D3#define NOTE_Eb3#define NOTE_E3#define NOTE_F3#define NOTE_Gb3#define NOTE_G3#define NOTE_Ab3#define NOTE_A3#define NOTE_Bb3#define NOTE_B3#define NOTE_C4#define NOTE_Db4#define NOTE_D4#define NOTE_Eb4#define NOTE_E4#define NOTE_F4#define NOTE_Gb4#define NOTE_G4#define NOTE_Ab4

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/buzzer_8h.htm (1 of 2) [10/29/2010 2:43:40 PM]

410

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 411: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: buzzer.h File Reference

#define NOTE_A4#define NOTE_Bb4#define NOTE_B4#define NOTE_C5#define NOTE_Db5#define NOTE_D5#define NOTE_Eb5#define NOTE_E5#define NOTE_F5#define NOTE_Gb5#define NOTE_G5#define NOTE_Ab5#define NOTE_A5#define NOTE_Bb5#define NOTE_B5

Functions

void halPlayTune_P (int8u PGM *tune, boolean bkg)void halStackIndicatePresence (void)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/buzzer_8h.htm (2 of 2) [10/29/2010 2:43:40 PM]

411

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 412: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: cbke-crypto-engine.h File Reference

stack » include

cbke-crypto-engine.h File Reference

Detailed Description

EmberZNet Smart Energy security API. See Smart Energy Security for documention.

Definition in file cbke-crypto-engine.h.

Go to the source code of this file.

Functions

EmberStatus emberGetCertificate (EmberCertificateData *result)EmberStatus emberGenerateCbkeKeys (void)EmberStatus emberCalculateSmacs (boolean amInitiator, EmberCertificateData *partnerCert,

EmberPublicKeyData *partnerEphemeralPublicKey)EmberStatus emberClearTemporaryDataMaybeStoreLinkKey (boolean storeLinkKey)EmberStatus emberDsaSign (EmberMessageBuffer messageToSign)

void emberGenerateCbkeKeysHandler (EmberStatus status, EmberPublicKeyData *ephemeralPublicKey)

void emberCalculateSmacsHandler (EmberStatus status, EmberSmacData *initiatorSmac, EmberSmacData *responderSmac)

void emberDsaSignHandler (EmberStatus status, EmberMessageBuffer signedMessage)

EmberStatus emberSetPreinstalledCbkeData (EmberPublicKeyData *caPublic, EmberCertificateData *myCert, EmberPrivateKeyData *myKey)

boolean emberGetStackCertificateEui64 (EmberEUI64 certEui64)EmberStatus emberDsaVerify (EmberMessageDigest *digest, EmberCertificateData

*signerCertificate, EmberSignatureData *receivedSig)void emberDsaVerifyHandler (EmberStatus status)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/cbke-crypto-engine_8h.htm [10/29/2010 2:43:41 PM]

412

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 413: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: command-interpreter.h File Reference

app » util » serial

command-interpreter.h File Reference

Detailed Description

Processes commands coming from the serial port. See Command Interpreter for documentation.

Definition in file command-interpreter.h.

Go to the source code of this file.

Data Structures

struct EmberCommandEntry Command entry for a command table. More...

struct EmberCommandStateS

The command state structure. Using a structure allows commands to be read from multiple sources. More...

Command Table Settings

#define EMBER_COMMENT_CHARACTER#define EMBER_MAX_COMMAND_LENGTH

Macros to Retrieve Arguments

Use the following macros in your functions that process commands to retrieve arguments from the command interpreter state object. These macros pull out unsigned integers, signed integers, and buffers.

#define emberUnsignedCommandArgument(state, index)#define emberSignedCommandArgument(state, index)#define emberBufferCommandArgument(state, index)

Defines

#define TEMP_GREATER_THAN_MAX_ARG_SIZE#define PERFORM_BOUNDS_CHECKING#define emberProcessCommandInput(state, port)#define emberCommandName(state)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/command-interpreter_8h.htm (1 of 2) [10/29/2010 2:43:41 PM]

413

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 414: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: command-interpreter.h File Reference

Typedefs

typedef int16u ArgTypeUtypedef void(*) CommandAction (struct EmberCommandStateS *state)

typedef EmberCommandStateS EmberCommandState

Enumerations

enum EmberCommandStatus { EMBER_CMD_SUCCESS, EMBER_CMD_ERR_PORT_PROBLEM, EMBER_CMD_ERR_NO_BUFFER_AVAILABLE, EMBER_CMD_ERR_NO_SUCH_COMMAND, EMBER_CMD_ERR_WRONG_COMMAND_ARGUMENTS, EMBER_CMD_ERR_TOO_MANY_COMMAND_ARGUMENTS, EMBER_CMD_ERR_ARGUMENT_OUT_OF_RANGE, EMBER_CMD_ERR_ARGUMENT_SYNTAX_ERROR, EMBER_CMD_ERR_STRING_TOO_LONG, EMBER_CMD_ERR_NO_BINARY_STRING_TERMINATOR }

Functions

void emberCommandReaderInit (EmberCommandState *state)boolean emberProcessCommandString (EmberCommandState *state, int8u

*input, int8u size)

Variables

PGM_NO_CONST PGM_P emberCommandErrorNames []

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/command-interpreter_8h.htm (2 of 2) [10/29/2010 2:43:41 PM]

414

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 415: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: crc.h File Reference

hal » micro

crc.h File Reference

Detailed Description

See Cyclic Redundancy Code (CRC) for detailed documentation.

Definition in file crc.h.

Go to the source code of this file.

Defines

#define INITIAL_CRC#define CRC32_START#define CRC32_END

Functions

int16u halCommonCrc16 (int8u newByte, int16u prevResult)int32u halCommonCrc32 (int8u newByte, int32u prevResult)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/crc_8h.htm [10/29/2010 2:43:42 PM]

415

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 416: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: dev0470.h File Reference

hal » micro » avr-atmega » 32 » board

dev0470.h File Reference

Detailed Description

Functions specific to the dev0470 breakout board.

See Carrier Board Control.

Definition in file dev0470.h.

Go to the source code of this file.

SPI Protocol Parameters

The following are used to aid in the abstraction with the SPI Protocl. The HAL uses these definitions so it is able to work across a variety of speeds as well as allow the developer to tweak parameters as desired.

The values used here are based upon an ATmega32L Host operating at 3.6864MHz which generates a 17.361us tick.

#define TCCR1B_CONFIGURATION#define WAIT_SECTION_TIMEOUT#define INTER_COMMAND_SPACING#define WAKE_HANDSHAKE_TIMEOUT#define STARTUP_TIMEOUT_SINGLE#define STARTUP_TIMEOUT_COUNT

SPI Protocol Connection Items

The following are used to aid in the abstraction with the SPI Protocol. The HAL uses these definitions so it is able to work across a variety of boards which could have different connections. The names and ports/pins used below are intended to match with a schematic of the system to provide the abstraction.

#define SPIP_nSSEL_PORT#define SPIP_nSSEL_DDR

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/dev0470_8h.htm (1 of 4) [10/29/2010 2:43:42 PM]

416

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 417: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: dev0470.h File Reference

#define SPIP_nSSEL#define SPIP_MOSI_PORT#define SPIP_MOSI_DDR#define SPIP_MOSI#define SPIP_MISO_PORT#define SPIP_MISO_DDR#define SPIP_MISO#define SPIP_SCLK_PORT#define SPIP_SCLK_DDR#define SPIP_SCLK#define SPIP_nHOST_INT_PORT#define SPIP_nHOST_INT_DDR#define SPIP_nHOST_INT_PIN#define SPIP_nHOST_INT#define SPIP_nWAKE_PORT#define SPIP_nWAKE_DDR#define SPIP_nWAKE#define SPIP_nRESET_PORT#define SPIP_nRESET_DDR#define SPIP_nRESET

LED Definitions

The following are used to aid in the abstraction with the LED connections. The names and ports/pins used below are intended to match with a schematic of the system to provide the abstraction.

The BOARDLEDn macros should always be used when manipulating the state of LEDs.

BOARDLED_MASK should be set to a mask with a bit set for each pin to an LED is connected

#define BOARDLED_MASK#define LED_DDR#define LED_PORT

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/dev0470_8h.htm (2 of 4) [10/29/2010 2:43:42 PM]

417

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 418: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: dev0470.h File Reference

enum HalBoardLedPins { BOARDLED0, BOARDLED1, BOARDLED2, BOARDLED3, BOARDLED4, BOARDLED5, BOARD_ACTIVITY_LED, BOARD_HEARTBEAT_LED, BOARDLED0, BOARDLED1, BOARD_ACTIVITY_LED, BOARD_HEARTBEAT_LED, BOARDLED0, BOARDLED1, BOARD_ACTIVITY_LED, BOARD_HEARTBEAT_LED }

Button Definitions

The following are used to aid in the abstraction with the Button connections. The names and ports/pins used below are intended to match with a schematic of the system to provide the abstraction.

The BUTTONn macros should always be used with manipulating the buttons as they directly refer to the pins to which the buttons are connected.

#define BUTTON0#define BUTTON0_PORT#define BUTTON0_DDR#define BUTTON0_PIN#define BUTTON0_INT#define BUTTON0_INT_VECT#define BUTTON0_CONFIG_FALLING_EDGE()#define BUTTON0_CONFIG_RISING_EDGE()#define BUTTON1#define BUTTON1_PORT#define BUTTON1_DDR#define BUTTON1_PIN#define BUTTON1_INT#define BUTTON1_INT_VECT#define BUTTON1_CONFIG_FALLING_EDGE()#define BUTTON1_CONFIG_RISING_EDGE()

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/dev0470_8h.htm (3 of 4) [10/29/2010 2:43:42 PM]

418

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 419: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: dev0470.h File Reference

Temperature sensor ADC channel

Define the analog input channel connected to the LM-20 temperature sensor. The scale factor compensates for different platform input ranges. PA0/ADC0 must be an input. PA1 must be an output and set to a high level to power the sensor.

#define TEMP_SENSOR_ADC_CHANNEL#define TEMP_SENSOR_SCALE_FACTOR

Board Specific Functions

The following macros exist to aid in the initialization, power up from sleep, and power down to sleep operations. These macros are responsible for either initializing directly, or calling initialization functions for any peripherals that are specific to this board implementation. These macros are called from halInit, halPowerDown, and halPowerUp respectively.

#define halInternalInitBoard()#define halInternalPowerDownBoard()#define halInternalPowerUpBoard()

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/dev0470_8h.htm (4 of 4) [10/29/2010 2:43:42 PM]

419

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 420: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: dev0473.h File Reference

hal » micro » avr-atmega » 128 » board

dev0473.h File Reference

Detailed Description

Functions specific to the dev0473 breakout board (ATmega128L-EM260).

See Carrier Board Control for documentation.

Definition in file dev0473.h.

Go to the source code of this file.

SPI Protocol Parameters

The following are used to aid in the abstraction with the SPI Protocl. The HAL uses these definitions so it is able to work across a variety of speeds as well as allow the developer to tweak parameters as desired.

The values used here are based upon an ATmega128L Host operating at 8MHz which generates a 32us tick.

#define TCCR1B_CONFIGURATION#define WAIT_SECTION_TIMEOUT#define INTER_COMMAND_SPACING#define WAKE_HANDSHAKE_TIMEOUT#define STARTUP_TIMEOUT_SINGLE#define STARTUP_TIMEOUT_COUNT

SPI Protocol Connection Items

The following are used to aid in the abstraction with the SPI Protocol. The HAL uses these definitions so it is able to work across a variety of boards which could have different connections. The names and ports/pins used below are intended to match with a schematic of the system to provide the abstraction.

#define SPIP_nSSEL_PORT#define SPIP_nSSEL_DDR

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/dev0473_8h.htm (1 of 4) [10/29/2010 2:43:43 PM]

420

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 421: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: dev0473.h File Reference

#define SPIP_nSSEL#define SPIP_MOSI_PORT#define SPIP_MOSI_DDR#define SPIP_MOSI#define SPIP_MISO_PORT#define SPIP_MISO_DDR#define SPIP_MISO#define SPIP_SCLK_PORT#define SPIP_SCLK_DDR#define SPIP_SCLK#define SPIP_nHOST_INT_PORT#define SPIP_nHOST_INT_DDR#define SPIP_nHOST_INT_PIN#define SPIP_nHOST_INT#define SPIP_nWAKE_PORT#define SPIP_nWAKE_DDR#define SPIP_nWAKE#define SPIP_nRESET_PORT#define SPIP_nRESET_DDR#define SPIP_nRESET

LED Definitions

The following are used to aid in the abstraction with the LED connections. The microcontroller-specific sources use these definitions so they are able to work across a variety of boards which could have different connections. The names and ports/pins used below are intended to match with a schematic of the system to provide the abstraction.

The BOARDLEDn enum values should always be used when manipulating the state of LEDs, as they directly refer to the pins to which the LEDs are connected

BOARDLED_MASK should be set to a mask with a bit set for each pin to an LED is connected

#define BOARDLED_MASK#define LED_DDR#define LED_PORT

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/dev0473_8h.htm (2 of 4) [10/29/2010 2:43:43 PM]

421

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 422: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: dev0473.h File Reference

enum HalBoardLedPins { BOARDLED0, BOARDLED1, BOARDLED2, BOARDLED3, BOARDLED4, BOARDLED5, BOARD_ACTIVITY_LED, BOARD_HEARTBEAT_LED, BOARDLED0, BOARDLED1, BOARD_ACTIVITY_LED, BOARD_HEARTBEAT_LED, BOARDLED0, BOARDLED1, BOARD_ACTIVITY_LED, BOARD_HEARTBEAT_LED }

Button Definitions

The following are used to aid in the abstraction with the Button connections. The names and ports/pins used below are intended to match with a schematic of the system to provide the abstraction.

The BUTTONn macros should always be used with manipulating the buttons as they directly refer to the pins to which the buttons are connected.

#define BUTTON0#define BUTTON0_PORT#define BUTTON0_DDR#define BUTTON0_PIN#define BUTTON0_INT#define BUTTON0_INT_VECT#define BUTTON0_CONFIG_FALLING_EDGE()#define BUTTON0_CONFIG_RISING_EDGE()#define BUTTON1#define BUTTON1_PORT#define BUTTON1_DDR#define BUTTON1_PIN#define BUTTON1_INT#define BUTTON1_INT_VECT#define BUTTON1_CONFIG_FALLING_EDGE()#define BUTTON1_CONFIG_RISING_EDGE()

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/dev0473_8h.htm (3 of 4) [10/29/2010 2:43:43 PM]

422

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 423: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: dev0473.h File Reference

Temperature sensor ADC channel

Define the analog input channel connected to the LM-20 temperature sensor. The scale factor compensates for different platform input ranges. PF1/ADC1 must be an input. PC7 must be an output and set to a high level to power the sensor.

#define TEMP_SENSOR_ADC_CHANNEL#define TEMP_SENSOR_SCALE_FACTOR

Board Specific Functions

The following macros exist to aid in the initialization, power up from sleep, and power down to sleep operations. These macros are responsible for either initializing directly, or calling initialization functions for any peripherals that are specific to this board implementation. These macros are called from halInit, halPowerDown, and halPowerUp respectively.

#define halInternalInitBoard()#define halInternalPowerDownBoard()#define halInternalPowerUpBoard()

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/dev0473_8h.htm (4 of 4) [10/29/2010 2:43:43 PM]

423

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 424: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-configuration-defaults.h File Reference

stack » config

ember-configuration-defaults.h File Reference

Detailed Description

User-configurable stack memory allocation defaults.

Note:Application developers should not modify any portion of this file. Doing so may cause mysterious bugs. Allocations should be adjusted only by defining the appropriate macros in the application's CONFIGURATION_HEADER.

See Configuration for documentation.

Definition in file ember-configuration-defaults.h.

Go to the source code of this file.

Defines

#define EMBER_API_MAJOR_VERSION#define EMBER_API_MINOR_VERSION#define EMBER_STACK_PROFILE#define EMBER_MAX_END_DEVICE_CHILDREN#define EMBER_SECURITY_LEVEL#define EMBER_CHILD_TABLE_SIZE#define EMBER_KEY_TABLE_SIZE#define EMBER_CERTIFICATE_TABLE_SIZE#define EMBER_MAX_DEPTH#define EMBER_MAX_HOPS#define EMBER_PACKET_BUFFER_COUNT#define EMBER_MAX_NEIGHBOR_TABLE_SIZE#define EMBER_NEIGHBOR_TABLE_SIZE#define EMBER_INDIRECT_TRANSMISSION_TIMEOUT#define EMBER_MAX_INDIRECT_TRANSMISSION_TIMEOUT#define EMBER_END_DEVICE_POLL_TIMEOUT#define EMBER_END_DEVICE_POLL_TIMEOUT_SHIFT

file:///C|/dev/perforce/software/v2/tephra-park/doxygen...ut/API_EM260_forPDF/ember-configuration-defaults_8h.htm (1 of 2) [10/29/2010 2:43:44 PM]

424

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 425: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-configuration-defaults.h File Reference

#define EMBER_MOBILE_NODE_POLL_TIMEOUT#define EMBER_APS_UNICAST_MESSAGE_COUNT#define EMBER_BINDING_TABLE_SIZE#define EMBER_ADDRESS_TABLE_SIZE#define EMBER_RESERVED_MOBILE_CHILD_ENTRIES#define EMBER_ROUTE_TABLE_SIZE#define EMBER_DISCOVERY_TABLE_SIZE#define EMBER_MULTICAST_TABLE_SIZE#define EMBER_SOURCE_ROUTE_TABLE_SIZE#define EMBER_BROADCAST_TABLE_SIZE#define EMBER_ASSERT_SERIAL_PORT#define EMBER_MAXIMUM_ALARM_DATA_SIZE#define EMBER_BROADCAST_ALARM_DATA_SIZE#define EMBER_UNICAST_ALARM_DATA_SIZE#define EMBER_FRAGMENT_DELAY_MS#define EMBER_FRAGMENT_MAX_WINDOW_SIZE#define EMBER_FRAGMENT_WINDOW_SIZE#define EMBER_BINDING_TABLE_TOKEN_SIZE#define EMBER_CHILD_TABLE_TOKEN_SIZE#define EMBER_KEY_TABLE_TOKEN_SIZE#define EMBER_REQUEST_KEY_TIMEOUT#define EMBER_END_DEVICE_BIND_TIMEOUT#define EMBER_PAN_ID_CONFLICT_REPORT_THRESHOLD#define EMBER_TASK_COUNT

file:///C|/dev/perforce/software/v2/tephra-park/doxygen...ut/API_EM260_forPDF/ember-configuration-defaults_8h.htm (2 of 2) [10/29/2010 2:43:44 PM]

425

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 426: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-debug.h File Reference

stack » include

ember-debug.h File Reference

Detailed Description

See Debugging Utilities for documentation.

Definition in file ember-debug.h.

Go to the source code of this file.

Defines

#define NO_DEBUG#define BASIC_DEBUG#define FULL_DEBUG#define emberDebugInit(port)

Functions

void emberDebugAssert (PGM_P filename, int linenumber)void emberDebugMemoryDump (int8u *start, int8u *end)void emberDebugBinaryPrintf (PGM_P formatString,...)void emDebugSendVuartMessage (int8u *buff, int8u len)void emberDebugError (EmberStatus code)

boolean emberDebugReportOff (void)void emberDebugReportRestore (boolean state)void emberDebugPrintf (PGM_P formatString,...)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ember-debug_8h.htm [10/29/2010 2:43:44 PM]

426

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 427: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-types.h File Reference

stack » include

ember-types.h File Reference

Detailed Description

Ember data type definitions.

See Ember Common Data Types for details.

Definition in file ember-types.h.

Go to the source code of this file.

Data Structures

struct EmberZigbeeNetwork Defines a ZigBee network and the associated parameters. More...

struct EmberNetworkParameters Holds network parameters. More...

struct EmberApsFrame

An in-memory representation of a ZigBee APS frame of an incoming or outgoing message. More...

struct EmberBindingTableEntry Defines an entry in the binding table. More...

struct EmberNeighborTableEntry Defines an entry in the neighbor table. More...

struct EmberRouteTableEntry Defines an entry in the route table. More...

struct EmberMulticastTableEntry Defines an entry in the multicast table. More...

struct EmberEventControl Control structure for events. More...

struct EmberTaskControl Control structure for tasks. More...

struct EmberKeyData This data structure contains the key data that is pasesd into various other functions. More...

struct EmberCertificateData

This data structure contains the certificate data that is used for Certificate Based Key Exchange (CBKE). More...

struct EmberPublicKeyData

This data structure contains the public key data tha is used for Certificate Based Key Exchange (CBKE). More...

struct EmberPrivateKeyData

This data structure contains the private key data tha is used for Certificate Based Key Exchange (CBKE). More...

struct EmberSmacData

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ember-types_8h.htm (1 of 15) [10/29/2010 2:43:47 PM]

427

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 428: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-types.h File Reference

This data structure contains the Shared Message Authentication Code (SMAC) data that is used for Certificate Based Key Exchange (CBKE). More...

struct EmberSignatureData

This data structure contains a DSA signature. It is the bit concatenantion of the 'r' and 's' components of the signature. More...

struct EmberMessageDigest This data structure contains an AES-MMO Hash (the message digest). More...

struct EmberAesMmoHashContext

This data structure contains the context data when calculating an AES MMO hash (message digest). More...

struct EmberInitialSecurityState

This describes the Initial Security features and requirements that will be used when forming or joining the network. More...

struct EmberCurrentSecurityState This describes the security features used by the stack for a joined device. More...

struct EmberKeyStruct This describes a one of several different types of keys and its associated data. More...

Miscellaneous Ember Types

#define EUI64_SIZE#define EXTENDED_PAN_ID_SIZE#define EMBER_ENCRYPTION_KEY_SIZE#define EMBER_CERTIFICATE_SIZE#define EMBER_PUBLIC_KEY_SIZE#define EMBER_PRIVATE_KEY_SIZE#define EMBER_SMAC_SIZE#define EMBER_SIGNATURE_SIZE#define EMBER_AES_HASH_BLOCK_SIZE#define EMBER_MAX_802_15_4_CHANNEL_NUMBER#define EMBER_MIN_802_15_4_CHANNEL_NUMBER#define EMBER_NUM_802_15_4_CHANNELS#define EMBER_ALL_802_15_4_CHANNELS_MASK#define EMBER_ZIGBEE_COORDINATOR_ADDRESS#define EMBER_NULL_NODE_ID#define EMBER_NULL_BINDING#define EMBER_TABLE_ENTRY_UNUSED_NODE_ID#define EMBER_MULTICAST_NODE_ID#define EMBER_UNKNOWN_NODE_ID#define EMBER_DISCOVERY_ACTIVE_NODE_ID#define EMBER_NULL_ADDRESS_TABLE_INDEX#define EMBER_ZDO_ENDPOINT#define EMBER_BROADCAST_ENDPOINT#define EMBER_ZDO_PROFILE_ID

typedef int8u EmberStatustypedef int8u EmberEUI64 [EUI64_SIZE]typedef int8u EmberMessageBuffer

typedef int16u EmberNodeIdtypedef int16u EmberMulticastIdtypedef int16u EmberPanId

ZigBee Broadcast Addresses

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ember-types_8h.htm (2 of 15) [10/29/2010 2:43:47 PM]

428

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 429: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-types.h File Reference

ZigBee specifies three different broadcast addresses that reach different collections of nodes. Broadcasts are normally sent only to routers. Broadcasts can also be forwarded to end devices, either all of them or only those that do not sleep. Broadcasting to end devices is both significantly more resource-intensive and significantly less reliable than broadcasting to routers.

#define EMBER_BROADCAST_ADDRESS#define EMBER_RX_ON_WHEN_IDLE_BROADCAST_ADDRESS#define EMBER_SLEEPY_BROADCAST_ADDRESS

Ember Concentrator Types

#define EMBER_LOW_RAM_CONCENTRATOR#define EMBER_HIGH_RAM_CONCENTRATOR

txPowerModes for emberSetTxPowerMode and mfglibSetPower

#define EMBER_TX_POWER_MODE_DEFAULT#define EMBER_TX_POWER_MODE_BOOST#define EMBER_TX_POWER_MODE_ALTERNATE#define EMBER_TX_POWER_MODE_BOOST_AND_ALTERNATE

Alarm Message and Counters Request Definitions

#define EMBER_PRIVATE_PROFILE_ID#define EMBER_BROADCAST_ALARM_CLUSTER#define EMBER_UNICAST_ALARM_CLUSTER#define EMBER_CACHED_UNICAST_ALARM_CLUSTER#define EMBER_REPORT_COUNTERS_REQUEST#define EMBER_REPORT_COUNTERS_RESPONSE#define EMBER_REPORT_AND_CLEAR_COUNTERS_REQUEST#define EMBER_REPORT_AND_CLEAR_COUNTERS_RESPONSE#define EMBER_OTA_CERTIFICATE_UPGRADE_CLUSTER

Network and IEEE Address Request/Response

Network request: <transaction sequence number: 1> <EUI64:8> <type:1> <start index:1> IEEE request: <transaction sequence number: 1> <node ID:2> <type:1> <start index:1> <type> = 0x00 single address response, ignore the start index = 0x01 extended response -> sends kid's IDs as well Response: <transaction sequence number: 1> <status:1> <EUI64:8> <node ID:2> <ID count:1> <start index:1> <child ID:2>*

#define NETWORK_ADDRESS_REQUEST#define NETWORK_ADDRESS_RESPONSE#define IEEE_ADDRESS_REQUEST#define IEEE_ADDRESS_RESPONSE

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ember-types_8h.htm (3 of 15) [10/29/2010 2:43:47 PM]

429

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 430: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-types.h File Reference

Node Descriptor Request/Response

Request: <transaction sequence number: 1> <node ID:2> Response: <transaction sequence number: 1> <status:1> <node ID:2> <type:1> <APS flags, freq:1> <MAC flags:1> <manufacturer:2> <max buffer size:1> <max transfer size:2>

#define NODE_DESCRIPTOR_REQUEST#define NODE_DESCRIPTOR_RESPONSE

Power Descriptor Request / Response

Request: <transaction sequence number: 1> <node ID:2> Response: <transaction sequence number: 1> <status:1> <node ID:2> <current power mode, available power sources:1> <current power source, current power source level:1>

#define POWER_DESCRIPTOR_REQUEST#define POWER_DESCRIPTOR_RESPONSE

Simple Descriptor Request / Response

Request: <transaction sequence number: 1> <node ID:2> <endpoint:1> Response: <transaction sequence number: 1> <status:1> <node ID:2> <length:1> <endpoint:1> <app profile ID:2> <app device ID:2> <app device version, app flags:1> <input cluster count:1> <input cluster:2>* <output cluster count:1> <output cluster:2>*

#define SIMPLE_DESCRIPTOR_REQUEST#define SIMPLE_DESCRIPTOR_RESPONSE

Active Endpoints Request / Response

Request: <transaction sequence number: 1> <node ID:2> Response: <transaction sequence number: 1> <status:1> <node ID:2> <endpoint count:1> <endpoint:1>*

#define ACTIVE_ENDPOINTS_REQUEST#define ACTIVE_ENDPOINTS_RESPONSE

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ember-types_8h.htm (4 of 15) [10/29/2010 2:43:47 PM]

430

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 431: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-types.h File Reference

Match Descriptors Request / Response

Request: <transaction sequence number: 1> <node ID:2> <app profile ID:2> <input cluster count:1> <input cluster:2>* <output cluster count:1> <output cluster:2>* Response: <transaction sequence number: 1> <status:1> <node ID:2> <endpoint count:1> <endpoint:1>*

#define MATCH_DESCRIPTORS_REQUEST#define MATCH_DESCRIPTORS_RESPONSE

Discovery Cache Request / Response

Request: <transaction sequence number: 1> <source node ID:2> <source EUI64:8> Response: <transaction sequence number: 1> <status (== EMBER_ZDP_SUCCESS):1>

#define DISCOVERY_CACHE_REQUEST#define DISCOVERY_CACHE_RESPONSE

End Device Announce and End Device Announce Response

Request: <transaction sequence number: 1> <node ID:2> <EUI64:8> <capabilities:1> No response is sent.

#define END_DEVICE_ANNOUNCE#define END_DEVICE_ANNOUNCE_RESPONSE

System Server Discovery Request / Response

This is broadcast and only servers which have matching services respond. The response contains the request services that the recipient provides.

Request: <transaction sequence number: 1> <server mask:2> Response: <transaction sequence number: 1> <status (== EMBER_ZDP_SUCCESS):1> <server mask:2>

#define SYSTEM_SERVER_DISCOVERY_REQUEST#define SYSTEM_SERVER_DISCOVERY_RESPONSE

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ember-types_8h.htm (5 of 15) [10/29/2010 2:43:47 PM]

431

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 432: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-types.h File Reference

Find Node Cache Request / Response

This is broadcast and only discovery servers which have the information for the device of interest, or the device of interest itself, respond. The requesting device can then direct any service discovery requests to the responder.

Request: <transaction sequence number: 1> <device of interest ID:2> <d-of-i EUI64:8> Response: <transaction sequence number: 1> <responder ID:2> <device of interest ID:2> <d-of-i EUI64:8>

#define FIND_NODE_CACHE_REQUEST#define FIND_NODE_CACHE_RESPONSE

End Device Bind Request / Response

Request: <transaction sequence number: 1> <node ID:2> <EUI64:8> <endpoint:1> <app profile ID:2> <input cluster count:1> <input cluster:2>* <output cluster count:1> <output cluster:2>* Response: <transaction sequence number: 1> <status:1>

#define END_DEVICE_BIND_REQUEST#define END_DEVICE_BIND_RESPONSE

Binding types and Request / Response

Bind and unbind have the same formats. There are two possible formats, depending on whether the destination is a group address or a device address. Device addresses include an endpoint, groups don't.

Request: <transaction sequence number: 1> <source EUI64:8> <source endpoint:1> <cluster ID:2> <destination address:3 or 10> Destination address: <0x01:1> <destination group:2> Or: <0x03:1> <destination EUI64:8> <destination endpoint:1> Response: <transaction sequence number: 1> <status:1>

#define UNICAST_BINDING#define UNICAST_MANY_TO_ONE_BINDING#define MULTICAST_BINDING#define BIND_REQUEST#define BIND_RESPONSE#define UNBIND_REQUEST#define UNBIND_RESPONSE

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ember-types_8h.htm (6 of 15) [10/29/2010 2:43:47 PM]

432

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 433: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-types.h File Reference

LQI Table Request / Response

Request: <transaction sequence number: 1> <start index:1> Response: <transaction sequence number: 1> <status:1> <neighbor table entries:1> <start index:1> <entry count:1> <entry:22>* <entry> = <extended PAN ID:8> <EUI64:8> <node ID:2> <device type, rx on when idle, relationship:1> <permit joining:1> <depth:1> <LQI:1>

The device-type byte has the following fields:

Name Mask Values device type 0x03 0x00 coordinator 0x01 router 0x02 end device 0x03 unknown

rx mode 0x0C 0x00 off when idle 0x04 on when idle 0x08 unknown

relationship 0x70 0x00 parent 0x10 child 0x20 sibling 0x30 other 0x40 previous child reserved 0x10

The permit-joining byte has the following fields

Name Mask Values permit joining 0x03 0x00 not accepting join requests 0x01 accepting join requests 0x02 unknown reserved 0xFC

#define LQI_TABLE_REQUEST#define LQI_TABLE_RESPONSE

Routing Table Request / Response

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ember-types_8h.htm (7 of 15) [10/29/2010 2:43:47 PM]

433

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 434: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-types.h File Reference

Request: <transaction sequence number: 1> <start index:1> Response: <transaction sequence number: 1> <status:1> <routing table entries:1> <start index:1> <entry count:1> <entry:5>* <entry> = <destination address:2> <status:1> <next hop:2>

The status byte has the following fields:

Name Mask Values status 0x07 0x00 active 0x01 discovery underway 0x02 discovery failed 0x03 inactive 0x04 validation underway

flags 0x38 0x08 memory constrained 0x10 many-to-one 0x20 route record required

reserved 0xC0

#define ROUTING_TABLE_REQUEST#define ROUTING_TABLE_RESPONSE

Binding Table Request / Response

Request: <transaction sequence number: 1> <start index:1> Response: <transaction sequence number: 1> <status:1> <binding table entries:1> <start index:1> <entry count:1> <entry:14/21>* <entry> = <source EUI64:8> <source endpoint:1> <cluster ID:2> <dest addr mode:1> <dest:2/8> <dest endpoint:0/1>

Note:

If Dest. Address Mode = 0x03, then the Long Dest. Address will be used and Dest. endpoint will be included. If Dest. Address Mode = 0x01, then the Short Dest. Address will be used and there will be no Dest. endpoint.

#define BINDING_TABLE_REQUEST#define BINDING_TABLE_RESPONSE

Leave Request / Response

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ember-types_8h.htm (8 of 15) [10/29/2010 2:43:47 PM]

434

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 435: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-types.h File Reference

Request: <transaction sequence number: 1> <EUI64:8> <flags:1> The flag bits are: 0x40 remove children 0x80 rejoin Response: <transaction sequence number: 1> <status:1>

#define LEAVE_REQUEST#define LEAVE_RESPONSE#define LEAVE_REQUEST_REMOVE_CHILDREN_FLAG#define LEAVE_REQUEST_REJOIN_FLAG

Permit Joining Request / Response

Request: <transaction sequence number: 1> <duration:1> <permit authentication:1> Response: <transaction sequence number: 1> <status:1>

#define PERMIT_JOINING_REQUEST#define PERMIT_JOINING_RESPONSE

Network Update Request / Response

Request: <transaction sequence number: 1> <scan channels:4> <duration:1> <count:0/1> <manager:0/2>

If the duration is in 0x00 ... 0x05, then 'count' is present but not 'manager'. Perform 'count' scans of the given duration on the given channels.

If duration is 0xFE, then 'channels' should have a single channel and 'count' and 'manager' are not present. Switch to the indicated channel. If duration is 0xFF, then 'count' is not present. Set the active channels and the network manager ID to the values given.

Unicast requests always get a response, which is INVALID_REQUEST if the duration is not a legal value.

Response: <status:1> <scanned channels:4> <transmissions:2> <failures:2> <energy count:1> <energy:1>*

#define NWK_UPDATE_REQUEST#define NWK_UPDATE_RESPONSE

Unsupported

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ember-types_8h.htm (9 of 15) [10/29/2010 2:43:47 PM]

435

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 436: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-types.h File Reference

Not mandatory and not supported.

#define COMPLEX_DESCRIPTOR_REQUEST#define COMPLEX_DESCRIPTOR_RESPONSE#define USER_DESCRIPTOR_REQUEST#define USER_DESCRIPTOR_RESPONSE#define DISCOVERY_REGISTER_REQUEST#define DISCOVERY_REGISTER_RESPONSE#define USER_DESCRIPTOR_SET#define USER_DESCRIPTOR_CONFIRM#define NETWORK_DISCOVERY_REQUEST#define NETWORK_DISCOVERY_RESPONSE#define DIRECT_JOIN_REQUEST#define DIRECT_JOIN_RESPONSE#define CLUSTER_ID_RESPONSE_MINIMUM

ZDO response status.

Most responses to ZDO commands contain a status byte. The meaning of this byte is defined by the ZigBee Device Profile.

enum EmberZdoStatus { EMBER_ZDP_SUCCESS, EMBER_ZDP_INVALID_REQUEST_TYPE, EMBER_ZDP_DEVICE_NOT_FOUND, EMBER_ZDP_INVALID_ENDPOINT, EMBER_ZDP_NOT_ACTIVE, EMBER_ZDP_NOT_SUPPORTED, EMBER_ZDP_TIMEOUT, EMBER_ZDP_NO_MATCH, EMBER_ZDP_NO_ENTRY, EMBER_ZDP_NO_DESCRIPTOR, EMBER_ZDP_INSUFFICIENT_SPACE, EMBER_ZDP_NOT_PERMITTED, EMBER_ZDP_TABLE_FULL, EMBER_ZDP_NOT_AUTHORIZED, EMBER_NWK_ALREADY_PRESENT, EMBER_NWK_TABLE_FULL, EMBER_NWK_UNKNOWN_DEVICE }

ZDO server mask bits

These are used in server discovery requests and responses.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ember-types_8h.htm (10 of 15) [10/29/2010 2:43:47 PM]

436

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 437: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-types.h File Reference

enum EmberZdoServerMask { EMBER_ZDP_PRIMARY_TRUST_CENTER, EMBER_ZDP_SECONDARY_TRUST_CENTER, EMBER_ZDP_PRIMARY_BINDING_TABLE_CACHE, EMBER_ZDP_SECONDARY_BINDING_TABLE_CACHE, EMBER_ZDP_PRIMARY_DISCOVERY_CACHE, EMBER_ZDP_SECONDARY_DISCOVERY_CACHE, EMBER_ZDP_NETWORK_MANAGER }

ZDO configuration flags.

For controlling which ZDO requests are passed to the application. These are normally controlled via the following configuration definitions:

EMBER_APPLICATION_RECEIVES_SUPPORTED_ZDO_REQUESTS EMBER_APPLICATION_HANDLES_UNSUPPORTED_ZDO_REQUESTS EMBER_APPLICATION_HANDLES_ENDPOINT_ZDO_REQUESTS EMBER_APPLICATION_HANDLES_BINDING_ZDO_REQUESTS

See ember-configuration.h for more information.

enum EmberZdoConfigurationFlags { EMBER_APP_RECEIVES_SUPPORTED_ZDO_REQUESTS, EMBER_APP_HANDLES_UNSUPPORTED_ZDO_REQUESTS, EMBER_APP_HANDLES_ZDO_ENDPOINT_REQUESTS, EMBER_APP_HANDLES_ZDO_BINDING_REQUESTS }

Defines

#define EMBER_JOIN_DECISION_STRINGS#define EMBER_DEVICE_UPDATE_STRINGS#define emberInitializeNetworkParameters(parameters)#define EMBER_COUNTER_STRINGS#define EMBER_STANDARD_SECURITY_MODE#define EMBER_TRUST_CENTER_NODE_ID#define EMBER_NO_TRUST_CENTER_MODE

Typedefs

typedef int8u EmberTaskIdstruct { EmberEventControl * control void(* handler )(void)} EmberEventData

typedef int8u EmberLibraryStatus

Enumerations

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ember-types_8h.htm (11 of 15) [10/29/2010 2:43:47 PM]

437

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 438: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-types.h File Reference

enum EmberNodeType { EMBER_UNKNOWN_DEVICE, EMBER_COORDINATOR, EMBER_ROUTER, EMBER_END_DEVICE, EMBER_SLEEPY_END_DEVICE, EMBER_MOBILE_END_DEVICE }

enum EmberApsOption { EMBER_APS_OPTION_NONE, EMBER_APS_OPTION_DSA_SIGN, EMBER_APS_OPTION_ENCRYPTION, EMBER_APS_OPTION_RETRY, EMBER_APS_OPTION_ENABLE_ROUTE_DISCOVERY, EMBER_APS_OPTION_FORCE_ROUTE_DISCOVERY, EMBER_APS_OPTION_SOURCE_EUI64, EMBER_APS_OPTION_DESTINATION_EUI64, EMBER_APS_OPTION_ENABLE_ADDRESS_DISCOVERY, EMBER_APS_OPTION_POLL_RESPONSE, EMBER_APS_OPTION_ZDO_RESPONSE_REQUIRED, EMBER_APS_OPTION_FRAGMENT }

enum EmberIncomingMessageType { EMBER_INCOMING_UNICAST, EMBER_INCOMING_UNICAST_REPLY, EMBER_INCOMING_MULTICAST, EMBER_INCOMING_MULTICAST_LOOPBACK, EMBER_INCOMING_BROADCAST, EMBER_INCOMING_BROADCAST_LOOPBACK }

enum EmberOutgoingMessageType { EMBER_OUTGOING_DIRECT, EMBER_OUTGOING_VIA_ADDRESS_TABLE, EMBER_OUTGOING_VIA_BINDING, EMBER_OUTGOING_MULTICAST, EMBER_OUTGOING_BROADCAST }

enum EmberNetworkStatus { EMBER_NO_NETWORK, EMBER_JOINING_NETWORK, EMBER_JOINED_NETWORK, EMBER_JOINED_NETWORK_NO_PARENT, EMBER_LEAVING_NETWORK }

enum EmberNetworkScanType { EMBER_ENERGY_SCAN, EMBER_ACTIVE_SCAN }

enum EmberBindingType { EMBER_UNUSED_BINDING, EMBER_UNICAST_BINDING, EMBER_MANY_TO_ONE_BINDING, EMBER_MULTICAST_BINDING }

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ember-types_8h.htm (12 of 15) [10/29/2010 2:43:47 PM]

438

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 439: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-types.h File Reference

enum EmberJoinDecision { EMBER_USE_PRECONFIGURED_KEY, EMBER_SEND_KEY_IN_THE_CLEAR, EMBER_DENY_JOIN, EMBER_NO_ACTION }

enum EmberDeviceUpdate { EMBER_STANDARD_SECURITY_SECURED_REJOIN, EMBER_STANDARD_SECURITY_UNSECURED_JOIN, EMBER_DEVICE_LEFT, EMBER_STANDARD_SECURITY_UNSECURED_REJOIN, EMBER_HIGH_SECURITY_SECURED_REJOIN, EMBER_HIGH_SECURITY_UNSECURED_JOIN, EMBER_HIGH_SECURITY_UNSECURED_REJOIN }

enum EmberClusterListId { EMBER_INPUT_CLUSTER_LIST, EMBER_OUTPUT_CLUSTER_LIST }

enum EmberEventUnits { EMBER_EVENT_INACTIVE, EMBER_EVENT_MS_TIME, EMBER_EVENT_QS_TIME, EMBER_EVENT_MINUTE_TIME, EMBER_EVENT_ZERO_DELAY }

enum EmberJoinMethod { EMBER_USE_MAC_ASSOCIATION, EMBER_USE_NWK_REJOIN, EMBER_USE_NWK_REJOIN_HAVE_NWK_KEY, EMBER_USE_NWK_COMMISSIONING }

enum EmberCounterType { EMBER_COUNTER_MAC_RX_BROADCAST, EMBER_COUNTER_MAC_TX_BROADCAST, EMBER_COUNTER_MAC_RX_UNICAST, EMBER_COUNTER_MAC_TX_UNICAST_SUCCESS, EMBER_COUNTER_MAC_TX_UNICAST_RETRY, EMBER_COUNTER_MAC_TX_UNICAST_FAILED, EMBER_COUNTER_APS_DATA_RX_BROADCAST, EMBER_COUNTER_APS_DATA_TX_BROADCAST, EMBER_COUNTER_APS_DATA_RX_UNICAST, EMBER_COUNTER_APS_DATA_TX_UNICAST_SUCCESS, EMBER_COUNTER_APS_DATA_TX_UNICAST_RETRY, EMBER_COUNTER_APS_DATA_TX_UNICAST_FAILED, EMBER_COUNTER_ROUTE_DISCOVERY_INITIATED, EMBER_COUNTER_NEIGHBOR_ADDED, EMBER_COUNTER_NEIGHBOR_REMOVED, EMBER_COUNTER_NEIGHBOR_STALE, EMBER_COUNTER_JOIN_INDICATION, EMBER_COUNTER_CHILD_REMOVED, EMBER_COUNTER_ASH_OVERFLOW_ERROR, EMBER_COUNTER_ASH_FRAMING_ERROR, EMBER_COUNTER_ASH_OVERRUN_ERROR, EMBER_COUNTER_NWK_FRAME_COUNTER_FAILURE, EMBER_COUNTER_APS_FRAME_COUNTER_FAILURE,

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ember-types_8h.htm (13 of 15) [10/29/2010 2:43:47 PM]

439

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 440: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-types.h File Reference

EMBER_COUNTER_ASH_XOFF, EMBER_COUNTER_APS_LINK_KEY_NOT_AUTHORIZED, EMBER_COUNTER_NWK_DECRYPTION_FAILURE, EMBER_COUNTER_APS_DECRYPTION_FAILURE, EMBER_COUNTER_ALLOCATE_PACKET_BUFFER_FAILURE, EMBER_COUNTER_TYPE_COUNT }

enum EmberInitialSecurityBitmask { EMBER_DISTRIBUTED_TRUST_CENTER_MODE, EMBER_GLOBAL_LINK_KEY, EMBER_PRECONFIGURED_NETWORK_KEY_MODE, EMBER_HAVE_TRUST_CENTER_EUI64, EMBER_TRUST_CENTER_USES_HASHED_LINK_KEY, EMBER_HAVE_PRECONFIGURED_KEY, EMBER_HAVE_NETWORK_KEY, EMBER_GET_LINK_KEY_WHEN_JOINING, EMBER_REQUIRE_ENCRYPTED_KEY, EMBER_NO_FRAME_COUNTER_RESET, EMBER_GET_PRECONFIGURED_KEY_FROM_INSTALL_CODE }

enum EmberCurrentSecurityBitmask { EMBER_STANDARD_SECURITY_MODE_, EMBER_DISTRIBUTED_TRUST_CENTER_MODE_, EMBER_GLOBAL_LINK_KEY_, EMBER_HAVE_TRUST_CENTER_LINK_KEY, EMBER_TRUST_CENTER_USES_HASHED_LINK_KEY_ }

enum EmberKeyStructBitmask { EMBER_KEY_HAS_SEQUENCE_NUMBER, EMBER_KEY_HAS_OUTGOING_FRAME_COUNTER, EMBER_KEY_HAS_INCOMING_FRAME_COUNTER, EMBER_KEY_HAS_PARTNER_EUI64, EMBER_KEY_IS_AUTHORIZED }

enum EmberKeyType { EMBER_TRUST_CENTER_LINK_KEY, EMBER_TRUST_CENTER_MASTER_KEY, EMBER_CURRENT_NETWORK_KEY, EMBER_NEXT_NETWORK_KEY, EMBER_APPLICATION_LINK_KEY, EMBER_APPLICATION_MASTER_KEY }

enum EmberKeyStatus { EMBER_APP_LINK_KEY_ESTABLISHED, EMBER_APP_MASTER_KEY_ESTABLISHED, EMBER_TRUST_CENTER_LINK_KEY_ESTABLISHED, EMBER_KEY_ESTABLISHMENT_TIMEOUT, EMBER_KEY_TABLE_FULL, EMBER_TC_RESPONDED_TO_KEY_REQUEST, EMBER_TC_APP_KEY_SENT_TO_REQUESTER, EMBER_TC_RESPONSE_TO_KEY_REQUEST_FAILED, EMBER_TC_REQUEST_KEY_TYPE_NOT_SUPPORTED, EMBER_TC_NO_LINK_KEY_FOR_REQUESTER, EMBER_TC_REQUESTER_EUI64_UNKNOWN, EMBER_TC_RECEIVED_FIRST_APP_KEY_REQUEST, EMBER_TC_TIMEOUT_WAITING_FOR_SECOND_APP_KEY_REQUEST,

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ember-types_8h.htm (14 of 15) [10/29/2010 2:43:47 PM]

440

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 441: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-types.h File Reference

EMBER_TC_NON_MATCHING_APP_KEY_REQUEST_RECEIVED, EMBER_TC_FAILED_TO_SEND_APP_KEYS, EMBER_TC_FAILED_TO_STORE_APP_KEY_REQUEST, EMBER_TC_REJECTED_APP_KEY_REQUEST }

enum EmberLinkKeyRequestPolicy { EMBER_DENY_KEY_REQUESTS, EMBER_ALLOW_KEY_REQUESTS }

enum EmberMacPassthroughType { EMBER_MAC_PASSTHROUGH_NONE, EMBER_MAC_PASSTHROUGH_SE_INTERPAN, EMBER_MAC_PASSTHROUGH_EMBERNET, EMBER_MAC_PASSTHROUGH_EMBERNET_SOURCE, EMBER_MAC_PASSTHROUGH_APPLICATION }

Functions

int8u * emberKeyContents (EmberKeyData *key)int8u * emberCertificateContents (EmberCertificateData *cert)int8u * emberPublicKeyContents (EmberPublicKeyData *key)int8u * emberPrivateKeyContents (EmberPrivateKeyData *key)int8u * emberSmacContents (EmberSmacData *key)int8u * emberSignatureContents (EmberSignatureData *sig)

Variable Documentation

EmberEventControl* control

The control structure for the event.

Definition at line 992 of file ember-types.h.

void(* handler)(void)

The procedure to call when the event fires.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ember-types_8h.htm (15 of 15) [10/29/2010 2:43:47 PM]

441

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 442: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: error-def.h File Reference

stack » include

error-def.h File Reference

Detailed Description

Return-code definitions for EmberZNet stack API functions.

See Ember Status Codes for documentation.

Definition in file error-def.h.

Go to the source code of this file.

Generic Messages

These messages are system wide.

#define EMBER_SUCCESS(x00)#define EMBER_ERR_FATAL(x01)#define EMBER_BAD_ARGUMENT(x02)#define EMBER_EEPROM_MFG_STACK_VERSION_MISMATCH(x04)#define EMBER_INCOMPATIBLE_STATIC_MEMORY_DEFINITIONS(x05)#define EMBER_EEPROM_MFG_VERSION_MISMATCH(x06)#define EMBER_EEPROM_STACK_VERSION_MISMATCH(x07)

Packet Buffer Module Errors

#define EMBER_NO_BUFFERS(x18)

Serial Manager Errors

#define EMBER_SERIAL_INVALID_BAUD_RATE(x20)#define EMBER_SERIAL_INVALID_PORT(x21)#define EMBER_SERIAL_TX_OVERFLOW(x22)#define EMBER_SERIAL_RX_OVERFLOW(x23)#define EMBER_SERIAL_RX_FRAME_ERROR(x24)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/error-def_8h.htm (1 of 5) [10/29/2010 2:43:48 PM]

442

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 443: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: error-def.h File Reference

#define EMBER_SERIAL_RX_PARITY_ERROR(x25)#define EMBER_SERIAL_RX_EMPTY(x26)#define EMBER_SERIAL_RX_OVERRUN_ERROR(x27)

MAC Errors

#define EMBER_MAC_TRANSMIT_QUEUE_FULL(x39)#define EMBER_MAC_UNKNOWN_HEADER_TYPE(x3A)#define EMBER_MAC_ACK_HEADER_TYPE(x3B)#define EMBER_MAC_SCANNING(x3D)#define EMBER_MAC_NO_DATA(x31)#define EMBER_MAC_JOINED_NETWORK(x32)#define EMBER_MAC_BAD_SCAN_DURATION(x33)#define EMBER_MAC_INCORRECT_SCAN_TYPE(x34)#define EMBER_MAC_INVALID_CHANNEL_MASK(x35)#define EMBER_MAC_COMMAND_TRANSMIT_FAILURE(x36)#define EMBER_MAC_NO_ACK_RECEIVED(x40)#define EMBER_MAC_INDIRECT_TIMEOUT(x42)

Simulated EEPROM Errors

#define EMBER_SIM_EEPROM_ERASE_PAGE_GREEN(x43)#define EMBER_SIM_EEPROM_ERASE_PAGE_RED(x44)#define EMBER_SIM_EEPROM_FULL(x45)#define EMBER_SIM_EEPROM_INIT_1_FAILED(x48)#define EMBER_SIM_EEPROM_INIT_2_FAILED(x49)#define EMBER_SIM_EEPROM_INIT_3_FAILED(x4A)

Flash Errors

#define EMBER_ERR_FLASH_WRITE_INHIBITED(x46)#define EMBER_ERR_FLASH_VERIFY_FAILED(x47)#define EMBER_ERR_FLASH_PROG_FAIL(x4B)#define EMBER_ERR_FLASH_ERASE_FAIL(x4C)

Bootloader Errors

#define EMBER_ERR_BOOTLOADER_TRAP_TABLE_BAD(x58)#define EMBER_ERR_BOOTLOADER_TRAP_UNKNOWN(x59)#define EMBER_ERR_BOOTLOADER_NO_IMAGE(x05A)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/error-def_8h.htm (2 of 5) [10/29/2010 2:43:48 PM]

443

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 444: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: error-def.h File Reference

Transport Errors

#define EMBER_DELIVERY_FAILED(x66)#define EMBER_BINDING_INDEX_OUT_OF_RANGE(x69)#define EMBER_ADDRESS_TABLE_INDEX_OUT_OF_RANGE(x6A)#define EMBER_INVALID_BINDING_INDEX(x6C)#define EMBER_INVALID_CALL(x70)#define EMBER_COST_NOT_KNOWN(x71)#define EMBER_MAX_MESSAGE_LIMIT_REACHED(x72)#define EMBER_MESSAGE_TOO_LONG(x74)#define EMBER_BINDING_IS_ACTIVE(x75)#define EMBER_ADDRESS_TABLE_ENTRY_IS_ACTIVE(x76)

HAL Module Errors

#define EMBER_ADC_CONVERSION_DONE(x80)#define EMBER_ADC_CONVERSION_BUSY(x81)#define EMBER_ADC_CONVERSION_DEFERRED(x82)#define EMBER_ADC_NO_CONVERSION_PENDING(x84)#define EMBER_SLEEP_INTERRUPTED(x85)

PHY Errors

#define EMBER_PHY_TX_UNDERFLOW(x88)#define EMBER_PHY_TX_INCOMPLETE(x89)#define EMBER_PHY_INVALID_CHANNEL(x8A)#define EMBER_PHY_INVALID_POWER(x8B)#define EMBER_PHY_TX_BUSY(x8C)#define EMBER_PHY_TX_CCA_FAIL(x8D)#define EMBER_PHY_OSCILLATOR_CHECK_FAILED(x8E)#define EMBER_PHY_ACK_RECEIVED(x8F)

Return Codes Passed to emberStackStatusHandler()

See also emberStackStatusHandler().

#define EMBER_NETWORK_UP(x90)#define EMBER_NETWORK_DOWN(x91)#define EMBER_JOIN_FAILED(x94)#define EMBER_MOVE_FAILED(x96)#define EMBER_CANNOT_JOIN_AS_ROUTER(x98)#define EMBER_NODE_ID_CHANGED(x99)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/error-def_8h.htm (3 of 5) [10/29/2010 2:43:48 PM]

444

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 445: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: error-def.h File Reference

#define EMBER_PAN_ID_CHANGED(x9A)#define EMBER_CHANNEL_CHANGED(x9B)#define EMBER_NO_BEACONS(xAB)#define EMBER_RECEIVED_KEY_IN_THE_CLEAR(xAC)#define EMBER_NO_NETWORK_KEY_RECEIVED(xAD)#define EMBER_NO_LINK_KEY_RECEIVED(xAE)#define EMBER_PRECONFIGURED_KEY_REQUIRED(xAF)

Security Errors

#define EMBER_KEY_INVALID(xB2)#define EMBER_INVALID_SECURITY_LEVEL(x95)#define EMBER_APS_ENCRYPTION_ERROR(xA6)#define EMBER_TRUST_CENTER_MASTER_KEY_NOT_SET(xA7)#define EMBER_SECURITY_STATE_NOT_SET(xA8)#define EMBER_KEY_TABLE_INVALID_ADDRESS(xB3)#define EMBER_SECURITY_CONFIGURATION_INVALID(xB7)#define EMBER_TOO_SOON_FOR_SWITCH_KEY(xB8)#define EMBER_SIGNATURE_VERIFY_FAILURE(xB9)#define EMBER_KEY_NOT_AUTHORIZED(xBB)

Miscellaneous Network Errors

#define EMBER_NOT_JOINED(x93)#define EMBER_NETWORK_BUSY(xA1)#define EMBER_INVALID_ENDPOINT(xA3)#define EMBER_BINDING_HAS_CHANGED(xA4)#define EMBER_INSUFFICIENT_RANDOM_DATA(xA5)#define EMBER_SOURCE_ROUTE_FAILURE(xA9)#define EMBER_MANY_TO_ONE_ROUTE_FAILURE(xAA)

Miscellaneous Utility Errors

#define EMBER_STACK_AND_HARDWARE_MISMATCH(xB0)#define EMBER_INDEX_OUT_OF_RANGE(xB1)#define EMBER_TABLE_FULL(xB4)#define EMBER_TABLE_ENTRY_ERASED(xB6)#define EMBER_LIBRARY_NOT_PRESENT(xB5)#define EMBER_OPERATION_IN_PROGRESS(xBA)#define EMBER_TRUST_CENTER_EUI_HAS_CHANGED(xBC)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/error-def_8h.htm (4 of 5) [10/29/2010 2:43:48 PM]

445

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 446: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: error-def.h File Reference

Application Errors

These error codes are available for application use.

#define EMBER_APPLICATION_ERROR_0(xF0)#define EMBER_APPLICATION_ERROR_1(xF1)#define EMBER_APPLICATION_ERROR_2(xF2)#define EMBER_APPLICATION_ERROR_3(xF3)#define EMBER_APPLICATION_ERROR_4(xF4)#define EMBER_APPLICATION_ERROR_5(xF5)#define EMBER_APPLICATION_ERROR_6(xF6)#define EMBER_APPLICATION_ERROR_7(xF7)#define EMBER_APPLICATION_ERROR_8(xF8)#define EMBER_APPLICATION_ERROR_9(xF9)#define EMBER_APPLICATION_ERROR_10(xFA)#define EMBER_APPLICATION_ERROR_11(xFB)#define EMBER_APPLICATION_ERROR_12(xFC)#define EMBER_APPLICATION_ERROR_13(xFD)#define EMBER_APPLICATION_ERROR_14(xFE)#define EMBER_APPLICATION_ERROR_15(xFF)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/error-def_8h.htm (5 of 5) [10/29/2010 2:43:48 PM]

446

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 447: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: error.h File Reference

stack » include

error.h File Reference

Detailed Description

Return codes for Ember API functions and module definitions.

See Ember Status Codes for documentation.

Definition in file error.h.

Go to the source code of this file.

Defines

#define DEFINE_ERROR(symbol, value)

Typedefs

typedef int8u EmberStatus

Enumerations

enum { EMBER_ERROR_CODE_COUNT }

Typedef Documentation

typedef int8u EmberStatus

Return type for Ember functions.

Definition at line 19 of file error.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/error_8h.htm (1 of 2) [10/29/2010 2:43:48 PM]

447

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 448: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: error.h File Reference

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/error_8h.htm (2 of 2) [10/29/2010 2:43:48 PM]

448

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 449: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ezsp-host-configuration-defaults.h File Reference

app » util » ezsp

ezsp-host-configuration-defaults.h File Reference

Detailed Description

User-configurable parameters for host applications.

The default values set in this file can be overridden by putting #defines into the host application's CONFIGURATION_HEADER.

See Configuration for documentation.

Definition in file ezsp-host-configuration-defaults.h.

Go to the source code of this file.

Defines

#define EZSP_HOST_SOURCE_ROUTE_TABLE_SIZE#define EZSP_HOST_ASH_RX_POOL_SIZE#define EZSP_HOST_FORM_AND_JOIN_BUFFER_SIZE

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ezsp-host-configuration-defaults_8h.htm [10/29/2010 2:43:49 PM]

449

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 450: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: form-and-join.h File Reference

app » util » common

form-and-join.h File Reference

Detailed Description

Utilities for forming and joining networks.

See Forming and Joining Networks for documentation.

Definition in file form-and-join.h.

Go to the source code of this file.

Functions

EmberStatus emberScanForUnusedPanId (int32u channelMask, int8u duration)EmberStatus emberScanForJoinableNetwork (int32u channelMask, int8u *extendedPanId)EmberStatus emberScanForNextJoinableNetwork (void)

boolean emberFormAndJoinIsScanning (void)void emberUnusedPanIdFoundHandler (EmberPanId panId, int8u channel)void emberJoinableNetworkFoundHandler (EmberZigbeeNetwork *networkFound,

int8u lqi, int8s rssi)void emberScanErrorHandler (EmberStatus status)

boolean emberFormAndJoinScanCompleteHandler (int8u channel, EmberStatus status)boolean emberFormAndJoinNetworkFoundHandler (EmberZigbeeNetwork

*networkFound, int8u lqi, int8s rssi)boolean emberFormAndJoinEnergyScanResultHandler (int8u channel, int8s

maxRssiValue)void emberFormAndJoinTick (void)void emberFormAndJoinTaskInit (void)void emberFormAndJoinRunTask (void)

Variables

boolean emberEnableDualChannelScan

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/form-and-join_8h.htm [10/29/2010 2:43:49 PM]

450

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 451: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: form-and-join3_2.h File Reference

app » util » common

form-and-join3_2.h File Reference

Detailed Description

Utilities for forming and joining networks. Deprecated and will be removed from a future release. Use form-and-join.h instead.

See Forming and Joining Networks for documentation.

Definition in file form-and-join3_2.h.

Go to the source code of this file.

Enumerations

enum formAndJoinScanType { FORM_AND_JOIN_NOT_SCANNING, FORM_AND_JOIN_ENERGY_SCAN, FORM_AND_JOIN_PAN_ID_SCAN, FORM_AND_JOIN_JOINABLE_SCAN, FORM_AND_JOIN_CROSSTALK_SCAN }

Functions

void formZigbeeNetwork3_2 (int32u channelMask, int8s radioTxPower, int8u *extendedPanIdDesired)

void joinZigbeeNetwork3_2 (EmberNodeType nodeType, int32u channelMask, int8s radioTxPower, int8u *extendedPanIdDesired)

void scanError (EmberStatus status)

Enumeration Type Documentation

enum formAndJoinScanType

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/form-and-join3__2_8h.htm (1 of 4) [10/29/2010 2:43:50 PM]

451

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 452: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: form-and-join3_2.h File Reference

The current reason for scanning.

Enumerator: FORM_AND_JOIN_NOT_SCANNING FORM_AND_JOIN_ENERGY_SCAN Energy scan for finding a quiet channel. FORM_AND_JOIN_PAN_ID_SCAN Active scan to see which PAN IDs are in use. FORM_AND_JOIN_JOINABLE_SCAN Active scan for a network to join. FORM_AND_JOIN_CROSSTALK_SCAN Active scan to work around channel

crosstalk.

Definition at line 21 of file form-and-join3_2.h.

Function Documentation

void formZigbeeNetwork3_2 ( int32u channelMask, int8s radioTxPower, int8u * extendedPanIdDesired

)

Form a network.

This performs the following actions:

1. Do an energy scan on the indicated channels and randomly choose one from amongst those with the least average energy.

2. Randomly pick a short PAN ID that does not appear during an active scan on the chosen channel.

3. use the Extended PAN ID passed in or pick a random one if the Extended PAN ID passed in is "0" or a null pointer.

4. Form a network using the chosen channel, short PAN ID, and extended PAN ID.

If any errors occur, the status code is passed to scanError() and no network is formed. Success is indicated by calling emberStackStatusHandler() with the EMBER_NETWORK_UP status value.

Parameters:channelMask radioTxPower extendedPanIdDesired

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/form-and-join3__2_8h.htm (2 of 4) [10/29/2010 2:43:50 PM]

452

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 453: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: form-and-join3_2.h File Reference

void joinZigbeeNetwork3_2 ( EmberNodeType nodeType, int32u channelMask, int8s radioTxPower, int8u * extendedPanIdDesired

)

Join a network.

This tries to join the first network found on the indicated channels that

1. currently permits joining2. matches the stack profile of the application3. matches the Extended PAN ID passed in, or if "0" is passed in it matches any Extended

PAN ID.

If any errors occur, the status code is passed to scanError() and no network is joined. Success is indicated by calling emberStackStatusHandler() with the EMBER_NETWORK_UP status value.

With some board layouts, the em250 is susceptible to a dual channel issue in which packets from 12 channels above or below can sometimes be heard faintly. This affects channels 11, 12, 13, 14, 23, 24, 25, and 26. Hardware reference designs EM250_REF_DES_LAT, version C0 and EM250_REF_DES_CER, version B0 solve the problem.

This function also implements a software workaround. After discovering a network on one of the susceptible channels, joinZigbeeNetwork also scans the channel 12 up or down. If the same network is found there, it chooses the correct one by comparing the link quality of the received beacons.

Parameters:nodeType channelMask radioTxPower extendedPanIdDesired

void scanError ( EmberStatus status )

A callback the application needs to provided.

If an error occurs while attempting to form or join a network, this procedure is called and the form or join effort is aborted.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/form-and-join3__2_8h.htm (3 of 4) [10/29/2010 2:43:50 PM]

453

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 454: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: form-and-join3_2.h File Reference

Parameters:status

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/form-and-join3__2_8h.htm (4 of 4) [10/29/2010 2:43:50 PM]

454

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 455: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: fragment-host.h File Reference

app » util » zigbee-framework

fragment-host.h File Reference

Detailed Description

Fragmented message support for EZSP Hosts. Splits long messages into smaller blocks for transmission and reassembles received blocks. See Message Fragmentation for documentation.

Definition in file fragment-host.h.

Go to the source code of this file.

Initialization

void ezspFragmentInit (int16u receiveBufferLength, int8u *receiveBuffer)

Transmitting

EmberStatus ezspFragmentSendUnicast (EmberOutgoingMessageType type, int16u indexOrDestination, EmberApsFrame *apsFrame, int8u maxFragmentSize, int16u messageLength, int8u *messageContents)

EmberStatus ezspFragmentSourceRouteHandler (void)boolean ezspFragmentMessageSent (EmberApsFrame *apsFrame, EmberStatus status)

void ezspFragmentMessageSentHandler (EmberStatus status)

Receiving

boolean ezspFragmentIncomingMessage (EmberApsFrame *apsFrame, EmberNodeId sender, int16u *messageLength, int8u **messageContents)

void ezspFragmentTick (void)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/fragment-host_8h.htm [10/29/2010 2:43:50 PM]

455

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 456: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: hal.h File Reference

hal

hal.h File Reference

Detailed Description

Generic set of HAL includes for all platforms.

See also Hardware Abstraction Layer (HAL) API Reference for more documentation.

Some HAL includes are not used or present in builds intended for the Host processor connected to the Ember Network Coprocessor.

Definition in file hal.h.

#include "micro/micro.h" #include "micro/adc.h" #include "micro/button.h" #include "micro/buzzer.h" #include "micro/crc.h" #include "micro/endian.h" #include "micro/led.h" #include "micro/random.h" #include "micro/serial.h" #include "micro/spi.h" #include "micro/system-timer.h" #include "micro/bootloader-interface.h" #include "micro/diagnostic.h" #include "micro/token.h"

Go to the source code of this file.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/hal_8h.htm [10/29/2010 2:43:50 PM]

456

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 457: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: host.h File Reference

hal » micro » unix » host » board

host.h File Reference

Detailed Description

Sample API functions.

See also Carrier Board Control.

Definition in file host.h.

Go to the source code of this file.

Defines

#define halInternalInitBoard()#define halInternalPowerDownBoard()#define halInternalPowerUpBoard()#define BUTTON0#define BUTTON1#define TEMP_SENSOR_ADC_CHANNEL#define TEMP_SENSOR_SCALE_FACTOR

Enumerations

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/host_8h.htm (1 of 2) [10/29/2010 2:43:51 PM]

457

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 458: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: host.h File Reference

enum HalBoardLedPins { BOARDLED0, BOARDLED1, BOARDLED2, BOARDLED3, BOARDLED4, BOARDLED5, BOARD_ACTIVITY_LED, BOARD_HEARTBEAT_LED, BOARDLED0, BOARDLED1, BOARD_ACTIVITY_LED, BOARD_HEARTBEAT_LED, BOARDLED0, BOARDLED1, BOARD_ACTIVITY_LED, BOARD_HEARTBEAT_LED }

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/host_8h.htm (2 of 2) [10/29/2010 2:43:51 PM]

458

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 459: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: iar.h File Reference

hal » micro » avr-atmega » compiler

iar.h File Reference

Detailed Description

Compiler/platform-specific definitions and typedefs for the IAR AVR C compiler.

See also Common Microcontroller Functions.

This file should be included first in all source files by setting the preprocessor macro PLATFORM_HEADER to point to it.

Definition in file iar.h.

#include "hal/micro/generic/compiler/platform-common.h"

Go to the source code of this file.

Master Program Memory Declarations

These are a set of defines for simple declarations of program memory.

#define PGM#define PGM_P#define PGM_PU#define PGM_NO_CONST

Miscellaneous Macros

#define MAIN_FUNCTION_PARAMETERS#define MAIN_FUNCTION_ARGUMENTS#define BIGENDIAN_CPU#define NO_STRIPPING#define EEPROM#define __SOURCEFILE__#define assert(condition)#define __delay_cycles(x)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/iar_8h.htm (1 of 12) [10/29/2010 2:43:52 PM]

459

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 460: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: iar.h File Reference

#define DEBUG_LEVEL#define halResetWatchdog()#define __attribute__(nothing)#define UNUSED#define SIGNED_ENUM#define simulatedTimePasses()#define simulatedTimePassesMs(x)#define simulatedSerialTimePasses()

void halInternalAssertFailed (PGM_P filename, int linenumber)

Global Interrupt Manipulation Macros

#define START_ATOMIC_CLOCK()#define STOP_ATOMIC_CLOCK()#define DECLARE_INTERRUPT_STATE#define DECLARE_INTERRUPT_STATE_LITE#define DISABLE_INTERRUPTS()#define DISABLE_INTERRUPTS_LITE()#define RESTORE_INTERRUPTS()#define RESTORE_INTERRUPTS_LITE()#define INTERRUPTS_ON()#define INTERRUPTS_OFF()#define INTERRUPTS_WERE_ON()#define INTERRUPTS_ARE_OFF()#define ATOMIC(code)#define ATOMIC_LITE(code)#define HANDLE_PENDING_INTERRUPTS()

Master Variable Types

These are a set of typedefs to make the size of all variable declarations explicitly known.

typedef unsigned char booleantypedef unsigned char int8u

typedef signed char int8stypedef unsigned int int16u

typedef signed int int16stypedef unsigned long int32u

typedef signed long int32stypedef unsigned int PointerType

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/iar_8h.htm (2 of 12) [10/29/2010 2:43:52 PM]

460

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 461: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: iar.h File Reference

Defines

#define _HAL_USE_COMMON_MEMUTILS_#define _HAL_USE_COMMON_DIVMOD_#define PLATCOMMONOKTOINCLUDE

Define Documentation

#define PGM

Standard program memory delcaration.

Definition at line 67 of file iar.h.

#define PGM_P

Char pointer to program memory declaration.

Definition at line 72 of file iar.h.

#define PGM_PU

Unsigned char pointer to program memory declaration.

Definition at line 77 of file iar.h.

#define PGM_NO_CONST

Sometimes a second PGM is needed in a declaration. Having two 'const' declarations generates a warning so we have a second PGM that turns into nothing under gcc.

Definition at line 90 of file iar.h.

#define MAIN_FUNCTION_PARAMETERS

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/iar_8h.htm (3 of 12) [10/29/2010 2:43:52 PM]

461

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 462: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: iar.h File Reference

Define the parameters to main(), and for those functions that are passed the arguments from main().

Definition at line 104 of file iar.h.

#define MAIN_FUNCTION_ARGUMENTS

Define the parameters to main(), and for those functions that are passed the arguments from main().

Definition at line 105 of file iar.h.

#define BIGENDIAN_CPU

A convenient method for code to know what endiannes processor it is running on. For the AVR, we are little endian.

Definition at line 112 of file iar.h.

#define NO_STRIPPING

A friendlier name for the compiler's intrinsic for not stripping.

Definition at line 119 of file iar.h.

#define EEPROM

A friendlier name for the compiler's intrinsic for eeprom reference.

Definition at line 126 of file iar.h.

#define __SOURCEFILE__

The __SOURCEFILE__ macro is used by asserts to list the filename if it isn't otherwise defined, set it to the compiler intrinsic which specifies the whole filename and path of the sourcefile.

Definition at line 135 of file iar.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/iar_8h.htm (4 of 12) [10/29/2010 2:43:52 PM]

462

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 463: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: iar.h File Reference

#define assert ( condition )

A custom implementation of the C language assert macro. This macro implements the conditional evaluation and calls the function halInternalAssertFailed(). (see hal/micro/micro.h).

Definition at line 152 of file iar.h.

#define __delay_cycles ( x )

__delay_cycles() is an intrinsic IAR WB call; however, we have explicity disallowed it since it is too specific to the system clock.

Note:Please use halCommonDelayMicroseconds() instead, because it correctly accounts for various system clock speeds.

Definition at line 169 of file iar.h.

#define DEBUG_LEVEL

Set debug level based on whether or the DEBUG is defined. For the AVR, no debugging support is included if DEBUG is not defined.

Definition at line 180 of file iar.h.

#define halResetWatchdog ( )

Macro to reset the watchdog timer. Note: be very very careful when using this as you can easily get into an infinite loop if you are not careful.

Definition at line 189 of file iar.h.

#define __attribute__ ( nothing )

Define __attribute__ to nothing since it isn't handled by IAR.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/iar_8h.htm (5 of 12) [10/29/2010 2:43:52 PM]

463

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 464: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: iar.h File Reference

Definition at line 195 of file iar.h.

#define UNUSED

Declare a variable as unused to avoid a warning. Has no effect in IAR builds.

Definition at line 202 of file iar.h.

#define SIGNED_ENUM

Some platforms need to cast enum values that have the high bit set.

Definition at line 208 of file iar.h.

#define simulatedTimePasses ( )

Stub for code not running in simulation.

Definition at line 214 of file iar.h.

#define simulatedTimePassesMs ( x )

Stub for code not running in simulation.

Definition at line 218 of file iar.h.

#define simulatedSerialTimePasses ( )

Stub for code not running in simulation.

Definition at line 222 of file iar.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/iar_8h.htm (6 of 12) [10/29/2010 2:43:52 PM]

464

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 465: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: iar.h File Reference

#define START_ATOMIC_CLOCK ( )

Definition at line 328 of file iar.h.

#define STOP_ATOMIC_CLOCK ( )

Definition at line 329 of file iar.h.

#define DECLARE_INTERRUPT_STATE

This macro should be called in the local variable declarations section of any function which calls DISABLE_INTERRUPTS() or RESTORE_INTERRUPTS().

Definition at line 337 of file iar.h.

#define DECLARE_INTERRUPT_STATE_LITE

Definition at line 338 of file iar.h.

#define DISABLE_INTERRUPTS ( )

Disable interrupts, saving the previous state so it can be later restored with RESTORE_INTERRUPTS().

Note:Do not fail to call RESTORE_INTERRUPTS().

It is safe to nest this call.

Use the LITE version only if you are certain interrupts will not be disabled for long, and pair with RESTORE_INTERRUPTS_LITE().

Definition at line 349 of file iar.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/iar_8h.htm (7 of 12) [10/29/2010 2:43:52 PM]

465

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 466: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: iar.h File Reference

#define DISABLE_INTERRUPTS_LITE ( )

Definition at line 357 of file iar.h.

#define RESTORE_INTERRUPTS ( )

Restore the global interrupt state previously saved by DISABLE_INTERRUPTS().

Note:Do not call without having first called DISABLE_INTERRUPTS() to have saved the state.

It is safe to nest this call.

Use the LITE version only if you are certain interrupts will not be disabled very long, and pair with DISABLE_INTERRUPTS_LITE().

Definition at line 374 of file iar.h.

#define RESTORE_INTERRUPTS_LITE ( )

Definition at line 384 of file iar.h.

#define INTERRUPTS_ON ( )

Enable global interrupts without regard to the current or previous state.

Definition at line 398 of file iar.h.

#define INTERRUPTS_OFF ( )

Disable global interrupts without regard to the current or previous state.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/iar_8h.htm (8 of 12) [10/29/2010 2:43:52 PM]

466

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 467: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: iar.h File Reference

Definition at line 409 of file iar.h.

#define INTERRUPTS_WERE_ON ( )

Returns:TRUE if global interrupt flag was enabled when DISABLE_INTERRUPTS() was called.

Definition at line 420 of file iar.h.

#define INTERRUPTS_ARE_OFF ( )

Returns:TRUE if the current global interrupt flag is enabled.

Definition at line 426 of file iar.h.

#define ATOMIC ( code )

A block of code may be made atomic by wrapping it with this macro. Something which is atomic cannot be interrupted by interrupts.

Note:Use the LITE version only if you are certain interrupts will not be disabled very long.

Definition at line 436 of file iar.h.

#define ATOMIC_LITE ( code )

Definition at line 444 of file iar.h.

#define HANDLE_PENDING_INTERRUPTS ( )

Allows up to two pending interrupts to be executed. Usually this would be called at a safe point while interrupts are disabled (such as within an ISR).

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/iar_8h.htm (9 of 12) [10/29/2010 2:43:52 PM]

467

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 468: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: iar.h File Reference

Takes no action if interrupts are already enabled.

The implementation accounts for an AVR related oddity, wherein one instruction must be executed (a NOP in this instance) before global interrupts are allowed to occur.

Definition at line 464 of file iar.h.

#define _HAL_USE_COMMON_MEMUTILS_

Definition at line 481 of file iar.h.

#define _HAL_USE_COMMON_DIVMOD_

Definition at line 482 of file iar.h.

#define PLATCOMMONOKTOINCLUDE

Definition at line 485 of file iar.h.

Typedef Documentation

typedef unsigned char boolean

A typedef to make the size of the variable explicitly known.

Definition at line 47 of file iar.h.

typedef unsigned char int8u

A typedef to make the size of the variable explicitly known.

Definition at line 48 of file iar.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/iar_8h.htm (10 of 12) [10/29/2010 2:43:52 PM]

468

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 469: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: iar.h File Reference

typedef signed char int8s

A typedef to make the size of the variable explicitly known.

Definition at line 49 of file iar.h.

typedef unsigned int int16u

A typedef to make the size of the variable explicitly known.

Definition at line 50 of file iar.h.

typedef signed int int16s

A typedef to make the size of the variable explicitly known.

Definition at line 51 of file iar.h.

typedef unsigned long int32u

A typedef to make the size of the variable explicitly known.

Definition at line 52 of file iar.h.

typedef signed long int32s

A typedef to make the size of the variable explicitly known.

Definition at line 53 of file iar.h.

typedef unsigned int PointerType

A typedef to make the size of the variable explicitly known.

Definition at line 54 of file iar.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/iar_8h.htm (11 of 12) [10/29/2010 2:43:52 PM]

469

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 470: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: iar.h File Reference

Function Documentation

void halInternalAssertFailed ( PGM_P filename, int linenumber

)

A prototype definition for use by the assert macro. (see hal/micro/micro.h).

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/iar_8h.htm (12 of 12) [10/29/2010 2:43:52 PM]

470

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 471: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: led.h File Reference

hal » micro

led.h File Reference

Detailed Description

See LED Control for documentation.

Definition in file led.h.

Go to the source code of this file.

Typedefs

typedef enum HalBoardLedPins HalBoardLed

Functions

void halInternalInitLed (void)void halToggleLed (HalBoardLed led)void halSetLed (HalBoardLed led)void halClearLed (HalBoardLed led)void halStackIndicateActivity (boolean turnOn)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/led_8h.htm [10/29/2010 2:43:53 PM]

471

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 472: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: linux-serial.h File Reference

app » util » serial

linux-serial.h File Reference

Detailed Description

Ember serial functionality specific to a PC with Unix library support.

See Serial Communication for documentation.

Definition in file linux-serial.h.

Go to the source code of this file.

Defines

#define SERIAL_PORT_RAW#define SERIAL_PORT_CLI

Functions

void emberSerialSetPrompt (const char *thePrompt)void emberSerialCleanup (void)

int emberSerialGetInputFd (int8u port)void emberSerialCommandCompletionInit (EmberCommandEntry *listOfCommands)void emberSerialCommandCompletionInitCli (cliSerialCmdEntry *cliCmdList, int cliCmdListLength)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/linux-serial_8h.htm [10/29/2010 2:43:53 PM]

472

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 473: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: micro.h File Reference

hal » micro

micro.h File Reference

Detailed Description

Full HAL functions common across all microcontroller-specific files. See Common Microcontroller Functions for documentation.

Some functions in this file return an EmberStatus value. See error-def.h for definitions of all EmberStatus return values.

Definition in file micro.h.

#include "hal/micro/generic/em2xx-reset-defs.h"

Go to the source code of this file.

Defines

#define halGetEm2xxResetInfo()

Functions

void halStackProcessBootCount (void)int8u halGetResetInfo (void)

PGM_P halGetResetString (void)void halInternalAssertFailed (PGM_P filename, int linenumber)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/micro_8h.htm [10/29/2010 2:43:53 PM]

473

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 474: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: micro.h File Reference

hal » micro » avr-atmega » 32

avr-atmega/32/micro.h File Reference

Detailed Description

Utility and convenience functions for ATmega32 microcontroller See Common Microcontroller Functions for documentation.

Definition in file avr-atmega/32/micro.h.

Go to the source code of this file.

Defines

#define MILLISECOND_TICKS_PER_SECOND#define RESET_UNKNOWN#define RESET_EXTERNAL#define RESET_POWERON#define RESET_WATCHDOG#define RESET_BROWNOUT#define RESET_JTAG#define RESET_ASSERT#define RESET_RSTACK#define RESET_CSTACK#define RESET_BOOTLOADER#define RESET_PC_ROLLOVER#define RESET_SOFTWARE#define RESET_PROTFAULT#define RESET_FLASH_VERIFY_FAIL#define RESET_FLASH_WRITE_INHIBIT#define RESET_BOOTLOADER_IMG_BAD

Functions

void halStackTriggerDebugTimeSyncCapture (void)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/avr-atmega_232_2micro_8h.htm [10/29/2010 2:43:54 PM]

474

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 475: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: micro.h File Reference

hal » micro » avr-atmega » 128

avr-atmega/128/micro.h File Reference

Detailed Description

Utility and convenience functions for ATmega128 microcontroller.

See also Common Microcontroller Functions.

Unless otherwise noted, the EmberNet stack does not use these functions, and therefore the HAL is not required to implement them. However, many of the supplied example applications do use them.

Note:These HAL files/functions are also used for the ATmega64 microcontroller since the only difference between the ATmega128 and ATmega64 is the size of the flash.

Definition in file avr-atmega/128/micro.h.

Go to the source code of this file.

Defines

#define MILLISECOND_TICKS_PER_SECOND#define RESET_UNKNOWN#define RESET_EXTERNAL#define RESET_POWERON#define RESET_WATCHDOG#define RESET_BROWNOUT#define RESET_JTAG#define RESET_ASSERT#define RESET_RSTACK#define RESET_CSTACK#define RESET_BOOTLOADER#define RESET_PC_ROLLOVER#define RESET_SOFTWARE#define RESET_PROTFAULT#define RESET_FLASH_VERIFY_FAIL

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/avr-atmega_2128_2micro_8h.htm (1 of 4) [10/29/2010 2:43:55 PM]

475

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 476: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: micro.h File Reference

#define RESET_FLASH_WRITE_INHIBIT#define RESET_BOOTLOADER_IMG_BAD

Functions

void halStackTriggerDebugTimeSyncCapture (void)

Define Documentation

#define MILLISECOND_TICKS_PER_SECOND

Definition at line 90 of file avr-atmega/128/micro.h.

#define RESET_UNKNOWN

Defines conditions representing possible reasons for a reset.

Definition at line 96 of file avr-atmega/128/micro.h.

#define RESET_EXTERNAL

Definition at line 97 of file avr-atmega/128/micro.h.

#define RESET_POWERON

Definition at line 98 of file avr-atmega/128/micro.h.

#define RESET_WATCHDOG

Definition at line 99 of file avr-atmega/128/micro.h.

#define RESET_BROWNOUT

Definition at line 100 of file avr-atmega/128/micro.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/avr-atmega_2128_2micro_8h.htm (2 of 4) [10/29/2010 2:43:55 PM]

476

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 477: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: micro.h File Reference

#define RESET_JTAG

Definition at line 101 of file avr-atmega/128/micro.h.

#define RESET_ASSERT

Definition at line 102 of file avr-atmega/128/micro.h.

#define RESET_RSTACK

Definition at line 103 of file avr-atmega/128/micro.h.

#define RESET_CSTACK

Definition at line 104 of file avr-atmega/128/micro.h.

#define RESET_BOOTLOADER

Definition at line 105 of file avr-atmega/128/micro.h.

#define RESET_PC_ROLLOVER

Definition at line 106 of file avr-atmega/128/micro.h.

#define RESET_SOFTWARE

Definition at line 107 of file avr-atmega/128/micro.h.

#define RESET_PROTFAULT

Definition at line 108 of file avr-atmega/128/micro.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/avr-atmega_2128_2micro_8h.htm (3 of 4) [10/29/2010 2:43:55 PM]

477

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 478: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: micro.h File Reference

#define RESET_FLASH_VERIFY_FAIL

Definition at line 109 of file avr-atmega/128/micro.h.

#define RESET_FLASH_WRITE_INHIBIT

Definition at line 110 of file avr-atmega/128/micro.h.

#define RESET_BOOTLOADER_IMG_BAD

Definition at line 111 of file avr-atmega/128/micro.h.

Function Documentation

void halStackTriggerDebugTimeSyncCapture ( void )

Used by the debug stack to trigger the backchannel timer capture circuitry.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/avr-atmega_2128_2micro_8h.htm (4 of 4) [10/29/2010 2:43:55 PM]

478

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 479: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: network-manager.h File Reference

app » util » zigbee-framework

network-manager.h File Reference

Detailed Description

Utilities for use by the ZigBee network manager. See Network Manager for documentation.

Definition in file network-manager.h.

#include <CONFIGURATION_HEADER>

Go to the source code of this file.

Defines

#define NM_WARNING_LIMIT#define NM_WINDOW_SIZE#define NM_CHANNEL_MASK#define NM_WATCHLIST_SIZE

Functions

void nmUtilWarningHandler (void)boolean nmUtilProcessIncoming (EmberApsFrame *apsFrame, int8u messageLength, int8u

*message)EmberStatus nmUtilChangeChannelRequest (void)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/network-manager_8h.htm [10/29/2010 2:43:55 PM]

479

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 480: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: random.h File Reference

hal » micro

random.h File Reference

Detailed Description

See Random Number Generation for detailed documentation.

Definition in file random.h.

Go to the source code of this file.

Functions

void halStackSeedRandom (int32u seed)int16u halCommonGetRandom (void)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/random_8h.htm [10/29/2010 2:43:55 PM]

480

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 481: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: reserved-ram.h File Reference

hal » micro » avr-atmega » 32

32/reserved-ram.h File Reference

Detailed Description

Memory allocations that allow for data sharing between the normally running application and bootloader.

See also Common Microcontroller Functions.

By establishing a common memory "segment" we allow data exchange between applications. for example the sample applications and the bootloader share id information for over the air bootloading.

This is done by specifying hard coded ram addresses for key data, and a block or "segment" of ram which will not be erased by either application when they boot.

There is a potential here for backwards compatilbity issues, since older applications are likely to "reserve" less ram, this is why it's a good idea to reserve slightly more room than needed. although, assuming you're only applications are "some app" and the bootloader, and it's only the bootloader that falls behind, and that it never even approaches the ram use limit - maybe not such an issue.

The actual ram reserved block is specified in the linker scripts.

Definition in file 32/reserved-ram.h.

Go to the source code of this file.

Reserved RAM Definitions

These are reserved addresses for storing simple data for exchange between applications.

#define HAL_RESERVED_RAM_PC_DIAG#define HAL_RESERVED_RAM_RESET_CAUSE#define HAL_RESERVED_RAM_RESET_CAUSE_B#define HAL_RESERVED_RAM_RSTACK_H#define HAL_RESERVED_RAM_RSTACK_L#define HAL_RESERVED_RAM_CSTACK_H

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/32_2reserved-ram_8h.htm (1 of 5) [10/29/2010 2:43:56 PM]

481

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 482: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: reserved-ram.h File Reference

#define HAL_RESERVED_RAM_CSTACK_L

Reset Cause Definitions

These are markers of possible reset causes.

#define RESET_CAUSE_SELF_WDOG#define RESET_CAUSE_ASSERT_BIT#define RESET_CAUSE_CSTACK_BIT#define RESET_CAUSE_RSTACK_BIT#define RESET_CAUSE_BOOTLOADER_BIT#define RESET_CAUSE_SOFTWARE_BIT

Defines

#define SRAM_BASE#define SRAM_END

Define Documentation

#define HAL_RESERVED_RAM_PC_DIAG

A reserved address for storing simple data for exchange between applications.

Definition at line 43 of file 32/reserved-ram.h.

#define HAL_RESERVED_RAM_RESET_CAUSE

A reserved address for storing simple data for exchange between applications.

Definition at line 44 of file 32/reserved-ram.h.

#define HAL_RESERVED_RAM_RESET_CAUSE_B

A reserved address for storing simple data for exchange between applications.

Definition at line 45 of file 32/reserved-ram.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/32_2reserved-ram_8h.htm (2 of 5) [10/29/2010 2:43:56 PM]

482

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 483: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: reserved-ram.h File Reference

#define HAL_RESERVED_RAM_RSTACK_H

A reserved address for storing simple data for exchange between applications.

Definition at line 46 of file 32/reserved-ram.h.

#define HAL_RESERVED_RAM_RSTACK_L

A reserved address for storing simple data for exchange between applications.

Definition at line 47 of file 32/reserved-ram.h.

#define HAL_RESERVED_RAM_CSTACK_H

A reserved address for storing simple data for exchange between applications.

Definition at line 48 of file 32/reserved-ram.h.

#define HAL_RESERVED_RAM_CSTACK_L

A reserved address for storing simple data for exchange between applications.

Definition at line 49 of file 32/reserved-ram.h.

#define RESET_CAUSE_SELF_WDOG

A marker of a possible reset cause.

Definition at line 59 of file 32/reserved-ram.h.

#define RESET_CAUSE_ASSERT_BIT

A marker of a possible reset cause.

Definition at line 60 of file 32/reserved-ram.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/32_2reserved-ram_8h.htm (3 of 5) [10/29/2010 2:43:56 PM]

483

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 484: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: reserved-ram.h File Reference

#define RESET_CAUSE_CSTACK_BIT

A marker of a possible reset cause.

Definition at line 61 of file 32/reserved-ram.h.

#define RESET_CAUSE_RSTACK_BIT

A marker of a possible reset cause.

Definition at line 62 of file 32/reserved-ram.h.

#define RESET_CAUSE_BOOTLOADER_BIT

A marker of a possible reset cause.

Definition at line 63 of file 32/reserved-ram.h.

#define RESET_CAUSE_SOFTWARE_BIT

A marker of a possible reset cause.

Definition at line 64 of file 32/reserved-ram.h.

#define SRAM_BASE

The start of RAM memory.

There isn't currently an easy way to share this between the linker scripts and the C code directly (since they aren't really segments). With that said... This must match the value in the linker scripts.

Definition at line 75 of file 32/reserved-ram.h.

#define SRAM_END

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/32_2reserved-ram_8h.htm (4 of 5) [10/29/2010 2:43:56 PM]

484

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 485: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: reserved-ram.h File Reference

The end of normal RAM memory.

There isn't currently an easy way to share this between the linker scripts and the C code directly (since they aren't really segments). With that said... This must match the value in the linker scripts.

Definition at line 85 of file 32/reserved-ram.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/32_2reserved-ram_8h.htm (5 of 5) [10/29/2010 2:43:56 PM]

485

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 486: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: reserved-ram.h File Reference

hal » micro » avr-atmega » 128

128/reserved-ram.h File Reference

Go to the source code of this file.

Reserved RAM Definitions

These are reserved addresses for storing simple data for exchange between applications.

#define HAL_RESERVED_RAM_BOOTLOADER_KEY#define HAL_RESERVED_RAM_PC_DIAG#define HAL_RESERVED_RAM_GATEWAY_ID#define HAL_RESERVED_RAM_EUI64_ID#define HAL_RESERVED_RAM_PAN_ID#define HAL_RESERVED_RAM_NODE_ID#define HAL_RESERVED_RAM_CHANNEL#define HAL_RESERVED_RAM_POWER#define HAL_RESERVED_RAM_BANDS#define HAL_RESERVED_RAM_MODE#define HAL_RESERVED_RAM_RESET_CAUSE#define HAL_RESERVED_RAM_RESET_CAUSE_B#define HAL_RESERVED_RAM_RSTACK_H#define HAL_RESERVED_RAM_RSTACK_L#define HAL_RESERVED_RAM_CSTACK_H#define HAL_RESERVED_RAM_CSTACK_L

Reset Cause Definitions

These are markers of possible reset causes.

#define RESET_CAUSE_SELF_WDOG#define RESET_CAUSE_ASSERT_BIT#define RESET_CAUSE_CSTACK_BIT#define RESET_CAUSE_RSTACK_BIT#define RESET_CAUSE_BOOTLOADER_BIT#define RESET_CAUSE_SOFTWARE_BIT

Defines

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/128_2reserved-ram_8h.htm (1 of 7) [10/29/2010 2:43:57 PM]

486

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 487: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: reserved-ram.h File Reference

#define SRAM_BASE#define SRAM_END#define EXT_SRAM_END

Define Documentation

#define HAL_RESERVED_RAM_BOOTLOADER_KEY

Description:A reserved address for storing simple data for exchange between applications.

Definition at line 43 of file 128/reserved-ram.h.

#define HAL_RESERVED_RAM_PC_DIAG

Description:A reserved address for storing simple data for exchange between applications.

Definition at line 44 of file 128/reserved-ram.h.

#define HAL_RESERVED_RAM_GATEWAY_ID

Description:A reserved address for storing simple data for exchange between applications.

Definition at line 45 of file 128/reserved-ram.h.

#define HAL_RESERVED_RAM_EUI64_ID

Description:A reserved address for storing simple data for exchange between applications.

Definition at line 46 of file 128/reserved-ram.h.

#define HAL_RESERVED_RAM_PAN_ID

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/128_2reserved-ram_8h.htm (2 of 7) [10/29/2010 2:43:57 PM]

487

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 488: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: reserved-ram.h File Reference

Description:A reserved address for storing simple data for exchange between applications.

Definition at line 47 of file 128/reserved-ram.h.

#define HAL_RESERVED_RAM_NODE_ID

Description:A reserved address for storing simple data for exchange between applications.

Definition at line 48 of file 128/reserved-ram.h.

#define HAL_RESERVED_RAM_CHANNEL

Description:A reserved address for storing simple data for exchange between applications.

Definition at line 49 of file 128/reserved-ram.h.

#define HAL_RESERVED_RAM_POWER

Description:A reserved address for storing simple data for exchange between applications.

Definition at line 50 of file 128/reserved-ram.h.

#define HAL_RESERVED_RAM_BANDS

Description:A reserved address for storing simple data for exchange between applications.

Definition at line 51 of file 128/reserved-ram.h.

#define HAL_RESERVED_RAM_MODE

Description:A reserved address for storing simple data for exchange between applications.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/128_2reserved-ram_8h.htm (3 of 7) [10/29/2010 2:43:57 PM]

488

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 489: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: reserved-ram.h File Reference

Definition at line 52 of file 128/reserved-ram.h.

#define HAL_RESERVED_RAM_RESET_CAUSE

Description:A reserved address for storing simple data for exchange between applications.

Definition at line 53 of file 128/reserved-ram.h.

#define HAL_RESERVED_RAM_RESET_CAUSE_B

Description:A reserved address for storing simple data for exchange between applications.

Definition at line 54 of file 128/reserved-ram.h.

#define HAL_RESERVED_RAM_RSTACK_H

Description:A reserved address for storing simple data for exchange between applications.

Definition at line 55 of file 128/reserved-ram.h.

#define HAL_RESERVED_RAM_RSTACK_L

Description:A reserved address for storing simple data for exchange between applications.

Definition at line 56 of file 128/reserved-ram.h.

#define HAL_RESERVED_RAM_CSTACK_H

Description:A reserved address for storing simple data for exchange between applications.

Definition at line 57 of file 128/reserved-ram.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/128_2reserved-ram_8h.htm (4 of 7) [10/29/2010 2:43:57 PM]

489

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 490: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: reserved-ram.h File Reference

#define HAL_RESERVED_RAM_CSTACK_L

Description:A reserved address for storing simple data for exchange between applications.

Definition at line 58 of file 128/reserved-ram.h.

#define RESET_CAUSE_SELF_WDOG

Description:A marker of a possible reset cause.

Definition at line 68 of file 128/reserved-ram.h.

#define RESET_CAUSE_ASSERT_BIT

Description:A marker of a possible reset cause.

Definition at line 69 of file 128/reserved-ram.h.

#define RESET_CAUSE_CSTACK_BIT

Description:A marker of a possible reset cause.

Definition at line 70 of file 128/reserved-ram.h.

#define RESET_CAUSE_RSTACK_BIT

Description:A marker of a possible reset cause.

Definition at line 71 of file 128/reserved-ram.h.

#define RESET_CAUSE_BOOTLOADER_BIT

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/128_2reserved-ram_8h.htm (5 of 7) [10/29/2010 2:43:57 PM]

490

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 491: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: reserved-ram.h File Reference

Description:A marker of a possible reset cause.

Definition at line 72 of file 128/reserved-ram.h.

#define RESET_CAUSE_SOFTWARE_BIT

Description:A marker of a possible reset cause.

Definition at line 73 of file 128/reserved-ram.h.

#define SRAM_BASE

Description:The start of RAM memory.

There isn't currently an easy way to share this between the linker scripts and the C code directly (since they aren't really segments). With that said... This must match the value in the linker scripts.

Definition at line 84 of file 128/reserved-ram.h.

#define SRAM_END

Description:The end of normal RAM memory.

There isn't currently an easy way to share this between the linker scripts and the C code directly (since they aren't really segments). With that said... This must match the value in the linker scripts.

Definition at line 94 of file 128/reserved-ram.h.

#define EXT_SRAM_END

Description:The end of external RAM memory.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/128_2reserved-ram_8h.htm (6 of 7) [10/29/2010 2:43:57 PM]

491

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 492: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: reserved-ram.h File Reference

There isn't currently an easy way to share this between the linker scripts and the C code directly (since they aren't really segments). With that said... This must match the value in the linker scripts.

Definition at line 104 of file 128/reserved-ram.h.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/128_2reserved-ram_8h.htm (7 of 7) [10/29/2010 2:43:57 PM]

492

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 493: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: serial.h File Reference

hal » micro

hal/micro/serial.h File Reference

Detailed Description

Serial hardware abstraction layer interfaces. See Serial UART Communication for documentation.

Definition in file hal/micro/serial.h.

Go to the source code of this file.

Serial Mode Definitions

These are numerical definitions for the possible serial modes so that code can test for the one being used. There may be additional modes defined in the micro-specific micro.h.

#define EMBER_SERIAL_UNUSED#define EMBER_SERIAL_FIFO#define EMBER_SERIAL_BUFFER#define EMBER_SERIAL_LOWLEVEL

FIFO Utility Macros

These macros manipulate the FIFO queue data structures to add and remove data.

#define FIFO_ENQUEUE(queue, data, size)#define FIFO_DEQUEUE(queue, size)

Serial HAL APIs

These functions must be implemented by the HAL in order for the serial code to operate. Only the higher-level serial code uses these functions, so they should not be called directly. The HAL should also implement the appropriate interrupt handlers to drain the TX queues and fill the RX FIFO queue.

#define halInternalUartFlowControl(port)#define halInternalUartRxPump(port)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/hal_2micro_2serial_8h.htm (1 of 9) [10/29/2010 2:43:58 PM]

493

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 494: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: serial.h File Reference

EmberStatus halInternalUartInit (int8u port, SerialBaudRate rate, SerialParity parity, int8u stopBits)

void halInternalPowerDownUart (void)void halInternalPowerUpUart (void)void halInternalStartUartTx (int8u port)void halInternalStopUartTx (int8u port)

EmberStatus halInternalForceWriteUartData (int8u port, int8u *data, int8u length)EmberStatus halInternalForceReadUartByte (int8u port, int8u *dataByte)

void halInternalWaitUartTxComplete (int8u port)void halInternalRestartUart (void)

boolean halInternalUart1FlowControlRxIsEnabled (void)boolean halInternalUart1XonRefreshDone (void)boolean halInternalUart1TxIsIdle (void)

Buffered Serial Utility APIs

The higher-level serial code implements these APIs, which the HAL uses to deal with buffered serial output.

void emSerialBufferNextMessageIsr (EmSerialBufferQueue *q)void emSerialBufferNextBlockIsr (EmSerialBufferQueue *q, int8u port)

Virtual UART API

API used by the stack in debug builds to receive data arriving over the virtual UART.

void halStackReceiveVuartMessage (int8u *buff, int8u len)

Enumerations

enum SerialBaudRate { DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD,

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/hal_2micro_2serial_8h.htm (2 of 9) [10/29/2010 2:43:58 PM]

494

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 495: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: serial.h File Reference

DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD,

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/hal_2micro_2serial_8h.htm (3 of 9) [10/29/2010 2:43:58 PM]

495

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 496: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: serial.h File Reference

DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD,

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/hal_2micro_2serial_8h.htm (4 of 9) [10/29/2010 2:43:58 PM]

496

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 497: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: serial.h File Reference

DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD,

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/hal_2micro_2serial_8h.htm (5 of 9) [10/29/2010 2:43:58 PM]

497

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 498: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: serial.h File Reference

DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD,

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/hal_2micro_2serial_8h.htm (6 of 9) [10/29/2010 2:43:58 PM]

498

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 499: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: serial.h File Reference

DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD,

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/hal_2micro_2serial_8h.htm (7 of 9) [10/29/2010 2:43:58 PM]

499

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 500: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: serial.h File Reference

DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD,

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/hal_2micro_2serial_8h.htm (8 of 9) [10/29/2010 2:43:58 PM]

500

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 501: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: serial.h File Reference

DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, DEFINE_BAUD, CUSTOM }

enum NameOfType { NONE, ODD, EVEN }

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/hal_2micro_2serial_8h.htm (9 of 9) [10/29/2010 2:43:58 PM]

501

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 502: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: serial.h File Reference

app » util » serial

app/util/serial/serial.h File Reference

Detailed Description

High-level serial communication functions.

See Serial Communication for documentation.

Definition in file app/util/serial/serial.h.

Go to the source code of this file.

Printf Prototypes

These prototypes are for the internal printf implementation, in case it is desired to use it elsewhere. See the code for emberSerialPrintf() for an example of printf usage.

typedef EmberStatus( emPrintfFlushHandler )(int8u flushVar, int8u *contents, int8u length)

int8u emPrintfInternal (emPrintfFlushHandler handler, int8u port, PGM_P buff, va_list list)

Defines

#define emberSerialWriteUsed(port)

Functions

EmberStatus emberSerialInit (int8u port, SerialBaudRate rate, SerialParity parity, int8u stopBits)

int16u emberSerialReadAvailable (int8u port)EmberStatus emberSerialReadByte (int8u port, int8u *dataByte)EmberStatus emberSerialReadLine (int8u port, char *data, int8u

max)EmberStatus emberSerialReadPartialLine (int8u port, char

*data, int8u max, int8u *index)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/app_2util_2serial_2serial_8h.htm (1 of 2) [10/29/2010 2:43:59 PM]

502

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 503: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: serial.h File Reference

int16u emberSerialWriteAvailable (int8u port)EmberStatus emberSerialWriteByte (int8u port, int8u dataByte)EmberStatus emberSerialWriteHex (int8u port, int8u dataByte)EmberStatus emberSerialWriteString (int8u port, PGM_P string)

XAP2B_PAGEZERO_ON EmberStatus emberSerialPrintf (int8u port, PGM_P formatString,...)

XAP2B_PAGEZERO_OFF XAP2B_PAGEZERO_ON EmberStatus

emberSerialPrintfLine (int8u port, PGM_P formatString,...)

XAP2B_PAGEZERO_OFF XAP2B_PAGEZERO_ON EmberStatus emberSerialPrintCarriageReturn (int8u port)

XAP2B_PAGEZERO_OFF EmberStatus emberSerialPrintfVarArg (int8u port, PGM_P formatString, va_list ap)

EmberStatus emberSerialWriteData (int8u port, int8u *data, int8u length)

EmberStatus emberSerialWriteBuffer (int8u port, EmberMessageBuffer buffer, int8u start, int8u length)

XAP2B_PAGEZERO_ON EmberStatus emberSerialWaitSend (int8u port)XAP2B_PAGEZERO_OFF EmberStatus emberSerialGuaranteedPrintf (int8u port, PGM_P

formatString,...)void emberSerialBufferTick (void)void emberSerialFlushRx (int8u port)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/app_2util_2serial_2serial_8h.htm (2 of 2) [10/29/2010 2:43:59 PM]

503

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 504: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: spi-protocol.h File Reference

hal » micro » avr-atmega

spi-protocol.h File Reference

Detailed Description

Example AVR SPI Protocol implementation for interfacing with EM260.

See SPI Access for documentation.

Definition in file spi-protocol.h.

#include "app/util/ezsp/ezsp-enum.h"

Go to the source code of this file.

SPI Protocol Interface

int8u * halNcpFrameint8u halNcpSpipErrorByte

void halNcpSerialInit (void)void halNcpSerialPowerup (void)void halNcpSerialPowerdown (void)

EzspStatus halNcpHardReset (void)EzspStatus halNcpHardResetReqBootload (boolean requestBootload)

void halNcpWakeUp (void)void halNcpSendCommand (void)void halNcpSendRawCommand (void)

EzspStatus halNcpPollForResponse (void)void halNcpIsAwakeIsr (boolean isAwake)

boolean halNcpHasData (void)boolean halNcpVerifySpiProtocolVersion (void)boolean halNcpVerifySpiProtocolActive (void)

SPI Protocol Test Function

void spipTest (int16u test, int16u params)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/spi-protocol_8h.htm [10/29/2010 2:43:59 PM]

504

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 505: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: spi.h File Reference

hal » micro

spi.h File Reference

Detailed Description

Generic SPI manipulation routines.

See SPI Access for documentation.

Definition in file spi.h.

Go to the source code of this file.

Functions

void halCommonInitSpi (void)void halCommonSpiWrite (int8u data)

int8u halCommonSpiRead (void)int8u halCommonSpiReadWrite (int8u data)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/spi_8h.htm [10/29/2010 2:44:00 PM]

505

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 506: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: system-timer.h File Reference

hal » micro

system-timer.h File Reference

Detailed Description

See System Timer Control for documentation.

Definition in file system-timer.h.

Go to the source code of this file.

Defines

#define halIdleForMilliseconds(duration)

Functions

int16u halInternalStartSystemTimer (void)int16u halCommonGetInt16uMillisecondTick (void)int32u halCommonGetInt32uMillisecondTick (void)int16u halCommonGetInt16uQuarterSecondTick (void)

EmberStatus halSleepForQuarterSeconds (int32u *duration)EmberStatus halSleepForMilliseconds (int32u *duration)EmberStatus halCommonIdleForMilliseconds (int32u *duration)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/system-timer_8h.htm [10/29/2010 2:44:00 PM]

506

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 507: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: system-timer.h File Reference

hal » micro » avr-atmega » 32

avr-atmega/32/system-timer.h File Reference

Detailed Description

Functions that provide access to the system clock for ATmega32 microcontroller.

See System Timer Control for documentation.

Definition in file avr-atmega/32/system-timer.h.

Go to the source code of this file.

Functions

void halCommonSetSystemTime (int32u time)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/avr-atmega_232_2system-timer_8h.htm [10/29/2010 2:44:00 PM]

507

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 508: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: system-timer.h File Reference

hal » micro » avr-atmega » 128

avr-atmega/128/system-timer.h File Reference

Detailed Description

Functions that provide access to the system clock for ATmega128 microcontroller.

See System Timer Control for documentation.

Definition in file avr-atmega/128/system-timer.h.

Go to the source code of this file.

Functions

void halCommonSetSystemTime (int32u time)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/avr-atmega_2128_2system-timer_8h.htm [10/29/2010 2:44:01 PM]

508

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 509: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: uart.h File Reference

hal » micro » avr-atmega

uart.h File Reference

Detailed Description

Prototypes and defines for the hardware-specific UARTs.

See Hardware-Specific UART for documentation.

Definition in file uart.h.

Go to the source code of this file.

UART0 Tinies

UART I/O tiny implementations for UART0.

#define halUart0InitTiny()#define halUart0WriteByteTiny(x)

EmberStatus halUart0ReadByteTimeoutTiny (int8u *dataByte)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/uart_8h.htm [10/29/2010 2:44:01 PM]

509

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 510: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: zigbee-device-common.h File Reference

app » util » zigbee-framework

zigbee-device-common.h File Reference

Detailed Description

ZigBee Device Object (ZDO) functions available on all platforms. See ZigBee Device Object (ZDO) Information for documentation.

Definition in file zigbee-device-common.h.

Go to the source code of this file.

Service Discovery Functions

EmberStatus emberNodeDescriptorRequest (EmberNodeId target, EmberApsOption options)EmberStatus emberPowerDescriptorRequest (EmberNodeId target, EmberApsOption options)EmberStatus emberSimpleDescriptorRequest (EmberNodeId target, int8u targetEndpoint,

EmberApsOption options)EmberStatus emberActiveEndpointsRequest (EmberNodeId target, EmberApsOption options)

Binding Manager Functions

EmberStatus emberBindRequest (EmberNodeId target, EmberEUI64 source, int8u sourceEndpoint, int16u clusterId, int8u type, EmberEUI64 destination, EmberMulticastId groupAddress, int8u destinationEndpoint, EmberApsOption options)

EmberStatus emberUnbindRequest (EmberNodeId target, EmberEUI64 source, int8u sourceEndpoint, int16u clusterId, int8u type, EmberEUI64 destination, EmberMulticastId groupAddress, int8u destinationEndpoint, EmberApsOption options)

Node Manager Functions

EmberStatus emberLqiTableRequest (EmberNodeId target, int8u startIndex, EmberApsOption options)

EmberStatus emberRoutingTableRequest (EmberNodeId target, int8u startIndex, EmberApsOption options)

EmberStatus emberBindingTableRequest (EmberNodeId target, int8u startIndex, EmberApsOption options)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/zigbee-device-common_8h.htm (1 of 2) [10/29/2010 2:44:01 PM]

510

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 511: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: zigbee-device-common.h File Reference

EmberStatus emberLeaveRequest (EmberNodeId target, EmberEUI64 deviceAddress, int8u leaveRequestFlags, EmberApsOption options)

EmberStatus emberPermitJoiningRequest (EmberNodeId target, int8u duration, int8u authentication, EmberApsOption options)

void emberSetZigDevRequestRadius (int8u radius)int8u emberGetZigDevRequestRadius (void)int8u emberGetLastZigDevRequestSequence (void)

Defines

#define ZDO_MESSAGE_OVERHEAD

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/zigbee-device-common_8h.htm (2 of 2) [10/29/2010 2:44:01 PM]

511

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 512: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: zigbee-device-host.h File Reference

app » util » zigbee-framework

zigbee-device-host.h File Reference

Detailed Description

ZigBee Device Object (ZDO) functions not provided by the stack. See ZigBee Device Object (ZDO) Information for documentation.

Definition in file zigbee-device-host.h.

Go to the source code of this file.

Device Discovery Functions

EmberStatus emberNetworkAddressRequest (EmberEUI64 target, boolean reportKids, int8u childStartIndex)

EmberStatus emberIeeeAddressRequest (EmberNodeId target, boolean reportKids, int8u childStartIndex, EmberApsOption options)

Service Discovery Functions

EmberStatus ezspMatchDescriptorsRequest (EmberNodeId target, int16u profile, int8u inCount, int8u outCount, int16u *inClusters, int16u *outClusters, EmberApsOption options)

Binding Manager Functions

EmberStatus ezspEndDeviceBindRequest (EmberNodeId localNodeId, EmberEUI64 localEui64, int8u endpoint, int16u profile, int8u inCount, int8u outCount, int16u *inClusters, int16u *outClusters, EmberApsOption options)

Function to Decode Address Response Messages

EmberNodeId ezspDecodeAddressResponse (int8u *response, EmberEUI64 eui64Return)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/zigbee-device-host_8h.htm [10/29/2010 2:44:02 PM]

512

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 513: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: zigbee-device-stack.h File Reference

stack » include

zigbee-device-stack.h File Reference

Detailed Description

ZigBee Device Object (ZDO) functions included in the stack.

See ZigBee Device Object for documentation.

Definition in file zigbee-device-stack.h.

Go to the source code of this file.

Functions

EmberStatus emberNetworkAddressRequest (EmberEUI64 target, boolean reportKids, int8u childStartIndex)

EmberStatus emberIeeeAddressRequest (EmberNodeId target, boolean reportKids, int8u childStartIndex, EmberApsOption options)

EmberStatus emberEnergyScanRequest (EmberNodeId target, int32u scanChannels, int8u scanDuration, int16u scanCount)

EmberStatus emberSetNetworkManagerRequest (EmberNodeId networkManager, int32u activeChannels)

EmberStatus emberChannelChangeRequest (int8u channel)EmberStatus emberSendDeviceAnnouncement (void)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/zigbee-device-stack_8h.htm [10/29/2010 2:44:02 PM]

513

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 514: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Directory Hierarchy

EmberZNet API Reference: For the EM260 Co-Processor Directories

The directory hierarchy:

● app �❍ ezsp-uart-host �❍ util

■ bootload ■ common ■ ezsp ■ serial ■ zigbee-framework

● hal �❍ micro

■ avr-atmega ■ 128

■ board ■ 32

■ board ■ compiler

■ generic ■ unix

■ host ■ board

● stack �❍ config �❍ include

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/dirs.htm [10/29/2010 2:44:03 PM]

514

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 515: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: /cygdrive/c/dev/perforce/software/v2/tephra-park/app/ Directory Reference

app

app Directory Reference

Directories

directory ezsp-uart-hostdirectory util

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/O...API_EM260_forPDF/dir_39f4b559b0178c03828b1f07d5c65d40.htm [10/29/2010 2:44:03 PM]

515

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 516: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: /cygdrive/c/dev/perforce/software/v2/tephra-park/app/ezsp-uart-host/ Directory Reference

app » ezsp-uart-host

ezsp-uart-host Directory Reference

Files

file ash-host-io.h [code]file ash-host-priv.h [code]file ash-host-queues.h [code]file ash-host-ui.h [code]file ash-host.h [code]

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Ou.../API_EM260_forPDF/dir_4ef060ddc0a7ca328ff6dc8d2a2a306f.htm [10/29/2010 2:44:03 PM]

516

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 517: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: /cygdrive/c/dev/perforce/software/v2/tephra-park/app/util/ Directory Reference

app » util

util Directory Reference

Directories

directory bootloaddirectory commondirectory ezspdirectory serialdirectory zigbee-framework

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/O...API_EM260_forPDF/dir_e694ca3f9b9179c521604c8809395f5b.htm [10/29/2010 2:44:04 PM]

517

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 518: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: /cygdrive/c/dev/perforce/software/v2/tephra-park/app/util/bootload/ Directory Reference

app » util » bootload

bootload Directory Reference

Files

file bootload-ezsp-utils.h [code]file bootload-utils.h [code]

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/O...API_EM260_forPDF/dir_9df1b99b771da598f6e56b06d077b285.htm [10/29/2010 2:44:04 PM]

518

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 519: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: /cygdrive/c/dev/perforce/software/v2/tephra-park/app/util/common/ Directory Reference

app » util » common

common Directory Reference

Files

file form-and-join.h [code]file form-and-join3_2.h [code]

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/O...API_EM260_forPDF/dir_70905e05b70b2645bc107a4f78f8f189.htm [10/29/2010 2:44:04 PM]

519

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 520: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: /cygdrive/c/dev/perforce/software/v2/tephra-park/app/util/ezsp/ Directory Reference

app » util » ezsp

ezsp Directory Reference

Files

file ezsp-host-configuration-defaults.h [code]

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/O...API_EM260_forPDF/dir_e182c8825235f61a22dc04be92992345.htm [10/29/2010 2:44:05 PM]

520

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 521: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: /cygdrive/c/dev/perforce/software/v2/tephra-park/app/util/serial/ Directory Reference

app » util » serial

serial Directory Reference

Files

file command-interpreter.h [code]file linux-serial.h [code]file app/util/serial/serial.h [code]

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/...PI_EM260_forPDF/dir_7abe1b25796db1b772f6053a2d68bb74.htm [10/29/2010 2:44:05 PM]

521

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 522: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: /cygdrive/c/dev/per...e/software/v2/tephra-park/app/util/zigbee-framework/ Directory Reference

app » util » zigbee-framework

zigbee-framework Directory Reference

Files

file ami-inter-pan-host.h [code]file ami-inter-pan.h [code]file fragment-host.h [code]file network-manager.h [code]file zigbee-device-common.h [code]file zigbee-device-host.h [code]

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/O...API_EM260_forPDF/dir_3d116a09ca84e9f47a56f391151424e2.htm [10/29/2010 2:44:05 PM]

522

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 523: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: /cygdrive/c/dev/perforce/software/v2/tephra-park/hal/ Directory Reference

hal

hal Directory Reference

Directories

directory micro

Files

file hal.h [code]

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Ou.../API_EM260_forPDF/dir_a777f3d7a7f23e6a10ca6f0b66fdae83.htm [10/29/2010 2:44:06 PM]

523

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 524: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: /cygdrive/c/dev/perforce/software/v2/tephra-park/hal/micro/ Directory Reference

hal » micro

micro Directory Reference

Directories

directory avr-atmegadirectory genericdirectory unix

Files

file adc.h [code]file bootloader-interface-standalone.h [code]file button.h [code]file buzzer.h [code]file crc.h [code]file led.h [code]file micro.h [code]file random.h [code]file hal/micro/serial.h [code]file spi.h [code]file system-timer.h [code]

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/O...API_EM260_forPDF/dir_8965a4c3ba19911fc58ec635add1be61.htm [10/29/2010 2:44:06 PM]

524

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 525: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: /cygdrive/c/dev/perforce/software/v2/tephra-park/hal/micro/avr-atmega/ Directory Reference

hal » micro » avr-atmega

avr-atmega Directory Reference

Directories

directory 128directory 32directory compiler

Files

file bootloader-interface-standalone-v1.h [code]file spi-protocol.h [code]file uart.h [code]

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/O...API_EM260_forPDF/dir_bcef5f0d71f6b0e10f7a36d7e75bec2d.htm [10/29/2010 2:44:06 PM]

525

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 526: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: /cygdrive/c/dev/per...ce/software/v2/tephra-park/hal/micro/avr-atmega/128/ Directory Reference

hal » micro » avr-atmega » 128

128 Directory Reference

Directories

directory board

Files

file bootloader.h [code]file avr-atmega/128/micro.h [code]file 128/reserved-ram.h [code]file avr-atmega/128/system-timer.h [code]

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/O...API_EM260_forPDF/dir_09e1e8ad50f93b573a13b5ee31291ba5.htm [10/29/2010 2:44:07 PM]

526

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 527: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: /cygdrive/c/dev/pe...ware/v2/tephra-park/hal/micro/avr-atmega/128/board/ Directory Reference

hal » micro » avr-atmega » 128 » board

board Directory Reference

Files

file dev0473.h [code]

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/...PI_EM260_forPDF/dir_ce3d490d371be70390a88755574108b9.htm [10/29/2010 2:44:07 PM]

527

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 528: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: /cygdrive/c/dev/perforce/software/v2/tephra-park/hal/micro/avr-atmega/32/ Directory Reference

hal » micro » avr-atmega » 32

32 Directory Reference

Directories

directory board

Files

file avr-atmega/32/micro.h [code]file 32/reserved-ram.h [code]file avr-atmega/32/system-timer.h [code]

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/O...API_EM260_forPDF/dir_b7b068d935e7aaa501a53592f1d4a3e4.htm [10/29/2010 2:44:07 PM]

528

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 529: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: /cygdrive/c/dev/per...ftware/v2/tephra-park/hal/micro/avr-atmega/32/board/ Directory Reference

hal » micro » avr-atmega » 32 » board

board Directory Reference

Files

file dev0470.h [code]

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/...PI_EM260_forPDF/dir_4116d74606772458b3bde8ab1e524d73.htm [10/29/2010 2:44:08 PM]

529

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 530: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: /cygdrive/c/dev/per...ftware/v2/tephra-park/hal/micro/avr-atmega/compiler/ Directory Reference

hal » micro » avr-atmega » compiler

compiler Directory Reference

Files

file iar.h [code]

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/O...API_EM260_forPDF/dir_de981fcd0be87e0ad08f83e4b7c55028.htm [10/29/2010 2:44:08 PM]

530

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 531: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: /cygdrive/c/dev/perforce/software/v2/tephra-park/hal/micro/generic/ Directory Reference

hal » micro » generic

generic Directory Reference

Files

file ash-common.h [code]file ash-protocol.h [code]

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/O...API_EM260_forPDF/dir_e91efe88c2c8ae7ff120e59a0be41681.htm [10/29/2010 2:44:08 PM]

531

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 532: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: /cygdrive/c/dev/perforce/software/v2/tephra-park/hal/micro/unix/ Directory Reference

hal » micro » unix

unix Directory Reference

Directories

directory host

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/O...API_EM260_forPDF/dir_f308195c86bef83829e4a1db0c02e378.htm [10/29/2010 2:44:09 PM]

532

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 533: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: /cygdrive/c/dev/perforce/software/v2/tephra-park/hal/micro/unix/host/ Directory Reference

hal » micro » unix » host

host Directory Reference

Directories

directory board

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/O...API_EM260_forPDF/dir_72dd67a419fd84aa64e9902673bbe15d.htm [10/29/2010 2:44:09 PM]

533

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 534: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: /cygdrive/c/dev/per...e/software/v2/tephra-park/hal/micro/unix/host/board/ Directory Reference

hal » micro » unix » host » board

board Directory Reference

Files

file host.h [code]

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/O...API_EM260_forPDF/dir_fb80d116003835f35473d95ffb4a44cc.htm [10/29/2010 2:44:09 PM]

534

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 535: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: /cygdrive/c/dev/perforce/software/v2/tephra-park/stack/ Directory Reference

stack

stack Directory Reference

Directories

directory configdirectory include

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/O...API_EM260_forPDF/dir_eea837824b377a80e401f8ed8edbc134.htm [10/29/2010 2:44:10 PM]

535

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 536: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: /cygdrive/c/dev/perforce/software/v2/tephra-park/stack/config/ Directory Reference

stack » config

config Directory Reference

Files

file ember-configuration-defaults.h [code]

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/O...API_EM260_forPDF/dir_701d0c1c411db42336cb51ac3ca661e6.htm [10/29/2010 2:44:10 PM]

536

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 537: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: /cygdrive/c/dev/perforce/software/v2/tephra-park/stack/include/ Directory Reference

stack » include

include Directory Reference

Files

file cbke-crypto-engine.h [code]file ember-debug.h [code]file ember-types.h [code]file error-def.h [code]file error.h [code]file zigbee-device-stack.h [code]

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Ou.../API_EM260_forPDF/dir_405eafee75b7a613f4fbffe94984b3eb.htm [10/29/2010 2:44:10 PM]

537

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 538: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

Index ● _ - a - b - c - d - e - f - h - i - j - l - m - n - o - p - r - s - t - u - w - z -

- _ -

● __attribute__ : iar.h ● __delay_cycles : iar.h ● __SOURCEFILE__ : iar.h ● _HAL_USE_COMMON_DIVMOD_ : iar.h ● _HAL_USE_COMMON_MEMUTILS_ : iar.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals.htm [10/29/2010 2:44:11 PM]

538

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 539: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-types.h Source File

stack » include

ember-types.h

Go to the documentation of this file.

00001 00020 #ifndef EMBER_TYPES_H00021 #define EMBER_TYPES_H00022 00023 #ifndef DOXYGEN_SHOULD_SKIP_THIS00024 #include "stack/config/ember-configuration-defaults.h"00025 #include "stack/include/ember-static-struct.h"00026 #endif //DOXYGEN_SHOULD_SKIP_THIS00027 00032 00033 00037 #define EUI64_SIZE 800038 00042 #define EXTENDED_PAN_ID_SIZE 800043 00047 #define EMBER_ENCRYPTION_KEY_SIZE 1600048 00053 #define EMBER_CERTIFICATE_SIZE 4800054 00058 #define EMBER_PUBLIC_KEY_SIZE 2200059 00063 #define EMBER_PRIVATE_KEY_SIZE 2100064 00068 #define EMBER_SMAC_SIZE 1600069 00074 #define EMBER_SIGNATURE_SIZE 4200075 00079 #define EMBER_AES_HASH_BLOCK_SIZE 1600080 00081 00085 #ifndef __EMBERSTATUS_TYPE__00086 #define __EMBERSTATUS_TYPE__00087 typedef int8u EmberStatus;00088 #endif //__EMBERSTATUS_TYPE__00089 00093 typedef int8u EmberEUI64[EUI64_SIZE];00094 00104 typedef int8u EmberMessageBuffer;00105 00109 typedef int16u EmberNodeId;00110 00112 typedef int16u EmberMulticastId;00113 00117 typedef int16u EmberPanId;00118 00122 #define EMBER_MAX_802_15_4_CHANNEL_NUMBER 2600123 00127 #define EMBER_MIN_802_15_4_CHANNEL_NUMBER 11

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ember-types_8h-source.htm (1 of 18) [10/29/2010 2:44:15 PM]

539

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 540: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-types.h Source File

00128 00132 #define EMBER_NUM_802_15_4_CHANNELS \00133 (EMBER_MAX_802_15_4_CHANNEL_NUMBER - EMBER_MIN_802_15_4_CHANNEL_NUMBER + 1)00134 00138 #define EMBER_ALL_802_15_4_CHANNELS_MASK 0x07FFF800UL00139 00143 #define EMBER_ZIGBEE_COORDINATOR_ADDRESS 0x000000144 00149 #define EMBER_NULL_NODE_ID 0xFFFF00150 00155 #define EMBER_NULL_BINDING 0xFF00156 00166 #define EMBER_TABLE_ENTRY_UNUSED_NODE_ID 0xFFFF00167 00174 #define EMBER_MULTICAST_NODE_ID 0xFFFE00175 00183 #define EMBER_UNKNOWN_NODE_ID 0xFFFD00184 00192 #define EMBER_DISCOVERY_ACTIVE_NODE_ID 0xFFFC00193 00198 #define EMBER_NULL_ADDRESS_TABLE_INDEX 0xFF00199 00203 #define EMBER_ZDO_ENDPOINT 000204 00208 #define EMBER_BROADCAST_ENDPOINT 0xFF00209 00213 #define EMBER_ZDO_PROFILE_ID 0x000000214 00216 00217 00230 #define EMBER_BROADCAST_ADDRESS 0xFFFC00231 00232 #define EMBER_RX_ON_WHEN_IDLE_BROADCAST_ADDRESS 0xFFFD00233 00234 #define EMBER_SLEEPY_BROADCAST_ADDRESS 0xFFFF00235 00243 #ifdef DOXYGEN_SHOULD_SKIP_THIS00244 enum EmberNodeType00245 #else00246 typedef int8u EmberNodeType;00247 enum00248 #endif00249 {00251 EMBER_UNKNOWN_DEVICE = 0,00253 EMBER_COORDINATOR = 1,00255 EMBER_ROUTER = 2,00257 EMBER_END_DEVICE = 3,00261 EMBER_SLEEPY_END_DEVICE = 4,00263 EMBER_MOBILE_END_DEVICE = 500264 };00265 00269 typedef struct {00270 int8u channel;00271 int16u panId;00272 int8u extendedPanId[8];

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ember-types_8h-source.htm (2 of 18) [10/29/2010 2:44:15 PM]

540

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 541: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-types.h Source File

00273 boolean allowingJoin;00274 int8u stackProfile;00275 int8u nwkUpdateId;00276 } EmberZigbeeNetwork;00277 00278 00285 #ifdef DOXYGEN_SHOULD_SKIP_THIS00286 enum EmberApsOption00287 #else00288 typedef int16u EmberApsOption;00289 enum00290 #endif00291 {00293 EMBER_APS_OPTION_NONE = 0x0000,00300 EMBER_APS_OPTION_DSA_SIGN = 0x0010,00303 EMBER_APS_OPTION_ENCRYPTION = 0x0020,00307 EMBER_APS_OPTION_RETRY = 0x0040,00313 EMBER_APS_OPTION_ENABLE_ROUTE_DISCOVERY = 0x0100,00316 EMBER_APS_OPTION_FORCE_ROUTE_DISCOVERY = 0x0200,00318 EMBER_APS_OPTION_SOURCE_EUI64 = 0x0400,00320 EMBER_APS_OPTION_DESTINATION_EUI64 = 0x0800,00323 EMBER_APS_OPTION_ENABLE_ADDRESS_DISCOVERY = 0x1000,00328 EMBER_APS_OPTION_POLL_RESPONSE = 0x2000,00333 EMBER_APS_OPTION_ZDO_RESPONSE_REQUIRED = 0x4000,00339 EMBER_APS_OPTION_FRAGMENT = SIGNED_ENUM 0x800000340 };00341 00342 00343 00347 #ifdef DOXYGEN_SHOULD_SKIP_THIS00348 enum EmberIncomingMessageType00349 #else00350 typedef int8u EmberIncomingMessageType;00351 enum00352 #endif00353 {00355 EMBER_INCOMING_UNICAST,00357 EMBER_INCOMING_UNICAST_REPLY,00359 EMBER_INCOMING_MULTICAST,00361 EMBER_INCOMING_MULTICAST_LOOPBACK,00363 EMBER_INCOMING_BROADCAST,00365 EMBER_INCOMING_BROADCAST_LOOPBACK00366 };00367 00368 00372 #ifdef DOXYGEN_SHOULD_SKIP_THIS00373 enum EmberOutgoingMessageType00374 #else00375 typedef int8u EmberOutgoingMessageType;00376 enum00377 #endif00378 {00380 EMBER_OUTGOING_DIRECT,00382 EMBER_OUTGOING_VIA_ADDRESS_TABLE,

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ember-types_8h-source.htm (3 of 18) [10/29/2010 2:44:15 PM]

541

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 542: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-types.h Source File

00384 EMBER_OUTGOING_VIA_BINDING,00387 EMBER_OUTGOING_MULTICAST,00390 EMBER_OUTGOING_BROADCAST00391 };00392 00393 00397 #ifdef DOXYGEN_SHOULD_SKIP_THIS00398 enum EmberNetworkStatus00399 #else00400 typedef int8u EmberNetworkStatus;00401 enum00402 #endif00403 {00405 EMBER_NO_NETWORK,00407 EMBER_JOINING_NETWORK,00409 EMBER_JOINED_NETWORK,00412 EMBER_JOINED_NETWORK_NO_PARENT,00414 EMBER_LEAVING_NETWORK00415 };00416 00417 00421 #ifdef DOXYGEN_SHOULD_SKIP_THIS00422 enum EmberNetworkScanType00423 #else00424 typedef int8u EmberNetworkScanType;00425 enum00426 #endif00427 {00429 EMBER_ENERGY_SCAN,00431 EMBER_ACTIVE_SCAN00432 };00433 00434 00438 #ifdef DOXYGEN_SHOULD_SKIP_THIS00439 enum EmberBindingType00440 #else00441 typedef int8u EmberBindingType;00442 enum00443 #endif00444 {00446 EMBER_UNUSED_BINDING = 0,00448 EMBER_UNICAST_BINDING = 1,00452 EMBER_MANY_TO_ONE_BINDING = 2,00456 EMBER_MULTICAST_BINDING = 3,00457 };00458 00459 00468 #define EMBER_LOW_RAM_CONCENTRATOR 0xFFF800469 00473 #define EMBER_HIGH_RAM_CONCENTRATOR 0xFFF900474 00476 00477 00481 #ifdef DOXYGEN_SHOULD_SKIP_THIS00482 enum EmberJoinDecision

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ember-types_8h-source.htm (4 of 18) [10/29/2010 2:44:15 PM]

542

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 543: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-types.h Source File

00483 #else00484 typedef int8u EmberJoinDecision;00485 enum00486 #endif00487 {00489 EMBER_USE_PRECONFIGURED_KEY = 0,00491 EMBER_SEND_KEY_IN_THE_CLEAR,00493 EMBER_DENY_JOIN,00495 EMBER_NO_ACTION00496 };00497 00501 #define EMBER_JOIN_DECISION_STRINGS \00502 "use preconfigured key", \00503 "send key in the clear", \00504 "deny join", \00505 "no action",00506 00507 00513 // These map to the actual values within the APS Command frame so they cannot00514 // be arbitrarily changed.00515 #ifdef DOXYGEN_SHOULD_SKIP_THIS00516 enum EmberDeviceUpdate00517 #else00518 typedef int8u EmberDeviceUpdate;00519 enum00520 #endif00521 {00522 EMBER_STANDARD_SECURITY_SECURED_REJOIN = 0,00523 EMBER_STANDARD_SECURITY_UNSECURED_JOIN = 1,00524 EMBER_DEVICE_LEFT = 2,00525 EMBER_STANDARD_SECURITY_UNSECURED_REJOIN = 3,00526 EMBER_HIGH_SECURITY_SECURED_REJOIN = 4,00527 EMBER_HIGH_SECURITY_UNSECURED_JOIN = 5,00528 /* 6 Reserved */00529 EMBER_HIGH_SECURITY_UNSECURED_REJOIN = 7,00530 /* 8 - 15 Reserved */00531 };00532 00536 #define EMBER_DEVICE_UPDATE_STRINGS \00537 "secured rejoin", \00538 "UNsecured join", \00539 "device left", \00540 "UNsecured rejoin", \00541 "high secured rejoin", \00542 "high UNsecured join", \00543 "RESERVED", /* reserved status code, per the spec. */ \00544 "high UNsecured rejoin",00545 00549 #ifdef DOXYGEN_SHOULD_SKIP_THIS00550 enum EmberClusterListId00551 #else00552 typedef int8u EmberClusterListId;00553 enum00554 #endif00555 {00557 EMBER_INPUT_CLUSTER_LIST = 0,

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ember-types_8h-source.htm (5 of 18) [10/29/2010 2:44:15 PM]

543

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 544: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-types.h Source File

00559 EMBER_OUTPUT_CLUSTER_LIST = 100560 };00561 00562 00567 #ifdef DOXYGEN_SHOULD_SKIP_THIS00568 enum EmberEventUnits00569 #else00570 typedef int8u EmberEventUnits;00571 enum00572 #endif00573 {00575 EMBER_EVENT_INACTIVE = 0,00577 EMBER_EVENT_MS_TIME,00580 EMBER_EVENT_QS_TIME,00583 EMBER_EVENT_MINUTE_TIME,00585 EMBER_EVENT_ZERO_DELAY00586 };00587 00588 00592 #ifdef DOXYGEN_SHOULD_SKIP_THIS00593 enum EmberJoinMethod00594 #else00595 typedef int8u EmberJoinMethod;00596 enum00597 #endif00598 {00604 EMBER_USE_MAC_ASSOCIATION = 0,00605 00616 EMBER_USE_NWK_REJOIN = 1,00617 00618 00619 /* For those networks where the "permit joining" flag is never turned00620 * on, they will need to use a NWK Rejoin. If those devices have been 00621 * preconfigured with the NWK key (including sequence number) they can use00622 * a secured rejoin. This is only necessary for end devices since they need00623 * a parent. Routers can simply use the ::EMBER_USE_NWK_COMMISSIONING00624 * join method below.00625 */00626 EMBER_USE_NWK_REJOIN_HAVE_NWK_KEY = 2,00627 00632 EMBER_USE_NWK_COMMISSIONING = 3,00633 };00634 00635 00642 typedef struct {00644 int8u extendedPanId[8];00646 int16u panId;00648 int8s radioTxPower;00650 int8u radioChannel;00655 EmberJoinMethod joinMethod;00656 00661 EmberNodeId nwkManagerId;00667 int8u nwkUpdateId;00673 int32u channels;00674 } EmberNetworkParameters;

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ember-types_8h-source.htm (6 of 18) [10/29/2010 2:44:15 PM]

544

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 545: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-types.h Source File

00675 00676 00677 #ifdef DOXYGEN_SHOULD_SKIP_THIS00678 #define emberInitializeNetworkParameters(parameters) \00679 (MEMSET(parameters, 0, sizeof(EmberNetworkParameters)))00680 #else00681 void emberInitializeNetworkParameters(EmberNetworkParameters* parameters);00682 #endif00683 00687 typedef struct {00689 int16u profileId;00691 int16u clusterId;00693 int8u sourceEndpoint;00695 int8u destinationEndpoint;00697 EmberApsOption options;00699 int16u groupId;00701 int8u sequence;00702 } EmberApsFrame;00703 00704 00711 typedef struct {00713 EmberBindingType type;00715 int8u local;00723 int16u clusterId;00725 int8u remote;00730 EmberEUI64 identifier;00731 } EmberBindingTableEntry;00732 00733 00739 typedef struct {00741 int16u shortId;00744 int8u averageLqi;00747 int8u inCost;00754 int8u outCost;00760 int8u age;00762 EmberEUI64 longId;00763 } EmberNeighborTableEntry;00764 00770 typedef struct {00772 int16u destination;00774 int16u nextHop;00777 int8u status;00780 int8u age;00783 int8u concentratorType;00788 int8u routeRecordState;00789 } EmberRouteTableEntry;00790 00798 typedef struct {00800 EmberMulticastId multicastId;00804 int8u endpoint;00805 } EmberMulticastTableEntry;00806 00811 #ifdef DOXYGEN_SHOULD_SKIP_THIS

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ember-types_8h-source.htm (7 of 18) [10/29/2010 2:44:15 PM]

545

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 546: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-types.h Source File

00812 enum EmberCounterType00813 #else00814 typedef int8u EmberCounterType;00815 enum00816 #endif00817 {00819 EMBER_COUNTER_MAC_RX_BROADCAST = 0,00821 EMBER_COUNTER_MAC_TX_BROADCAST = 1,00823 EMBER_COUNTER_MAC_RX_UNICAST = 2,00825 EMBER_COUNTER_MAC_TX_UNICAST_SUCCESS = 3,00831 EMBER_COUNTER_MAC_TX_UNICAST_RETRY = 4,00833 EMBER_COUNTER_MAC_TX_UNICAST_FAILED = 5,00834 00836 EMBER_COUNTER_APS_DATA_RX_BROADCAST = 6,00838 EMBER_COUNTER_APS_DATA_TX_BROADCAST = 7,00840 EMBER_COUNTER_APS_DATA_RX_UNICAST = 8,00842 EMBER_COUNTER_APS_DATA_TX_UNICAST_SUCCESS = 9,00848 EMBER_COUNTER_APS_DATA_TX_UNICAST_RETRY = 10, 00850 EMBER_COUNTER_APS_DATA_TX_UNICAST_FAILED = 11,00851 00854 EMBER_COUNTER_ROUTE_DISCOVERY_INITIATED = 12,00855 00857 EMBER_COUNTER_NEIGHBOR_ADDED = 13,00859 EMBER_COUNTER_NEIGHBOR_REMOVED = 14,00861 EMBER_COUNTER_NEIGHBOR_STALE = 15,00862 00864 EMBER_COUNTER_JOIN_INDICATION = 16,00866 EMBER_COUNTER_CHILD_REMOVED = 17,00867 00869 EMBER_COUNTER_ASH_OVERFLOW_ERROR = 18,00871 EMBER_COUNTER_ASH_FRAMING_ERROR = 19,00873 EMBER_COUNTER_ASH_OVERRUN_ERROR = 20,00874 00877 EMBER_COUNTER_NWK_FRAME_COUNTER_FAILURE = 21,00878 00881 EMBER_COUNTER_APS_FRAME_COUNTER_FAILURE = 22,00882 00884 EMBER_COUNTER_ASH_XOFF = 23,00885 00889 EMBER_COUNTER_APS_LINK_KEY_NOT_AUTHORIZED = 24,00890 00893 EMBER_COUNTER_NWK_DECRYPTION_FAILURE = 25,00894 00897 EMBER_COUNTER_APS_DECRYPTION_FAILURE = 26,00898 00903 EMBER_COUNTER_ALLOCATE_PACKET_BUFFER_FAILURE = 27,00904 00906 EMBER_COUNTER_TYPE_COUNT = 2800907 };00908 00912 #define EMBER_COUNTER_STRINGS \00913 "Mac Rx Bcast", \00914 "Mac Tx Bcast", \00915 "Mac Rx Ucast", \

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ember-types_8h-source.htm (8 of 18) [10/29/2010 2:44:15 PM]

546

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 547: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-types.h Source File

00916 "Mac Tx Ucast", \00917 "Mac Tx Ucast Retry", \00918 "Mac Tx Ucast Fail", \00919 "APS Rx Bcast", \00920 "APS Tx Bcast", \00921 "APS Rx Ucast", \00922 "APS Tx Ucast Success", \00923 "APS Tx Ucast Retry", \00924 "APS Tx Ucast Fail", \00925 "Route Disc Initiated", \00926 "Neighbor Added", \00927 "Neighbor Removed", \00928 "Neighbor Stale", \00929 "Join Indication", \00930 "Child Moved", \00931 "ASH Overflow", \00932 "ASH Frame Error", \00933 "ASH Overrun Error", \00934 "NWK FC Failure", \00935 "APS FC Failure", \00936 "ASH XOff", \00937 "APS Unauthorized Key", \00938 "NWK Decrypt Failures", \00939 "APS Decrypt Failures", \00940 "Total Packet Buffers", \00941 "Free Packet Buffers", \00942 "Packet Buffer allocate failures", \00943 NULL00944 00946 typedef int8u EmberTaskId;00947 00948 #ifndef EZSP_HOST00949 00955 typedef struct {00957 EmberEventUnits status;00959 EmberTaskId taskid;00963 int32u timeToExecute;00964 } EmberEventControl;00965 #else00966 // host applications use an older, basic form of the event system00973 typedef struct {00975 EmberEventUnits status;00979 int16u timeToExecute;00980 } EmberEventControl;00981 #endif00982 00990 typedef PGM struct {00992 EmberEventControl *control;00994 void (*handler)(void);00995 } EmberEventData;00996 01001 typedef struct {01002 // The time when the next event associated with this task will fire01003 int32u nextEventTime;01004 // The list of events associated with this task01005 EmberEventData *events;

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ember-types_8h-source.htm (9 of 18) [10/29/2010 2:44:15 PM]

547

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 548: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-types.h Source File

01006 // A flag that indicates the task has something to do other than events01007 boolean busy;01008 } EmberTaskControl;01009 01014 01019 #define EMBER_TX_POWER_MODE_DEFAULT 0x000001020 01023 #define EMBER_TX_POWER_MODE_BOOST 0x000101024 01028 #define EMBER_TX_POWER_MODE_ALTERNATE 0x000201029 01033 #define EMBER_TX_POWER_MODE_BOOST_AND_ALTERNATE (EMBER_TX_POWER_MODE_BOOST \01034 |EMBER_TX_POWER_MODE_ALTERNATE)01035 #ifndef DOXYGEN_SHOULD_SKIP_THIS01036 // The application does not ever need to call emberSetTxPowerMode() with the01037 // txPowerMode parameter set to this value. This value is used internally by01038 // the stack to indicate that the default token configuration has not been01039 // overidden by a prior call to emberSetTxPowerMode().01040 #define EMBER_TX_POWER_MODE_USE_TOKEN 0x800001041 #endif//DOXYGEN_SHOULD_SKIP_THIS01042 01044 01049 01057 #define EMBER_PRIVATE_PROFILE_ID 0xC00E01058 01097 #define EMBER_BROADCAST_ALARM_CLUSTER 0x000001098 01135 #define EMBER_UNICAST_ALARM_CLUSTER 0x000101136 01152 #define EMBER_CACHED_UNICAST_ALARM_CLUSTER 0x000201153 01157 #define EMBER_REPORT_COUNTERS_REQUEST 0x000301158 01160 #define EMBER_REPORT_COUNTERS_RESPONSE 0x800301161 01166 #define EMBER_REPORT_AND_CLEAR_COUNTERS_REQUEST 0x000401167 01169 #define EMBER_REPORT_AND_CLEAR_COUNTERS_RESPONSE 0x800401170 01175 #define EMBER_OTA_CERTIFICATE_UPGRADE_CLUSTER 0x000501176 01178 01179 01182 typedef struct { 01184 int8u contents[EMBER_ENCRYPTION_KEY_SIZE];01185 } EmberKeyData;01186 01189 typedef struct {01190 /* This is the certificate byte data. */01191 int8u contents[EMBER_CERTIFICATE_SIZE];01192 } EmberCertificateData;01193 01196 typedef struct {01197 int8u contents[EMBER_PUBLIC_KEY_SIZE];01198 } EmberPublicKeyData;

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ember-types_8h-source.htm (10 of 18) [10/29/2010 2:44:15 PM]

548

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 549: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-types.h Source File

01199 01202 typedef struct {01203 int8u contents[EMBER_PRIVATE_KEY_SIZE];01204 } EmberPrivateKeyData;01205 01208 typedef struct {01209 int8u contents[EMBER_SMAC_SIZE];01210 } EmberSmacData;01211 01215 typedef struct {01216 int8u contents[EMBER_SIGNATURE_SIZE];01217 } EmberSignatureData;01218 01221 typedef struct {01222 int8u contents[EMBER_AES_HASH_BLOCK_SIZE];01223 } EmberMessageDigest;01224 01228 typedef struct {01229 int8u result[EMBER_AES_HASH_BLOCK_SIZE];01230 int32u length;01231 } EmberAesMmoHashContext;01232 01233 01239 #define EMBER_STANDARD_SECURITY_MODE 0x000001240 01244 #define EMBER_TRUST_CENTER_NODE_ID 0x000001245 01246 01250 #ifdef DOXYGEN_SHOULD_SKIP_THIS01251 enum EmberInitialSecurityBitmask01252 #else01253 typedef int16u EmberInitialSecurityBitmask;01254 enum01255 #endif01256 {01259 EMBER_DISTRIBUTED_TRUST_CENTER_MODE = 0x0002,01262 EMBER_GLOBAL_LINK_KEY = 0x0004,01265 EMBER_PRECONFIGURED_NETWORK_KEY_MODE = 0x0008,01266 01267 #if !defined DOXYGEN_SHOULD_SKIP_THIS01268 // Hidden fields used internally.01269 EMBER_HAVE_TRUST_CENTER_UNKNOWN_KEY_TOKEN = 0x0010,01270 EMBER_HAVE_TRUST_CENTER_LINK_KEY_TOKEN = 0x0020,01271 EMBER_HAVE_TRUST_CENTER_MASTER_KEY_TOKEN = 0x0030,01272 #endif01273 01283 EMBER_HAVE_TRUST_CENTER_EUI64 = 0x0040,01284 01291 EMBER_TRUST_CENTER_USES_HASHED_LINK_KEY = 0x0084,01292 01296 EMBER_HAVE_PRECONFIGURED_KEY = 0x0100,01300 EMBER_HAVE_NETWORK_KEY = 0x0200,01305 EMBER_GET_LINK_KEY_WHEN_JOINING = 0x0400,01311 EMBER_REQUIRE_ENCRYPTED_KEY = 0x0800,

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ember-types_8h-source.htm (11 of 18) [10/29/2010 2:44:15 PM]

549

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 550: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-types.h Source File

01319 EMBER_NO_FRAME_COUNTER_RESET = 0x1000,01325 EMBER_GET_PRECONFIGURED_KEY_FROM_INSTALL_CODE = 0x2000,01326 01327 #if !defined DOXYGEN_SHOULD_SKIP_THIS01328 // Internal data01329 EM_SAVED_IN_TOKEN = 0x4000,01330 #define EM_SECURITY_INITIALIZED 0x00008000L01331 01332 // This is only used internally. High security is not released or supported01333 // except for golden unit compliance.01334 #define EMBER_HIGH_SECURITY_MODE 0x000101335 #else 01336 /* All other bits are reserved and must be zero. */01337 #endif01338 };01339 01342 #define EMBER_NO_TRUST_CENTER_MODE EMBER_DISTRIBUTED_TRUST_CENTER_MODE01343 01344 #if !defined DOXYGEN_SHOULD_SKIP_THIS01345 #define NO_TRUST_CENTER_KEY_TOKEN 0x000001346 #define TRUST_CENTER_KEY_TOKEN_MASK 0x003001347 #define SECURITY_BIT_TOKEN_MASK 0x01FF01348 01349 // This is negative logic to support all devices currently in the field01350 // without this bit set.01351 #define KEY_IS_NOT_AUTHORIZED 0x00010000L // RAM bitmask value01352 01353 #define SECURITY_LOWER_BIT_MASK 0x000000FF // ""01354 #define SECURITY_UPPER_BIT_MASK 0x00FF0000L // ""01355 #endif01356 01359 typedef struct {01364 int16u bitmask;01373 EmberKeyData preconfiguredKey;01379 EmberKeyData networkKey;01386 int8u networkKeySequenceNumber;01394 EmberEUI64 preconfiguredTrustCenterEui64;01395 } EmberInitialSecurityState;01396 01397 01401 #ifdef DOXYGEN_SHOULD_SKIP_THIS01402 enum EmberCurrentSecurityBitmask01403 #else01404 typedef int16u EmberCurrentSecurityBitmask;01405 enum01406 #endif01407 {01408 #if defined DOXYGEN_SHOULD_SKIP_THIS01409 // These options are the same for Initial and Current Security state01410 01413 EMBER_STANDARD_SECURITY_MODE_ = 0x0000,01416 EMBER_DISTRIBUTED_TRUST_CENTER_MODE_ = 0x0002,01419 EMBER_GLOBAL_LINK_KEY_ = 0x0004,01420 #else01421 // Bit 3 reserved01422 #endif01423

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ember-types_8h-source.htm (12 of 18) [10/29/2010 2:44:15 PM]

550

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 551: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-types.h Source File

01424 EMBER_HAVE_TRUST_CENTER_LINK_KEY = 0x0010,01425 01427 EMBER_TRUST_CENTER_USES_HASHED_LINK_KEY_ = 0x0084,01428 01429 // Bits 1,5,6, 8-15 reserved01430 };01431 01432 #if !defined DOXYGEN_SHOULD_SKIP_THIS01433 #define INITIAL_AND_CURRENT_BITMASK 0x00FF01434 #endif01435 01436 01439 typedef struct {01442 EmberCurrentSecurityBitmask bitmask;01446 EmberEUI64 trustCenterLongAddress;01447 } EmberCurrentSecurityState;01448 01449 01453 #ifdef DOXYGEN_SHOULD_SKIP_THIS01454 enum EmberKeyStructBitmask01455 #else01456 typedef int16u EmberKeyStructBitmask;01457 enum01458 #endif01459 {01462 EMBER_KEY_HAS_SEQUENCE_NUMBER = 0x0001,01466 EMBER_KEY_HAS_OUTGOING_FRAME_COUNTER = 0x0002,01470 EMBER_KEY_HAS_INCOMING_FRAME_COUNTER = 0x0004,01474 EMBER_KEY_HAS_PARTNER_EUI64 = 0x0008,01478 EMBER_KEY_IS_AUTHORIZED = 0x0010,01479 };01480 01482 #ifdef DOXYGEN_SHOULD_SKIP_THIS01483 enum EmberKeyType01484 #else01485 typedef int8u EmberKeyType;01486 enum01487 #endif01488 {01490 EMBER_TRUST_CENTER_LINK_KEY = 1,01492 EMBER_TRUST_CENTER_MASTER_KEY = 2,01494 EMBER_CURRENT_NETWORK_KEY = 3,01496 EMBER_NEXT_NETWORK_KEY = 4,01498 EMBER_APPLICATION_LINK_KEY = 5,01500 EMBER_APPLICATION_MASTER_KEY = 6,01501 };01502 01506 typedef struct {01509 EmberKeyStructBitmask bitmask;01511 EmberKeyType type;01513 EmberKeyData key;01516 int32u outgoingFrameCounter;01519 int32u incomingFrameCounter;01522 int8u sequenceNumber;01525 EmberEUI64 partnerEUI64;

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ember-types_8h-source.htm (13 of 18) [10/29/2010 2:44:15 PM]

551

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 552: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-types.h Source File

01526 } EmberKeyStruct;01527 01528 01532 #ifdef DOXYGEN_SHOULD_SKIP_THIS01533 enum EmberKeyStatus01534 #else 01535 typedef int8u EmberKeyStatus;01536 enum01537 #endif01538 {01539 EMBER_APP_LINK_KEY_ESTABLISHED = 1,01540 EMBER_APP_MASTER_KEY_ESTABLISHED = 2,01541 EMBER_TRUST_CENTER_LINK_KEY_ESTABLISHED = 3,01542 EMBER_KEY_ESTABLISHMENT_TIMEOUT = 4,01543 EMBER_KEY_TABLE_FULL = 5,01544 01545 // These are success status values applying only to the01546 // Trust Center answering key requests01547 EMBER_TC_RESPONDED_TO_KEY_REQUEST = 6,01548 EMBER_TC_APP_KEY_SENT_TO_REQUESTER = 7,01549 01550 // These are failure status values applying only to the01551 // Trust Center answering key requests01552 EMBER_TC_RESPONSE_TO_KEY_REQUEST_FAILED = 8,01553 EMBER_TC_REQUEST_KEY_TYPE_NOT_SUPPORTED = 9,01554 EMBER_TC_NO_LINK_KEY_FOR_REQUESTER = 10,01555 EMBER_TC_REQUESTER_EUI64_UNKNOWN = 11,01556 EMBER_TC_RECEIVED_FIRST_APP_KEY_REQUEST = 12,01557 EMBER_TC_TIMEOUT_WAITING_FOR_SECOND_APP_KEY_REQUEST = 13,01558 EMBER_TC_NON_MATCHING_APP_KEY_REQUEST_RECEIVED = 14,01559 EMBER_TC_FAILED_TO_SEND_APP_KEYS = 15,01560 EMBER_TC_FAILED_TO_STORE_APP_KEY_REQUEST = 16,01561 EMBER_TC_REJECTED_APP_KEY_REQUEST = 17,01562 };01563 01567 #ifdef DOXYGEN_SHOULD_SKIP_THIS01568 enum EmberLinkKeyRequestPolicy01569 #else 01570 typedef int8u EmberLinkKeyRequestPolicy;01571 enum01572 #endif01573 {01574 EMBER_DENY_KEY_REQUESTS = 0x00, 01575 EMBER_ALLOW_KEY_REQUESTS = 0x01,01576 };01577 01578 01586 #if defined DOXYGEN_SHOULD_SKIP_THIS01587 int8u* emberKeyContents(EmberKeyData* key);01588 #else01589 #define emberKeyContents(key) ((key)->contents)01590 #endif01591 01599 #if defined DOXYGEN_SHOULD_SKIP_THIS01600 int8u* emberCertificateContents(EmberCertificateData* cert);

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ember-types_8h-source.htm (14 of 18) [10/29/2010 2:44:15 PM]

552

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 553: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-types.h Source File

01601 #else01602 #define emberCertificateContents(cert) ((cert)->contents)01603 #endif01604 01612 #if defined DOXYGEN_SHOULD_SKIP_THIS01613 int8u* emberPublicKeyContents(EmberPublicKeyData* key);01614 #else01615 #define emberPublicKeyContents(key) ((key)->contents)01616 #endif01617 01625 #if defined DOXYGEN_SHOULD_SKIP_THIS01626 int8u* emberPrivateKeyContents(EmberPrivateKeyData* key);01627 #else01628 #define emberPrivateKeyContents(key) ((key)->contents)01629 #endif01630 01635 #if defined DOXYGEN_SHOULD_SKIP_THIS01636 int8u* emberSmacContents(EmberSmacData* key);01637 #else01638 #define emberSmacContents(key) ((key)->contents)01639 #endif01640 01644 #if defined DOXYGEN_SHOULD_SKIP_THIS01645 int8u* emberSignatureContents(EmberSignatureData* sig);01646 #else01647 #define emberSignatureContents(sig) ((sig)->contents)01648 #endif01649 01654 #ifdef DOXYGEN_SHOULD_SKIP_THIS01655 enum EmberMacPassthroughType01656 #else01657 typedef int8u EmberMacPassthroughType;01658 enum01659 #endif01660 {01662 EMBER_MAC_PASSTHROUGH_NONE = 0x00,01664 EMBER_MAC_PASSTHROUGH_SE_INTERPAN = 0x01,01666 EMBER_MAC_PASSTHROUGH_EMBERNET = 0x02,01668 EMBER_MAC_PASSTHROUGH_EMBERNET_SOURCE = 0x04,01670 EMBER_MAC_PASSTHROUGH_APPLICATION = 0x0801671 };01672 01673 typedef int8u EmberLibraryStatus;01674 01679 01685 #ifdef DOXYGEN_SHOULD_SKIP_THIS01686 enum EmberZdoStatus01687 #else01688 typedef int8u EmberZdoStatus;01689 enum01690 #endif01691 {01692 // These values are taken from Table 48 of ZDP Errata 043238r003 and Table 201693 // of NWK 02130r10.01694 EMBER_ZDP_SUCCESS = 0x00,01695 // 0x01 to 0x7F are reserved

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ember-types_8h-source.htm (15 of 18) [10/29/2010 2:44:15 PM]

553

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 554: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-types.h Source File

01696 EMBER_ZDP_INVALID_REQUEST_TYPE = 0x80,01697 EMBER_ZDP_DEVICE_NOT_FOUND = 0x81,01698 EMBER_ZDP_INVALID_ENDPOINT = 0x82,01699 EMBER_ZDP_NOT_ACTIVE = 0x83,01700 EMBER_ZDP_NOT_SUPPORTED = 0x84,01701 EMBER_ZDP_TIMEOUT = 0x85,01702 EMBER_ZDP_NO_MATCH = 0x86,01703 // 0x87 is reserved = 0x87,01704 EMBER_ZDP_NO_ENTRY = 0x88,01705 EMBER_ZDP_NO_DESCRIPTOR = 0x89,01706 EMBER_ZDP_INSUFFICIENT_SPACE = 0x8a,01707 EMBER_ZDP_NOT_PERMITTED = 0x8b,01708 EMBER_ZDP_TABLE_FULL = 0x8c,01709 EMBER_ZDP_NOT_AUTHORIZED = 0x8d,01710 01711 EMBER_NWK_ALREADY_PRESENT = 0xC5,01712 EMBER_NWK_TABLE_FULL = 0xC7,01713 EMBER_NWK_UNKNOWN_DEVICE = 0xC801714 };01715 01728 01729 01730 01731 01732 01733 01734 01735 01736 01737 01738 01739 01740 01741 01742 #define NETWORK_ADDRESS_REQUEST 0x000001743 #define NETWORK_ADDRESS_RESPONSE 0x800001744 #define IEEE_ADDRESS_REQUEST 0x000101745 #define IEEE_ADDRESS_RESPONSE 0x800101747 01757 #define NODE_DESCRIPTOR_REQUEST 0x000201758 #define NODE_DESCRIPTOR_RESPONSE 0x800201760 01770 #define POWER_DESCRIPTOR_REQUEST 0x000301771 #define POWER_DESCRIPTOR_RESPONSE 0x800301773 01787 #define SIMPLE_DESCRIPTOR_REQUEST 0x000401788 #define SIMPLE_DESCRIPTOR_RESPONSE 0x800401790 01799 #define ACTIVE_ENDPOINTS_REQUEST 0x000501800 #define ACTIVE_ENDPOINTS_RESPONSE 0x800501802 01814 #define MATCH_DESCRIPTORS_REQUEST 0x000601815 #define MATCH_DESCRIPTORS_RESPONSE 0x800601817

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ember-types_8h-source.htm (16 of 18) [10/29/2010 2:44:15 PM]

554

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 555: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-types.h Source File

01827 #define DISCOVERY_CACHE_REQUEST 0x001201828 #define DISCOVERY_CACHE_RESPONSE 0x801201830 01839 #define END_DEVICE_ANNOUNCE 0x001301840 #define END_DEVICE_ANNOUNCE_RESPONSE 0x801301842 01854 #define SYSTEM_SERVER_DISCOVERY_REQUEST 0x001501855 #define SYSTEM_SERVER_DISCOVERY_RESPONSE 0x801501857 01862 #ifdef DOXYGEN_SHOULD_SKIP_THIS01863 enum EmberZdoServerMask01864 #else01865 typedef int16u EmberZdoServerMask;01866 enum01867 #endif01868 {01869 EMBER_ZDP_PRIMARY_TRUST_CENTER = 0x0001,01870 EMBER_ZDP_SECONDARY_TRUST_CENTER = 0x0002,01871 EMBER_ZDP_PRIMARY_BINDING_TABLE_CACHE = 0x0004,01872 EMBER_ZDP_SECONDARY_BINDING_TABLE_CACHE = 0x0008,01873 EMBER_ZDP_PRIMARY_DISCOVERY_CACHE = 0x0010,01874 EMBER_ZDP_SECONDARY_DISCOVERY_CACHE = 0x0020,01875 EMBER_ZDP_NETWORK_MANAGER = 0x0040,01876 // Bits 0x0080 to 0x8000 are reserved.01877 };01878 01892 #define FIND_NODE_CACHE_REQUEST 0x001C01893 #define FIND_NODE_CACHE_RESPONSE 0x801C01895 01906 #define END_DEVICE_BIND_REQUEST 0x002001907 #define END_DEVICE_BIND_RESPONSE 0x802001909 01927 #define UNICAST_BINDING 0x0301928 #define UNICAST_MANY_TO_ONE_BINDING 0x8301929 #define MULTICAST_BINDING 0x0101930 01931 #define BIND_REQUEST 0x002101932 #define BIND_RESPONSE 0x802101933 #define UNBIND_REQUEST 0x002201934 #define UNBIND_RESPONSE 0x802201936 01984 #define LQI_TABLE_REQUEST 0x003101985 #define LQI_TABLE_RESPONSE 0x803101987 02020 #define ROUTING_TABLE_REQUEST 0x003202021 #define ROUTING_TABLE_RESPONSE 0x803202023 02042 #define BINDING_TABLE_REQUEST 0x003302043 #define BINDING_TABLE_RESPONSE 0x803302045 02056 #define LEAVE_REQUEST 0x003402057 #define LEAVE_RESPONSE 0x803402058 02059 #define LEAVE_REQUEST_REMOVE_CHILDREN_FLAG 0x40

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ember-types_8h-source.htm (17 of 18) [10/29/2010 2:44:15 PM]

555

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 556: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-types.h Source File

02060 #define LEAVE_REQUEST_REJOIN_FLAG 0x8002062 02071 #define PERMIT_JOINING_REQUEST 0x003602072 #define PERMIT_JOINING_RESPONSE 0x803602074 02100 #define NWK_UPDATE_REQUEST 0x003802101 #define NWK_UPDATE_RESPONSE 0x803802103 02107 #define COMPLEX_DESCRIPTOR_REQUEST 0x001002108 #define COMPLEX_DESCRIPTOR_RESPONSE 0x801002109 #define USER_DESCRIPTOR_REQUEST 0x001102110 #define USER_DESCRIPTOR_RESPONSE 0x801102111 #define DISCOVERY_REGISTER_REQUEST 0x001202112 #define DISCOVERY_REGISTER_RESPONSE 0x801202113 #define USER_DESCRIPTOR_SET 0x001402114 #define USER_DESCRIPTOR_CONFIRM 0x801402115 #define NETWORK_DISCOVERY_REQUEST 0x003002116 #define NETWORK_DISCOVERY_RESPONSE 0x803002117 #define DIRECT_JOIN_REQUEST 0x003502118 #define DIRECT_JOIN_RESPONSE 0x803502119 02120 02121 #define CLUSTER_ID_RESPONSE_MINIMUM 0x800002123 02124 02136 #ifdef DOXYGEN_SHOULD_SKIP_THIS02137 enum EmberZdoConfigurationFlags02138 #else02139 typedef int8u EmberZdoConfigurationFlags;02140 enum02141 #endif02142 02143 {02144 EMBER_APP_RECEIVES_SUPPORTED_ZDO_REQUESTS = 0x01,02145 EMBER_APP_HANDLES_UNSUPPORTED_ZDO_REQUESTS = 0x02,02146 EMBER_APP_HANDLES_ZDO_ENDPOINT_REQUESTS = 0x04,02147 EMBER_APP_HANDLES_ZDO_BINDING_REQUESTS = 0x0802148 };02149 02151 02152 #endif // EMBER_TYPES_H02153

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ember-types_8h-source.htm (18 of 18) [10/29/2010 2:44:15 PM]

556

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 557: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ami-inter-pan.h Source File

app » util » zigbee-framework

ami-inter-pan.h

Go to the documentation of this file.

00001 00016 // The three types of inter-PAN messages. The values are actually the00017 // corresponding APS frame controls.00018 //00019 // 0x03 is the special interPAN message type. Unicast mode is 0x00,00020 // broadcast mode is 0x08, and multicast mode is 0x0C.00021 //00022 00023 #define INTER_PAN_UNICAST 0x0300024 #define INTER_PAN_BROADCAST 0x0B00025 #define INTER_PAN_MULTICAST 0x0F00026 00027 // Frame control, sequence, dest PAN ID, dest, source PAN ID, source.00028 #define MAX_INTER_PAN_MAC_SIZE (2 + 1 + 2 + 8 + 2 + 8)00029 // Short form has a short destination.00030 00031 // NWK stub frame has two control bytes.00032 #define STUB_NWK_SIZE 200033 #define STUB_NWK_FRAME_CONTROL 0x000B00034 00035 // APS frame control, group ID, cluster ID, profile ID00036 #define MAX_STUB_APS_SIZE (1 + 2 + 2 + 2)00037 // Short form has no group ID.00038 00039 #define MAX_INTER_PAN_HEADER_SIZE \00040 (MAX_INTER_PAN_MAC_SIZE + STUB_NWK_SIZE + MAX_STUB_APS_SIZE)00041 00045 typedef struct {00046 int8u messageType; // one of the INTER_PAN_...CAST values00047 00048 // MAC addressing00049 // For outgoing messages this is the destination. For incoming messages00050 // it is the source, which always has a long address.00051 int16u panId;00052 boolean hasLongAddress; // always TRUE for incoming messages00053 EmberNodeId shortAddress;00054 EmberEUI64 longAddress;00055 00056 // APS data00057 int16u profileId;00058 int16u clusterId;00059 int16u groupId; // only used for INTER_PAN_MULTICAST

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ami-inter-pan_8h-source.htm (1 of 2) [10/29/2010 2:44:15 PM]

557

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 558: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ami-inter-pan.h Source File

00060 } InterPanHeader;00061 00062 00066 EmberMessageBuffer makeInterPanMessage(InterPanHeader *headerData,00067 EmberMessageBuffer payload);00068 00076 int8u parseInterPanMessage(EmberMessageBuffer message,00077 int8u startOffset,00078 InterPanHeader *headerData);00079

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ami-inter-pan_8h-source.htm (2 of 2) [10/29/2010 2:44:15 PM]

558

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 559: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ami-inter-pan-host.h Source File

app » util » zigbee-framework

ami-inter-pan-host.h

Go to the documentation of this file.

00001 00021 #define INTER_PAN_UNICAST 0x0300022 #define INTER_PAN_BROADCAST 0x0B00023 #define INTER_PAN_MULTICAST 0x0F00024 00025 00026 // Frame control, sequence, dest PAN ID, dest, source PAN ID, source.00027 #define MAX_INTER_PAN_MAC_SIZE (2 + 1 + 2 + 8 + 2 + 8)00028 //Short form has a short destination. 00029 00030 // NWK stub frame has two control bytes.00031 #define STUB_NWK_SIZE 200032 #define STUB_NWK_FRAME_CONTROL 0x000B00033 00034 // APS frame control, group ID, cluster ID, profile ID00035 #define MAX_STUB_APS_SIZE (1 + 2 + 2 + 2)00036 00037 // Short form has no group ID.00038 #define MAX_INTER_PAN_HEADER_SIZE \00039 (MAX_INTER_PAN_MAC_SIZE + STUB_NWK_SIZE + MAX_STUB_APS_SIZE)00040 00045 typedef struct {00046 int8u messageType; // one of the INTER_PAN_...CAST values00047 00048 // MAC addressing00049 // For outgoing messages this is the destination. For incoming messages00050 // it is the source, which always has a long address.00051 int16u panId;00052 boolean hasLongAddress; // always TRUE for incoming messages00053 EmberNodeId shortAddress;00054 EmberEUI64 longAddress;00055 00056 // APS data00057 int16u profileId;00058 int16u clusterId;00059 int16u groupId; // only used for INTER_PAN_MULTICAST00060 } InterPanHeader;00061 00068 int8u makeInterPanMessage(InterPanHeader *headerData,00069 int8u *message,00070 int8u maxLength,00071 int8u *payload,

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ami-inter-pan-host_8h-source.htm (1 of 2) [10/29/2010 2:44:16 PM]

559

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 560: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ami-inter-pan-host.h Source File

00072 int8u payloadLength);00073 00081 int8u parseInterPanMessage(int8u *message,00082 int8u messageLength,00083 InterPanHeader *headerData);00084 00085

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ami-inter-pan-host_8h-source.htm (2 of 2) [10/29/2010 2:44:16 PM]

560

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 561: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: error.h Source File

stack » include

error.h

Go to the documentation of this file.

00001 00011 #ifndef __ERRORS_H__00012 #define __ERRORS_H__00013 00017 #ifndef __EMBERSTATUS_TYPE__00018 #define __EMBERSTATUS_TYPE__00019 typedef int8u EmberStatus;00020 #endif //__EMBERSTATUS_TYPE__00021 00035 #define DEFINE_ERROR(symbol, value) \00036 EMBER_ ## symbol = value,00037 00038 00039 enum {00040 #ifndef DOXYGEN_SHOULD_SKIP_THIS00041 #include "include/error-def.h"00042 #endif //DOXYGEN_SHOULD_SKIP_THIS00043 00046 EMBER_ERROR_CODE_COUNT00047 00048 };00049 00050 #undef DEFINE_ERROR00051 00052 #endif // __ERRORS_H__00053

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/error_8h-source.htm [10/29/2010 2:44:16 PM]

561

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 562: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: error-def.h Source File

stack » include

error-def.h

Go to the documentation of this file.

00001 00038 00039 #ifdef DOXYGEN_SHOULD_SKIP_THIS00040 00043 #define EMBER_SUCCESS(0x00)00044 #else00045 DEFINE_ERROR(SUCCESS, 0)00046 #endif //DOXYGEN_SHOULD_SKIP_THIS00047 00048 00049 #ifdef DOXYGEN_SHOULD_SKIP_THIS00050 00053 #define EMBER_ERR_FATAL(0x01)00054 #else00055 DEFINE_ERROR(ERR_FATAL, 0x01)00056 #endif //DOXYGEN_SHOULD_SKIP_THIS00057 00058 00059 #ifdef DOXYGEN_SHOULD_SKIP_THIS00060 00063 #define EMBER_BAD_ARGUMENT(0x02)00064 #else00065 DEFINE_ERROR(BAD_ARGUMENT, 0x02)00066 #endif //DOXYGEN_SHOULD_SKIP_THIS00067 00068 00069 #ifdef DOXYGEN_SHOULD_SKIP_THIS00070 00074 #define EMBER_EEPROM_MFG_STACK_VERSION_MISMATCH(0x04)00075 #else00076 DEFINE_ERROR(EEPROM_MFG_STACK_VERSION_MISMATCH, 0x04)00077 #endif //DOXYGEN_SHOULD_SKIP_THIS00078 00079 00080 #ifdef DOXYGEN_SHOULD_SKIP_THIS00081 00085 #define EMBER_INCOMPATIBLE_STATIC_MEMORY_DEFINITIONS(0x05)00086 #else00087 DEFINE_ERROR(INCOMPATIBLE_STATIC_MEMORY_DEFINITIONS, 0x05)00088 #endif //DOXYGEN_SHOULD_SKIP_THIS00089 00090 00091 #ifdef DOXYGEN_SHOULD_SKIP_THIS

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/error-def_8h-source.htm (1 of 18) [10/29/2010 2:44:19 PM]

562

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 563: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: error-def.h Source File

00092 00096 #define EMBER_EEPROM_MFG_VERSION_MISMATCH(0x06)00097 #else00098 DEFINE_ERROR(EEPROM_MFG_VERSION_MISMATCH, 0x06)00099 #endif //DOXYGEN_SHOULD_SKIP_THIS00100 00101 00102 #ifdef DOXYGEN_SHOULD_SKIP_THIS00103 00107 #define EMBER_EEPROM_STACK_VERSION_MISMATCH(0x07)00108 #else00109 DEFINE_ERROR(EEPROM_STACK_VERSION_MISMATCH, 0x07)00110 #endif //DOXYGEN_SHOULD_SKIP_THIS00111 00113 00114 00119 00120 #ifdef DOXYGEN_SHOULD_SKIP_THIS00121 00124 #define EMBER_NO_BUFFERS(0x18)00125 #else00126 DEFINE_ERROR(NO_BUFFERS, 0x18)00127 #endif //DOXYGEN_SHOULD_SKIP_THIS00128 00130 00135 00136 #ifdef DOXYGEN_SHOULD_SKIP_THIS00137 00140 #define EMBER_SERIAL_INVALID_BAUD_RATE(0x20)00141 #else00142 DEFINE_ERROR(SERIAL_INVALID_BAUD_RATE, 0x20)00143 #endif //DOXYGEN_SHOULD_SKIP_THIS00144 00145 00146 #ifdef DOXYGEN_SHOULD_SKIP_THIS00147 00150 #define EMBER_SERIAL_INVALID_PORT(0x21)00151 #else00152 DEFINE_ERROR(SERIAL_INVALID_PORT, 0x21)00153 #endif //DOXYGEN_SHOULD_SKIP_THIS00154 00155 00156 #ifdef DOXYGEN_SHOULD_SKIP_THIS00157 00160 #define EMBER_SERIAL_TX_OVERFLOW(0x22)00161 #else00162 DEFINE_ERROR(SERIAL_TX_OVERFLOW, 0x22)00163 #endif //DOXYGEN_SHOULD_SKIP_THIS00164 00165 00166 #ifdef DOXYGEN_SHOULD_SKIP_THIS

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/error-def_8h-source.htm (2 of 18) [10/29/2010 2:44:19 PM]

563

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 564: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: error-def.h Source File

00167 00171 #define EMBER_SERIAL_RX_OVERFLOW(0x23)00172 #else00173 DEFINE_ERROR(SERIAL_RX_OVERFLOW, 0x23)00174 #endif //DOXYGEN_SHOULD_SKIP_THIS00175 00176 00177 #ifdef DOXYGEN_SHOULD_SKIP_THIS00178 00181 #define EMBER_SERIAL_RX_FRAME_ERROR(0x24)00182 #else00183 DEFINE_ERROR(SERIAL_RX_FRAME_ERROR, 0x24)00184 #endif //DOXYGEN_SHOULD_SKIP_THIS00185 00186 00187 #ifdef DOXYGEN_SHOULD_SKIP_THIS00188 00191 #define EMBER_SERIAL_RX_PARITY_ERROR(0x25)00192 #else00193 DEFINE_ERROR(SERIAL_RX_PARITY_ERROR, 0x25)00194 #endif //DOXYGEN_SHOULD_SKIP_THIS00195 00196 00197 #ifdef DOXYGEN_SHOULD_SKIP_THIS00198 00201 #define EMBER_SERIAL_RX_EMPTY(0x26)00202 #else00203 DEFINE_ERROR(SERIAL_RX_EMPTY, 0x26)00204 #endif //DOXYGEN_SHOULD_SKIP_THIS00205 00206 00207 #ifdef DOXYGEN_SHOULD_SKIP_THIS00208 00212 #define EMBER_SERIAL_RX_OVERRUN_ERROR(0x27)00213 #else00214 DEFINE_ERROR(SERIAL_RX_OVERRUN_ERROR, 0x27)00215 #endif //DOXYGEN_SHOULD_SKIP_THIS00216 00218 00223 00224 #ifdef DOXYGEN_SHOULD_SKIP_THIS00225 00228 #define EMBER_MAC_TRANSMIT_QUEUE_FULL(0x39)00229 #else00230 // Internal00231 DEFINE_ERROR(MAC_TRANSMIT_QUEUE_FULL, 0x39)00232 #endif //DOXYGEN_SHOULD_SKIP_THIS00233 00234 00235 #ifdef DOXYGEN_SHOULD_SKIP_THIS00236

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/error-def_8h-source.htm (3 of 18) [10/29/2010 2:44:19 PM]

564

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 565: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: error-def.h Source File

00239 #define EMBER_MAC_UNKNOWN_HEADER_TYPE(0x3A)00240 #else00241 DEFINE_ERROR(MAC_UNKNOWN_HEADER_TYPE, 0x3A)00242 #endif //DOXYGEN_SHOULD_SKIP_THIS00243 00244 #ifdef DOXYGEN_SHOULD_SKIP_THIS00245 00248 #define EMBER_MAC_ACK_HEADER_TYPE(0x3B)00249 #else00250 DEFINE_ERROR(MAC_ACK_HEADER_TYPE, 0x3B)00251 #endif //DOXYGEN_SHOULD_SKIP_THIS00252 00253 00254 00255 #ifdef DOXYGEN_SHOULD_SKIP_THIS00256 00259 #define EMBER_MAC_SCANNING(0x3D)00260 #else00261 DEFINE_ERROR(MAC_SCANNING, 0x3D)00262 #endif //DOXYGEN_SHOULD_SKIP_THIS00263 00264 00265 #ifdef DOXYGEN_SHOULD_SKIP_THIS00266 00269 #define EMBER_MAC_NO_DATA(0x31)00270 #else00271 DEFINE_ERROR(MAC_NO_DATA, 0x31)00272 #endif //DOXYGEN_SHOULD_SKIP_THIS00273 00274 00275 #ifdef DOXYGEN_SHOULD_SKIP_THIS00276 00279 #define EMBER_MAC_JOINED_NETWORK(0x32)00280 #else00281 DEFINE_ERROR(MAC_JOINED_NETWORK, 0x32)00282 #endif //DOXYGEN_SHOULD_SKIP_THIS00283 00284 00285 #ifdef DOXYGEN_SHOULD_SKIP_THIS00286 00290 #define EMBER_MAC_BAD_SCAN_DURATION(0x33)00291 #else00292 DEFINE_ERROR(MAC_BAD_SCAN_DURATION, 0x33)00293 #endif //DOXYGEN_SHOULD_SKIP_THIS00294 00295 00296 #ifdef DOXYGEN_SHOULD_SKIP_THIS00297 00300 #define EMBER_MAC_INCORRECT_SCAN_TYPE(0x34)00301 #else00302 DEFINE_ERROR(MAC_INCORRECT_SCAN_TYPE, 0x34)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/error-def_8h-source.htm (4 of 18) [10/29/2010 2:44:19 PM]

565

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 566: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: error-def.h Source File

00303 #endif //DOXYGEN_SHOULD_SKIP_THIS00304 00305 00306 #ifdef DOXYGEN_SHOULD_SKIP_THIS00307 00310 #define EMBER_MAC_INVALID_CHANNEL_MASK(0x35)00311 #else00312 DEFINE_ERROR(MAC_INVALID_CHANNEL_MASK, 0x35)00313 #endif //DOXYGEN_SHOULD_SKIP_THIS00314 00315 00316 #ifdef DOXYGEN_SHOULD_SKIP_THIS00317 00321 #define EMBER_MAC_COMMAND_TRANSMIT_FAILURE(0x36)00322 #else00323 DEFINE_ERROR(MAC_COMMAND_TRANSMIT_FAILURE, 0x36)00324 #endif //DOXYGEN_SHOULD_SKIP_THIS00325 00326 00327 #ifdef DOXYGEN_SHOULD_SKIP_THIS00328 00332 #define EMBER_MAC_NO_ACK_RECEIVED(0x40)00333 #else00334 DEFINE_ERROR(MAC_NO_ACK_RECEIVED, 0x40)00335 #endif //DOXYGEN_SHOULD_SKIP_THIS00336 00337 00338 #ifdef DOXYGEN_SHOULD_SKIP_THIS00339 00342 #define EMBER_MAC_INDIRECT_TIMEOUT(0x42)00343 #else00344 DEFINE_ERROR(MAC_INDIRECT_TIMEOUT, 0x42)00345 #endif //DOXYGEN_SHOULD_SKIP_THIS00346 00348 00349 00354 00355 00356 #ifdef DOXYGEN_SHOULD_SKIP_THIS00357 00365 #define EMBER_SIM_EEPROM_ERASE_PAGE_GREEN(0x43)00366 #else00367 DEFINE_ERROR(SIM_EEPROM_ERASE_PAGE_GREEN, 0x43)00368 #endif //DOXYGEN_SHOULD_SKIP_THIS00369 00370 00371 #ifdef DOXYGEN_SHOULD_SKIP_THIS00372 00381 #define EMBER_SIM_EEPROM_ERASE_PAGE_RED(0x44)00382 #else00383 DEFINE_ERROR(SIM_EEPROM_ERASE_PAGE_RED, 0x44)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/error-def_8h-source.htm (5 of 18) [10/29/2010 2:44:19 PM]

566

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 567: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: error-def.h Source File

00384 #endif //DOXYGEN_SHOULD_SKIP_THIS00385 00386 00387 #ifdef DOXYGEN_SHOULD_SKIP_THIS00388 00396 #define EMBER_SIM_EEPROM_FULL(0x45)00397 #else00398 DEFINE_ERROR(SIM_EEPROM_FULL, 0x45)00399 #endif //DOXYGEN_SHOULD_SKIP_THIS00400 00401 00402 // Errors 46 and 47 are now defined below in the 00403 // flash error block (was attempting to prevent renumbering)00404 00405 00406 #ifdef DOXYGEN_SHOULD_SKIP_THIS00407 00414 #define EMBER_SIM_EEPROM_INIT_1_FAILED(0x48)00415 #else00416 DEFINE_ERROR(SIM_EEPROM_INIT_1_FAILED, 0x48)00417 #endif //DOXYGEN_SHOULD_SKIP_THIS00418 00419 00420 #ifdef DOXYGEN_SHOULD_SKIP_THIS00421 00427 #define EMBER_SIM_EEPROM_INIT_2_FAILED(0x49)00428 #else00429 DEFINE_ERROR(SIM_EEPROM_INIT_2_FAILED, 0x49)00430 #endif //DOXYGEN_SHOULD_SKIP_THIS00431 00432 00433 #ifdef DOXYGEN_SHOULD_SKIP_THIS00434 00441 #define EMBER_SIM_EEPROM_INIT_3_FAILED(0x4A)00442 #else00443 DEFINE_ERROR(SIM_EEPROM_INIT_3_FAILED, 0x4A)00444 #endif //DOXYGEN_SHOULD_SKIP_THIS00445 00447 00448 00453 00454 #ifdef DOXYGEN_SHOULD_SKIP_THIS00455 00462 #define EMBER_ERR_FLASH_WRITE_INHIBITED(0x46)00463 #else00464 DEFINE_ERROR(ERR_FLASH_WRITE_INHIBITED, 0x46)00465 #endif //DOXYGEN_SHOULD_SKIP_THIS00466 00467 00468 #ifdef DOXYGEN_SHOULD_SKIP_THIS00469 00475 #define EMBER_ERR_FLASH_VERIFY_FAILED(0x47)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/error-def_8h-source.htm (6 of 18) [10/29/2010 2:44:19 PM]

567

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 568: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: error-def.h Source File

00476 #else00477 DEFINE_ERROR(ERR_FLASH_VERIFY_FAILED, 0x47)00478 #endif //DOXYGEN_SHOULD_SKIP_THIS00479 00480 00481 #ifdef DOXYGEN_SHOULD_SKIP_THIS00482 00488 #define EMBER_ERR_FLASH_PROG_FAIL(0x4B)00489 #else00490 DEFINE_ERROR(ERR_FLASH_PROG_FAIL, 0x4B)00491 #endif //DOXYGEN_SHOULD_SKIP_THIS00492 00493 00494 #ifdef DOXYGEN_SHOULD_SKIP_THIS00495 00501 #define EMBER_ERR_FLASH_ERASE_FAIL(0x4C)00502 #else00503 DEFINE_ERROR(ERR_FLASH_ERASE_FAIL, 0x4C)00504 #endif //DOXYGEN_SHOULD_SKIP_THIS00505 00507 00508 00513 00514 00515 #ifdef DOXYGEN_SHOULD_SKIP_THIS00516 00520 #define EMBER_ERR_BOOTLOADER_TRAP_TABLE_BAD(0x58)00521 #else00522 DEFINE_ERROR(ERR_BOOTLOADER_TRAP_TABLE_BAD, 0x58)00523 #endif //DOXYGEN_SHOULD_SKIP_THIS00524 00525 00526 #ifdef DOXYGEN_SHOULD_SKIP_THIS00527 00531 #define EMBER_ERR_BOOTLOADER_TRAP_UNKNOWN(0x59)00532 #else00533 DEFINE_ERROR(ERR_BOOTLOADER_TRAP_UNKNOWN, 0x59)00534 #endif //DOXYGEN_SHOULD_SKIP_THIS00535 00536 00537 #ifdef DOXYGEN_SHOULD_SKIP_THIS00538 00542 #define EMBER_ERR_BOOTLOADER_NO_IMAGE(0x05A)00543 #else00544 DEFINE_ERROR(ERR_BOOTLOADER_NO_IMAGE, 0x5A)00545 #endif //DOXYGEN_SHOULD_SKIP_THIS00546 00548 00549 00554 00555 #ifdef DOXYGEN_SHOULD_SKIP_THIS

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/error-def_8h-source.htm (7 of 18) [10/29/2010 2:44:19 PM]

568

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 569: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: error-def.h Source File

00556 00560 #define EMBER_DELIVERY_FAILED(0x66)00561 #else00562 DEFINE_ERROR(DELIVERY_FAILED, 0x66)00563 #endif //DOXYGEN_SHOULD_SKIP_THIS00564 00565 00566 #ifdef DOXYGEN_SHOULD_SKIP_THIS00567 00570 #define EMBER_BINDING_INDEX_OUT_OF_RANGE(0x69)00571 #else00572 DEFINE_ERROR(BINDING_INDEX_OUT_OF_RANGE, 0x69)00573 #endif //DOXYGEN_SHOULD_SKIP_THIS00574 00575 00576 #ifdef DOXYGEN_SHOULD_SKIP_THIS00577 00581 #define EMBER_ADDRESS_TABLE_INDEX_OUT_OF_RANGE(0x6A)00582 #else00583 DEFINE_ERROR(ADDRESS_TABLE_INDEX_OUT_OF_RANGE, 0x6A)00584 #endif //DOXYGEN_SHOULD_SKIP_THIS00585 00586 00587 #ifdef DOXYGEN_SHOULD_SKIP_THIS00588 00591 #define EMBER_INVALID_BINDING_INDEX(0x6C)00592 #else00593 DEFINE_ERROR(INVALID_BINDING_INDEX, 0x6C)00594 #endif //DOXYGEN_SHOULD_SKIP_THIS00595 00596 00597 #ifdef DOXYGEN_SHOULD_SKIP_THIS00598 00602 #define EMBER_INVALID_CALL(0x70)00603 #else00604 DEFINE_ERROR(INVALID_CALL, 0x70)00605 #endif //DOXYGEN_SHOULD_SKIP_THIS00606 00607 00608 #ifdef DOXYGEN_SHOULD_SKIP_THIS00609 00612 #define EMBER_COST_NOT_KNOWN(0x71)00613 #else00614 DEFINE_ERROR(COST_NOT_KNOWN, 0x71)00615 #endif //DOXYGEN_SHOULD_SKIP_THIS00616 00617 00618 #ifdef DOXYGEN_SHOULD_SKIP_THIS00619 00623 #define EMBER_MAX_MESSAGE_LIMIT_REACHED(0x72)00624 #else

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/error-def_8h-source.htm (8 of 18) [10/29/2010 2:44:19 PM]

569

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 570: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: error-def.h Source File

00625 DEFINE_ERROR(MAX_MESSAGE_LIMIT_REACHED, 0x72)00626 #endif //DOXYGEN_SHOULD_SKIP_THIS00627 00628 #ifdef DOXYGEN_SHOULD_SKIP_THIS00629 00633 #define EMBER_MESSAGE_TOO_LONG(0x74)00634 #else00635 DEFINE_ERROR(MESSAGE_TOO_LONG, 0x74)00636 #endif //DOXYGEN_SHOULD_SKIP_THIS00637 00638 00639 #ifdef DOXYGEN_SHOULD_SKIP_THIS00640 00644 #define EMBER_BINDING_IS_ACTIVE(0x75)00645 #else00646 DEFINE_ERROR(BINDING_IS_ACTIVE, 0x75)00647 #endif //DOXYGEN_SHOULD_SKIP_THIS00648 00649 #ifdef DOXYGEN_SHOULD_SKIP_THIS00650 00654 #define EMBER_ADDRESS_TABLE_ENTRY_IS_ACTIVE(0x76)00655 #else00656 DEFINE_ERROR(ADDRESS_TABLE_ENTRY_IS_ACTIVE, 0x76)00657 #endif //DOXYGEN_SHOULD_SKIP_THIS00658 00660 00665 00666 00667 #ifdef DOXYGEN_SHOULD_SKIP_THIS00668 00671 #define EMBER_ADC_CONVERSION_DONE(0x80)00672 #else00673 DEFINE_ERROR(ADC_CONVERSION_DONE, 0x80)00674 #endif //DOXYGEN_SHOULD_SKIP_THIS00675 00676 00677 #ifdef DOXYGEN_SHOULD_SKIP_THIS00678 00682 #define EMBER_ADC_CONVERSION_BUSY(0x81)00683 #else00684 DEFINE_ERROR(ADC_CONVERSION_BUSY, 0x81)00685 #endif //DOXYGEN_SHOULD_SKIP_THIS00686 00687 00688 #ifdef DOXYGEN_SHOULD_SKIP_THIS00689 00693 #define EMBER_ADC_CONVERSION_DEFERRED(0x82)00694 #else00695 DEFINE_ERROR(ADC_CONVERSION_DEFERRED, 0x82)00696 #endif //DOXYGEN_SHOULD_SKIP_THIS00697

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/error-def_8h-source.htm (9 of 18) [10/29/2010 2:44:19 PM]

570

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 571: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: error-def.h Source File

00698 00699 #ifdef DOXYGEN_SHOULD_SKIP_THIS00700 00703 #define EMBER_ADC_NO_CONVERSION_PENDING(0x84)00704 #else00705 DEFINE_ERROR(ADC_NO_CONVERSION_PENDING, 0x84)00706 #endif //DOXYGEN_SHOULD_SKIP_THIS00707 00708 00709 #ifdef DOXYGEN_SHOULD_SKIP_THIS00710 00714 #define EMBER_SLEEP_INTERRUPTED(0x85)00715 #else00716 DEFINE_ERROR(SLEEP_INTERRUPTED, 0x85)00717 #endif //DOXYGEN_SHOULD_SKIP_THIS00718 00720 00725 00726 00727 #ifdef DOXYGEN_SHOULD_SKIP_THIS00728 00731 #define EMBER_PHY_TX_UNDERFLOW(0x88)00732 #else00733 DEFINE_ERROR(PHY_TX_UNDERFLOW, 0x88)00734 #endif //DOXYGEN_SHOULD_SKIP_THIS00735 00736 00737 #ifdef DOXYGEN_SHOULD_SKIP_THIS00738 00741 #define EMBER_PHY_TX_INCOMPLETE(0x89)00742 #else00743 DEFINE_ERROR(PHY_TX_INCOMPLETE, 0x89)00744 #endif //DOXYGEN_SHOULD_SKIP_THIS00745 00746 00747 #ifdef DOXYGEN_SHOULD_SKIP_THIS00748 00751 #define EMBER_PHY_INVALID_CHANNEL(0x8A)00752 #else00753 DEFINE_ERROR(PHY_INVALID_CHANNEL, 0x8A)00754 #endif //DOXYGEN_SHOULD_SKIP_THIS00755 00756 00757 #ifdef DOXYGEN_SHOULD_SKIP_THIS00758 00761 #define EMBER_PHY_INVALID_POWER(0x8B)00762 #else00763 DEFINE_ERROR(PHY_INVALID_POWER, 0x8B)00764 #endif //DOXYGEN_SHOULD_SKIP_THIS00765 00766

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/error-def_8h-source.htm (10 of 18) [10/29/2010 2:44:19 PM]

571

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 572: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: error-def.h Source File

00767 #ifdef DOXYGEN_SHOULD_SKIP_THIS00768 00772 #define EMBER_PHY_TX_BUSY(0x8C)00773 #else00774 DEFINE_ERROR(PHY_TX_BUSY, 0x8C)00775 #endif //DOXYGEN_SHOULD_SKIP_THIS00776 00777 00778 #ifdef DOXYGEN_SHOULD_SKIP_THIS00779 00783 #define EMBER_PHY_TX_CCA_FAIL(0x8D)00784 #else00785 DEFINE_ERROR(PHY_TX_CCA_FAIL, 0x8D)00786 #endif //DOXYGEN_SHOULD_SKIP_THIS00787 00788 00789 #ifdef DOXYGEN_SHOULD_SKIP_THIS00790 00794 #define EMBER_PHY_OSCILLATOR_CHECK_FAILED(0x8E)00795 #else00796 DEFINE_ERROR(PHY_OSCILLATOR_CHECK_FAILED, 0x8E)00797 #endif //DOXYGEN_SHOULD_SKIP_THIS00798 00799 00800 #ifdef DOXYGEN_SHOULD_SKIP_THIS00801 00804 #define EMBER_PHY_ACK_RECEIVED(0x8F)00805 #else00806 DEFINE_ERROR(PHY_ACK_RECEIVED, 0x8F)00807 #endif //DOXYGEN_SHOULD_SKIP_THIS00808 00810 00816 00817 00818 #ifdef DOXYGEN_SHOULD_SKIP_THIS00819 00823 #define EMBER_NETWORK_UP(0x90)00824 #else00825 DEFINE_ERROR(NETWORK_UP, 0x90)00826 #endif //DOXYGEN_SHOULD_SKIP_THIS00827 00828 00829 #ifdef DOXYGEN_SHOULD_SKIP_THIS00830 00833 #define EMBER_NETWORK_DOWN(0x91)00834 #else00835 DEFINE_ERROR(NETWORK_DOWN, 0x91)00836 #endif //DOXYGEN_SHOULD_SKIP_THIS00837 00838 00839 #ifdef DOXYGEN_SHOULD_SKIP_THIS

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/error-def_8h-source.htm (11 of 18) [10/29/2010 2:44:19 PM]

572

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 573: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: error-def.h Source File

00840 00843 #define EMBER_JOIN_FAILED(0x94)00844 #else00845 DEFINE_ERROR(JOIN_FAILED, 0x94)00846 #endif //DOXYGEN_SHOULD_SKIP_THIS00847 00848 00849 #ifdef DOXYGEN_SHOULD_SKIP_THIS00850 00854 #define EMBER_MOVE_FAILED(0x96)00855 #else00856 DEFINE_ERROR(MOVE_FAILED, 0x96)00857 #endif //DOXYGEN_SHOULD_SKIP_THIS00858 00859 00860 #ifdef DOXYGEN_SHOULD_SKIP_THIS00861 00866 #define EMBER_CANNOT_JOIN_AS_ROUTER(0x98)00867 #else00868 DEFINE_ERROR(CANNOT_JOIN_AS_ROUTER, 0x98)00869 #endif //DOXYGEN_SHOULD_SKIP_THIS00870 00871 00872 #ifdef DOXYGEN_SHOULD_SKIP_THIS00873 00876 #define EMBER_NODE_ID_CHANGED(0x99)00877 #else00878 DEFINE_ERROR(NODE_ID_CHANGED, 0x99)00879 #endif00880 00881 00882 #ifdef DOXYGEN_SHOULD_SKIP_THIS00883 00886 #define EMBER_PAN_ID_CHANGED(0x9A)00887 #else00888 DEFINE_ERROR(PAN_ID_CHANGED, 0x9A)00889 #endif00890 00891 #ifdef DOXYGEN_SHOULD_SKIP_THIS00892 00894 #define EMBER_CHANNEL_CHANGED(0x9B)00895 #else00896 DEFINE_ERROR(CHANNEL_CHANGED, 0x9B)00897 #endif00898 00899 #ifdef DOXYGEN_SHOULD_SKIP_THIS00900 00903 #define EMBER_NO_BEACONS(0xAB)00904 #else 00905 DEFINE_ERROR(NO_BEACONS, 0xAB)00906 #endif

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/error-def_8h-source.htm (12 of 18) [10/29/2010 2:44:19 PM]

573

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 574: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: error-def.h Source File

00907 00908 00909 #ifdef DOXYGEN_SHOULD_SKIP_THIS00910 00914 #define EMBER_RECEIVED_KEY_IN_THE_CLEAR(0xAC)00915 #else00916 DEFINE_ERROR(RECEIVED_KEY_IN_THE_CLEAR, 0xAC)00917 #endif00918 00919 00920 #ifdef DOXYGEN_SHOULD_SKIP_THIS00921 00924 #define EMBER_NO_NETWORK_KEY_RECEIVED(0xAD)00925 #else00926 DEFINE_ERROR(NO_NETWORK_KEY_RECEIVED, 0xAD)00927 #endif00928 00929 00930 #ifdef DOXYGEN_SHOULD_SKIP_THIS00931 00934 #define EMBER_NO_LINK_KEY_RECEIVED(0xAE)00935 #else00936 DEFINE_ERROR(NO_LINK_KEY_RECEIVED, 0xAE)00937 #endif00938 00939 00940 #ifdef DOXYGEN_SHOULD_SKIP_THIS00941 00945 #define EMBER_PRECONFIGURED_KEY_REQUIRED(0xAF)00946 #else00947 DEFINE_ERROR(PRECONFIGURED_KEY_REQUIRED, 0xAF)00948 #endif00949 00950 00952 00956 #ifdef DOXYGEN_SHOULD_SKIP_THIS00957 00961 #define EMBER_KEY_INVALID(0xB2)00962 #else00963 DEFINE_ERROR(KEY_INVALID, 0xB2)00964 #endif // DOXYGEN_SHOULD_SKIP_THIS00965 00966 #ifdef DOXYGEN_SHOULD_SKIP_THIS00967 00971 #define EMBER_INVALID_SECURITY_LEVEL(0x95)00972 #else00973 DEFINE_ERROR(INVALID_SECURITY_LEVEL, 0x95)00974 #endif //DOXYGEN_SHOULD_SKIP_THIS00975 00976 #ifdef DOXYGEN_SHOULD_SKIP_THIS00977

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/error-def_8h-source.htm (13 of 18) [10/29/2010 2:44:19 PM]

574

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 575: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: error-def.h Source File

00985 #define EMBER_APS_ENCRYPTION_ERROR(0xA6)00986 #else00987 DEFINE_ERROR(APS_ENCRYPTION_ERROR, 0xA6)00988 #endif //DOXYGEN_SHOULD_SKIP_THIS00989 00990 #ifdef DOXYGEN_SHOULD_SKIP_THIS00991 00994 #define EMBER_TRUST_CENTER_MASTER_KEY_NOT_SET(0xA7)00995 #else00996 DEFINE_ERROR(TRUST_CENTER_MASTER_KEY_NOT_SET, 0xA7)00997 #endif //DOXYGEN_SHOULD_SKIP_THIS00998 00999 #ifdef DOXYGEN_SHOULD_SKIP_THIS01000 01003 #define EMBER_SECURITY_STATE_NOT_SET(0xA8)01004 #else01005 DEFINE_ERROR(SECURITY_STATE_NOT_SET, 0xA8)01006 #endif //DOXYGEN_SHOULD_SKIP_THIS01007 01008 #ifdef DOXYGEN_SHOULD_SKIP_THIS01009 01016 #define EMBER_KEY_TABLE_INVALID_ADDRESS(0xB3)01017 #else01018 DEFINE_ERROR(KEY_TABLE_INVALID_ADDRESS, 0xB3)01019 #endif //DOYXGEN_SHOULD_SKIP_THIS01020 01021 #ifdef DOXYGEN_SHOULD_SKIP_THIS01022 01025 #define EMBER_SECURITY_CONFIGURATION_INVALID(0xB7)01026 #else01027 DEFINE_ERROR(SECURITY_CONFIGURATION_INVALID, 0xB7)01028 #endif //DOXYGEN_SHOULD_SKIP_THIS01029 01030 #ifdef DOXYGEN_SHOULD_SKIP_THIS01031 01036 #define EMBER_TOO_SOON_FOR_SWITCH_KEY(0xB8)01037 #else01038 DEFINE_ERROR(TOO_SOON_FOR_SWITCH_KEY, 0xB8)01039 #endif01040 01041 #ifdef DOXYGEN_SHOULD_SKIP_THIS01042 01045 #define EMBER_SIGNATURE_VERIFY_FAILURE(0xB9)01046 #else01047 DEFINE_ERROR(SIGNATURE_VERIFY_FAILURE, 0xB9)01048 #endif01049 01050 #ifdef DOXYGEN_SHOULD_SKIP_THIS01051 01057 #define EMBER_KEY_NOT_AUTHORIZED(0xBB)01058 #else

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/error-def_8h-source.htm (14 of 18) [10/29/2010 2:44:19 PM]

575

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 576: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: error-def.h Source File

01059 DEFINE_ERROR(KEY_NOT_AUTHORIZED, 0xBB)01060 #endif01061 01062 01064 01065 01070 01071 01072 #ifdef DOXYGEN_SHOULD_SKIP_THIS01073 01076 #define EMBER_NOT_JOINED(0x93)01077 #else01078 DEFINE_ERROR(NOT_JOINED, 0x93)01079 #endif //DOXYGEN_SHOULD_SKIP_THIS01080 01081 #ifdef DOXYGEN_SHOULD_SKIP_THIS01082 01086 #define EMBER_NETWORK_BUSY(0xA1)01087 #else01088 DEFINE_ERROR(NETWORK_BUSY, 0xA1)01089 #endif //DOXYGEN_SHOULD_SKIP_THIS01090 01091 01092 #ifdef DOXYGEN_SHOULD_SKIP_THIS01093 01097 #define EMBER_INVALID_ENDPOINT(0xA3)01098 #else01099 DEFINE_ERROR(INVALID_ENDPOINT, 0xA3)01100 #endif //DOXYGEN_SHOULD_SKIP_THIS01101 01102 01103 #ifdef DOXYGEN_SHOULD_SKIP_THIS01104 01108 #define EMBER_BINDING_HAS_CHANGED(0xA4)01109 #else01110 DEFINE_ERROR(BINDING_HAS_CHANGED, 0xA4)01111 #endif //DOXYGEN_SHOULD_SKIP_THIS01112 01113 #ifdef DOXYGEN_SHOULD_SKIP_THIS01114 01118 #define EMBER_INSUFFICIENT_RANDOM_DATA(0xA5)01119 #else01120 DEFINE_ERROR(INSUFFICIENT_RANDOM_DATA, 0xA5)01121 #endif //DOXYGEN_SHOULD_SKIP_THIS01122 01123 01124 #ifdef DOXYGEN_SHOULD_SKIP_THIS01125 01128 #define EMBER_SOURCE_ROUTE_FAILURE(0xA9)01129 #else01130 DEFINE_ERROR(SOURCE_ROUTE_FAILURE, 0xA9)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/error-def_8h-source.htm (15 of 18) [10/29/2010 2:44:19 PM]

576

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 577: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: error-def.h Source File

01131 #endif01132 01133 #ifdef DOXYGEN_SHOULD_SKIP_THIS01134 01139 #define EMBER_MANY_TO_ONE_ROUTE_FAILURE(0xAA)01140 #else01141 DEFINE_ERROR(MANY_TO_ONE_ROUTE_FAILURE, 0xAA)01142 #endif01143 01144 01146 01151 01152 01153 #ifdef DOXYGEN_SHOULD_SKIP_THIS01154 01160 #define EMBER_STACK_AND_HARDWARE_MISMATCH(0xB0)01161 #else01162 DEFINE_ERROR(STACK_AND_HARDWARE_MISMATCH, 0xB0)01163 #endif //DOXYGEN_SHOULD_SKIP_THIS01164 01165 01166 #ifdef DOXYGEN_SHOULD_SKIP_THIS01167 01171 #define EMBER_INDEX_OUT_OF_RANGE(0xB1)01172 #else01173 DEFINE_ERROR(INDEX_OUT_OF_RANGE, 0xB1)01174 #endif01175 01176 #ifdef DOXYGEN_SHOULD_SKIP_THIS01177 01180 #define EMBER_TABLE_FULL(0xB4)01181 #else01182 DEFINE_ERROR(TABLE_FULL, 0xB4)01183 #endif //DOXYGEN_SHOULD_SKIP_THIS01184 01185 #ifdef DOXYGEN_SHOULD_SKIP_THIS01186 01190 #define EMBER_TABLE_ENTRY_ERASED(0xB6)01191 #else01192 DEFINE_ERROR(TABLE_ENTRY_ERASED, 0xB6)01193 #endif01194 01195 #ifdef DOXYGEN_SHOULD_SKIP_THIS01196 01200 #define EMBER_LIBRARY_NOT_PRESENT(0xB5)01201 #else01202 DEFINE_ERROR(LIBRARY_NOT_PRESENT, 0xB5)01203 #endif01204 01205 #ifdef DOXYGEN_SHOULD_SKIP_THIS01206

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/error-def_8h-source.htm (16 of 18) [10/29/2010 2:44:20 PM]

577

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 578: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: error-def.h Source File

01210 #define EMBER_OPERATION_IN_PROGRESS(0xBA)01211 #else01212 DEFINE_ERROR(OPERATION_IN_PROGRESS, 0xBA)01213 #endif01214 01215 #ifdef DOXYGEN_SHOULD_SKIP_THIS01216 01221 #define EMBER_TRUST_CENTER_EUI_HAS_CHANGED(0xBC)01222 #else01223 DEFINE_ERROR(TRUST_CENTER_EUI_HAS_CHANGED, 0xBC)01224 #endif01225 01227 01233 01234 #ifdef DOXYGEN_SHOULD_SKIP_THIS01235 01239 #define EMBER_APPLICATION_ERROR_0(0xF0)01240 #define EMBER_APPLICATION_ERROR_1(0xF1)01241 #define EMBER_APPLICATION_ERROR_2(0xF2)01242 #define EMBER_APPLICATION_ERROR_3(0xF3)01243 #define EMBER_APPLICATION_ERROR_4(0xF4)01244 #define EMBER_APPLICATION_ERROR_5(0xF5)01245 #define EMBER_APPLICATION_ERROR_6(0xF6)01246 #define EMBER_APPLICATION_ERROR_7(0xF7)01247 #define EMBER_APPLICATION_ERROR_8(0xF8)01248 #define EMBER_APPLICATION_ERROR_9(0xF9)01249 #define EMBER_APPLICATION_ERROR_10(0xFA)01250 #define EMBER_APPLICATION_ERROR_11(0xFB)01251 #define EMBER_APPLICATION_ERROR_12(0xFC)01252 #define EMBER_APPLICATION_ERROR_13(0xFD)01253 #define EMBER_APPLICATION_ERROR_14(0xFE)01254 #define EMBER_APPLICATION_ERROR_15(0xFF)01255 #else01256 DEFINE_ERROR( APPLICATION_ERROR_0, 0xF0)01257 DEFINE_ERROR( APPLICATION_ERROR_1, 0xF1)01258 DEFINE_ERROR( APPLICATION_ERROR_2, 0xF2)01259 DEFINE_ERROR( APPLICATION_ERROR_3, 0xF3)01260 DEFINE_ERROR( APPLICATION_ERROR_4, 0xF4)01261 DEFINE_ERROR( APPLICATION_ERROR_5, 0xF5)01262 DEFINE_ERROR( APPLICATION_ERROR_6, 0xF6)01263 DEFINE_ERROR( APPLICATION_ERROR_7, 0xF7)01264 DEFINE_ERROR( APPLICATION_ERROR_8, 0xF8)01265 DEFINE_ERROR( APPLICATION_ERROR_9, 0xF9)01266 DEFINE_ERROR( APPLICATION_ERROR_10, 0xFA)01267 DEFINE_ERROR( APPLICATION_ERROR_11, 0xFB)01268 DEFINE_ERROR( APPLICATION_ERROR_12, 0xFC)01269 DEFINE_ERROR( APPLICATION_ERROR_13, 0xFD)01270 DEFINE_ERROR( APPLICATION_ERROR_14, 0xFE)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/error-def_8h-source.htm (17 of 18) [10/29/2010 2:44:20 PM]

578

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 579: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: error-def.h Source File

01271 DEFINE_ERROR( APPLICATION_ERROR_15, 0xFF)01272 #endif //DOXYGEN_SHOULD_SKIP_THIS01273 01275

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/error-def_8h-source.htm (18 of 18) [10/29/2010 2:44:20 PM]

579

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 580: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-configuration-defaults.h Source File

stack » config

ember-configuration-defaults.h

Go to the documentation of this file.

00001 00014 // Todo: 00015 // - explain how to use a configuration header00016 // - the documentation of the custom handlers should00017 // go in hal/ember-configuration.c, not here00018 // - the stack profile documentation is out of date00019 00047 #ifndef __EMBER_CONFIGURATION_DEFAULTS_H__00048 #define __EMBER_CONFIGURATION_DEFAULTS_H__00049 00050 #ifdef CONFIGURATION_HEADER00051 #include CONFIGURATION_HEADER00052 #endif00053 00054 #ifndef EMBER_API_MAJOR_VERSION00055 00058 #define EMBER_API_MAJOR_VERSION 200059 #endif00060 00061 #ifndef EMBER_API_MINOR_VERSION00062 00065 #define EMBER_API_MINOR_VERSION 000066 #endif00067 00080 #ifndef EMBER_STACK_PROFILE00081 #define EMBER_STACK_PROFILE 000082 #endif00083 00084 #if (EMBER_STACK_PROFILE == 2)00085 #define EMBER_MAX_DEPTH 1500086 #define EMBER_SECURITY_LEVEL 500087 #define EMBER_MIN_ROUTE_TABLE_SIZE 1000088 #define EMBER_MIN_DISCOVERY_TABLE_SIZE 400089 #define EMBER_INDIRECT_TRANSMISSION_TIMEOUT 768000090 #define EMBER_BROADCAST_TABLE_SIZE 1500091 #endif00092 00093 #ifndef EMBER_MAX_END_DEVICE_CHILDREN00094 00098 #define EMBER_MAX_END_DEVICE_CHILDREN 600099 #endif00100 00101 #ifndef DOXYGEN_SHOULD_SKIP_THIS00102 /* Need to put in a compile time check to make sure that we aren't specifying

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/..._EM260_forPDF/ember-configuration-defaults_8h-source.htm (1 of 5) [10/29/2010 2:44:21 PM]

580

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 581: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-configuration-defaults.h Source File

00103 * too many child devices. The current scheme is limited to 32 children00104 */00105 #if EMBER_MAX_END_DEVICE_CHILDREN > 3200106 #error "EMBER_MAX_END_DEVICE_CHILDREN can not exceed 32."00107 #endif00108 00109 #endif // DOXYGEN_SHOULD_SKIP_THIS00110 00111 #ifndef EMBER_SECURITY_LEVEL00112 00116 #define EMBER_SECURITY_LEVEL 500117 #endif00118 00119 #if ! (EMBER_SECURITY_LEVEL == 0 \00120 || EMBER_SECURITY_LEVEL == 5)00121 #error "Unsupported security level"00122 #endif00123 00124 #ifdef EMBER_CHILD_TABLE_SIZE 00125 #if (EMBER_MAX_END_DEVICE_CHILDREN < EMBER_CHILD_TABLE_SIZE)00126 #undef EMBER_CHILD_TABLE_SIZE00127 #endif00128 #endif00129 00130 #ifndef EMBER_CHILD_TABLE_SIZE00131 00145 #define EMBER_CHILD_TABLE_SIZE EMBER_MAX_END_DEVICE_CHILDREN00146 #endif00147 00161 #ifndef EMBER_KEY_TABLE_SIZE00162 #define EMBER_KEY_TABLE_SIZE 000163 #endif00164 00174 #ifndef EMBER_CERTIFICATE_TABLE_SIZE00175 #define EMBER_CERTIFICATE_TABLE_SIZE 000176 #else00177 #if EMBER_CERTIFICATE_TABLE_SIZE > 100178 #error "EMBER_CERTIFICATE_TABLE_SIZE > 1 is not supported!"00179 #endif00180 #endif00181 00187 #ifndef EMBER_MAX_DEPTH00188 #define EMBER_MAX_DEPTH 1500189 #elif (EMBER_MAX_DEPTH > 15)00190 // Depth is a 4-bit field00191 #error "EMBER_MAX_DEPTH cannot be greater than 15"00192 #endif00193 00200 #ifndef EMBER_MAX_HOPS00201 #define EMBER_MAX_HOPS (2 * EMBER_MAX_DEPTH)00202 #endif00203 00210 #ifndef EMBER_PACKET_BUFFER_COUNT

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/..._EM260_forPDF/ember-configuration-defaults_8h-source.htm (2 of 5) [10/29/2010 2:44:21 PM]

581

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 582: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-configuration-defaults.h Source File

00211 #define EMBER_PACKET_BUFFER_COUNT 2400212 #endif00213 00225 #define EMBER_MAX_NEIGHBOR_TABLE_SIZE 1600226 #ifndef EMBER_NEIGHBOR_TABLE_SIZE00227 #define EMBER_NEIGHBOR_TABLE_SIZE 1600228 #endif00229 00236 #ifndef EMBER_INDIRECT_TRANSMISSION_TIMEOUT00237 #define EMBER_INDIRECT_TRANSMISSION_TIMEOUT 300000238 #endif00239 #define EMBER_MAX_INDIRECT_TRANSMISSION_TIMEOUT 3000000240 #if (EMBER_INDIRECT_TRANSMISSION_TIMEOUT \00241 > EMBER_MAX_INDIRECT_TRANSMISSION_TIMEOUT)00242 #error "Indirect transmission timeout too large."00243 #endif00244 00258 #ifndef EMBER_END_DEVICE_POLL_TIMEOUT00259 #define EMBER_END_DEVICE_POLL_TIMEOUT 500260 #endif00261 00269 #ifndef EMBER_END_DEVICE_POLL_TIMEOUT_SHIFT00270 #define EMBER_END_DEVICE_POLL_TIMEOUT_SHIFT 600271 #endif00272 00279 #ifndef EMBER_MOBILE_NODE_POLL_TIMEOUT00280 #define EMBER_MOBILE_NODE_POLL_TIMEOUT 2000281 #endif00282 00295 #ifndef EMBER_APS_UNICAST_MESSAGE_COUNT00296 #define EMBER_APS_UNICAST_MESSAGE_COUNT 1000297 #endif00298 00301 #ifndef EMBER_BINDING_TABLE_SIZE00302 #define EMBER_BINDING_TABLE_SIZE 000303 #endif00304 00309 #ifndef EMBER_ADDRESS_TABLE_SIZE00310 #define EMBER_ADDRESS_TABLE_SIZE 800311 #endif00312 00319 #ifndef EMBER_RESERVED_MOBILE_CHILD_ENTRIES00320 #define EMBER_RESERVED_MOBILE_CHILD_ENTRIES 000321 #endif00322 00329 #ifndef EMBER_ROUTE_TABLE_SIZE00330 #ifdef EMBER_MIN_ROUTE_TABLE_SIZE00331 #define EMBER_ROUTE_TABLE_SIZE EMBER_MIN_ROUTE_TABLE_SIZE00332 #else00333 #define EMBER_ROUTE_TABLE_SIZE 1600334 #endif00335 #elif defined(EMBER_MIN_ROUTE_TABLE_SIZE) \

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/..._EM260_forPDF/ember-configuration-defaults_8h-source.htm (3 of 5) [10/29/2010 2:44:21 PM]

582

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 583: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-configuration-defaults.h Source File

00336 && EMBER_ROUTE_TABLE_SIZE < EMBER_MIN_ROUTE_TABLE_SIZE00337 #error "EMBER_ROUTE_TABLE_SIZE is less than required by stack profile."00338 #endif00339 00345 #ifndef EMBER_DISCOVERY_TABLE_SIZE00346 #ifdef EMBER_MIN_DISCOVERY_TABLE_SIZE00347 #define EMBER_DISCOVERY_TABLE_SIZE EMBER_MIN_DISCOVERY_TABLE_SIZE00348 #else00349 #define EMBER_DISCOVERY_TABLE_SIZE 800350 #endif00351 #elif defined(EMBER_MIN_DISCOVERY_TABLE_SIZE) \00352 && EMBER_DISCOVERY_TABLE_SIZE < EMBER_MIN_DISCOVERY_TABLE_SIZE00353 #error "EMBER_DISCOVERY_TABLE_SIZE is less than required by stack profile."00354 #endif00355 00361 #ifndef EMBER_MULTICAST_TABLE_SIZE00362 #define EMBER_MULTICAST_TABLE_SIZE 800363 #endif00364 00371 #ifndef EMBER_SOURCE_ROUTE_TABLE_SIZE00372 #define EMBER_SOURCE_ROUTE_TABLE_SIZE 3200373 #endif00374 00380 #ifndef EMBER_BROADCAST_TABLE_SIZE00381 #define EMBER_BROADCAST_TABLE_SIZE 1500382 #elif EMBER_BROADCAST_TABLE_SIZE < 1500383 #error "EMBER_BROADCAST__TABLE_SIZE is less than the minimum value of 15."00384 #elif 254 < EMBER_BROADCAST_TABLE_SIZE00385 #error "EMBER_BROADCAST__TABLE_SIZE is larger than the maximum value of 254."00386 #endif00387 00397 #if !defined(EMBER_ASSERT_OUTPUT_DISABLED) \00398 && !defined(EMBER_ASSERT_SERIAL_PORT)00399 #define EMBER_ASSERT_SERIAL_PORT 100400 #endif00401 00415 #define EMBER_MAXIMUM_ALARM_DATA_SIZE 1600416 00434 #ifndef EMBER_BROADCAST_ALARM_DATA_SIZE00435 #define EMBER_BROADCAST_ALARM_DATA_SIZE 000436 #elif EMBER_MAXIMUM_ALARM_DATA_SIZE < EMBER_BROADCAST_ALARM_DATA_SIZE00437 #error "EMBER_BROADCAST_ALARM_DATA_SIZE is too large."00438 #endif00439 00448 #ifndef EMBER_UNICAST_ALARM_DATA_SIZE00449 #define EMBER_UNICAST_ALARM_DATA_SIZE 000450 #elif EMBER_MAXIMUM_ALARM_DATA_SIZE < EMBER_UNICAST_ALARM_DATA_SIZE00451 #error "EMBER_UNICAST_ALARM_DATA_SIZE is too large."00452 #endif00453 00457 #ifndef EMBER_FRAGMENT_DELAY_MS00458 #define EMBER_FRAGMENT_DELAY_MS 0

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/..._EM260_forPDF/ember-configuration-defaults_8h-source.htm (4 of 5) [10/29/2010 2:44:21 PM]

583

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 584: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-configuration-defaults.h Source File

00459 #endif00460 00464 #define EMBER_FRAGMENT_MAX_WINDOW_SIZE 800465 00470 #ifndef EMBER_FRAGMENT_WINDOW_SIZE00471 #define EMBER_FRAGMENT_WINDOW_SIZE 100472 #elif EMBER_FRAGMENT_MAX_WINDOW_SIZE < EMBER_FRAGMENT_WINDOW_SIZE00473 #error "EMBER_FRAGMENT_WINDOW_SIZE is too large."00474 #endif00475 00476 #ifndef EMBER_BINDING_TABLE_TOKEN_SIZE00477 #define EMBER_BINDING_TABLE_TOKEN_SIZE EMBER_BINDING_TABLE_SIZE00478 #endif00479 #ifndef EMBER_CHILD_TABLE_TOKEN_SIZE00480 #define EMBER_CHILD_TABLE_TOKEN_SIZE EMBER_CHILD_TABLE_SIZE00481 #endif00482 #ifndef EMBER_KEY_TABLE_TOKEN_SIZE00483 #define EMBER_KEY_TABLE_TOKEN_SIZE EMBER_KEY_TABLE_SIZE00484 #endif00485 00498 #ifndef EMBER_REQUEST_KEY_TIMEOUT00499 #define EMBER_REQUEST_KEY_TIMEOUT 000500 #elif EMBER_REQUEST_KEY_TIMEOUT > 1000501 #error "EMBER_REQUEST_KEY_TIMEOUT is too large."00502 #endif00503 00507 #ifndef EMBER_END_DEVICE_BIND_TIMEOUT00508 #define EMBER_END_DEVICE_BIND_TIMEOUT 6000509 #endif00510 00519 #ifndef EMBER_PAN_ID_CONFLICT_REPORT_THRESHOLD00520 #define EMBER_PAN_ID_CONFLICT_REPORT_THRESHOLD 100521 #endif00522 00528 #ifndef EMBER_TASK_COUNT00529 #define EMBER_TASK_COUNT (3)00530 #endif00531 00532 00536 #endif //__EMBER_CONFIGURATION_DEFAULTS_H__

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/..._EM260_forPDF/ember-configuration-defaults_8h-source.htm (5 of 5) [10/29/2010 2:44:21 PM]

584

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 585: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ezsp-host-configuration-defaults.h Source File

app » util » ezsp

ezsp-host-configuration-defaults.h

Go to the documentation of this file.

00001 00019 #ifdef CONFIGURATION_HEADER00020 #include CONFIGURATION_HEADER00021 #endif00022 00023 #ifndef EZSP_HOST_SOURCE_ROUTE_TABLE_SIZE00024 00032 #define EZSP_HOST_SOURCE_ROUTE_TABLE_SIZE 3200033 #endif00034 00035 #ifndef EZSP_HOST_ASH_RX_POOL_SIZE00036 00043 #define EZSP_HOST_ASH_RX_POOL_SIZE 2000044 #endif00045 00046 #ifndef EZSP_HOST_FORM_AND_JOIN_BUFFER_SIZE00047 00056 #define EZSP_HOST_FORM_AND_JOIN_BUFFER_SIZE 4000057 #endif00058

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Outp..._EM260_forPDF/ezsp-host-configuration-defaults_8h-source.htm [10/29/2010 2:44:21 PM]

585

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 586: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-debug.h Source File

stack » include

ember-debug.h

Go to the documentation of this file.

00001 00008 #ifndef __EMBER_DEBUG_H__00009 #define __EMBER_DEBUG_H__00010 00019 // Define the values for DEBUG_LEVEL00020 #define NO_DEBUG 000021 #define BASIC_DEBUG 100022 #define FULL_DEBUG 200023 00030 #define emberDebugInit(port) do {} while(FALSE)00031 00032 #if (DEBUG_LEVEL >= BASIC_DEBUG) || defined(DOXYGEN_SHOULD_SKIP_THIS)00033 00039 void emberDebugAssert(PGM_P filename, int linenumber);00040 00041 00049 void emberDebugMemoryDump(int8u *start, int8u *end);00050 00077 void emberDebugBinaryPrintf(PGM_P formatString, ...);00078 00086 void emDebugSendVuartMessage(int8u *buff, int8u len);00087 00088 #else // (DEBUG_LEVEL >= BASIC_DEBUG) || defined(DOXYGEN_SHOULD_SKIP_THIS)00089 #define emberDebugAssert(filename, linenumber) do {} while(FALSE)00090 #define emberDebugMemoryDump(start, end) do {} while(FALSE)00091 #define emberDebugBinaryPrintf(formatstring, ...) do {} while(FALSE)00092 #define emDebugSendVuartMessage(buff, len) do {} while(FALSE)00093 #endif // (DEBUG_LEVEL >= BASIC_DEBUG) || defined(DOXYGEN_SHOULD_SKIP_THIS)00094 00095 #if (DEBUG_LEVEL == FULL_DEBUG) || defined(DOXYGEN_SHOULD_SKIP_THIS)00096 00100 void emberDebugError(EmberStatus code);00101 00106 boolean emberDebugReportOff(void);00107 00113 void emberDebugReportRestore(boolean state);00114 00115 // Format: Same as emberSerialPrintf00116 // emberDebugPrintf("format string"[, parameters ...])00132 void emberDebugPrintf(PGM_P formatString, ...);00133 00134 #else // (DEBUG_LEVEL == FULL_DEBUG) || defined(DOXYGEN_SHOULD_SKIP_THIS)00135 #define emberDebugError(code) do {} while(FALSE)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ember-debug_8h-source.htm (1 of 2) [10/29/2010 2:44:22 PM]

586

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 587: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ember-debug.h Source File

00136 // Note the following doesn't have a do{}while(FALSE) 00137 // because it has a return value00138 #define emberDebugReportOff() (FALSE)00139 #define emberDebugReportRestore(state) do {} while(FALSE)00140 #define emberDebugPrintf(...) do {} while(FALSE)00141 #endif // (DEBUG_LEVEL == FULL_DEBUG) || defined(DOXYGEN_SHOULD_SKIP_THIS)00142 00146 #endif // __EMBER_DEBUG_H__00147

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ember-debug_8h-source.htm (2 of 2) [10/29/2010 2:44:22 PM]

587

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 588: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: micro.h Source File

hal » micro

micro.h

Go to the documentation of this file.

00001 00020 #ifndef __MICRO_H__00021 #define __MICRO_H__00022 00023 #include "hal/micro/generic/em2xx-reset-defs.h"00024 00025 #ifndef DOXYGEN_SHOULD_SKIP_THIS00026 00027 #ifndef EZSP_HOST00028 // If we are not a Host processor, Define distinct literal values for00029 // each platform and micro. The Host processor is not tied to a00030 // specific platform or micro since it uses EZSP. These values are00031 // used in ebl headers and the bootloader query response message.00032 // Some values may reserved for future use.00033 00034 // PLAT 1 was the AVR ATMega, no longer supported00035 // for PLAT 1, MICRO 1 is the AVR ATMega 6400036 // for PLAT 1, MICRO 2 is the AVR ATMega 12800037 // for PLAT 1, MICRO 3 is the AVR ATMega 3200038 00039 // PLAT 2 is the XAP2b00040 // for PLAT 2, MICRO 1 is the em25000041 // for PLAT 2, MICRO 2 is the em26000042 00043 // PLAT 4 is the Cortex-M300044 // for PLAT 4, MICRO 1 is the em35000045 // for PLAT 4, MICRO 2 is the em36000046 // for PLAT 4, MICRO 3 is the em35700047 // for PLAT 4, MICRO 4 is the em36700048 // for PLAT 4, MICRO 5 is the em35100049 // for PLAT 4, MICRO 6 is the em35x00050 // for PLAT 4, MICRO 7 is the stm32w10800051 00052 #if defined( EMBER_TEST )00053 #define PLAT 100054 #define MICRO 200055 #elif defined (AVR_ATMEGA)00056 #define PLAT 100057 #if defined (AVR_ATMEGA_64)00058 #define MICRO 100059 #elif defined (AVR_ATMEGA_128)00060 #define MICRO 200061 #elif defined (AVR_ATMEGA_32)00062 #define MICRO 300063 #endif

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/micro_8h-source.htm (1 of 4) [10/29/2010 2:44:23 PM]

588

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 589: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: micro.h Source File

00064 #elif defined (XAP2B)00065 #define PLAT 200066 #if defined (XAP2B_EM250)00067 #define MICRO 100068 #elif defined (XAP2B_EM260)00069 #define MICRO 200070 #endif00071 #elif defined (MSP430)00072 #define PLAT 300073 #if defined (MSP430_1612)00074 #define MICRO 100075 #elif defined (MSP430_1471)00076 #define MICRO 200077 #endif00078 #elif defined (CORTEXM3)00079 #define PLAT 400080 #if defined (CORTEXM3_EM350)00081 #define MICRO 100082 #elif defined (CORTEXM3_EM360)00083 #define MICRO 200084 #elif defined (CORTEXM3_EM357)00085 #define MICRO 300086 #elif defined (CORTEXM3_EM367)00087 #define MICRO 400088 #elif defined (CORTEXM3_EM351)00089 #define MICRO 500090 #elif defined (CORTEXM3_EM35X)00091 #define MICRO 600092 #elif defined (CORTEXM3_STM32W108)00093 #define MICRO 700094 #endif00095 #else00096 #error no platform defined, or unsupported00097 #endif00098 00099 #ifndef MICRO00100 #error no micro defined, or unsupported00101 #endif00102 00103 #endif //EZSP_HOST00104 00105 // Define distinct literal values for each phy.00106 // These values are used in the bootloader query response message.00107 // PHY 0 is a null phy00108 // PHY 1 is the em2420 (no longer supported)00109 // PHY 2 is the em25000110 // PHY 3 is the em3xx00111 00112 #if defined (PHY_EM2420) || defined (PHY_EM2420B)00113 #error EM2420 is no longer supported.00114 #elif defined (PHY_EM250) || defined (PHY_EM250B)00115 #define PHY 200116 #elif defined (PHY_EM3XX)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/micro_8h-source.htm (2 of 4) [10/29/2010 2:44:23 PM]

589

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 590: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: micro.h Source File

00117 #define PHY 300118 #elif defined (PHY_NULL)00119 #define PHY 000120 #else00121 #error no phy defined, or unsupported00122 #endif00123 00124 #endif // DOXYGEN_SHOULD_SKIP_THIS00125 00139 void halStackProcessBootCount(void);00140 00145 int8u halGetResetInfo(void);00146 00154 PGM_P halGetResetString(void);00155 00164 #ifdef CORTEXM300165 int8u halGetEm2xxResetInfo(void);00166 #else00167 #define halGetEm2xxResetInfo() halGetResetInfo()00168 #endif00169 00170 00180 void halInternalAssertFailed(PGM_P filename, int linenumber);00181 00182 00183 #ifndef DOXYGEN_SHOULD_SKIP_THIS00184 00185 #include "micro-common.h"00186 00187 #if defined( EMBER_TEST )00188 #include "hal/micro/unix/simulation/micro.h"00189 #include "hal/micro/unix/simulation/bootloader.h"00190 #elif defined(AVR_ATMEGA)00191 #if defined(AVR_ATMEGA_64) || defined(AVR_ATMEGA_128)00192 #include "avr-atmega/128/micro.h"00193 #include "avr-atmega/128/bootloader.h"00194 #elif defined(AVR_ATMEGA_32)00195 #include "avr-atmega/32/micro.h"00196 #else00197 // default, assume 12800198 #include "avr-atmega/128/micro.h"00199 #include "avr-atmega/128/bootloader.h"00200 #endif00201 #elif defined(MSP430_1612)00202 #include "msp430/1612/micro.h"00203 #include "msp430/1612/bootloader.h"00204 #elif defined(MSP430_1471)00205 #include "msp430/1471/micro.h"00206 #include "msp430/1471/bootloader.h"00207 #elif defined(XAP2B)00208 #include "xap2b/em250/micro.h"00209 #elif defined(CORTEXM3)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/micro_8h-source.htm (3 of 4) [10/29/2010 2:44:23 PM]

590

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 591: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: micro.h Source File

00210 #include "cortexm3/micro.h"00211 #elif defined(EZSP_HOST)00212 #include "hal/micro/unix/host/micro.h"00213 #else00214 #error no platform or micro defined00215 #endif00216 00217 // the number of ticks (as returned from halCommonGetInt32uMillisecondTick)00218 // that represent an actual second. This can vary on different platforms.00219 // It must be defined by the host system.00220 #ifndef MILLISECOND_TICKS_PER_SECOND00221 #define MILLISECOND_TICKS_PER_SECOND 102400222 // See bug 1023200223 // #error "MILLISECOND_TICKS_PER_SECOND is not defined in micro.h!"00224 #endif00225 00226 #endif // DOXYGEN_SHOULD_SKIP_THIS00227 00228 #endif //__MICRO_H__00229

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/micro_8h-source.htm (4 of 4) [10/29/2010 2:44:23 PM]

591

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 592: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: micro.h Source File

hal » micro » avr-atmega » 32

avr-atmega/32/micro.h

Go to the documentation of this file.

00001 00014 #ifndef __32_MICRO_H__00015 #define __32_MICRO_H__00016 00017 #ifndef DOXYGEN_SHOULD_SKIP_THIS00018 00019 #ifndef __MICRO_H__00020 #error do not include this file directly - include micro/micro.h00021 #endif00022 00023 #include "micro/avr-atmega/32/reserved-ram.h"00024 00026 // Serial definitions00027 #define EM_NUM_SERIAL_PORTS 100028 00029 #endif // DOXYGEN_SHOULD_SKIP_THIS00030 00031 00036 void halStackTriggerDebugTimeSyncCapture(void);00037 00038 00039 #ifndef DOXYGEN_SHOULD_SKIP_THIS00040 #define ADCSR ADCSRA00041 #define EICRA MCUCR00042 #define EICRB MCUCSR00043 #define EIMSK GICR00044 #define EIFR GIFR00045 #define WDCE WDTOE00046 #endif // DOXYGEN_SHOULD_SKIP_THIS00047 00048 // the number of ticks (as returned from halCommonGetInt32uMillisecondTick)00049 // that represent an actual second. This can vary on different platforms.00050 #define MILLISECOND_TICKS_PER_SECOND 90000051 00056 #define RESET_UNKNOWN 0 // cause not known00057 #define RESET_EXTERNAL 1 // reset pin was asserted00058 #define RESET_POWERON 2 // supply voltage was < power-on threshold00059 #define RESET_WATCHDOG 3 // watchdog low water mark caused NMI00060 #define RESET_BROWNOUT 4 // n/a (no hardware support)00061 #define RESET_JTAG 5 // reset by debugger00062 #define RESET_ASSERT 6 // a self-check within the code failed00063 #define RESET_RSTACK 7 // n/a (memory fault instead)00064 #define RESET_CSTACK 8 // n/a (memory fault instead)

file:///C|/dev/perforce/software/v2/tephra-park/doxyge...t/API_EM260_forPDF/avr-atmega_232_2micro_8h-source.htm (1 of 2) [10/29/2010 2:44:23 PM]

592

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 593: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: micro.h Source File

00065 #define RESET_BOOTLOADER 9 // requested by bootloader00066 #define RESET_PC_ROLLOVER 10 // n/a (memor fault instead)00067 #define RESET_SOFTWARE 11 // reset requested by software00068 #define RESET_PROTFAULT 12 // n/a (memoru fault instead)00069 #define RESET_FLASH_VERIFY_FAIL 13 // flash write verify failure00070 #define RESET_FLASH_WRITE_INHIBIT 14 // flash write inhibited: already written00071 #define RESET_BOOTLOADER_IMG_BAD 15 // app BTL: bad EEPROM upgrade image 00072 00073 #endif //__32_MICRO_H__00074

file:///C|/dev/perforce/software/v2/tephra-park/doxyge...t/API_EM260_forPDF/avr-atmega_232_2micro_8h-source.htm (2 of 2) [10/29/2010 2:44:23 PM]

593

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 594: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: serial.h Source File

hal » micro

hal/micro/serial.h

Go to the documentation of this file.

00001 00023 #ifndef __HAL_SERIAL_H__00024 #define __HAL_SERIAL_H__00025 00026 // EM_NUM_SERIAL_PORTS is inherited from the micro specifc micro.h00027 #if (EM_NUM_SERIAL_PORTS == 1)00028 #define FOR_EACH_PORT(cast,prefix,suffix) \00029 cast(prefix##0##suffix)00030 #elif (EM_NUM_SERIAL_PORTS == 2)00031 #define FOR_EACH_PORT(cast,prefix,suffix) \00032 cast(prefix##0##suffix), \00033 cast(prefix##1##suffix)00034 #elif (EM_NUM_SERIAL_PORTS == 3)00035 #define FOR_EACH_PORT(cast,prefix,suffix) \00036 cast(prefix##0##suffix), \00037 cast(prefix##1##suffix), \00038 cast(prefix##2##suffix)00039 #else00040 #error unsupported number of serial ports00041 #endif00042 00055 #define EMBER_SERIAL_UNUSED 000056 #define EMBER_SERIAL_FIFO 100057 #define EMBER_SERIAL_BUFFER 200058 #define EMBER_SERIAL_LOWLEVEL 300059 00061 #ifndef DOXYGEN_SHOULD_SKIP_THIS00062 00063 // The following tests for setting of an invalid mode00064 #ifdef EMBER_SERIAL0_MODE00065 #if (EMBER_SERIAL0_MODE != EMBER_SERIAL_FIFO) && \00066 (EMBER_SERIAL0_MODE != EMBER_SERIAL_BUFFER) && \00067 (EMBER_SERIAL0_MODE != EMBER_SERIAL_LOWLEVEL) && \00068 (EMBER_SERIAL0_MODE != EMBER_SERIAL_UNUSED)00069 #error Invalid Serial 0 Mode00070 #endif00071 #else00072 #define EMBER_SERIAL0_MODE EMBER_SERIAL_UNUSED00073 #endif00074 #ifdef EMBER_SERIAL1_MODE00075 #if (EMBER_SERIAL1_MODE != EMBER_SERIAL_FIFO) && \00076 (EMBER_SERIAL1_MODE != EMBER_SERIAL_BUFFER) && \00077 (EMBER_SERIAL1_MODE != EMBER_SERIAL_LOWLEVEL) && \00078 (EMBER_SERIAL1_MODE != EMBER_SERIAL_UNUSED)00079 #error Invalid Serial 1 Mode00080 #endif00081 #else00082 #define EMBER_SERIAL1_MODE EMBER_SERIAL_UNUSED

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/hal_2micro_2serial_8h-source.htm (1 of 5) [10/29/2010 2:44:24 PM]

594

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 595: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: serial.h Source File

00083 #endif00084 #ifdef EMBER_SERIAL2_MODE00085 #if (EMBER_SERIAL2_MODE != EMBER_SERIAL_FIFO) && \00086 (EMBER_SERIAL2_MODE != EMBER_SERIAL_BUFFER) && \00087 (EMBER_SERIAL2_MODE != EMBER_SERIAL_LOWLEVEL) && \00088 (EMBER_SERIAL2_MODE != EMBER_SERIAL_UNUSED)00089 #error Invalid Serial 2 Mode00090 #endif00091 #else00092 #define EMBER_SERIAL2_MODE EMBER_SERIAL_UNUSED00093 #endif00094 00095 // Determine if FIFO and/or Buffer modes are being used, so those sections of00096 // code may be disabled if not00097 #if (EMBER_SERIAL0_MODE == EMBER_SERIAL_FIFO) || \00098 (EMBER_SERIAL1_MODE == EMBER_SERIAL_FIFO) || \00099 (EMBER_SERIAL2_MODE == EMBER_SERIAL_FIFO)00100 #define EM_ENABLE_SERIAL_FIFO00101 #endif00102 #if (EMBER_SERIAL0_MODE == EMBER_SERIAL_BUFFER) || \00103 (EMBER_SERIAL1_MODE == EMBER_SERIAL_BUFFER) || \00104 (EMBER_SERIAL2_MODE == EMBER_SERIAL_BUFFER)00105 #define EM_ENABLE_SERIAL_BUFFER00106 #endif00107 00108 00116 typedef struct {00118 int16u head;00120 int16u tail;00122 volatile int16u used;00124 int8u fifo[];00125 } EmSerialFifoQueue;00126 00127 00131 typedef struct {00133 int8u length;00135 EmberMessageBuffer buffer;00137 int8u startIndex;00138 } EmSerialBufferQueueEntry;00139 00143 typedef struct {00145 int8u head; 00147 int8u tail; 00149 volatile int8u used; 00151 volatile int8u dead; 00154 EmberMessageBuffer currentBuffer;00156 int8u *nextByte;00158 int8u *lastByte;00160 EmSerialBufferQueueEntry fifo[];00161 } EmSerialBufferQueue;00162 00172 extern void *emSerialTxQueues[EM_NUM_SERIAL_PORTS];00174 extern EmSerialFifoQueue *emSerialRxQueues[EM_NUM_SERIAL_PORTS];00176 extern int16u PGM emSerialTxQueueMasks[EM_NUM_SERIAL_PORTS];00178 extern int16u PGM emSerialTxQueueSizes[EM_NUM_SERIAL_PORTS];

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/hal_2micro_2serial_8h-source.htm (2 of 5) [10/29/2010 2:44:24 PM]

595

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 596: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: serial.h Source File

00180 extern int16u PGM emSerialRxQueueSizes[EM_NUM_SERIAL_PORTS];00182 extern int8u emSerialRxError[EM_NUM_SERIAL_PORTS];00184 extern int16u emSerialRxErrorIndex[EM_NUM_SERIAL_PORTS];00186 extern int8u PGM emSerialPortModes[EM_NUM_SERIAL_PORTS];00187 00188 //Compatibility code for the AVR Atmega00189 #ifdef AVR_ATMEGA00190 extern int8u PGM emSerialTxQueueWraps[EM_NUM_SERIAL_PORTS];00191 extern int8u PGM emSerialRxQueueWraps[EM_NUM_SERIAL_PORTS];00192 #else00193 extern int16u PGM emSerialTxQueueWraps[EM_NUM_SERIAL_PORTS];00194 extern int16u PGM emSerialRxQueueWraps[EM_NUM_SERIAL_PORTS];00195 #endif00196 00199 #ifdef EZSP_UART00200 #define HANDLE_ASH_ERROR(type) emberCounterHandler(type, 0)00201 #else00202 #define HANDLE_ASH_ERROR(type)00203 #endif00204 00205 #endif //DOXYGEN_SHOULD_SKIP_THIS00206 00207 00224 //Compatibility code for the AVR Atmega00225 #ifdef AVR_ATMEGA00226 #define FIFO_ENQUEUE(queue,data,size) \00227 do { \00228 queue->fifo[queue->head] = data; \00229 queue->head = ((queue->head + 1) & size); \00230 queue->used++; \00231 } while(0)00232 #else00233 #define FIFO_ENQUEUE(queue,data,size) \00234 do { \00235 queue->fifo[queue->head] = data; \00236 queue->head = ((queue->head + 1) % size); \00237 queue->used++; \00238 } while(0)00239 #endif00240 00248 //Compatibility code for the AVR Atmega00249 #ifdef AVR_ATMEGA00250 #define FIFO_DEQUEUE(queue,size) \00251 queue->fifo[queue->tail]; \00252 queue->tail = ((queue->tail + 1) & size); \00253 queue->used--00254 #else00255 #define FIFO_DEQUEUE(queue,size) \00256 queue->fifo[queue->tail]; \00257 queue->tail = ((queue->tail + 1) % size); \00258 queue->used--00259 #endif00260 00264 #ifdef DOXYGEN_SHOULD_SKIP_THIS00265 00269 enum SerialBaudRate

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/hal_2micro_2serial_8h-source.htm (3 of 5) [10/29/2010 2:44:24 PM]

596

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 597: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: serial.h Source File

00270 #else00271 #ifndef DEFINE_BAUD00272 #define DEFINE_BAUD(num) BAUD_##num00273 #endif00274 typedef int8u SerialBaudRate;00275 enum00276 #endif //DOXYGEN_SHOULD_SKIP_THIS00277 { 00278 DEFINE_BAUD(300) = 0, // BAUD_30000279 DEFINE_BAUD(600) = 1, // BAUD_60000280 DEFINE_BAUD(900) = 2, // etc...00281 DEFINE_BAUD(1200) = 3,00282 DEFINE_BAUD(2400) = 4,00283 DEFINE_BAUD(4800) = 5,00284 DEFINE_BAUD(9600) = 6,00285 DEFINE_BAUD(14400) = 7,00286 DEFINE_BAUD(19200) = 8,00287 DEFINE_BAUD(28800) = 9,00288 DEFINE_BAUD(38400) = 10,00289 DEFINE_BAUD(50000) = 11,00290 DEFINE_BAUD(57600) = 12,00291 DEFINE_BAUD(76800) = 13,00292 DEFINE_BAUD(100000) = 14,00293 DEFINE_BAUD(115200) = 15,00294 #ifdef AVR_ATMEGA00295 DEFINE_BAUD(CUSTOM) = 1600296 #else00297 DEFINE_BAUD(230400) = 16, /*<! define higher baud rates for the EM2XX and EM3XX */00298 DEFINE_BAUD(460800) = 17, /*<! Note: receiving data at baud rates > 115200 */00299 DEFINE_BAUD(CUSTOM) = 18 /*<! may not be reliable due to interrupt latency */00300 #endif00301 };00302 00303 00304 #ifdef DOXYGEN_SHOULD_SKIP_THIS00305 00309 enum NameOfType00310 #else00311 #ifndef DEFINE_PARITY00312 #define DEFINE_PARITY(val) PARITY_##val00313 #endif00314 typedef int8u SerialParity;00315 enum00316 #endif //DOXYGEN_SHOULD_SKIP_THIS00317 {00318 DEFINE_PARITY(NONE) = 0, // PARITY_NONE00319 DEFINE_PARITY(ODD) = 1, // PARITY_ODD00320 DEFINE_PARITY(EVEN) = 2 // PARITY_EVEN00321 };00322 00348 EmberStatus halInternalUartInit(int8u port, 00349 SerialBaudRate rate,00350 SerialParity parity,

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/hal_2micro_2serial_8h-source.htm (4 of 5) [10/29/2010 2:44:24 PM]

597

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 598: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: serial.h Source File

00351 int8u stopBits);00352 00357 void halInternalPowerDownUart(void);00358 00363 void halInternalPowerUpUart(void);00364 00371 void halInternalStartUartTx(int8u port);00372 00373 00379 void halInternalStopUartTx(int8u port);00380 00381 00393 EmberStatus halInternalForceWriteUartData(int8u port, int8u *data, int8u length);00394 00403 EmberStatus halInternalForceReadUartByte(int8u port, int8u *dataByte);00404 00410 void halInternalWaitUartTxComplete(int8u port);00411 00419 #if (EMBER_SERIAL1_MODE == EMBER_SERIAL_FIFO) && \00420 ( defined(EMBER_SERIAL1_XONXOFF) || \00421 (defined(XAP2B) && defined(EMBER_SERIAL1_RTSCTS) ) ) 00422 void halInternalUartFlowControl(int8u port);00423 #else00424 #define halInternalUartFlowControl(port) do {} while(FALSE)00425 #endif00426 00434 #if (defined(XAP2B)&&(EMBER_SERIAL1_MODE == EMBER_SERIAL_BUFFER)) || defined(CORTEXM3)00435 void halInternalUartRxPump(int8u port);00436 #else00437 #define halInternalUartRxPump(port) do {} while(FALSE)00438 #endif00439 00445 void halInternalRestartUart(void);00446 00452 boolean halInternalUart1FlowControlRxIsEnabled(void);00453 00458 boolean halInternalUart1XonRefreshDone(void);00459 00464 boolean halInternalUart1TxIsIdle(void);00465 00481 void emSerialBufferNextMessageIsr(EmSerialBufferQueue *q);00482 00483 00493 void emSerialBufferNextBlockIsr(EmSerialBufferQueue *q, int8u port);00494 00511 void halStackReceiveVuartMessage(int8u* buff, int8u len);00512 00515 #endif //__HAL_SERIAL_H__00516

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/hal_2micro_2serial_8h-source.htm (5 of 5) [10/29/2010 2:44:24 PM]

598

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 599: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: uart.h Source File

hal » micro » avr-atmega

uart.h

Go to the documentation of this file.

00001 00024 #ifndef __UART_H__00025 #define __UART_H__00026 00027 #ifndef DOXYGEN_SHOULD_SKIP_THIS00028 00029 #define ENABLE_BIT_DEFINITIONS00030 00031 #include <ioavr.h>00032 00033 #if defined(AVR_ATMEGA_8) || defined(AVR_ATMEGA_32)00034 #define UCSR0C UCSRC00035 #define UPM00 UPM000036 #define UPM01 UPM100037 #define USBS0 USBS00038 #define UBRR0L UBRRL00039 #define UBRR0H UBRRH00040 #define UCSR0B UCSRB00041 #define TXCIE0 TXCIE00042 #define RXCIE0 RXCIE00043 #define TXEN0 TXEN00044 #define RXEN0 RXEN00045 #define UCSR0A UCSRA00046 #define TXC0 TXC00047 #define UDRIE0 UDRIE00048 #define USART0_RXC_vect USART_RXC_vect00049 #define FE0 FE00050 #define DOR0 DOR00051 #define UPE0 PE00052 #define UDR0 UDR00053 #define USART0_UDRE_vect USART_UDRE_vect00054 #define UDRE0 UDRE00055 #define RXC0 RXC00056 00057 #else00058 00059 #define TXCIE TXCIE000060 #define URSEL 700061 #define UBRRH UBRR0H00062 #define GIFR EIFR00063 #define GICR EIMSK00064 #ifndef AVR_ATMEGA_16900065 #define AS2 AS000066 #define TCN2UB TCN0UB00067 #endif

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/uart_8h-source.htm (1 of 2) [10/29/2010 2:44:25 PM]

599

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 600: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: uart.h Source File

00068 00069 #endif00070 00071 #endif //DOXYGEN_SHOULD_SKIP_THIS00072 00074 00078 00079 00080 00081 #ifndef AVR_ATMEGA_800082 00089 #define halUart0InitTiny() \00090 UBRR0L = UDR0; \00091 UBRR0L = UBRRH; \00092 UCSR0C = BIT(URSEL) | BIT(UCSZ01) | BIT(UCSZ00) | BIT(USBS0); \00093 UBRR0L = 25; \00094 UCSR0B = BIT(TXEN0) | BIT(RXEN0); \00095 UCSR0A = BIT(TXC0);00096 #else //MEGA800097 00105 #define halUart0InitTiny() \00106 UBRR0L = UDR0; \00107 UBRR0L = UBRRH; \00108 UCSR0C = BIT(URSEL) | BIT(UCSZ1) | BIT(UCSZ0) | BIT(USBS0); \00109 UBRR0L = 51; \00110 UCSR0B = BIT(TXEN0) | BIT(RXEN0); \00111 UCSR0A = BIT(TXC0);00112 #endif00113 00119 #define halUart0WriteByteTiny(x) \00120 while ( !( UCSR0A & BIT(UDRE0)) ) {} \00121 UDR0 = x;00122 00135 EmberStatus halUart0ReadByteTimeoutTiny(int8u *dataByte);00136 00138 00139 00140 00141 00142 #endif //__HAL_SERIAL_H__00143

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/uart_8h-source.htm (2 of 2) [10/29/2010 2:44:25 PM]

600

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 601: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: adc.h Source File

hal » micro

adc.h

Go to the documentation of this file.

00001 00039 #ifndef __ADC_H__00040 #define __ADC_H__00041 00042 #ifdef DOXYGEN_SHOULD_SKIP_THIS00043 00051 enum ADCUser00052 #else00053 // A type for the ADC User enumeration.00054 typedef int8u ADCUser;00055 enum00056 #endif //DOXYGEN_SHOULD_SKIP_THIS00057 {00059 ADC_USER_LQI = 0,00061 ADC_USER_APP = 1,00063 ADC_USER_APP2 = 200064 };00065 00069 #define NUM_ADC_USERS 3 // make sure to update if the above is adjusted00070 00071 00072 #ifdef DOXYGEN_SHOULD_SKIP_THIS00073 00075 enum ADCReferenceType00076 #else00077 // A type for the AVR Atmega reference enumeration.00078 typedef int8u ADCReferenceType;00079 enum00080 #endif //DOXYGEN_SHOULD_SKIP_THIS00081 {00083 ADC_REF_AREF = 0x00,00085 ADC_REF_AVCC = 0x40,00087 ADC_REF_INT = 0xC000088 };00089 00090 00091 #ifdef DOXYGEN_SHOULD_SKIP_THIS00092 00094 enum ADCRateType00095 #else00096 // A type for the EM250 rate enumeration.00097 typedef int8u ADCRateType;00098 enum00099 #endif //DOXYGEN_SHOULD_SKIP_THIS00100 {00102 ADC_CONVERSION_TIME_US_32 = 0x0,

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/adc_8h-source.htm (1 of 4) [10/29/2010 2:44:26 PM]

601

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 602: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: adc.h Source File

00104 ADC_CONVERSION_TIME_US_64 = 0x1,00106 ADC_CONVERSION_TIME_US_128 = 0x2,00108 ADC_CONVERSION_TIME_US_256 = 0x3,00110 ADC_CONVERSION_TIME_US_512 = 0x4,00112 ADC_CONVERSION_TIME_US_1024 = 0x5,00114 ADC_CONVERSION_TIME_US_2048 = 0x6,00116 ADC_CONVERSION_TIME_US_4096 = 0x7,00117 };00118 00119 00120 #ifdef XAP2B00121 00123 enum00124 {00126 ADC_SOURCE_ADC0_GND = 0x0,00128 ADC_SOURCE_ADC1_GND = 0x1,00130 ADC_SOURCE_ADC2_GND = 0x2,00132 ADC_SOURCE_ADC3_GND = 0x3,00134 ADC_SOURCE_VDD_PADS_GND = 0x4,00136 ADC_SOURCE_VDD_GND = 0x5,00138 ADC_SOURCE_VGND = 0x7,00140 ADC_SOURCE_VREF = 0x8,00142 ADC_SOURCE_ADC0_ADC1 = 0x9,00144 ADC_SOURCE_ADC2_ADC3 = 0xA00145 };00146 #endif // XAP2B00147 00148 #if defined (CORTEXM3)00149 00150 #define ADC_MUX_ADC0 0x000151 00152 #define ADC_MUX_ADC1 0x100153 00154 #define ADC_MUX_ADC2 0x200155 00156 #define ADC_MUX_ADC3 0x300157 00158 #define ADC_MUX_ADC4 0x400159 00160 #define ADC_MUX_ADC5 0x500161 00162 #define ADC_MUX_GND 0x800163 00164 #define ADC_MUX_VREF2 0x900165 00166 #define ADC_MUX_VREF 0xA00167 00168 #define ADC_MUX_VREG2 0xB00169 00170 // ADC_SOURCE_<pos>_<neg> selects <pos> as the positive input and <neg> as 00171 // the negative input.00172 enum00173 {00174 ADC_SOURCE_ADC0_VREF2 = ((ADC_MUX_ADC0 <<ADC_MUXN_BITS) + ADC_MUX_VREF2),00175 ADC_SOURCE_ADC0_GND = ((ADC_MUX_ADC0 <<ADC_MUXN_BITS) + ADC_MUX_GND),

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/adc_8h-source.htm (2 of 4) [10/29/2010 2:44:26 PM]

602

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 603: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: adc.h Source File

00176 00177 ADC_SOURCE_ADC1_VREF2 = ((ADC_MUX_ADC1 <<ADC_MUXN_BITS) + ADC_MUX_VREF2),00178 ADC_SOURCE_ADC1_GND = ((ADC_MUX_ADC1 <<ADC_MUXN_BITS) + ADC_MUX_GND),00179 00180 ADC_SOURCE_ADC2_VREF2 = ((ADC_MUX_ADC2 <<ADC_MUXN_BITS) + ADC_MUX_VREF2),00181 ADC_SOURCE_ADC2_GND = ((ADC_MUX_ADC2 <<ADC_MUXN_BITS) + ADC_MUX_GND),00182 00183 ADC_SOURCE_ADC3_VREF2 = ((ADC_MUX_ADC3 <<ADC_MUXN_BITS) + ADC_MUX_VREF2),00184 ADC_SOURCE_ADC3_GND = ((ADC_MUX_ADC3 <<ADC_MUXN_BITS) + ADC_MUX_GND),00185 00186 ADC_SOURCE_ADC4_VREF2 = ((ADC_MUX_ADC4 <<ADC_MUXN_BITS) + ADC_MUX_GND),00187 00188 ADC_SOURCE_ADC5_VREF2 = ((ADC_MUX_ADC5 <<ADC_MUXN_BITS) + ADC_MUX_GND),00189 00190 ADC_SOURCE_ADC1_ADC0 = ((ADC_MUX_ADC1 <<ADC_MUXN_BITS) + ADC_MUX_ADC0),00191 ADC_SOURCE_ADC0_ADC1 = ((ADC_MUX_ADC1 <<ADC_MUXN_BITS) + ADC_MUX_ADC0),00192 00193 ADC_SOURCE_ADC3_ADC2 = ((ADC_MUX_ADC3 <<ADC_MUXN_BITS) + ADC_MUX_ADC2),00194 ADC_SOURCE_ADC2_ADC3 = ((ADC_MUX_ADC3 <<ADC_MUXN_BITS) + ADC_MUX_ADC2),00195 00196 ADC_SOURCE_ADC5_ADC4 = ((ADC_MUX_ADC5 <<ADC_MUXN_BITS) + ADC_MUX_ADC4),00197 00198 ADC_SOURCE_GND_VREF2 = ((ADC_MUX_GND <<ADC_MUXN_BITS) + ADC_MUX_VREF2),00199 ADC_SOURCE_VGND = ((ADC_MUX_GND <<ADC_MUXN_BITS) + ADC_MUX_GND),00200 00201 ADC_SOURCE_VREF_VREF2 = ((ADC_MUX_VREF <<ADC_MUXN_BITS) + ADC_MUX_VREF2),00202 ADC_SOURCE_VREF = ((ADC_MUX_VREF <<ADC_MUXN_BITS) + ADC_MUX_GND),00203 00204 ADC_SOURCE_VREG2_VREF2 = ((ADC_MUX_VREG2 <<ADC_MUXN_BITS) + ADC_MUX_VREF2),00205 ADC_SOURCE_VDD_GND = ((ADC_MUX_VREG2 <<ADC_MUXN_BITS) + ADC_MUX_GND)00206 };00207 #endif // defined (CORTEXM3)00208 00211 enum00212 {00214 ADC_SOURCE_ADC0 = 0x0,00216 ADC_SOURCE_ADC1 = 0x1,00218 ADC_SOURCE_ADC2 = 0x2,00220 ADC_SOURCE_ADC3 = 0x3,00222 ADC_SOURCE_ADC4 = 0x4,00224 ADC_SOURCE_ADC5 = 0x5,00226 ADC_SOURCE_ADC6 = 0x6,00228 ADC_SOURCE_ADC7 = 0x7,00229 };00230 00235 typedef int8u ADCChannelType;00236 00237 00242 void halInternalInitAdc(void);00243 00244 00248 void halInternalSleepAdc(void);00249 00250

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/adc_8h-source.htm (3 of 4) [10/29/2010 2:44:26 PM]

603

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 604: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: adc.h Source File

00281 EmberStatus halStartAdcConversion(ADCUser id,00282 ADCReferenceType reference,00283 ADCChannelType channel,00284 ADCRateType rate);00285 00306 EmberStatus halRequestAdcData(ADCUser id, int16u *value);00307 00308 00326 EmberStatus halReadAdcBlocking(ADCUser id, int16u *value);00327 00328 00345 EmberStatus halAdcCalibrate(ADCUser id);00346 00347 00359 int16s halConvertValueToVolts(int16u value);00360 00361 00370 void emberCalibrateVref(void);00371 00372 #ifdef CORTEXM300373 void halAdcSetClock(boolean fast);00374 void halAdcSetRange(boolean high);00375 boolean halAdcGetClock(void);00376 boolean halAdcGetRange(void);00377 #endif00378 00379 #endif // __ADC_H__00380

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/adc_8h-source.htm (4 of 4) [10/29/2010 2:44:26 PM]

604

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 605: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: button.h Source File

hal » micro

button.h

Go to the documentation of this file.

00001 00024 #define BUTTON_PRESSED 100025 00028 #define BUTTON_RELEASED 000029 00036 void halInternalInitButton(void);00037 00049 int8u halButtonState(int8u button);00050 00063 int8u halButtonPinState(int8u button);00064 00079 void halButtonIsr(int8u button, int8u state);00080

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/button_8h-source.htm [10/29/2010 2:44:26 PM]

605

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 606: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: buzzer.h Source File

hal » micro

buzzer.h

Go to the documentation of this file.

00001 00023 #define NOTE_C3 11900024 #define NOTE_Db3 11200025 #define NOTE_D3 10600026 #define NOTE_Eb3 10000027 #define NOTE_E3 9400028 #define NOTE_F3 8900029 #define NOTE_Gb3 8400030 #define NOTE_G3 7900031 #define NOTE_Ab3 7400032 #define NOTE_A3 7000033 #define NOTE_Bb3 6600034 #define NOTE_B3 6300035 #define NOTE_C4 5900036 #define NOTE_Db4 5500037 #define NOTE_D4 5200038 #define NOTE_Eb4 4900039 #define NOTE_E4 4600040 #define NOTE_F4 4400041 #define NOTE_Gb4 4100042 #define NOTE_G4 3900043 #define NOTE_Ab4 3700044 #define NOTE_A4 3500045 #define NOTE_Bb4 3300046 #define NOTE_B4 3100047 #define NOTE_C5 2900048 #define NOTE_Db5 2700049 #define NOTE_D5 2600050 #define NOTE_Eb5 2400051 #define NOTE_E5 2300052 #define NOTE_F5 2100053 #define NOTE_Gb5 2000054 #define NOTE_G5 1900055 #define NOTE_Ab5 1800056 #define NOTE_A5 1700057 #define NOTE_Bb5 1600058 #define NOTE_B5 1500059 00082 void halPlayTune_P(int8u PGM *tune, boolean bkg);

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/buzzer_8h-source.htm (1 of 2) [10/29/2010 2:44:27 PM]

606

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 607: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: buzzer.h Source File

00083 00084 00089 void halStackIndicatePresence(void);00090

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/buzzer_8h-source.htm (2 of 2) [10/29/2010 2:44:27 PM]

607

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 608: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: led.h Source File

hal » micro

led.h

Go to the documentation of this file.

00001 00022 void halInternalInitLed(void);00023 00027 #if defined(STACK) || defined(MINIMAL_HAL)00028 typedef int8u HalBoardLed;00029 #else00030 typedef enum HalBoardLedPins HalBoardLed;00031 #endif00032 // Note: Even though many compilers will use 16 bits for an enum instead of 8, 00033 // we choose to use an enum here. The possible compiler inefficiency does not 00034 // affect stack-based parameters and local variables, which is the00035 // general case for led paramters.00036 00042 void halToggleLed(HalBoardLed led);00043 00049 void halSetLed(HalBoardLed led);00050 00056 void halClearLed(HalBoardLed led);00057 00067 void halStackIndicateActivity(boolean turnOn);00068

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/led_8h-source.htm [10/29/2010 2:44:27 PM]

608

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 609: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: host.h Source File

hal » micro » unix » host » board

host.h

Go to the documentation of this file.

00001 00016 #define halInternalInitBoard() \00017 do { \00018 /*halInternalInitLed(); not currently simulated */ \00019 } while(0)00020 00021 #define halInternalPowerDownBoard() \00022 do { \00023 /*halInternalInitLed(); not currently simulated */ \00024 } while(0) 00025 00026 #define halInternalPowerUpBoard() \00027 do { \00028 } while(0) 00029 00030 enum HalBoardLedPins {00031 BOARDLED0 = 0,00032 BOARDLED1 = 1,00033 BOARDLED2 = 2,00034 BOARDLED3 = 3,00035 BOARDLED4 = 4,00036 BOARDLED5 = 5,00037 BOARD_ACTIVITY_LED = BOARDLED0,00038 BOARD_HEARTBEAT_LED = BOARDLED100039 };00040 00041 #define BUTTON0 000042 #define BUTTON1 100043 #define TEMP_SENSOR_ADC_CHANNEL 000044 #define TEMP_SENSOR_SCALE_FACTOR 300045

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/host_8h-source.htm [10/29/2010 2:44:27 PM]

609

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 610: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: dev0470.h Source File

hal » micro » avr-atmega » 32 » board

dev0470.h

Go to the documentation of this file.

00001 00017 #ifndef __BOARD_H__00018 #define __BOARD_H__00019 00020 //This is the most convenient place to suck in the necessary header file00021 //operating the SPI Protocol.00022 #ifndef DOXYGEN_SHOULD_SKIP_THIS00023 #include "hal/micro/avr-atmega/spi-protocol.h"00024 #endif //DOXYGEN_SHOULD_SKIP_THIS00025 00026 //we operate at 3.6864MHz (17.361us tick) so we need to use the following:00038 #define TCCR1B_CONFIGURATION (BIT(CS11)|BIT(CS10))00039 #define WAIT_SECTION_TIMEOUT 11520 //200ms00040 #define INTER_COMMAND_SPACING 57 //1ms00041 #define WAKE_HANDSHAKE_TIMEOUT 576 //10ms00042 #define STARTUP_TIMEOUT_SINGLE 42750 //750ms00043 //[[ WBBFIXME-measure exactly how long we need during bootup; set to 10 for ]]00044 //[[ plenty of time until we figure out how long bootloader takes ]]00045 #define STARTUP_TIMEOUT_COUNT 10 // count*750 = 7500ms00046 //actual startup timeout time is (single*count) = 7500ms00048 00049 00059 #define SPIP_nSSEL_PORT PORTB00060 #define SPIP_nSSEL_DDR DDRB00061 #define SPIP_nSSEL 400062 #define SPIP_MOSI_PORT PORTB00063 #define SPIP_MOSI_DDR DDRB00064 #define SPIP_MOSI 500065 #define SPIP_MISO_PORT PORTB00066 #define SPIP_MISO_DDR DDRB00067 #define SPIP_MISO 600068 #define SPIP_SCLK_PORT PORTB00069 #define SPIP_SCLK_DDR DDRB00070 #define SPIP_SCLK 700071 #define SPIP_nHOST_INT_PORT PORTD00072 #define SPIP_nHOST_INT_DDR DDRD00073 #define SPIP_nHOST_INT_PIN PIND00074 #define SPIP_nHOST_INT 200075 #define SPIP_nWAKE_PORT PORTB00076 #define SPIP_nWAKE_DDR DDRB00077 #define SPIP_nWAKE 3

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/dev0470_8h-source.htm (1 of 4) [10/29/2010 2:44:28 PM]

610

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 611: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: dev0470.h Source File

00078 #define SPIP_nRESET_PORT PORTB00079 #define SPIP_nRESET_DDR DDRB00080 #define SPIP_nRESET 100081 00082 00083 00097 enum HalBoardLedPins {00098 BOARDLED0 = 2,00099 BOARDLED1 = 3,00100 BOARD_ACTIVITY_LED = BOARDLED0,00101 BOARD_HEARTBEAT_LED = BOARDLED100102 };00103 #define BOARDLED_MASK 0x0C00104 00105 #define LED_DDR DDRA00106 #define LED_PORT PORTA 00107 00108 00109 00120 00121 // Note that BUTTON0 cannot be used to wake the processor, as INT100122 // does not support wakeup on an edge.00123 #define BUTTON0 300124 #define BUTTON0_PORT PORTD00125 #define BUTTON0_DDR DDRD00126 #define BUTTON0_PIN PIND00127 #define BUTTON0_INT INT100128 #define BUTTON0_INT_VECT INT1_vect00129 #define BUTTON0_CONFIG_FALLING_EDGE() \00130 do { \00131 MCUCR |= BIT(ISC11); \00132 MCUCR &= ~BIT(ISC10); \00133 } while(0)00134 #define BUTTON0_CONFIG_RISING_EDGE() \00135 do { \00136 MCUCR |= BIT(ISC11); \00137 MCUCR |= BIT(ISC10); \00138 } while(0)00139 00140 #define BUTTON1 200141 #define BUTTON1_PORT PORTB00142 #define BUTTON1_DDR DDRB00143 #define BUTTON1_PIN PINB00144 #define BUTTON1_INT INT200145 #define BUTTON1_INT_VECT INT2_vect00146 #define BUTTON1_CONFIG_FALLING_EDGE() \00147 do { \00148 MCUCSR &= ~BIT(ISC2); \00149 } while(0)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/dev0470_8h-source.htm (2 of 4) [10/29/2010 2:44:28 PM]

611

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 612: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: dev0470.h Source File

00150 #define BUTTON1_CONFIG_RISING_EDGE() \00151 do { \00152 MCUCSR |= BIT(ISC2); \00153 } while(0)00154 00156 00166 #define TEMP_SENSOR_ADC_CHANNEL ADC_SOURCE_ADC000167 #define TEMP_SENSOR_SCALE_FACTOR 200168 00180 #define halInternalInitBoard() \00181 do { \00182 halInternalInitAdc(); \00183 halInternalInitButton(); \00184 halInternalInitLed(); \00185 /* temp sensor */ \00186 DDRA |= BIT(1); \00187 PORTA |= BIT(1); \00188 /* Buzzer */ \00189 DDRD |= 0x80; \00190 PORTD |= 0x80; \00191 /*** Configure SPI Protocol pins ***/ \00192 /*nRESET default input/pullup until used*/ \00193 SPIP_nRESET_DDR &= ~BIT(SPIP_nRESET); \00194 SPIP_nRESET_PORT |= BIT(SPIP_nRESET); \00195 /*Activate nHOST_INT internal pullup*/ \00196 SPIP_nHOST_INT_DDR &= ~BIT(SPIP_nHOST_INT); \00197 SPIP_nHOST_INT_PORT |= BIT(SPIP_nHOST_INT); \00198 /*Falling edge detection on nHOST_INT*/ \00199 EICRA |= BIT(ISC01);EICRA &= ~BIT(ISC00); \00200 SPIP_nWAKE_PORT |= BIT(SPIP_nWAKE); \00201 SPIP_nWAKE_DDR |= BIT(SPIP_nWAKE); \00202 SPIP_nSSEL_PORT |= BIT(SPIP_nSSEL); \00203 SPIP_nSSEL_DDR |= BIT(SPIP_nSSEL); \00204 SPIP_MOSI_PORT |= BIT(SPIP_MOSI); \00205 SPIP_MOSI_DDR |= BIT(SPIP_MOSI); \00206 SPIP_SCLK_PORT |= BIT(SPIP_SCLK); \00207 SPIP_SCLK_DDR |= BIT(SPIP_SCLK); \00208 /* SPI Master, Mode 0 */ \00209 SPCR = BIT(SPE) | BIT(MSTR); \00210 /* Fastest SPI speed = 3.6864Mhz/2 */ \00211 SPSR = BIT(SPI2X); \00212 /*initialize the SPI Protocol*/ \00213 halNcpSerialInit(); \00214 } while(0)00215 00216 #define halInternalPowerDownBoard() \00217 do { \00218 halInternalSleepAdc(); \00219 halInternalInitLed(); \00220 /* Disable Buzzer */ \00221 TCCR2 = BIT(WGM21); /* no clock, no timer override */ \00222 TIMSK &= ~(BIT(OCIE2)); /* disable interrupt */ \

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/dev0470_8h-source.htm (3 of 4) [10/29/2010 2:44:28 PM]

612

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 613: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: dev0470.h Source File

00223 /* Disable Temp sensor */ \00224 PORTA &= ~BIT(1); \00225 /* Wait for nHOST_INT to go high so that we don't */ \00226 /* immediately get interrupted and wake the host */ \00227 /* unnecessarily */ \00228 while (((SPIP_nHOST_INT_PIN&BIT(SPIP_nHOST_INT))== 0) \00229 && ((EIFR&BIT(INTF0)) != BIT(INTF0))) {}; \00230 /* Set nHOST_INT to trigger low */ \00231 /* - edge triggers will not wake the Atmega32 */ \00232 EICRA &= ~(BIT(ISC01) | BIT(ISC00)); \00233 EIFR = BIT(INTF0); /*clear interrupt flag */ \00234 EIMSK |= BIT(INT0);/*enable nHOST_INT interrupt for wake */ \00235 } while(0) 00236 00237 #define halInternalPowerUpBoard() \00238 do { \00239 halInternalInitAdc(); \00240 /* Enable Temp sensor */ \00241 DDRA |= BIT(1); \00242 PORTA |= BIT(1); \00243 EIMSK &= ~BIT(INT0);/* disable nHOST_INT interrupt */ \00244 EIFR = BIT(INTF0); /* clear interrupt flag */ \00245 /* Set nHOST_INT back to trigger on falling edge... */ \00246 EICRA |= BIT(ISC01);EICRA &= ~BIT(ISC00); \00247 halNcpSerialPowerup(); \00248 } while(0)00249 00250 00251 #endif //__BOARD_H__00252

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/dev0470_8h-source.htm (4 of 4) [10/29/2010 2:44:28 PM]

613

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 614: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: dev0473.h Source File

hal » micro » avr-atmega » 128 » board

dev0473.h

Go to the documentation of this file.

00001 00018 #ifndef __BOARD_H__00019 #define __BOARD_H__00020 00021 //This is the most convenient place to suck in the necessary header file00022 //operating the SPI Protocol.00023 #ifndef DOXYGEN_SHOULD_SKIP_THIS00024 #include "hal/micro/avr-atmega/spi-protocol.h"00025 #endif //DOXYGEN_SHOULD_SKIP_THIS00026 00027 //we operate at 8MHz (32us tick) so we need to use the following:00039 #define TCCR1B_CONFIGURATION (BIT(CS12))00040 #define WAIT_SECTION_TIMEOUT 6250 //200ms00041 #define INTER_COMMAND_SPACING 31 //1ms00042 #define WAKE_HANDSHAKE_TIMEOUT 313 //10ms00043 #define STARTUP_TIMEOUT_SINGLE 23438 //750ms00044 //[[ WBBFIXME-measure exactly how long we need during bootup; set to 10 for ]]00045 //[[ plenty of time until we figure out how long bootloader takes ]]00046 #define STARTUP_TIMEOUT_COUNT 10 // count*750 = 7500ms00047 //actual startup timeout time is (single*count) = 7500ms00049 00050 00060 #define SPIP_nSSEL_PORT PORTB00061 #define SPIP_nSSEL_DDR DDRB00062 #define SPIP_nSSEL 000063 #define SPIP_MOSI_PORT PORTB00064 #define SPIP_MOSI_DDR DDRB00065 #define SPIP_MOSI 200066 #define SPIP_MISO_PORT PORTB00067 #define SPIP_MISO_DDR DDRB00068 #define SPIP_MISO 300069 #define SPIP_SCLK_PORT PORTB00070 #define SPIP_SCLK_DDR DDRB00071 #define SPIP_SCLK 100072 #define SPIP_nHOST_INT_PORT PORTD00073 #define SPIP_nHOST_INT_DDR DDRD00074 #define SPIP_nHOST_INT_PIN PIND00075 #define SPIP_nHOST_INT 000076 #define SPIP_nWAKE_PORT PORTB00077 #define SPIP_nWAKE_DDR DDRB00078 #define SPIP_nWAKE 4

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/dev0473_8h-source.htm (1 of 4) [10/29/2010 2:44:30 PM]

614

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 615: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: dev0473.h Source File

00079 #define SPIP_nRESET_PORT PORTB00080 #define SPIP_nRESET_DDR DDRB00081 #define SPIP_nRESET 500082 00083 00084 00102 enum HalBoardLedPins {00103 BOARDLED0 = 0,00104 BOARDLED1 = 1,00105 BOARD_ACTIVITY_LED = BOARDLED0,00106 BOARD_HEARTBEAT_LED = BOARDLED100107 };00108 #define BOARDLED_MASK 0x0300109 00110 #define LED_DDR DDRC00111 #define LED_PORT PORTC 00112 00113 00114 00125 00126 // Note that BUTTON1 cannot be used to wake the processor, as INT400127 // does not support wakeup on an edge.00128 #define BUTTON0 100129 #define BUTTON0_PORT PORTD00130 #define BUTTON0_DDR DDRD00131 #define BUTTON0_PIN PIND00132 #define BUTTON0_INT INT100133 #define BUTTON0_INT_VECT INT1_vect00134 #define BUTTON0_CONFIG_FALLING_EDGE() \00135 do { \00136 EICRA |= BIT(ISC11); \00137 EICRA &= ~BIT(ISC10); \00138 } while(0)00139 #define BUTTON0_CONFIG_RISING_EDGE() \00140 do { \00141 EICRA |= BIT(ISC11); \00142 EICRA |= BIT(ISC10); \00143 } while(0)00144 00145 #define BUTTON1 400146 #define BUTTON1_PORT PORTE00147 #define BUTTON1_DDR DDRE00148 #define BUTTON1_PIN PINE00149 #define BUTTON1_INT INT400150 #define BUTTON1_INT_VECT INT4_vect00151 #define BUTTON1_CONFIG_FALLING_EDGE() \00152 do { \00153 EICRB |= BIT(ISC41); \00154 EICRB &= ~BIT(ISC40); \

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/dev0473_8h-source.htm (2 of 4) [10/29/2010 2:44:30 PM]

615

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 616: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: dev0473.h Source File

00155 } while(0)00156 #define BUTTON1_CONFIG_RISING_EDGE() \00157 do { \00158 EICRB |= BIT(ISC41); \00159 EICRB |= BIT(ISC40); \00160 } while(0)00161 00163 00173 #define TEMP_SENSOR_ADC_CHANNEL ADC_SOURCE_ADC100174 #define TEMP_SENSOR_SCALE_FACTOR 200175 00187 #define halInternalInitBoard() \00188 do { \00189 halInternalInitAdc(); \00190 halInternalInitButton(); \00191 halInternalInitLed(); \00192 /* temp sensor */ \00193 DDRC |= BIT(7); \00194 PORTC |= BIT(7); \00195 /* Buzzer */ \00196 DDRB |= 0x80; \00197 PORTB |= 0x80; \00198 /*** Configure SPI Protocol pins ***/ \00199 /*nRESET default input/pullup until used*/ \00200 SPIP_nRESET_DDR &= ~BIT(SPIP_nRESET); \00201 SPIP_nRESET_PORT |= BIT(SPIP_nRESET); \00202 /*Activate nHOST_INT internal pullup*/ \00203 SPIP_nHOST_INT_DDR &= ~BIT(SPIP_nHOST_INT); \00204 SPIP_nHOST_INT_PORT |= BIT(SPIP_nHOST_INT); \00205 /*Falling edge detection on nHOST_INT*/ \00206 EICRA |= BIT(ISC01);EICRA &= ~BIT(ISC00); \00207 SPIP_nWAKE_PORT |= BIT(SPIP_nWAKE); \00208 SPIP_nWAKE_DDR |= BIT(SPIP_nWAKE); \00209 SPIP_nSSEL_PORT |= BIT(SPIP_nSSEL); \00210 SPIP_nSSEL_DDR |= BIT(SPIP_nSSEL); \00211 SPIP_MOSI_PORT |= BIT(SPIP_MOSI); \00212 SPIP_MOSI_DDR |= BIT(SPIP_MOSI); \00213 SPIP_SCLK_PORT |= BIT(SPIP_SCLK); \00214 SPIP_SCLK_DDR |= BIT(SPIP_SCLK); \00215 /* SPI Master, Mode 0 */ \00216 SPCR = BIT(SPE) | BIT(MSTR); \00217 /* Fastest SPI speed = 3.6864Mhz/2 */ \00218 SPSR = BIT(SPI2X); \00219 /*initialize the SPI Protocol*/ \00220 halNcpSerialInit(); \00221 } while(0)00222 00223 #define halInternalPowerDownBoard() \00224 do { \00225 halInternalSleepAdc(); \00226 halInternalInitLed(); \00227 /* Disable Buzzer */ \

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/dev0473_8h-source.htm (3 of 4) [10/29/2010 2:44:30 PM]

616

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 617: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: dev0473.h Source File

00228 TCCR2 = BIT(WGM21); /* no clock, no timer override */ \00229 TIMSK &= ~(BIT(OCIE2)); /* disable interrupt */ \00230 /* Disable Temp sensor */ \00231 PORTC &= ~BIT(7); \00232 /* Wait for nHOST_INT to go high so that we don't */ \00233 /* immediately get interrupted and wake the host */ \00234 /* unnecessarily */ \00235 while (((SPIP_nHOST_INT_PIN&BIT(SPIP_nHOST_INT))== 0) \00236 && ((EIFR&BIT(INTF0)) != BIT(INTF0))) {}; \00237 /* Set nHOST_INT to trigger low */ \00238 /* - edge triggers will not wake the Atmega32 */ \00239 EICRA &= ~(BIT(ISC01) | BIT(ISC00)); \00240 EIFR = BIT(INTF0); /*clear interrupt flag */ \00241 EIMSK |= BIT(INT0);/*enable nHOST_INT interrupt for wake */ \00242 } while(0) 00243 00244 #define halInternalPowerUpBoard() \00245 do { \00246 halInternalInitAdc(); \00247 /* Enable Temp sensor */ \00248 DDRC |= BIT(7); \00249 PORTC |= BIT(7); \00250 EIMSK &= ~BIT(INT0);/* disable nHOST_INT interrupt */ \00251 EIFR = BIT(INTF0); /* clear interrupt flag */ \00252 /* Set nHOST_INT back to trigger on falling edge... */ \00253 EICRA |= BIT(ISC01);EICRA &= ~BIT(ISC00); \00254 halNcpSerialPowerup(); \00255 } while(0)00256 00257 00258 #endif //__BOARD_H__00259

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/dev0473_8h-source.htm (4 of 4) [10/29/2010 2:44:30 PM]

617

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 618: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: system-timer.h Source File

hal » micro

system-timer.h

Go to the documentation of this file.

00001 00031 #ifndef __SYSTEM_TIMER_H__00032 #define __SYSTEM_TIMER_H__00033 00034 #ifndef DOXYGEN_SHOULD_SKIP_THIS00035 00036 #if defined( EMBER_TEST )00037 #include "unix/simulation/system-timer-sim.h"00038 #elif defined(AVR_ATMEGA_32)00039 #include "avr-atmega/32/system-timer.h"00040 #elif defined(AVR_ATMEGA_128)00041 #include "avr-atmega/128/system-timer.h"00042 #endif00043 00044 #endif // DOXYGEN_SHOULD_SKIP_THIS00045 00046 00053 int16u halInternalStartSystemTimer(void);00054 00055 00056 #ifndef DOXYGEN_SHOULD_SKIP_THIS00057 XAP2B_PAGEZERO_ON00058 #endif00059 00066 int16u halCommonGetInt16uMillisecondTick(void);00067 #ifndef DOXYGEN_SHOULD_SKIP_THIS00068 XAP2B_PAGEZERO_OFF00069 #endif00070 00080 int32u halCommonGetInt32uMillisecondTick(void);00081 00091 int16u halCommonGetInt16uQuarterSecondTick(void);00092 00134 EmberStatus halSleepForQuarterSeconds(int32u *duration);00135 00177 EmberStatus halSleepForMilliseconds(int32u *duration); 00178 00201 EmberStatus halCommonIdleForMilliseconds(int32u *duration);00202 // Maintain the previous API for backwards compatibility00203 #define halIdleForMilliseconds(duration) halCommonIdleForMilliseconds((duration))00204 00205 00206 #endif //__SYSTEM_TIMER_H__

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/system-timer_8h-source.htm (1 of 2) [10/29/2010 2:44:30 PM]

618

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 619: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: system-timer.h Source File

00207

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/system-timer_8h-source.htm (2 of 2) [10/29/2010 2:44:30 PM]

619

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 620: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: crc.h Source File

hal » micro

crc.h

Go to the documentation of this file.

00001 00007 #ifndef __CRC_H__00008 #define __CRC_H__00009 00028 int16u halCommonCrc16(int8u newByte, int16u prevResult);00029 00030 00046 int32u halCommonCrc32(int8u newByte, int32u prevResult);00047 00048 // Commonly used initial and expected final CRC32 values00049 #define INITIAL_CRC 0xFFFFFFFFL00050 #define CRC32_START INITIAL_CRC00051 #define CRC32_END 0xDEBB20E3L // For CRC32 POLYNOMIAL run LSB-MSB00052 00053 00057 #endif //__CRC_H__00058

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/crc_8h-source.htm [10/29/2010 2:44:30 PM]

620

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 621: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ash-common.h Source File

hal » micro » generic

ash-common.h

Go to the documentation of this file.

00001 00010 #ifndef __ASH_COMMON_H__00011 #define __ASH_COMMON_H__00012 00044 int8u ashEncodeByte(int8u len, int8u byte, int8u *offset);00045 00067 EzspStatus ashDecodeByte(int8u byte, int8u *out, int8u *outLen);00068 00086 int8u ashRandomizeArray(int8u seed, int8u *buf, int8u len);00087 00092 void ashStartAckTimer(void);00093 00097 void ashStopAckTimer(void);00098 #define ashStopAckTimer() do {ashAckTimer = 0;} while (FALSE)00099 00104 #define ashAckTimerIsRunning() (ashAckTimer != 0)00105 00110 #define ashAckTimerIsNotRunning() (ashAckTimer == 0)00111 00116 boolean ashAckTimerHasExpired(void);00117 00134 void ashAdjustAckPeriod(boolean expired);00135 00140 #define ashSetAckPeriod(msec) \00141 do {ashAckPeriod = msec; ashAckTimer = 0;} while (FALSE)00142 00146 #define ashGetAckPeriod() (ashAckPeriod)00147 00151 #define ashSetAndStartAckTimer(msec) \00152 do {ashSetAckPeriod(msec); ashStartAckTimer();} while (FALSE)00153 00154 // Define the units used by the Not Ready timer as 2**n msecs00155 #define ASH_NR_TIMER_BIT 4 // log2 of msecs per NR timer unit00156 00164 void ashStartNrTimer(void);00165 00168 #define ashStopNrTimer() do {ashNrTimer = 0;} while (FALSE)00169 00175 boolean ashNrTimerHasExpired(void);00176 00180 #define ashNrTimerIsNotRunning() (ashAckTimer == 0)00181

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ash-common_8h-source.htm (1 of 2) [10/29/2010 2:44:31 PM]

621

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 622: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ash-common.h Source File

00182 extern boolean ashDecodeInProgress; // set FALSE to start decoding a new frame00183 00184 // ASH timers (units)00185 extern int16u ashAckTimer; // rec'd ack timer (msecs)00186 extern int16u ashAckPeriod; // rec'd ack timer period (msecs)00187 extern int8u ashNrTimer; // not ready timer (16 msec units)00188 00189 #endif //__ASH_COMMON_H__00190

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ash-common_8h-source.htm (2 of 2) [10/29/2010 2:44:31 PM]

622

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 623: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ash-protocol.h Source File

hal » micro » generic

ash-protocol.h

Go to the documentation of this file.

00001 00016 #ifndef __ASH_PROTOCOL_H__00017 #define __ASH_PROTOCOL_H__00018 00019 #include "app/util/ezsp/ezsp-protocol.h"00020 00021 #define ASH_VERSION 2 // protocol version00022 00023 // Special byte values for ASH protocol and/or low-level comm00024 // Bytes with these values must be escaped (byte-stuffed) before transmission00025 #define ASH_FLAG 0x7E 00026 #define ASH_ESC 0x7D 00027 #define ASH_XON 0x11 00028 #define ASH_XOFF 0x13 00029 #define ASH_SUB 0x18 00030 #define ASH_CAN 0x1A 00032 // The wake byte special function applies only when in between frames, so it00033 // does not need to be escaped within a frame.00034 #define ASH_WAKE 0xFF 00036 // Constant used in byte-stuffing00037 #define ASH_FLIP 0x20 00039 // Field and frame lengths, excluding flag byte and any byte stuffing overhead00040 // All limits are inclusive00041 #define ASH_MIN_DATA_FIELD_LEN EZSP_MIN_FRAME_LENGTH00042 #define ASH_MAX_DATA_FIELD_LEN EZSP_MAX_FRAME_LENGTH00043 #define ASH_MIN_DATA_FRAME_LEN (ASH_MIN_DATA_FIELD_LEN + 1) // with control00044 #define ASH_MIN_FRAME_LEN 1 // control plus data field, but not CRC00045 #define ASH_MAX_FRAME_LEN (ASH_MAX_DATA_FIELD_LEN + 1)00046 #define ASH_CRC_LEN 200047 #define ASH_MIN_FRAME_WITH_CRC_LEN (ASH_MIN_FRAME_LEN + ASH_CRC_LEN)00048 #define ASH_MAX_FRAME_WITH_CRC_LEN (ASH_MAX_FRAME_LEN + ASH_CRC_LEN)00049 00050 // Define lengths of short frames - includes control byte and data field00051 #define ASH_NCP_SHFRAME_RX_LEN 2 00052 #define ASH_NCP_SHFRAME_TX_LEN 3 00053 #define ASH_HOST_SHFRAME_RX_LEN 3 00054 #define ASH_HOST_SHFRAME_TX_LEN 2 00056 // Control byte formats00057 // +---------+----+----+----+----+----+----+----+----++---------+00058 // | | B7 | B6 | B5 | B4 | B3 | B2 | B1 | B0 || Range |00059 // +---------+----+----+----+----+----+----+----+----++---------+00060 // | DATA | 0 | frameNum | rF | ackNum ||0x00-0x7F|

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ash-protocol_8h-source.htm (1 of 3) [10/29/2010 2:44:32 PM]

623

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 624: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ash-protocol.h Source File

00061 // +---------+----+----+----+----+----+----+----+----++---------+00062 // | ACK | 1 | 0 | 0 | pF | nF | ackNum ||0x80-0x9F|00063 // | NAK | 1 | 0 | 1 | pF | nF | ackNum ||0xA0-0xBF|00064 // +---------+----+----+----+----+----+----+----+----++---------+00065 // | RST | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 || 0xC0 |00066 // | RSTACK | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 1 || 0xC1 |00067 // | ERROR | 1 | 1 | 0 | 0 | 0 | 0 | 1 | 0 || 0xC2 |00068 // +---------+----+----+----+----+----+----+----+----++---------+00069 // rF = rFlag (retransmission flag)00070 // nF = nFlag (receiver not ready flag)00071 // pF = flag reserved for future use00072 // Control byte values 0xC3-0xFE are unused, 0xFF is reserved.00073 00074 // Define frame control byte codes00075 #define ASH_DFRAME_MASK 0x8000076 #define ASH_CONTROL_DATA 0x0000077 00078 #define ASH_SHFRAME_MASK 0xE000079 #define ASH_CONTROL_ACK 0x8000080 #define ASH_CONTROL_NAK 0xA000081 #define ASH_CONTROL_RST 0xC000082 #define ASH_CONTROL_RSTACK 0xC100083 #define ASH_CONTROL_ERROR 0xC200084 00085 #define ASH_ACKNUM_MASK 0x07 00086 #define ASH_ACKNUM_BIT 000087 #define ASH_RFLAG_MASK 0x08 00088 #define ASH_RFLAG_BIT 300089 #define ASH_NFLAG_MASK 0x08 00090 #define ASH_NFLAG_BIT 300091 #define ASH_PFLAG_MASK 0x10 00092 #define ASH_PFLAG_BIT 400093 #define ASH_FRMNUM_MASK 0x70 00094 #define ASH_FRMNUM_BIT 400095 #define ASH_GET_RFLAG(ctl) ((ctl & ASH_RFLAG_MASK ) >> ASH_RFLAG_BIT )00096 #define ASH_GET_NFLAG(ctl) ((ctl & ASH_NFLAG_MASK ) >> ASH_NFLAG_BIT )00097 #define ASH_GET_FRMNUM(ctl) ((ctl & ASH_FRMNUM_MASK) >> ASH_FRMNUM_BIT)00098 #define ASH_GET_ACKNUM(ctl) ((ctl & ASH_ACKNUM_MASK) >> ASH_ACKNUM_BIT)00099 00100 // Lengths for each frame type: includes control and data field (if any),00101 // excludes the CRC and flag bytes00102 #define ASH_FRAME_LEN_DATA_MIN (ASH_MIN_DATA_FIELD_LEN + 1)00103 #define ASH_FRAME_LEN_ACK 1 // control00104 #define ASH_FRAME_LEN_NAK 1 // control00105 #define ASH_FRAME_LEN_RST 1 // control00106 #define ASH_FRAME_LEN_RSTACK 3 // control, version, reset reason00107 #define ASH_FRAME_LEN_ERROR 3 // control, version, error00108 00109 // Define macros for handling 3-bit frame numbers modulo 8

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ash-protocol_8h-source.htm (2 of 3) [10/29/2010 2:44:32 PM]

624

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 625: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ash-protocol.h Source File

00110 #define MOD8(n) ((n) & 7) 00111 #define INC8(n) (n=(MOD8(n+1))) 00112 // Return TRUE if n is within the range lo through hi, computed (mod 8)00113 #define WITHIN_RANGE(lo, n, hi) (MOD8(n-lo)<=MOD8(hi-lo))00114 00115 #endif //__ASH_PROTOCOL_H__00116

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ash-protocol_8h-source.htm (3 of 3) [10/29/2010 2:44:32 PM]

625

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 626: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: bootloader-interface-standalone.h Source File

hal » micro

bootloader-interface-standalone.h

Go to the documentation of this file.

00001 00017 #ifndef __BOOTLOADER_STANDALONE_H__00018 #define __BOOTLOADER_STANDALONE_H__00019 00028 int16u halGetStandaloneBootloaderVersion(void);00029 00033 #define NO_BOOTLOADER_MODE 0xFF00034 00037 #define STANDALONE_BOOTLOADER_NORMAL_MODE 100038 00041 #define STANDALONE_BOOTLOADER_RECOVERY_MODE 000042 00061 EmberStatus halLaunchStandaloneBootloader(int8u mode);00062 00063 00064 #endif //__BOOTLOADER_STANDALONE_H__00065

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Outp...I_EM260_forPDF/bootloader-interface-standalone_8h-source.htm [10/29/2010 2:44:32 PM]

626

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 627: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: bootloader-interface-standalone-v1.h Source File

hal » micro » avr-atmega

bootloader-interface-standalone-v1.h

Go to the documentation of this file.

00001 00019 #ifndef __BOOTLOADER_STANDALONE_V1_H__00020 #define __BOOTLOADER_STANDALONE_V1_H__00021 00026 #define BOOTLOADER_TYPE_STANDALONE 0xBEEF 00027 // BOOTLOADER_TYPE_APP is defined in bootloader-interface-app.h00028 00029 #ifndef DOXYGEN_SHOULD_SKIP_THIS00030 00031 // Automatically used by the trap functions for triggering the bootloader00032 #define BOOTLOADER_APP_REQUEST_KEY 0xFA2700033 00034 // Constants used by the standalone bootloader00035 #define FLASH_TAB_POINTERS 0x00F000036 #define FLASH_TAB_POINTERS_DEFAULT_TOKEN_TAB_PTR 0 //DEPRECATED00037 #define FLASH_TAB_POINTERS_UPPER_TOKEN_TAB_PTR 2 //DEPRECATED00038 #define FLASH_TAB_POINTERS_BOOT_TRAP_TAB_PTR 400039 #define FLASH_TAB_POINTERS_HELPERFUNC_TAB 600040 #define BOOTLOADER_TRAPTAB_SIGNATURE 0xBEEF00041 00042 #ifdef __HAS_ELPM__00043 #define LPM_HIGH(x,y) \00044 do { \00045 int8u reg; \00046 reg = RAMPZ; \00047 y = __extended_load_program_memory(x); \00048 RAMPZ = reg; \00049 } while(0)00050 00051 // #define LPM_HIGH __extended_load_program_memory00052 #define FLASH_HIGH __farflash00053 #else00054 #define LPM_HIGH(x,y) \00055 do { \00056 y = __load_program_memory(x); \00057 } while(0)00058 00059 #define FLASH_HIGH __flash00060 #endif // __HAS_ELPM__00061 00062 00063 00064 00067 00071 #ifdef DOXYGEN_SHOULD_SKIP_THIS

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/O...0_forPDF/bootloader-interface-standalone-v1_8h-source.htm (1 of 3) [10/29/2010 2:44:33 PM]

627

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 628: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: bootloader-interface-standalone-v1.h Source File

00072 enum StandaloneBootloaderTraps00073 #else00074 typedef int8u StandaloneBootloaderTraps;00075 enum00076 #endif00077 {00078 BOOT_TRAP_APP_START = 1,00079 BOOT_TRAP_FLASH_ADJUST = 300080 };00081 #endif // DOXYGEN_SHOULD_SKIP_THIS00082 00083 00101 EmberStatus halInternalStandaloneBootloaderTrap(int16u assumedBootloaderType,00102 int8u trapNumber, ...);00103 00104 #ifndef DOXYGEN_SHOULD_SKIP_THIS00105 00108 void bootloadAppStart(void);00109 #endif // DOXYGEN_SHOULD_SKIP_THIS00110 00111 #ifdef DOXYGEN_SHOULD_SKIP_THIS00112 00127 #define halBootloadAppStart(space, segment, ramPtr);00128 #else00129 #define halBootloadAppStart(space, segment, ramPtr) \00130 halInternalStandaloneBootloaderTrap(BOOTLOADER_TYPE_APP, \00131 BOOT_TRAP_APP_START)00132 #endif // DOXYGEN_SHOULD_SKIP_THIS00133 00149 void halInternalAdjustFlashBlock(int16u* dst, int16u* src, int8u size);00150 00151 #ifdef DOXYGEN_SHOULD_SKIP_THIS00152 00167 #define halBootloadAdjustFlash(space, segment, ramPtr);00168 #else00169 #define halBootloadAdjustFlash(space, segment, ramPtr) \00170 halInternalStandaloneBootloaderTrap(BOOTLOADER_TYPE_APP, \00171 BOOT_TRAP_FLASH_ADJUST, \00172 (segment), (ramPtr), (space))00173 #endif // DOXYGEN_SHOULD_SKIP_THIS00174 00175 // Note: bootloaderMode 0 means go into passive bootloader mode. Note:00176 // this includes single hop pass thru.00177 // bootloaderMode 1 means clone to node in gatewayID00178 // bootloaderMode 2 means look for an errant node and clone to it.00179 // bootloaderMode 3 means look for an errant node and do pass thru.00180 // bootloaderMode 4 (not valid here) is later on used for single hop00181 00182 enum {00183 BOOTLOADER_MODE_MENU = 0x00,00184 BOOTLOADER_MODE_PASSTHROUGH = 0x00,00185 BOOTLOADER_MODE_CLONE = 0x01,

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/O...0_forPDF/bootloader-interface-standalone-v1_8h-source.htm (2 of 3) [10/29/2010 2:44:33 PM]

628

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 629: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: bootloader-interface-standalone-v1.h Source File

00186 BOOTLOADER_MODE_CLONE_RECOVERY = 0x02,00187 BOOTLOADER_MODE_PASSTHROUGH_RECOVERY = 0x0300188 };00189 00214 EmberStatus halLaunchStandaloneBootloaderV1(int8u mode, int8u *eui64);00215 00217 00218 #endif //__BOOTLOADER_STANDALONE_V1_H__00219

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/O...0_forPDF/bootloader-interface-standalone-v1_8h-source.htm (3 of 3) [10/29/2010 2:44:33 PM]

629

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 630: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: bootload-ezsp-utils.h Source File

app » util » bootload

bootload-ezsp-utils.h

Go to the documentation of this file.

00001 00016 // application timers are based on quarter second intervals, each00017 // quarter second is measured in millisecond ticks. This value defines00018 // the approximate number of millisecond ticks in a quarter second.00019 // Account for variations in system timers.00020 #ifdef AVR_ATMEGA_3200021 #define TICKS_PER_QUARTER_SECOND 22500022 #else00023 #define TICKS_PER_QUARTER_SECOND 25000024 #endif00025 00026 // Node build info00027 extern int16u nodeBlVersion;00028 extern int8u nodePlat;00029 extern int8u nodeMicro;00030 extern int8u nodePhy;00031 00032 00033 // Both of these need to be correctly handled in the applications's00034 // ezspErrorHandler().00035 // ezsp error info00036 extern EzspStatus bootloadEzspLastError;00037 // If this is not EZSP_SUCCESS, the next call to ezspErrorHandler()00038 // will ignore this error.00039 extern EzspStatus ignoreNextEzspError;00040 00041 00042 // *******************************************************************00043 // Callback functions used by the bootload library.00044 00072 boolean hostBootloadUtilLaunchRequestHandler(int8u lqi,00073 int8s rssi,00074 int16u manufacturerId,00075 int8u *hardwareTag,00076 EmberEUI64 sourceEui);00077 00121 void hostBootloadUtilQueryResponseHandler(int8u lqi,00122 int8s rssi,00123 boolean bootloaderActive,00124 int16u manufacturerId,00125 int8u *hardwareTag,00126 EmberEUI64 targetEui,

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/bootload-ezsp-utils_8h-source.htm (1 of 2) [10/29/2010 2:44:33 PM]

630

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 631: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: bootload-ezsp-utils.h Source File

00127 int8u bootloaderCapabilities,00128 int8u platform,00129 int8u micro,00130 int8u phy,00131 int16u blVersion);00132 00140 void hostBootloadReinitHandler(void);00141 00142 00143 // Suppport routines in the bootloader utils library00144 00156 boolean isTheSameEui64(EmberEUI64 sourceEui, EmberEUI64 targetEui);00157 00168 void printLittleEndianEui64(int8u port, EmberEUI64 eui64);00169 00180 void printBigEndianEui64(int8u port, EmberEUI64 eui64);00181 00199 EmberStatus debugPrintf(int8u port, PGM_P formatString, ...);00200

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/bootload-ezsp-utils_8h-source.htm (2 of 2) [10/29/2010 2:44:33 PM]

631

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 632: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: bootload-utils.h Source File

app » util » bootload

bootload-utils.h

Go to the documentation of this file.

00001 00058 // *******************************************************************00059 // Literals that are needed by the application.00060 00066 #define BOOTLOAD_AUTH_COMMON_SIZE 1600067 #define BOOTLOAD_AUTH_CHALLENGE_SIZE BOOTLOAD_AUTH_COMMON_SIZE00068 #define BOOTLOAD_AUTH_RESPONSE_SIZE BOOTLOAD_AUTH_COMMON_SIZE00069 00076 #define BOOTLOAD_HARDWARE_TAG_SIZE 1600077 00078 #ifdef DOXYGEN_SHOULD_SKIP_THIS00079 00082 enum bootloadMode00083 #else00084 typedef int8u bootloadMode;00085 enum00086 #endif00087 {00089 BOOTLOAD_MODE_NONE,00091 BOOTLOAD_MODE_PASSTHRU,00092 };00093 00094 #ifdef DOXYGEN_SHOULD_SKIP_THIS00095 00106 enum bootloadState00107 #else00108 typedef int8u bootloadState;00109 enum00110 #endif00111 {00112 BOOTLOAD_STATE_NORMAL, 00113 BOOTLOAD_STATE_QUERY, 00114 BOOTLOAD_STATE_WAIT_FOR_AUTH_CHALLENGE, 00115 BOOTLOAD_STATE_WAIT_FOR_AUTH_RESPONSE, 00116 BOOTLOAD_STATE_DELAY_BEFORE_START, 00117 BOOTLOAD_STATE_START_UNICAST_BOOTLOAD, 00118 BOOTLOAD_STATE_START_BROADCAST_BOOTLOAD,00119 BOOTLOAD_STATE_START_SENDING_IMAGE, 00120 BOOTLOAD_STATE_SENDING_IMAGE, 00121 BOOTLOAD_STATE_WAIT_FOR_IMAGE_ACK, 00122 BOOTLOAD_STATE_WAIT_FOR_COMPLETE_ACK,

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/bootload-utils_8h-source.htm (1 of 3) [10/29/2010 2:44:34 PM]

632

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 633: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: bootload-utils.h Source File

00123 BOOTLOAD_STATE_DONE 00124 };00125 00126 00127 // *******************************************************************00128 // Public functions that are called by the application.00129 00143 void bootloadUtilInit(int8u appPort, int8u bootloadPort);00144 00166 EmberStatus bootloadUtilSendRequest(EmberEUI64 targetEui,00167 int16u mfgId,00168 int8u hardwareTag[BOOTLOAD_HARDWARE_TAG_SIZE],00169 int8u encryptKey[BOOTLOAD_AUTH_COMMON_SIZE],00170 bootloadMode mode);00171 00184 void bootloadUtilSendQuery(EmberEUI64 target);00185 00203 void bootloadUtilStartBootload(EmberEUI64 target, bootloadMode mode);00204 00210 void bootloadUtilTick(void);00211 00212 00213 // *******************************************************************00214 // Callback functions used by the bootload library.00215 00234 boolean bootloadUtilLaunchRequestHandler(int16u manufacturerId,00235 int8u hardwareTag[BOOTLOAD_HARDWARE_TAG_SIZE],00236 EmberEUI64 sourceEui);00237 00267 void bootloadUtilQueryResponseHandler(boolean bootloaderActive,00268 int16u manufacturerId,00269 int8u hardwareTag[BOOTLOAD_HARDWARE_TAG_SIZE],00270 EmberEUI64 targetEui,00271 int8u bootloaderCapabilities,00272 int8u platform,00273 int8u micro,00274 int8u phy,00275 int16u blVersion);00276 00289 void bootloadUtilSendAuthResponse(EmberEUI64 target);00290 00291 00292 // *******************************************************************00293 // Bootload state variables00294 00299 extern bootloadState blState;00300 #define IS_BOOTLOADING ((blState != BOOTLOAD_STATE_NORMAL) && \00301 (blState != BOOTLOAD_STATE_DONE))00302

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/bootload-utils_8h-source.htm (2 of 3) [10/29/2010 2:44:34 PM]

633

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 634: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: bootload-utils.h Source File

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/bootload-utils_8h-source.htm (3 of 3) [10/29/2010 2:44:34 PM]

634

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 635: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: command-interpreter.h Source File

app » util » serial

command-interpreter.h

Go to the documentation of this file.

00001 00010 #ifndef __COMMAND_INTERPRETER_H__00011 #define __COMMAND_INTERPRETER_H__00012 00068 #ifndef EMBER_COMMENT_CHARACTER00069 00072 #define EMBER_COMMENT_CHARACTER '#'00073 #endif00074 00075 #ifndef EMBER_MAX_COMMAND_LENGTH00076 00078 #define EMBER_MAX_COMMAND_LENGTH 1200079 #endif00080 00084 //Since the Cortex-M3 platform is native 32bit, we enable 32bit unsigned00085 //arguments in the command interpreter. This is useful since any addresses or00086 //similar arguments are best supplied as 32bits. All other platforms are both00087 //not native 32bit and even more resource constrained, so only use 16bit args.00088 #ifdef CORTEXM300089 typedef int32u ArgTypeU;00090 #define TEMP_GREATER_THAN_MAX_ARG_SIZE (0)00091 #define PERFORM_BOUNDS_CHECKING (!((type=='u')&&(size=='4')))00092 #else //everything else needs to save space00093 typedef int16u ArgTypeU;00094 #define TEMP_GREATER_THAN_MAX_ARG_SIZE (0xFFFF < temp)00095 #define PERFORM_BOUNDS_CHECKING (1)00096 #endif00097 00098 struct EmberCommandStateS; // To allow forward use of this type.00099 00100 typedef void (*CommandAction)(struct EmberCommandStateS *state);00101 00102 00103 #ifdef DOXYGEN_SHOULD_SKIP_THIS00104 00106 typedef struct {00107 #else00108 typedef PGM struct {00109 #endif00110 00113 PGM_P longName;00117 CommandAction action;00139 PGM_P argumentTypes;

file:///C|/dev/perforce/software/v2/tephra-park/doxygen...tput/API_EM260_forPDF/command-interpreter_8h-source.htm (1 of 3) [10/29/2010 2:44:35 PM]

635

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 636: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: command-interpreter.h Source File

00142 PGM_P description;00143 } EmberCommandEntry;00144 00145 #ifdef DOXYGEN_SHOULD_SKIP_THIS00146 00151 enum EmberCommandStatus00152 #else00153 typedef int8u EmberCommandStatus;00154 enum00155 #endif00156 {00157 EMBER_CMD_SUCCESS, 00158 EMBER_CMD_ERR_PORT_PROBLEM, 00159 EMBER_CMD_ERR_NO_BUFFER_AVAILABLE, 00160 EMBER_CMD_ERR_NO_SUCH_COMMAND, 00161 EMBER_CMD_ERR_WRONG_COMMAND_ARGUMENTS, 00162 EMBER_CMD_ERR_TOO_MANY_COMMAND_ARGUMENTS, 00163 EMBER_CMD_ERR_ARGUMENT_OUT_OF_RANGE, 00164 EMBER_CMD_ERR_ARGUMENT_SYNTAX_ERROR, 00165 EMBER_CMD_ERR_STRING_TOO_LONG, 00166 EMBER_CMD_ERR_NO_BINARY_STRING_TERMINATOR 00167 };00168 00169 extern PGM_NO_CONST PGM_P emberCommandErrorNames[];00170 00174 typedef struct EmberCommandStateS {00177 EmberCommandEntry *commands;00178 void (* errorHandler)(struct EmberCommandStateS *state);00180 ArgTypeU *arguments; 00181 00182 int8u maximumArguments;00186 int8u integerBase; 00188 int8u argumentCount;00189 00190 // The rest are internal settings00191 //00193 int8u state;00195 int8u error; 00199 int8u command[EMBER_MAX_COMMAND_LENGTH + 1]; 00200 00201 int16u commandIndex;00203 PGM_P argumentSpecs;00205 int8u stringLength;00207 int8u binaryLength; 00208 00209 EmberMessageBuffer stringBuffer;00210 00211 ArgTypeU integerValue;

file:///C|/dev/perforce/software/v2/tephra-park/doxygen...tput/API_EM260_forPDF/command-interpreter_8h-source.htm (2 of 3) [10/29/2010 2:44:35 PM]

636

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 637: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: command-interpreter.h Source File

00213 int8u integerSign; 00214 00215 int8u currentIntegerBase;00216 00218 EmberCommandEntry *currentCommands;00219 00220 } EmberCommandState;00221 00222 00229 #define emberUnsignedCommandArgument(state, index) \00230 ((state)->arguments[index])00231 00232 #define emberSignedCommandArgument(state, index) \00233 ((int16s) ((state)->arguments[index]))00234 00235 #define emberBufferCommandArgument(state, index) \00236 (LOW_BYTE((state)->arguments[index]))00237 00244 void emberCommandReaderInit(EmberCommandState *state);00245 00251 boolean emberProcessCommandString(EmberCommandState *state,00252 int8u *input,00253 int8u size);00254 00263 #define emberProcessCommandInput(state, port) \00264 emberProcessCommandString(state, NULL, port)00265 00269 #define emberCommandName(state) (state->command)00270 00271 00275 #endif //__COMMAND_INTERPRETER_H__

file:///C|/dev/perforce/software/v2/tephra-park/doxygen...tput/API_EM260_forPDF/command-interpreter_8h-source.htm (3 of 3) [10/29/2010 2:44:35 PM]

637

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 638: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: zigbee-device-common.h Source File

app » util » zigbee-framework

zigbee-device-common.h

Go to the documentation of this file.

00001 00016 #define ZDO_MESSAGE_OVERHEAD 100017 00036 #ifdef DOXYGEN_SHOULD_SKIP_THIS00037 EmberStatus emberNodeDescriptorRequest(EmberNodeId target,00038 EmberApsOption options);00039 #else00040 // Macroized to save code space.00041 EmberStatus emberSendZigDevRequestTarget(EmberNodeId target,00042 int16u clusterId,00043 EmberApsOption options);00044 #define emberNodeDescriptorRequest(target, opts) \00045 (emberSendZigDevRequestTarget((target), NODE_DESCRIPTOR_REQUEST, (opts)))00046 #endif00047 00063 #ifdef DOXYGEN_SHOULD_SKIP_THIS00064 EmberStatus emberPowerDescriptorRequest(EmberNodeId target,00065 EmberApsOption options);00066 #else00067 // Macroized to save code space.00068 #define emberPowerDescriptorRequest(target, opts) \00069 (emberSendZigDevRequestTarget((target), POWER_DESCRIPTOR_REQUEST, (opts)))00070 #endif00071 00090 EmberStatus emberSimpleDescriptorRequest(EmberNodeId target,00091 int8u targetEndpoint,00092 EmberApsOption options);00093 00106 #ifdef DOXYGEN_SHOULD_SKIP_THIS00107 EmberStatus emberActiveEndpointsRequest(EmberNodeId target,00108 EmberApsOption options);00109 #else00110 // Macroized to save code space.00111 #define emberActiveEndpointsRequest(target, opts) \00112 (emberSendZigDevRequestTarget((target), ACTIVE_ENDPOINTS_REQUEST, (opts)))00113 #endif00114 00144 #ifdef DOXYGEN_SHOULD_SKIP_THIS00145 EmberStatus emberBindRequest(EmberNodeId target,00146 EmberEUI64 source,00147 int8u sourceEndpoint,00148 int16u clusterId,

file:///C|/dev/perforce/software/v2/tephra-park/doxyge...ut/API_EM260_forPDF/zigbee-device-common_8h-source.htm (1 of 4) [10/29/2010 2:44:36 PM]

638

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 639: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: zigbee-device-common.h Source File

00149 int8u type,00150 EmberEUI64 destination,00151 EmberMulticastId groupAddress,00152 int8u destinationEndpoint,00153 EmberApsOption options);00154 #else00155 // Macroized to save code space.00156 #define emberBindRequest(target, \00157 src, \00158 srcEndpt, \00159 cluster, \00160 type, \00161 dest, \00162 groupAddress, \00163 destEndpt, \00164 opts) \00165 \00166 (emberSendZigDevBindRequest((target), \00167 BIND_REQUEST, \00168 (src), (srcEndpt), (cluster), \00169 (type), (dest), (groupAddress), \00170 (destEndpt), (opts)))00171 00172 EmberStatus emberSendZigDevBindRequest(EmberNodeId target,00173 int16u bindClusterId,00174 EmberEUI64 source,00175 int8u sourceEndpoint,00176 int16u clusterId,00177 int8u type,00178 EmberEUI64 destination,00179 EmberMulticastId groupAddress,00180 int8u destinationEndpoint,00181 EmberApsOption options);00182 #endif00183 00210 #ifdef DOXYGEN_SHOULD_SKIP_THIS00211 EmberStatus emberUnbindRequest(EmberNodeId target,00212 EmberEUI64 source,00213 int8u sourceEndpoint,00214 int16u clusterId,00215 int8u type,00216 EmberEUI64 destination,00217 EmberMulticastId groupAddress,00218 int8u destinationEndpoint,00219 EmberApsOption options);00220 #else00221 // Macroized to save code space.00222 #define emberUnbindRequest(target, \00223 src, \00224 srcEndpt, \

file:///C|/dev/perforce/software/v2/tephra-park/doxyge...ut/API_EM260_forPDF/zigbee-device-common_8h-source.htm (2 of 4) [10/29/2010 2:44:36 PM]

639

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 640: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: zigbee-device-common.h Source File

00225 cluster, \00226 type, \00227 dest, \00228 groupAddress, \00229 destEndpt, \00230 opts) \00231 \00232 (emberSendZigDevBindRequest((target), \00233 UNBIND_REQUEST, \00234 (src), (srcEndpt), (cluster), \00235 (type), (dest), (groupAddress), \00236 (destEndpt), (opts)))00237 #endif00238 00261 #ifdef DOXYGEN_SHOULD_SKIP_THIS00262 EmberStatus emberLqiTableRequest(EmberNodeId target,00263 int8u startIndex,00264 EmberApsOption options);00265 #else00266 #define emberLqiTableRequest(target, startIndex, options) \00267 (emberTableRequest(LQI_TABLE_REQUEST, (target), (startIndex), (options)))00268 00269 EmberStatus emberTableRequest(int16u clusterId,00270 EmberNodeId target,00271 int8u startIndex,00272 EmberApsOption options);00273 #endif00274 00291 #ifdef DOXYGEN_SHOULD_SKIP_THIS00292 EmberStatus emberRoutingTableRequest(EmberNodeId target,00293 int8u startIndex,00294 EmberApsOption options);00295 #else00296 #define emberRoutingTableRequest(target, startIndex, options) \00297 (emberTableRequest(ROUTING_TABLE_REQUEST, (target), (startIndex), (options)))00298 #endif00299 00317 #ifdef DOXYGEN_SHOULD_SKIP_THIS00318 EmberStatus emberBindingTableRequest(EmberNodeId target,00319 int8u startIndex,00320 EmberApsOption options);00321 #else00322 #define emberBindingTableRequest(target, startIndex, options) \00323 (emberTableRequest(BINDING_TABLE_REQUEST, (target), (startIndex), (options)))00324 #endif00325 00345 EmberStatus emberLeaveRequest(EmberNodeId target,00346 EmberEUI64 deviceAddress,00347 int8u leaveRequestFlags,00348 EmberApsOption options);00349

file:///C|/dev/perforce/software/v2/tephra-park/doxyge...ut/API_EM260_forPDF/zigbee-device-common_8h-source.htm (3 of 4) [10/29/2010 2:44:36 PM]

640

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 641: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: zigbee-device-common.h Source File

00366 EmberStatus emberPermitJoiningRequest(EmberNodeId target,00367 int8u duration,00368 int8u authentication,00369 EmberApsOption options);00370 00371 #ifdef DOXYGEN_SHOULD_SKIP_THIS00372 00377 void emberSetZigDevRequestRadius(int8u radius);00378 00384 int8u emberGetZigDevRequestRadius(void);00385 #else00386 extern int8u zigDevRequestRadius;00387 #define emberGetZigDevRequestRadius() (zigDevRequestRadius)00388 #define emberSetZigDevRequestRadius(x) (zigDevRequestRadius=x)00389 #endif00390 00396 int8u emberGetLastZigDevRequestSequence(void);00397 00400 #ifndef DOXYGEN_SHOULD_SKIP_THIS00401 //------------------------------------------------------------------------------00402 // Utility functions used by the library code.00403 00404 EmberStatus emberSendZigDevRequest(EmberNodeId destination,00405 int16u clusterId,00406 EmberApsOption options,00407 int8u *contents,00408 int8u length);00409 00419 int8u emberNextZigDevRequestSequence(void);00420 00421 #endif // DOXYGEN_SHOULD_SKIP_THIS00422

file:///C|/dev/perforce/software/v2/tephra-park/doxyge...ut/API_EM260_forPDF/zigbee-device-common_8h-source.htm (4 of 4) [10/29/2010 2:44:36 PM]

641

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 642: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: network-manager.h Source File

app » util » zigbee-framework

network-manager.h

Go to the documentation of this file.

00001 00090 #include CONFIGURATION_HEADER00091 00092 // The application is notified via nmUtilWarningHandler00093 // if NM_WARNING_LIMIT unsolicited scan reports are received00094 // within NM_WINDOW_SIZE minutes. To save flash and RAM,00095 // the actual timing is approximate.00096 #ifndef NM_WARNING_LIMIT00097 #define NM_WARNING_LIMIT 1600098 #endif00099 00100 #ifndef NM_WINDOW_SIZE00101 #define NM_WINDOW_SIZE 400102 #endif00103 00104 // The channels that should be used by the network manager.00105 00106 #ifndef NM_CHANNEL_MASK00107 #define NM_CHANNEL_MASK EMBER_ALL_802_15_4_CHANNELS_MASK00108 #endif00109 00110 // The number of channels used in the NM_CHANNEL_MASK.00111 00112 #ifndef NM_WATCHLIST_SIZE00113 #define NM_WATCHLIST_SIZE 1600114 #endif00115 00122 void nmUtilWarningHandler(void);00123 00132 boolean nmUtilProcessIncoming(EmberApsFrame *apsFrame,00133 int8u messageLength,00134 int8u* message);00135 00139 EmberStatus nmUtilChangeChannelRequest(void);00140

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/network-manager_8h-source.htm [10/29/2010 2:44:36 PM]

642

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 643: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: serial.h Source File

app » util » serial

app/util/serial/serial.h

Go to the documentation of this file.

00001 00012 #ifndef __SERIAL_H__00013 #define __SERIAL_H__00014 00015 #ifndef __HAL_H__00016 #error hal/hal.h should be included first00017 #endif00018 00019 #ifndef DOXYGEN_SHOULD_SKIP_THIS00020 #include <stdarg.h>00021 00022 //Rx FIFO Full indicator00023 #define RX_FIFO_FULL (0xFFFF)00024 00025 #endif // DOXYGEN_SHOULD_SKIP_THIS00026 00136 EmberStatus emberSerialInit(int8u port, 00137 SerialBaudRate rate,00138 SerialParity parity,00139 int8u stopBits);00140 00148 int16u emberSerialReadAvailable(int8u port);00149 00167 EmberStatus emberSerialReadByte(int8u port, int8u *dataByte);00168 00183 EmberStatus emberSerialReadLine(int8u port, char *data, int8u max);00184 00208 EmberStatus emberSerialReadPartialLine(int8u port, char *data, int8u max, int8u *index);00209 00218 int16u emberSerialWriteAvailable(int8u port);00219 00227 #define emberSerialWriteUsed(port) \00228 (emSerialTxQueueSizes[port] - emberSerialWriteAvailable(port))00229 00243 EmberStatus emberSerialWriteByte(int8u port, int8u dataByte);00244 00259 EmberStatus emberSerialWriteHex(int8u port, int8u dataByte);00260 00273 EmberStatus emberSerialWriteString(int8u port, PGM_P string);00274 00299 XAP2B_PAGEZERO_ON00300 EmberStatus emberSerialPrintf(int8u port, PGM_P formatString, ...);00301 XAP2B_PAGEZERO_OFF

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/...API_EM260_forPDF/app_2util_2serial_2serial_8h-source.htm (1 of 2) [10/29/2010 2:44:37 PM]

643

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 644: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: serial.h Source File

00302 00318 XAP2B_PAGEZERO_ON00319 EmberStatus emberSerialPrintfLine(int8u port, PGM_P formatString, ...);00320 XAP2B_PAGEZERO_OFF00321 00332 XAP2B_PAGEZERO_ON00333 EmberStatus emberSerialPrintCarriageReturn(int8u port);00334 XAP2B_PAGEZERO_OFF00335 00336 00349 EmberStatus emberSerialPrintfVarArg(int8u port, PGM_P formatString, va_list ap);00350 00366 EmberStatus emberSerialWriteData(int8u port, int8u *data, int8u length);00367 00368 //Host HALs do not use stack buffers.00369 #ifndef HAL_HOST00370 00388 EmberStatus emberSerialWriteBuffer(int8u port, EmberMessageBuffer buffer, int8u start, int8u length);00389 #endif //HAL_HOST00390 00403 XAP2B_PAGEZERO_ON00404 EmberStatus emberSerialWaitSend(int8u port);00405 XAP2B_PAGEZERO_OFF00406 00427 EmberStatus emberSerialGuaranteedPrintf(int8u port, PGM_P formatString, ...);00428 00434 void emberSerialBufferTick(void);00435 00441 void emberSerialFlushRx(int8u port);00442 00443 00444 00445 00466 typedef EmberStatus (emPrintfFlushHandler)(int8u flushVar, 00467 int8u *contents, 00468 int8u length);00469 00470 00488 int8u emPrintfInternal(emPrintfFlushHandler handler, int8u port, PGM_P buff, va_list list);00489 00490 00495 #endif // __SERIAL_H__00496

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/...API_EM260_forPDF/app_2util_2serial_2serial_8h-source.htm (2 of 2) [10/29/2010 2:44:37 PM]

644

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 645: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: linux-serial.h Source File

app » util » serial

linux-serial.h

Go to the documentation of this file.

00001 00014 // The normal CLI is accessible via port 0 while port 1 is usable for00015 // raw input. This is often used by applications to receive a 260 00016 // image for bootloading.00017 #define SERIAL_PORT_RAW 000018 #define SERIAL_PORT_CLI 100019 00020 void emberSerialSetPrompt(const char* thePrompt);00021 void emberSerialCleanup(void);00022 int emberSerialGetInputFd(int8u port);00023 00024 // For users of app/util/serial/command-interpreter.h00025 void emberSerialCommandCompletionInit(EmberCommandEntry* listOfCommands);00026 00027 // For users of app/util/serial/cli.h00028 void emberSerialCommandCompletionInitCli(cliSerialCmdEntry* cliCmdList, 00029 int cliCmdListLength);00030

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/linux-serial_8h-source.htm [10/29/2010 2:44:37 PM]

645

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 646: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ash-host.h Source File

app » ezsp-uart-host

ash-host.h

Go to the documentation of this file.

00001 00016 #ifndef __ASH_HOST_H__00017 #define __ASH_HOST_H__00018 00019 #define ASH_MAX_TIMEOUTS 6 00020 #define ASH_MAX_WAKE_TIME 150 00022 #define ASH_PORT_LEN 40 00024 // Bits in traceFlags to enable various host trace outputs00025 #define TRACE_FRAMES_BASIC 1 00026 #define TRACE_FRAMES_VERBOSE 2 00027 #define TRACE_EVENTS 4 00028 #define TRACE_EZSP 8 00029 #define TRACE_EZSP_VERBOSE 16 00031 // resetMethod values00032 #define ASH_RESET_METHOD_RST 0 00033 #define ASH_RESET_METHOD_DTR 1 00034 #define ASH_RESET_METHOD_CUSTOM 2 00035 #define ASH_RESET_METHOD_NONE 3 00037 // ncpType values00038 #define ASH_NCP_TYPE_EM2XX_EM3XX 0 00040 // ashSelectHostConfig() values00041 #define ASH_HOST_CONFIG_EM2XX_EM3XX_115200_RTSCTS 000042 #define ASH_HOST_CONFIG_EM2XX_EM3XX_57600_XONXOFF 100043 00047 typedef struct00048 {00049 char serialPort[ASH_PORT_LEN]; 00050 int32u baudRate; 00051 int8u stopBits; 00052 int8u rtsCts; 00053 int16u outBlockLen; 00054 int16u inBlockLen; 00055 int8u traceFlags; 00056 int8u txK; 00057 int8u randomize; 00058 int16u ackTimeInit; 00059 int16u ackTimeMin; 00060 int16u ackTimeMax; 00061 int16u timeRst; 00062 int8u nrLowLimit;

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ash-host_8h-source.htm (1 of 3) [10/29/2010 2:44:38 PM]

646

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 647: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ash-host.h Source File

00063 int8u nrHighLimit; 00064 int16u nrTime; 00065 int8u resetMethod; 00066 int8u ncpType; 00067 } AshHostConfig;00068 00069 #define ashReadConfig(member) \00070 (ashHostConfig.member)00071 00072 #define ashReadConfigOrDefault(member, defval) \00073 (ashHostConfig.member)00074 00075 #define ashWriteConfig(member, value) \00076 do { ashHostConfig.member = value; } while (0)00077 00078 #define BUMP_HOST_COUNTER(mbr) do {ashCount.mbr++;} while (0)00079 #define ADD_HOST_COUNTER(op, mbr) do {ashCount.mbr += op;} while(0)00080 00081 typedef struct 00082 {00083 int32u txBytes; 00084 int32u txBlocks; 00085 int32u txData; 00086 int32u txAllFrames; 00087 int32u txDataFrames; 00088 int32u txAckFrames; 00089 int32u txNakFrames; 00090 int32u txReDataFrames; 00091 int32u txN0Frames; 00092 int32u txN1Frames; 00093 int32u txCancelled; 00095 int32u rxBytes; 00096 int32u rxBlocks; 00097 int32u rxData; 00098 int32u rxAllFrames; 00099 int32u rxDataFrames; 00100 int32u rxAckFrames; 00101 int32u rxNakFrames; 00102 int32u rxReDataFrames; 00103 int32u rxN0Frames; 00104 int32u rxN1Frames; 00105 int32u rxCancelled; 00107 int32u rxCrcErrors; 00108 int32u rxCommErrors; 00109 int32u rxTooShort; 00110 int32u rxTooLong; 00111 int32u rxBadControl;

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ash-host_8h-source.htm (2 of 3) [10/29/2010 2:44:38 PM]

647

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 648: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ash-host.h Source File

00112 int32u rxBadLength; 00113 int32u rxBadAckNumber; 00114 int32u rxNoBuffer; 00115 int32u rxDuplicates; 00116 int32u rxOutOfSequence; 00117 int32u rxAckTimeouts; 00118 } AshCount;00119 00120 extern EzspStatus ashError;00121 extern EzspStatus ncpError;00122 extern AshHostConfig ashHostConfig;00123 extern AshCount ashCount;00124 extern boolean ncpSleepEnabled;00125 00138 EzspStatus ashSelectHostConfig(int8u config);00139 00148 EzspStatus ashStart(void);00149 00154 void ashStop(void);00155 00173 EzspStatus ashSend(int8u len, const int8u *inptr);00174 00187 EzspStatus ashResetNcp(void);00188 00199 EzspStatus ashWakeUpNcp(boolean init);00200 00210 boolean ashIsConnected(void);00211 00216 void ashSendExec(void);00217 00229 EzspStatus ashReceiveExec(void);00230 00244 EzspStatus ashReceive(int8u *len, int8u *buffer);00245 00250 boolean ashOkToSleep(void);00251 00252 #endif //__ASH_HOST_H___00253

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ash-host_8h-source.htm (3 of 3) [10/29/2010 2:44:38 PM]

648

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 649: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ash-host-io.h Source File

app » ezsp-uart-host

ash-host-io.h

Go to the documentation of this file.

00001 00009 #ifndef __ASH_HOST_IO_H__00010 #define __ASH_HOST_IO_H__00011 00027 EzspStatus ashSerialInit(void);00028 00032 void ashSerialClose(void);00033 00038 void ashResetDtr(void);00039 00044 void ashResetCustom(void);00045 00054 EzspStatus ashSerialWriteAvailable(void);00055 00060 void ashSerialWriteByte(int8u byte);00061 00066 void ashSerialWriteFlush(void);00067 00076 EzspStatus ashSerialReadByte(int8u *byte);00077 00086 EzspStatus ashSerialReadAvailable(int16u *count);00087 00091 void ashSerialReadFlush(void);00092 00095 void ashDebugFlush(void);00096 00099 #define DEBUG_STREAM stdout00100 00101 #ifdef WIN3200102 #define ashDebugPrintf printf00103 #else00104 #define ashDebugPrintf(...) fprintf(DEBUG_STREAM, __VA_ARGS__)00105 #endif00106 00107 #define ashDebugVfprintf(format, argPointer) \00108 vfprintf(DEBUG_STREAM, format, argPointer)00109 00113 int ashSerialGetFd(void);00114 00115 00122 boolean ashSerialOutputIsIdle(void);00123

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ash-host-io_8h-source.htm (1 of 2) [10/29/2010 2:44:39 PM]

649

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 650: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ash-host-io.h Source File

00124 #endif //__ASH_HOST_H___00125 00126 #if !defined(DOXYGEN_SHOULD_SKIP_THIS)00127 EzspStatus ashSetupSerialPort(int* serialPortFdReturn,00128 char* errorStringLocation,00129 int maxErrorLength,00130 boolean bootloaderMode);00131 #endif00132

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ash-host-io_8h-source.htm (2 of 2) [10/29/2010 2:44:39 PM]

650

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 651: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ash-host-queues.h Source File

app » ezsp-uart-host

ash-host-queues.h

Go to the documentation of this file.

00001 00016 #ifndef __ASH_HOST_QUEUE_H__00017 #define __ASH_HOST_QUEUE_H__00018 00024 #define TX_POOL_BUFFERS (EZSP_HOST_ASH_RX_POOL_SIZE + 5)00025 00029 #define RX_FREE_LWM 800030 #define RX_FREE_HWM 1200031 00034 typedef struct ashBuffer {00035 struct ashBuffer *link; 00036 int8u len; 00037 int8u data[ASH_MAX_DATA_FIELD_LEN];00038 } AshBuffer;00039 00042 typedef struct {00043 AshBuffer *tail;00044 } AshQueue;00045 00048 typedef struct {00049 AshBuffer *link;00050 } AshFreeList;00051 00057 void ashInitQueues(void);00058 00064 void ashFreeBuffer(AshFreeList *list, AshBuffer *buffer);00065 00072 AshBuffer *ashAllocBuffer(AshFreeList *list);00073 00081 AshBuffer *ashRemoveQueueHead(AshQueue *queue);00082 00090 AshBuffer *ashQueueHead(AshQueue *queue);00091 00101 AshBuffer *ashQueueNthEntry(AshQueue *queue, int8u n);00102 00113 AshBuffer *ashQueuePrecedingEntry(AshQueue *queue, AshBuffer *buffer);00114 00123 AshBuffer *ashRemoveQueueEntry(AshQueue *queue, AshBuffer *buffer);00124 00131 int8u ashQueueLength(AshQueue *queue);00132

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ash-host-queues_8h-source.htm (1 of 2) [10/29/2010 2:44:39 PM]

651

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 652: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ash-host-queues.h Source File

00133 00140 int8u ashFreeListLength(AshFreeList *list);00141 00147 void ashAddQueueTail(AshQueue *queue, AshBuffer *buffer);00148 00155 boolean ashQueueIsEmpty(AshQueue *queue);00156 00157 extern AshQueue txQueue;00158 extern AshQueue reTxQueue;00159 extern AshQueue rxQueue;00160 extern AshFreeList txFree;00161 extern AshFreeList rxFree;00162 00163 #endif //__ASH_HOST_QUEUE_H___00164

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ash-host-queues_8h-source.htm (2 of 2) [10/29/2010 2:44:39 PM]

652

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 653: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ash-host-ui.h Source File

app » ezsp-uart-host

ash-host-ui.h

Go to the documentation of this file.

00001 00016 #ifndef __ASH_HOST_UI_H__00017 #define __ASH_HOST_UI_H__00018 00023 void ashPrintUsage(char *name);00024 00033 boolean ashProcessCommandOptions(int argc, char *argv[]);00034 00043 void ashTraceEvent(const char *string);00044 00051 void ashPrintCounters(AshCount *counters, boolean clear);00052 00057 void ashClearCounters(AshCount *counters);00058 00065 const int8u* ashErrorString(int8u error);00066 00073 const int8u* ashEzspErrorString(int8u error);00074 00075 #define BUMP_HOST_COUNTER(mbr) do {ashCount.mbr++;} while (0)00076 #define ADD_HOST_COUNTER(op, mbr) do {ashCount.mbr += op;} while(0)00077 00078 #endif //__ASH_HOST_UI_H___00079

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ash-host-ui_8h-source.htm [10/29/2010 2:44:39 PM]

653

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 654: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: _EM260_API.top Source File

_EM260_API.top

Go to the documentation of this file.

00001

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/__EM260__API_8top-source.htm [10/29/2010 2:44:40 PM]

654

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 655: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: ash-host-priv.h Source File

app » ezsp-uart-host

ash-host-priv.h

Go to the documentation of this file.

00001 00018 #ifndef __ASH_HOST_PRIV_H__00019 #define __ASH_HOST_PRIV_H__00020 00021 // Defined in ash-host-ui.c00022 void ashTraceFrame(boolean sent);00023 void ashTraceEventRecdFrame(const char *string);00024 void ashTraceEventTime(const char *string);00025 void ashTraceDisconnected(int8u error);00026 void ashTraceArray(int8u *name, int8u len, int8u *data);00027 void ashTraceEzspFrameId(const char *message, int8u *ezspFrame);00028 void ashTraceEzspVerbose(char *format, ...);00029 void ashCountFrame(boolean sent);00030 00031 // Defined in ash-host.c00032 int8u readTxControl(void);00033 int8u readRxControl(void);00034 int8u readAckRx(void);00035 int8u readAckTx(void);00036 int8u readFrmTx(void);00037 int8u readFrmReTx(void);00038 int8u readFrmRx(void);00039 int8u readAshTimeouts(void);00040 00041 #endif //__ASH_HOST_PRIV_H___00042

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/ash-host-priv_8h-source.htm [10/29/2010 2:44:40 PM]

655

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 656: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: bootloader.h Source File

hal » micro » avr-atmega » 128

bootloader.h

Go to the documentation of this file.

00001 00015 #ifndef __BOOTLOADER_H__00016 #define __BOOTLOADER_H__00017 00018 #ifndef DOXYGEN_SHOULD_SKIP_THIS00019 00020 // Definitions relevant to the application bootloader.00021 // Defines the starting segment offset for the download segment 00022 // within the program space.00023 #define BOOTLOADER_DEFAULT_DOWNLOAD_SEGMENT 000024 // Defines the starting segment offset for the currently executing program00025 // within the program space.00026 #define BOOTLOADER_DEFAULT_PROGRAM_SEGMENT 400027 // Defines the starting segment offset for the recovery image00028 // within the program space.00029 #define BOOTLOADER_RECOVERY_IMAGE_SEGMENT 0x03E000030 00031 00032 // This points to where the trap table is stored in the internal flash00033 #define APP_TRAPTABLE_POINTER 0x1FFC000034 00035 // Definition for the recovery image (a bit not used by UCSR1A for errors).00036 #define NO_SERIAL_DATA 0x8000037 00042 00043 #if __HAS_ELPM__00044 #define halInternalReadFlashByte(addr) __extended_load_program_memory(addr)00045 #define halInternalReadFlashWord(addr) HIGH_LOW_TO_INT( \00046 __extended_load_program_memory((addr)+1),\00047 __extended_load_program_memory(addr) )00048 #else // __HAS_ELPM__00049 00056 #define halInternalReadFlashByte(addr) __load_program_memory(addr)00057 00064 #define halInternalReadFlashWord(addr) HIGH_LOW_TO_INT( \00065 __load_program_memory((addr)+1), \00066 __load_program_memory(addr) )00067 #endif // __HAS_ELPM__00068 00070 00071 #endif // DOXYGEN_SHOULD_SKIP_THIS00072 00073 #endif // __BOOTLOADER_H_

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/bootloader_8h-source.htm [10/29/2010 2:44:41 PM]

656

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 657: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: cbke-crypto-engine.h Source File

stack » include

cbke-crypto-engine.h

Go to the documentation of this file.

00001 00030 EmberStatus emberGetCertificate(EmberCertificateData* result);00031 00047 EmberStatus emberGenerateCbkeKeys(void);00048 00071 EmberStatus emberCalculateSmacs(boolean amInitiator,00072 EmberCertificateData* partnerCert, 00073 EmberPublicKeyData* partnerEphemeralPublicKey);00074 00089 EmberStatus emberClearTemporaryDataMaybeStoreLinkKey(boolean storeLinkKey);00090 00091 /* @brief LEGACY FUNCTION: This functionality has been replaced by a single00092 * bit in the ::EmberApsFrame, ::EMBER_APS_OPTION_DSA_SIGN. Devices wishing00093 * to send signed messages should use that as it requires fewer function calls00094 * and message buffering. emberDsaSignHandler() is still called when using00095 * ::EMBER_APS_OPTION_DSA_SIGN is used. However this function is still 00096 * supported.00097 *00098 * This function begins the process of signing the passed message00099 * contained within the buffer. If no other ECC operation is going on,00100 * it will immediately return with ::EMBER_OPERATION_IN_PROGRESS. 00101 * It will delay a period of time to let APS retries take place, but then it 00102 * will shutdown the radio and consume the CPU processing until the signing 00103 * is complete. This may take up to 1 second.00104 *00105 * The signed message will be returned in ::emberDsaSignHandler().00106 *00107 * @param messageToSign The message buffer where the complete message contained.00108 * 00109 * @return ::EMBER_OPERATION_IN_PROGRESS if the stack has queued up the00110 * operation for execution.00111 */00112 EmberStatus emberDsaSign(EmberMessageBuffer messageToSign);00113 00114 00115 /* @brief This function is an application callback that must be defined00116 * when using CBKE. It is called when the ephemeral key generation operation00117 * is complete. The newly generated public key is passed back to the 00118 * application to be sent to the CBKE partner over-the-air. Internally00119 * the stack saves the public and private key pair until it the function00120 * ::emberClearTemporaryDataMaybeStoreLinkKey() is called by the application.00121 *00122 * @param status This is the ::EmberStatus value indicating the success or 00123 * failure of the operation.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/cbke-crypto-engine_8h-source.htm (1 of 4) [10/29/2010 2:44:42 PM]

657

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 658: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: cbke-crypto-engine.h Source File

00124 * @param ephemeralPublicKey A pointer to an ::EmberPublicKeyData structure00125 * containing the newly generated public key.00126 */00127 void emberGenerateCbkeKeysHandler(EmberStatus status,00128 EmberPublicKeyData* ephemeralPublicKey);00129 00130 /* @brief This function is an application callback that must be defined00131 * when using CBKE. It is called when the shared secret generation is00132 * complete and the link key and SMACs have been derived. The link key is00133 * stored in a temporary location until the application decides to00134 * store or discard the key by calling00135 * ::emberClearTemporaryDataMaybeStoreLinkKey(). 00136 *00137 * @param status This is the ::EmberStatus value indicating the success or 00138 * failure of the operation.00139 * @param initiatorSmac This is a pointer to the ::EmberSmacData structure00140 * to the initiator's version of the SMAC.00141 * @param responderSmac This is a pointer to the ::EmberSmacData structure00142 * to the responder's version of the SMAC.00143 */00144 void emberCalculateSmacsHandler(EmberStatus status,00145 EmberSmacData* initiatorSmac,00146 EmberSmacData* responderSmac);00147 00148 /* @brief This function is an application callback that must be defined00149 * when using CBKE. This callback is provided to the application to let00150 * it know that the ECC operations have completed and the radio has been turned00151 * back on. When using the sign-and-send option of the ::EmberApsFrame, 00152 * ::EMBER_APS_OPTION_DSA_SIGN, the handler will NOT return the complete00153 * signed message. This callback is merely informative. If ::emberDsaSign() 00154 * has been called, the message plus signature will be returned to the caller00155 * and it must be sent separately by one of the message send primitives00156 * (such as ::emberSendUnicast()).00157 * 00158 * @param status This is the ::EmberStatus value indicating the success or 00159 * failure of the operation.00160 * @param signedMessage This is the ::EmberMessageBuffer indicating the newly00161 * signed message, if ::emberDsaSign() was called. If message was signed00162 * using ::EMBER_APS_OPTION_DSA_SIGN then this will be00163 * ::EMBER_NULL_MESSAGE_BUFFER.00164 */00165 void emberDsaSignHandler(EmberStatus status, 00166 EmberMessageBuffer signedMessage);00167 00168 00169 /* @brief This function is used to update the Smart Energy certificate,00170 * CA public key, and local private key that the device uses for CBKE.00171 * The preferred method for adding certificates is to pre-install them00172 * in MFG tokens when the chip is manufactured. However this function00173 * allows the certificate to be updated at runtime after the device has00174 * been deployed. 00175 * The behavior of this function differs based on the hardware platform.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/cbke-crypto-engine_8h-source.htm (2 of 4) [10/29/2010 2:44:42 PM]

658

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 659: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: cbke-crypto-engine.h Source File

00176 * 00177 * For the 2xx:00178 * To use this functionality the application must also set00179 * the stack configuration value ::EMBER_CERTIFICATE_TABLE_SIZE to 1.00180 * Attempts to call this function with ::EMBER_CERTIFICATE_TABLE_SIZE of 000181 * will return ::EMBER_SECURITY_CONFIGURATION_INVALID.00182 * The passed security data will be persistently stored in stack tokens.00183 * The certificate contains the EUI64 it is associated with. If that00184 * EUI64 matches the EUI64 currently in use by the device, this00185 * function may be called at any time, even while running in a network.00186 * If the EUI64 does not match, this function may only be called when the00187 * network is in a state of ::EMBER_NO_NETWORK. Attempts to do otherwise00188 * will result in a return value of ::EMBER_INVALID_CALL.00189 *00190 * For the 3xx:00191 * This function allows a one-time write of the MFG token if it has not00192 * already been set. It does NOT utilize the ::EMBER_CERTIFICATE_TABLE_SIZE00193 * so that should remain set at 0. Attempts to write the certificate that00194 * has already been written will return a result of00195 * ::EMBER_ERR_FLASH_WRITE_INHIBITED. If the EUI64 in the certificate is00196 * the same as the current EUI of the device then this function may be called00197 * while the stack is up. If the EUI in the certificate is different than00198 * the current value, this function may only be called when the network is in00199 * a state of ::EMBER_NO_NETWORK. Attempts to do otherwise will result in a00200 * return value of ::EMBER_INVALID_CALL. If the EUI in the certificate is00201 * different than the current value this function will also write the 00202 * Custom EUI64 MFG token. If that token has already been written the operation00203 * will fail and return a result of ::EMBER_BAD_ARGUMENT.00204 * If all the above criteria is met the token will be written and 00205 * ::EMBER_SUCCESS will be returned.00206 * 00207 * @note The device will immediately and persistently <b>change its EUI6400208 * to match the value in the certificate</b>. 00209 *00210 * @param caPublic A pointer to the CA public key data that will be stored00211 * in stack tokens.00212 * @param myCert A pointer to the certificate data that will be stored in00213 * stack tokens.00214 * @param mykey A pointer to the private key data that will be stored in00215 * stack tokens.00216 * @return The ::EmberStatus value indicating success or failure of the 00217 * operation.00218 */00219 EmberStatus emberSetPreinstalledCbkeData(EmberPublicKeyData* caPublic,00220 EmberCertificateData* myCert,00221 EmberPrivateKeyData* myKey);00222 00223 /* @brief This function retrieves the EUI64 from the stack token 00224 * Smart Energy Certificate (it does not examine the MFG token certificate)00225 * and returns the value in the "Subject" field (the EUI64) to the caller.00226 * If no stack token is set, the ::EMBER_CERTIFICATE_TABLE_SIZE is zero00227 * or if the CBKE library is not present, this function returns FALSE00228 * and the EUI64 for the return value is not set.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/cbke-crypto-engine_8h-source.htm (3 of 4) [10/29/2010 2:44:42 PM]

659

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 660: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: cbke-crypto-engine.h Source File

00229 *00230 * @param certEui64 The location of the return value for the EUI64.00231 * @return TRUE if the stack token certificate is set and the EUI6400232 * return value is valid. FALSE otherwise.00233 */00234 boolean emberGetStackCertificateEui64(EmberEUI64 certEui64);00235 00236 /* @brief This function verifies the ECDSA signature of the00237 * calculated digest and the associated received signature, using00238 * the signerCertificate passed in. It is expected that the application00239 * obtains the signerCertificate and perfoms the message digest calculation00240 * on its own.00241 */00242 EmberStatus emberDsaVerify(EmberMessageDigest* digest,00243 EmberCertificateData* signerCertificate,00244 EmberSignatureData* receivedSig);00245 00246 /* @brief This callback is executed by the stack when the DSA verification00247 * has completed and has a result. If the result is EMBER_SUCCESS, the 00248 * signature is valid. If the result is EMBER_SIGNATURE_VERIFY_FAILURE00249 * then the signature is invalid. If the result is anything else then the00250 * signature verify operation failed and the validity is unknown.00251 */00252 void emberDsaVerifyHandler(EmberStatus status);00253 00254

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/cbke-crypto-engine_8h-source.htm (4 of 4) [10/29/2010 2:44:42 PM]

660

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 661: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: form-and-join.h Source File

app » util » common

form-and-join.h

Go to the documentation of this file.

00001 00086 EmberStatus emberScanForUnusedPanId(int32u channelMask, int8u duration);00087 00114 EmberStatus emberScanForJoinableNetwork(int32u channelMask, int8u* extendedPanId);00115 00117 EmberStatus emberScanForNextJoinableNetwork(void);00118 00134 extern boolean emberEnableDualChannelScan;00135 00140 boolean emberFormAndJoinIsScanning(void);00141 00142 //------------------------------------------------------------------------------00143 // Callbacks the application needs to implement.00144 00153 void emberUnusedPanIdFoundHandler(EmberPanId panId, int8u channel);00154 00165 void emberJoinableNetworkFoundHandler(EmberZigbeeNetwork *networkFound,00166 int8u lqi,00167 int8s rssi);00168 00186 void emberScanErrorHandler(EmberStatus status);00187 00188 //------------------------------------------------------------------------------00189 // Library functions the application must call from within the00190 // corresponding EmberZNet or EZSP callback. 00191 00199 boolean emberFormAndJoinScanCompleteHandler(int8u channel, EmberStatus status);00200 00208 boolean emberFormAndJoinNetworkFoundHandler(EmberZigbeeNetwork *networkFound,00209 int8u lqi,00210 int8s rssi);00211 00219 boolean emberFormAndJoinEnergyScanResultHandler(int8u channel, int8s maxRssiValue);00220 00225 void emberFormAndJoinTick(void);00226 00230 void emberFormAndJoinTaskInit(void);00231 00235 void emberFormAndJoinRunTask(void);00236 00237

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/form-and-join_8h-source.htm (1 of 2) [10/29/2010 2:44:43 PM]

661

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 662: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: form-and-join.h Source File

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/form-and-join_8h-source.htm (2 of 2) [10/29/2010 2:44:43 PM]

662

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 663: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: form-and-join3_2.h Source File

app » util » common

form-and-join3_2.h

Go to the documentation of this file.

00001 00018 #ifdef DOXYGEN_SHOULD_SKIP_THIS00019 00021 enum formAndJoinScanType00022 #else00023 extern int8u formAndJoinScanType;00024 enum00025 #endif00026 {00027 FORM_AND_JOIN_NOT_SCANNING,00028 FORM_AND_JOIN_ENERGY_SCAN, 00029 FORM_AND_JOIN_PAN_ID_SCAN, 00030 FORM_AND_JOIN_JOINABLE_SCAN, 00031 FORM_AND_JOIN_CROSSTALK_SCAN 00032 };00033 00034 00055 void formZigbeeNetwork3_2(int32u channelMask, 00056 int8s radioTxPower,00057 int8u* extendedPanIdDesired);00058 00088 void joinZigbeeNetwork3_2(EmberNodeType nodeType,00089 int32u channelMask,00090 int8s radioTxPower,00091 int8u* extendedPanIdDesired);00092 00100 void scanError(EmberStatus status);00101

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/form-and-join3__2_8h-source.htm [10/29/2010 2:44:43 PM]

663

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 664: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: fragment-host.h Source File

app » util » zigbee-framework

fragment-host.h

Go to the documentation of this file.

00001 00055 void ezspFragmentInit(int16u receiveBufferLength, int8u *receiveBuffer);00056 00091 EmberStatus ezspFragmentSendUnicast(EmberOutgoingMessageType type,00092 int16u indexOrDestination,00093 EmberApsFrame *apsFrame,00094 int8u maxFragmentSize,00095 int16u messageLength,00096 int8u *messageContents);00097 00110 EmberStatus ezspFragmentSourceRouteHandler(void);00111 00126 boolean ezspFragmentMessageSent(EmberApsFrame *apsFrame, EmberStatus status);00127 00136 void ezspFragmentMessageSentHandler(EmberStatus status);00137 00169 boolean ezspFragmentIncomingMessage(EmberApsFrame *apsFrame,00170 EmberNodeId sender,00171 int16u *messageLength,00172 int8u **messageContents);00173 00178 void ezspFragmentTick(void);00179

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/fragment-host_8h-source.htm [10/29/2010 2:44:43 PM]

664

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 665: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: hal.h Source File

hal

hal.h

Go to the documentation of this file.

00001 00063 #ifndef __HAL_H__00064 #define __HAL_H__00065 00066 #ifdef HAL_HOST00067 00068 #include "host/button-common.h"00069 #include "host/crc.h"00070 #include "host/led-common.h"00071 #include "host/micro-common.h"00072 #include "host/serial.h"00073 #include "host/system-timer.h"00074 //Pull in the micro specific ADC, buzzer, and clocks headers. The00075 //specific header is chosen by the build include path pointing at00076 //the appropriate directory.00077 #include "adc.h"00078 #include "buzzer.h"00079 00080 #else //HAL_MICRO00081 00082 // Keep micro and board first for specifics used by other headers00083 #include "micro/micro.h"00084 #if !defined(STACK) && defined(BOARD_HEADER)00085 #include BOARD_HEADER00086 #endif00087 00088 #include "micro/adc.h"00089 #include "micro/button.h"00090 #include "micro/buzzer.h"00091 #include "micro/crc.h"00092 #include "micro/endian.h"00093 #include "micro/led.h"00094 #include "micro/random.h"00095 #include "micro/serial.h"00096 #include "micro/spi.h"00097 #include "micro/system-timer.h"00098 //Host processors do not use the following modules, therefore the header00099 //files should be ignored.00100 #ifndef EZSP_HOST00101 #include "micro/bootloader-interface.h"00102 #include "micro/diagnostic.h"00103 #include "micro/token.h"00104 //No public HAL code in release 4.0 uses the symbol timer,

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/hal_8h-source.htm (1 of 2) [10/29/2010 2:44:44 PM]

665

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 666: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: hal.h Source File

00105 //therefore it should not be in doxygen.00106 #ifndef DOXYGEN_SHOULD_SKIP_THIS00107 #include "micro/symbol-timer.h"00108 #endif // DOXYGEN_SHOULD_SKIP_THIS00109 #endif //EZSP_HOST00110 00111 #endif00112 00113 #endif //__HAL_H__00114

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/hal_8h-source.htm (2 of 2) [10/29/2010 2:44:44 PM]

666

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 667: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: iar.h Source File

hal » micro » avr-atmega » compiler

iar.h

Go to the documentation of this file.

00001 00020 #ifndef __IAR_H__00021 #define __IAR_H__00022 00023 #ifndef __ICCAVR__00024 #error Improper PLATFORM_HEADER00025 #endif00026 00027 00028 #ifndef DOXYGEN_SHOULD_SKIP_THIS00029 #include <inavr.h>00030 #define ENABLE_BIT_DEFINITIONS00031 #include <ioavr.h>00032 #include <stdarg.h>00033 #endif // DOXYGEN_SHOULD_SKIP_THIS00034 00035 // suppress warnings about unknown pragmas00036 // (as they may be pragmas known to other platforms)00037 #pragma diag_suppress = pe16100038 00047 typedef unsigned char boolean;00048 typedef unsigned char int8u;00049 typedef signed char int8s;00050 typedef unsigned int int16u;00051 typedef signed int int16s;00052 typedef unsigned long int32u;00053 typedef signed long int32s;00054 typedef unsigned int PointerType;00056 00057 00058 // AVR uses custom PGM definitions00063 #if defined(__HAS_ELPM__) || defined(DOXYGEN_SHOULD_SKIP_THIS)00064 00067 #define PGM __farflash00068 00072 #define PGM_P const char __farflash *00073 00077 #define PGM_PU const unsigned char __farflash *00078 #else00079 #define PGM __flash00080 #define PGM_P const char __flash *00081 #define PGM_PU const unsigned char __flash *00082 #endif

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/iar_8h-source.htm (1 of 7) [10/29/2010 2:44:45 PM]

667

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 668: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: iar.h Source File

00083 00084 00090 #define PGM_NO_CONST PGM00091 00092 00093 00095 00097 00098 00099 00104 #define MAIN_FUNCTION_PARAMETERS void00105 #define MAIN_FUNCTION_ARGUMENTS 00106 00107 00112 #define BIGENDIAN_CPU FALSE00113 00114 00119 #define NO_STRIPPING __root00120 00121 00126 #define EEPROM __eeprom00127 00128 00129 #ifndef __SOURCEFILE__00130 00135 #define __SOURCEFILE__ __FILE__00136 #endif00137 00138 00139 #undef assert00140 #if !defined(SIMPLER_ASSERT_REBOOT) || defined(DOXYGEN_SHOULD_SKIP_THIS)00141 00145 void halInternalAssertFailed(PGM_P filename, int linenumber);00146 00152 #define assert(condition) \00153 do { if (! (condition)) \00154 halInternalAssertFailed(__SOURCEFILE__, __LINE__); } while(0)00155 #else00156 #define assert(condition) \00157 do { if( !(condition) ) while(1){} } while(0)00158 #endif00159 00160 00161 #ifndef BOOTLOADER00162 #undef __delay_cycles00163 00169 #define __delay_cycles(x) please_use_halCommonDelayMicroseconds_instead_of_delay_cycles00170 #endif00171 00176 #ifndef DEBUG_LEVEL00177 #ifdef DEBUG00178 #define DEBUG_LEVEL FULL_DEBUG

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/iar_8h-source.htm (2 of 7) [10/29/2010 2:44:45 PM]

668

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 669: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: iar.h Source File

00179 #else00180 #define DEBUG_LEVEL NO_DEBUG00181 #endif00182 #endif00183 00189 #define halResetWatchdog() __watchdog_reset()00190 00191 00195 #define __attribute__(nothing)00196 00197 00202 #define UNUSED00203 00204 00208 #define SIGNED_ENUM00209 00210 00214 #define simulatedTimePasses()00215 00218 #define simulatedTimePassesMs(x)00219 00222 #define simulatedSerialTimePasses()00223 00225 00226 00227 00228 00230 00232 00233 00234 #ifdef BOOTLOADER00235 #ifndef DOXYGEN_SHOULD_SKIP_THIS00236 // The bootloader does not use interrupts00237 #define DECLARE_INTERRUPT_STATE00238 #define DISABLE_INTERRUPTS() do { } while(0)00239 #define RESTORE_INTERRUPTS() do { } while(0)00240 #define INTERRUPTS_ON() do { } while(0)00241 #define INTERRUPTS_OFF() do { } while(0)00242 #define INTERRUPTS_ARE_OFF() (FALSE)00243 #define ATOMIC(blah) { blah }00244 #define ATOMIC_LITE(blah) { blah }00245 #define HANDLE_PENDING_INTERRUPTS() do { } while(0)00246 #endif // DOXYGEN_SHOULD_SKIP_THIS00247 #else // BOOTLOADER00248 00249 #ifndef DOXYGEN_SHOULD_SKIP_THIS00250 // A series of macros for the diagnostics of the global interrupt state.00251 // These macros either enable or disable the debugging code in the00252 // Interrupt Manipulation Macros as well as define the two pins used for00253 // indicating the entry and exit of critical sections.00254 00255 //UNCOMMENT the below #define to enable interrupt debugging.

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/iar_8h-source.htm (3 of 7) [10/29/2010 2:44:45 PM]

669

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 670: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: iar.h Source File

00256 //#define INTERRUPT_DEBUGGING00257 #ifdef INTERRUPT_DEBUGGING00258 #define INT_DEBUG(x) x00259 #else00260 #define INT_DEBUG(x)00261 #endif00262 00263 #ifdef INTERRUPT_DEBUGGING00264 #define CLR_PORT_BIT(p, b) PORT##p &= ~BIT(b)00265 #define SET_PORT_BIT(p, b) PORT##p |= BIT(b)00266 #define BLIP_PORT_BIT(p, b) PORT##p |= BIT(b); PORT##p &= ~BIT(b)00267 #else00268 #define CLR_PORT_BIT(p, b)00269 #define SET_PORT_BIT(p, b)00270 #define BLIP_PORT_BIT(p, b)00271 #endif00272 00273 // GPIO outputs for measuring the duration of global interrupt state and00274 // specific interrupt service routines. The comments below give the meaning00275 // of the output when it is HIGH. 00276 // Pin assignments refer to the dev0222 board.00277 // LED 2 (PORTC.2): interrupts are disabled (includes ATOMIC blocks)00278 // LED 3 (PORTC.3): radio receive isr00279 // LED 4 (PORTC.4): radio transmit isr (symbol timer compare)00280 // LED 5 (PORTC.5): an isr other than radio, uart or system timer00281 // GPIO 0 (PORTG.0): uart 1 receive isr00282 // GPIO 1 (PORTG.1): uart 1 transmit isr00283 // GPIO 2 (PORTG.2): general purpose time marker00284 // GPIO 3 (PORTE.2): system/sleep timer isr00285 // GPIO 5 (PORTE.7): uart 1 receive isr error00286 #define INT_DEBUG_INTS_OFF() SET_PORT_BIT(C, 2)00287 #define INT_DEBUG_INTS_ON() CLR_PORT_BIT(C, 2)00288 #define INT_DEBUG_BEG_RADIO_RX() INT_DEBUG_INTS_OFF(); SET_PORT_BIT(C, 3)00289 #define INT_DEBUG_END_RADIO_RX() CLR_PORT_BIT(C, 3); INT_DEBUG_INTS_ON()00290 #define INT_DEBUG_BEG_SYMBOL_CMP() INT_DEBUG_INTS_OFF(); SET_PORT_BIT(C,4)00291 #define INT_DEBUG_END_SYMBOL_CMP() CLR_PORT_BIT(C,4); INT_DEBUG_INTS_ON()00292 #define INT_DEBUG_BEG_MISC_INT() INT_DEBUG_INTS_OFF(); SET_PORT_BIT(C, 5)00293 #define INT_DEBUG_END_MISC_INT() CLR_PORT_BIT(C, 5); INT_DEBUG_INTS_ON()00294 #define INT_DEBUG_BEG_UART1_RX() INT_DEBUG_INTS_OFF(); SET_PORT_BIT(G, 0)00295 #define INT_DEBUG_END_UART1_RX() CLR_PORT_BIT(G, 0); INT_DEBUG_INTS_ON()00296 #define INT_DEBUG_BEG_UART1_TX() INT_DEBUG_INTS_OFF(); SET_PORT_BIT(G, 1)00297 #define INT_DEBUG_END_UART1_TX() CLR_PORT_BIT(G, 1); INT_DEBUG_INTS_ON()00298 #define INT_DEBUG_TIME_MARKER(n) BLIP_PORT_BIT(G, 2)00299 #define INT_DEBUG_BEG_SYSTIME_CMP() INT_DEBUG_INTS_OFF(); SET_PORT_BIT(E, 2)00300 #define INT_DEBUG_END_SYSTIME_CMP() CLR_PORT_BIT(E, 2); INT_DEBUG_INTS_ON()00301 #define INT_DEBUG_BEG_UART1_RXERR() SET_PORT_BIT(E, 7)00302 #define INT_DEBUG_END_UART1_RXERR() CLR_PORT_BIT(E, 7)00303 00304 00305 00306 //UNCOMMENT the below #define to enable timing diabled interrupt blocks,00307 // except for "LITE" blocks that are never timed.00308 //#define ENABLE_ATOMIC_CLOCK

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/iar_8h-source.htm (4 of 7) [10/29/2010 2:44:45 PM]

670

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 671: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: iar.h Source File

00309 00310 #endif // DOXYGEN_SHOULD_SKIP_THIS00311 00312 //The core Global Interrupt Manipulation Macros start here.00313 00314 #ifdef ENABLE_ATOMIC_CLOCK00315 #define START_ATOMIC_CLOCK() \00316 do { \00317 if (INTERRUPTS_WERE_ON()) \00318 halStartAtomicClock(); \00319 } \00320 while(0)00321 #define STOP_ATOMIC_CLOCK() \00322 do { \00323 if (INTERRUPTS_WERE_ON()) \00324 halStopAtomicClock(); \00325 } \00326 while(0)00327 #else00328 #define START_ATOMIC_CLOCK()00329 #define STOP_ATOMIC_CLOCK()00330 #endif00331 00337 #define DECLARE_INTERRUPT_STATE int8u _emIsrState00338 #define DECLARE_INTERRUPT_STATE_LITE int8u _emIsrState00339 00340 00349 #define DISABLE_INTERRUPTS() \00350 _emIsrState = __save_interrupt(); \00351 do { \00352 INT_DEBUG_INTS_OFF(); \00353 __disable_interrupt(); \00354 START_ATOMIC_CLOCK(); \00355 } while(0)00356 00357 #define DISABLE_INTERRUPTS_LITE() \00358 _emIsrState = __save_interrupt(); \00359 do { \00360 INT_DEBUG_INTS_OFF(); \00361 __disable_interrupt(); \00362 } while(0)00363 00364 00374 #define RESTORE_INTERRUPTS() \00375 do { \00376 STOP_ATOMIC_CLOCK(); \00377 INT_DEBUG( \00378 if (INTERRUPTS_WERE_ON()) \00379 INT_DEBUG_INTS_ON(); \00380 ) \00381 __restore_interrupt(_emIsrState); \00382 } while(0)

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/iar_8h-source.htm (5 of 7) [10/29/2010 2:44:45 PM]

671

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 672: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: iar.h Source File

00383 00384 #define RESTORE_INTERRUPTS_LITE() \00385 do { \00386 INT_DEBUG( \00387 if (INTERRUPTS_WERE_ON()) \00388 INT_DEBUG_INTS_ON(); \00389 ) \00390 __restore_interrupt(_emIsrState); \00391 } while(0)00392 00393 00398 #define INTERRUPTS_ON() \00399 do { \00400 INT_DEBUG_INTS_ON(); \00401 __enable_interrupt(); \00402 } while(0)00403 00404 00409 #define INTERRUPTS_OFF() \00410 do { \00411 __disable_interrupt(); \00412 INT_DEBUG_INTS_OFF(); \00413 } while(0)00414 00415 00420 #define INTERRUPTS_WERE_ON() (_emIsrState & BIT(7))00421 00422 00426 #define INTERRUPTS_ARE_OFF() (!(__save_interrupt() & BIT(7))) 00427 00428 00436 #define ATOMIC(code) \00437 { \00438 DECLARE_INTERRUPT_STATE; \00439 DISABLE_INTERRUPTS(); \00440 { code } \00441 RESTORE_INTERRUPTS(); \00442 }00443 00444 #define ATOMIC_LITE(code) \00445 { \00446 DECLARE_INTERRUPT_STATE_LITE; \00447 DISABLE_INTERRUPTS_LITE(); \00448 { code } \00449 RESTORE_INTERRUPTS_LITE(); \00450 }00451 00452 00464 #define HANDLE_PENDING_INTERRUPTS() \00465 do { \00466 if (INTERRUPTS_ARE_OFF()) { \00467 INTERRUPTS_ON(); \

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/iar_8h-source.htm (6 of 7) [10/29/2010 2:44:45 PM]

672

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 673: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: iar.h Source File

00468 __no_operation(); \00469 __no_operation(); \00470 __no_operation(); \00471 INTERRUPTS_OFF(); \00472 } \00473 } while (0)00474 00475 00476 #endif // BOOTLOADER00478 00479 00480 00481 #define _HAL_USE_COMMON_MEMUTILS_00482 #define _HAL_USE_COMMON_DIVMOD_00483 00484 // Include platform-common last to pick up defaults and common definitions00485 #define PLATCOMMONOKTOINCLUDE00486 #include "hal/micro/generic/compiler/platform-common.h"00487 #undef PLATCOMMONOKTOINCLUDE00488 00489 #endif // __IAR_H__

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/iar_8h-source.htm (7 of 7) [10/29/2010 2:44:45 PM]

673

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 674: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: micro.h Source File

hal » micro » avr-atmega » 128

avr-atmega/128/micro.h

Go to the documentation of this file.

00001 00024 #ifndef __128_MICRO_H__00025 #define __128_MICRO_H__00026 00027 #ifndef DOXYGEN_SHOULD_SKIP_THIS00028 00029 #ifndef __MICRO_H__00030 #error do not include this file directly - include micro/micro.h00031 #endif00032 00033 #include "micro/avr-atmega/128/reserved-ram.h"00034 00036 // Serial definitions00037 00038 // Debug builds use 3 serial ports, one of which is a "virtual" port since the00039 // physical port is actually used for the debug channel itself00040 #if defined(DEBUG) && !defined(STACK)00041 #define EM_NUM_SERIAL_PORTS 300042 // Configures a specified serial port to operate in debug mode00043 #ifdef EMBER_SERIAL2_DEBUG00044 #error serial 2 not valid as a debug port00045 #endif00046 #if (!(defined(EMBER_SERIAL0_DEBUG))) && \00047 (!(defined(EMBER_SERIAL1_DEBUG)))00048 #error No valid EMBER_SERIALn_DEBUG definition present00049 #endif00050 #ifdef EMBER_SERIAL0_DEBUG00051 #define EMBER_SERIAL2_MODE EMBER_SERIAL_BUFFER00052 #define EMBER_SERIAL2_TX_QUEUE_SIZE 1600053 #define EMBER_SERIAL2_RX_QUEUE_SIZE 32 // TBD, what is minimum size?00054 #endif00055 #ifdef EMBER_SERIAL1_DEBUG00056 #define EMBER_SERIAL2_MODE EMBER_SERIAL_BUFFER00057 #define EMBER_SERIAL2_TX_QUEUE_SIZE 1600058 #define EMBER_SERIAL2_RX_QUEUE_SIZE 32 // TBD, what is minimum size?00059 #endif00060 #else00061 #define EM_NUM_SERIAL_PORTS 200062 #endif00063 00064 #endif // DOXYGEN_SHOULD_SKIP_THIS00065 00066 00071 void halStackTriggerDebugTimeSyncCapture(void);

file:///C|/dev/perforce/software/v2/tephra-park/doxyge.../API_EM260_forPDF/avr-atmega_2128_2micro_8h-source.htm (1 of 2) [10/29/2010 2:44:46 PM]

674

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 675: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: micro.h Source File

00072 00073 00074 #ifndef DOXYGEN_SHOULD_SKIP_THIS00075 00076 // note: you must actually reserve the ram in low-level-init.c and 00077 // all the linker scripts. this just defines the addresses00078 //#define NORMAL_RAM_END 0x10E0 00079 00080 // ATMega128 / 64 differences00081 00082 #ifdef AVR_ATMEGA_6400083 #define ADCSR ADCSRA // For ATMEGA64, it is called ADCSRA00084 #endif00085 00086 #endif // DOXYGEN_SHOULD_SKIP_THIS00087 00088 // the number of ticks (as returned from halCommonGetInt32uMillisecondTick)00089 // that represent an actual second. This can vary on different platforms.00090 #define MILLISECOND_TICKS_PER_SECOND 102400091 00096 #define RESET_UNKNOWN 0 // cause not known00097 #define RESET_EXTERNAL 1 // reset pin was asserted00098 #define RESET_POWERON 2 // supply voltage was < power-on threshold00099 #define RESET_WATCHDOG 3 // watchdog low water mark caused NMI00100 #define RESET_BROWNOUT 4 // n/a (no hardware support)00101 #define RESET_JTAG 5 // reset by debugger00102 #define RESET_ASSERT 6 // a self-check within the code failed00103 #define RESET_RSTACK 7 // n/a (memory fault instead)00104 #define RESET_CSTACK 8 // n/a (memory fault instead)00105 #define RESET_BOOTLOADER 9 // requested by bootloader00106 #define RESET_PC_ROLLOVER 10 // n/a (memor fault instead)00107 #define RESET_SOFTWARE 11 // reset requested by software00108 #define RESET_PROTFAULT 12 // n/a (memoru fault instead)00109 #define RESET_FLASH_VERIFY_FAIL 13 // flash write verify failure00110 #define RESET_FLASH_WRITE_INHIBIT 14 // flash write inhibited: already written00111 #define RESET_BOOTLOADER_IMG_BAD 15 // app BTL: bad EEPROM upgrade image 00112 00113 #endif //__128_MICRO_H__

file:///C|/dev/perforce/software/v2/tephra-park/doxyge.../API_EM260_forPDF/avr-atmega_2128_2micro_8h-source.htm (2 of 2) [10/29/2010 2:44:46 PM]

675

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 676: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: random.h Source File

hal » micro

random.h

Go to the documentation of this file.

00001 00016 #ifndef __RANDOM_H__00017 #define __RANDOM_H__00018 00026 void halStackSeedRandom(int32u seed);00027 00036 #if defined( EMBER_TEST )00037 #define halCommonGetRandom() halCommonGetRandomTraced(__FILE__, __LINE__)00038 int16u halCommonGetRandomTraced(char *file, int line);00039 #else00040 int16u halCommonGetRandom(void);00041 #endif00042 00046 #endif //__RANDOM_H__00047 00048

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/random_8h-source.htm [10/29/2010 2:44:46 PM]

676

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 677: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: reserved-ram.h Source File

hal » micro » avr-atmega » 32

32/reserved-ram.h

Go to the documentation of this file.

00001 00043 #define HAL_RESERVED_RAM_PC_DIAG 0x085E00044 #define HAL_RESERVED_RAM_RESET_CAUSE 0x085D00045 #define HAL_RESERVED_RAM_RESET_CAUSE_B 0x085C00046 #define HAL_RESERVED_RAM_RSTACK_H 0x085B00047 #define HAL_RESERVED_RAM_RSTACK_L 0x085A00048 #define HAL_RESERVED_RAM_CSTACK_H 0x085900049 #define HAL_RESERVED_RAM_CSTACK_L 0x085800050 00051 00059 #define RESET_CAUSE_SELF_WDOG 000060 #define RESET_CAUSE_ASSERT_BIT 100061 #define RESET_CAUSE_CSTACK_BIT 200062 #define RESET_CAUSE_RSTACK_BIT 300063 #define RESET_CAUSE_BOOTLOADER_BIT 400064 #define RESET_CAUSE_SOFTWARE_BIT 500065 00066 00067 00075 #define SRAM_BASE 0x0060 // Start of ram memory00076 00077 00085 #define SRAM_END 0x0857 // End of normal ram memory (~2k + SFR offset - reserved ram) 00086 00087 00088 #ifndef DOXYGEN_SHOULD_SKIP_THIS00089 #ifndef __IAR_SYSTEMS_ASM__00090 extern __no_init __root volatile int8u emResetCause;00091 extern __no_init __root volatile int8u emResetCauseMarker;00092 extern __no_init __root volatile int16u emResetRStack;00093 extern __no_init __root volatile int16u emResetCStack;00094 #endif00095 #endif //DOXYGEN_SHOULD_SKIP_THIS

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/32_2reserved-ram_8h-source.htm [10/29/2010 2:44:46 PM]

677

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 678: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: reserved-ram.h Source File

hal » micro » avr-atmega » 128

128/reserved-ram.h

Go to the documentation of this file.

00001 00043 #define HAL_RESERVED_RAM_BOOTLOADER_KEY 0x10FE 00044 #define HAL_RESERVED_RAM_PC_DIAG 0x10FC00045 #define HAL_RESERVED_RAM_GATEWAY_ID 0x10F400046 #define HAL_RESERVED_RAM_EUI64_ID 0x10EC00047 #define HAL_RESERVED_RAM_PAN_ID 0x10EA00048 #define HAL_RESERVED_RAM_NODE_ID 0x10E800049 #define HAL_RESERVED_RAM_CHANNEL 0x10E700050 #define HAL_RESERVED_RAM_POWER 0x10E600051 #define HAL_RESERVED_RAM_BANDS 0x10E500052 #define HAL_RESERVED_RAM_MODE 0x10E400053 #define HAL_RESERVED_RAM_RESET_CAUSE 0x10E300054 #define HAL_RESERVED_RAM_RESET_CAUSE_B 0x10E200055 #define HAL_RESERVED_RAM_RSTACK_H 0x10E100056 #define HAL_RESERVED_RAM_RSTACK_L 0x10E000057 #define HAL_RESERVED_RAM_CSTACK_H 0x10DF00058 #define HAL_RESERVED_RAM_CSTACK_L 0x10DE00059 00060 00068 #define RESET_CAUSE_SELF_WDOG 000069 #define RESET_CAUSE_ASSERT_BIT 100070 #define RESET_CAUSE_CSTACK_BIT 200071 #define RESET_CAUSE_RSTACK_BIT 300072 #define RESET_CAUSE_BOOTLOADER_BIT 400073 #define RESET_CAUSE_SOFTWARE_BIT 500074 00075 00076 00084 #define SRAM_BASE 0x0100 // Start of ram memory00085 00086 00094 #define SRAM_END 0x10DD // End of normal ram memory (~4k + SFR offset - reserved ram) 00095 00096 00104 #define EXT_SRAM_END 0x7FFF // Largest possible external sram chip (32k) 00105 00106 00107 #ifndef DOXYGEN_SHOULD_SKIP_THIS00108 #ifndef __IAR_SYSTEMS_ASM__00109 extern __no_init __root volatile int8u emResetCause;00110 extern __no_init __root volatile int8u emResetCauseMarker;

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/128_2reserved-ram_8h-source.htm (1 of 2) [10/29/2010 2:44:47 PM]

678

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 679: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: reserved-ram.h Source File

00111 extern __no_init __root volatile int16u emResetRStack;00112 extern __no_init __root volatile int16u emResetCStack;00113 #endif00114 #endif //DOXYGEN_SHOULD_SKIP_THIS00115

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/128_2reserved-ram_8h-source.htm (2 of 2) [10/29/2010 2:44:47 PM]

679

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 680: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: spi-protocol.h Source File

hal » micro » avr-atmega

spi-protocol.h

Go to the documentation of this file.

00001 00020 #ifndef __SPI_PROTOCOL_H__00021 #define __SPI_PROTOCOL_H__00022 00023 #include "app/util/ezsp/ezsp-enum.h"00024 00029 00030 00038 extern int8u *halNcpFrame;00039 00047 extern int8u halNcpSpipErrorByte;00048 00052 void halNcpSerialInit(void);00053 00058 void halNcpSerialPowerup(void);00059 00063 void halNcpSerialPowerdown(void);00064 00077 EzspStatus halNcpHardReset(void);00078 00093 EzspStatus halNcpHardResetReqBootload(boolean requestBootload);00094 00104 void halNcpWakeUp(void);00105 00117 void halNcpSendCommand(void);00118 00130 void halNcpSendRawCommand(void);00131 00140 EzspStatus halNcpPollForResponse(void);00141 00149 void halNcpIsAwakeIsr(boolean isAwake);00150 00155 boolean halNcpHasData(void);00156 00157 00165 boolean halNcpVerifySpiProtocolVersion(void);00166 00174 boolean halNcpVerifySpiProtocolActive(void);00175 00177 00182 00183

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/spi-protocol_8h-source.htm (1 of 2) [10/29/2010 2:44:47 PM]

680

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 681: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: spi-protocol.h Source File

00203 void spipTest(int16u test, int16u params);00204 00206 00207 #endif // __SPI_PROTOCOL_H__00208

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/spi-protocol_8h-source.htm (2 of 2) [10/29/2010 2:44:47 PM]

681

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 682: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: spi.h Source File

hal » micro

spi.h

Go to the documentation of this file.

00001 00026 #ifndef __SPI_H__00027 #define __SPI_H__00028 00033 void halCommonInitSpi(void);00034 00040 void halCommonSpiWrite(int8u data);00041 00047 int8u halCommonSpiRead(void);00048 00056 int8u halCommonSpiReadWrite(int8u data);00057 00058 #endif //__SPI_H__00059

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/spi_8h-source.htm [10/29/2010 2:44:48 PM]

682

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 683: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: system-timer.h Source File

hal » micro » avr-atmega » 32

avr-atmega/32/system-timer.h

Go to the documentation of this file.

00001 00018 #ifndef __32_SYSTEM_TIMER_H__00019 #define __32_SYSTEM_TIMER_H__00020 00021 #ifndef __SYSTEM_TIMER_H__00022 #error do not include this file directly - include micro/system-timer.h00023 #endif00024 00030 void halCommonSetSystemTime(int32u time);00031 00032 #endif //__32_SYSTEM_TIMER_H__00033

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Ou...PI_EM260_forPDF/avr-atmega_232_2system-timer_8h-source.htm [10/29/2010 2:44:48 PM]

683

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 684: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: system-timer.h Source File

hal » micro » avr-atmega » 128

avr-atmega/128/system-timer.h

Go to the documentation of this file.

00001 00018 #ifndef __128_SYSTEM_TIMER_H__00019 #define __128_SYSTEM_TIMER_H__00020 00021 #ifndef __SYSTEM_TIMER_H__00022 #error do not include this file directly - include micro/system-timer.h00023 #endif00024 00030 void halCommonSetSystemTime(int32u time);00031 00032 #endif //__128_SYSTEM_TIMER_H__00033

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Ou...I_EM260_forPDF/avr-atmega_2128_2system-timer_8h-source.htm [10/29/2010 2:44:48 PM]

684

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 685: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: zigbee-device-host.h Source File

app » util » zigbee-framework

zigbee-device-host.h

Go to the documentation of this file.

00001 00104 EmberStatus emberNetworkAddressRequest(EmberEUI64 target,00105 boolean reportKids,00106 int8u childStartIndex);00107 00125 EmberStatus emberIeeeAddressRequest(EmberNodeId target,00126 boolean reportKids,00127 int8u childStartIndex,00128 EmberApsOption options);00156 EmberStatus ezspMatchDescriptorsRequest(EmberNodeId target,00157 int16u profile,00158 int8u inCount,00159 int8u outCount,00160 int16u *inClusters,00161 int16u *outClusters,00162 EmberApsOption options);00188 EmberStatus ezspEndDeviceBindRequest(EmberNodeId localNodeId,00189 EmberEUI64 localEui64,00190 int8u endpoint,00191 int16u profile,00192 int8u inCount,00193 int8u outCount,00194 int16u *inClusters,00195 int16u *outClusters,00196 EmberApsOption options);00215 EmberNodeId ezspDecodeAddressResponse(int8u *response,00216 EmberEUI64 eui64Return);00217

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/zigbee-device-host_8h-source.htm [10/29/2010 2:44:49 PM]

685

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 686: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: zigbee-device-stack.h Source File

stack » include

zigbee-device-stack.h

Go to the documentation of this file.

00001 00010 #ifndef __ZIGBEE_DEVICE_STACK_H__00011 #define __ZIGBEE_DEVICE_STACK_H__00012 00035 EmberStatus emberNetworkAddressRequest(EmberEUI64 target,00036 boolean reportKids,00037 int8u childStartIndex);00038 00055 EmberStatus emberIeeeAddressRequest(EmberNodeId target,00056 boolean reportKids,00057 int8u childStartIndex,00058 EmberApsOption options);00059 00079 EmberStatus emberEnergyScanRequest(EmberNodeId target,00080 int32u scanChannels,00081 int8u scanDuration,00082 int16u scanCount);00083 00097 #ifdef DOXYGEN_SHOULD_SKIP_THIS00098 EmberStatus emberSetNetworkManagerRequest(EmberNodeId networkManager,00099 int32u activeChannels);00100 #else00101 #define emberSetNetworkManagerRequest(manager, channels) \00102 (emberEnergyScanRequest(EMBER_SLEEPY_BROADCAST_ADDRESS, \00103 (channels), \00104 0xFF, \00105 (manager)))00106 #endif00107 00121 #ifdef DOXYGEN_SHOULD_SKIP_THIS00122 EmberStatus emberChannelChangeRequest(int8u channel);00123 #else00124 #define emberChannelChangeRequest(channel) \00125 (emberEnergyScanRequest(EMBER_SLEEPY_BROADCAST_ADDRESS, \00126 BIT32(channel), \00127 0xFE, \00128 0))00129 #endif00130 00141 EmberStatus emberSendDeviceAnnouncement(void);00142 00146 #endif // __ZIGBEE_DEVICE_STACK_H__

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/zigbee-device-stack_8h-source.htm (1 of 2) [10/29/2010 2:44:49 PM]

686

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 687: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: zigbee-device-stack.h Source File

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/zigbee-device-stack_8h-source.htm (2 of 2) [10/29/2010 2:44:49 PM]

687

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 688: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

Index - _ ● a - b - c - d - e - f - h - i - j - l - m - n - o - p - r - s - t - u - w - z -

- a -

● ACTIVE_ENDPOINTS_REQUEST : ember-types.h ● ACTIVE_ENDPOINTS_RESPONSE : ember-types.h ● ADC_CONVERSION_TIME_US_1024 : adc.h ● ADC_CONVERSION_TIME_US_128 : adc.h ● ADC_CONVERSION_TIME_US_2048 : adc.h ● ADC_CONVERSION_TIME_US_256 : adc.h ● ADC_CONVERSION_TIME_US_32 : adc.h ● ADC_CONVERSION_TIME_US_4096 : adc.h ● ADC_CONVERSION_TIME_US_512 : adc.h ● ADC_CONVERSION_TIME_US_64 : adc.h ● ADC_REF_AREF : adc.h ● ADC_REF_AVCC : adc.h ● ADC_REF_INT : adc.h ● ADC_SOURCE_ADC0 : adc.h ● ADC_SOURCE_ADC1 : adc.h ● ADC_SOURCE_ADC2 : adc.h ● ADC_SOURCE_ADC3 : adc.h ● ADC_SOURCE_ADC4 : adc.h ● ADC_SOURCE_ADC5 : adc.h ● ADC_SOURCE_ADC6 : adc.h ● ADC_SOURCE_ADC7 : adc.h ● ADC_USER_APP : adc.h ● ADC_USER_APP2 : adc.h ● ADC_USER_LQI : adc.h ● ADCChannelType : adc.h ● ADCRateType : adc.h ● ADCReferenceType : adc.h ● ADCUser : adc.h ● ADD_HOST_COUNTER : ash-host.h , ash-host-ui.h ● ArgTypeU : command-interpreter.h ● ASH_ACKNUM_BIT : ash-protocol.h ● ASH_ACKNUM_MASK : ash-protocol.h ● ASH_CAN : ash-protocol.h ● ASH_CONTROL_ACK : ash-protocol.h ● ASH_CONTROL_DATA : ash-protocol.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x61.htm (1 of 5) [10/29/2010 2:44:50 PM]

688

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 689: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

● ASH_CONTROL_ERROR : ash-protocol.h ● ASH_CONTROL_NAK : ash-protocol.h ● ASH_CONTROL_RST : ash-protocol.h ● ASH_CONTROL_RSTACK : ash-protocol.h ● ASH_CRC_LEN : ash-protocol.h ● ASH_DFRAME_MASK : ash-protocol.h ● ASH_ESC : ash-protocol.h ● ASH_FLAG : ash-protocol.h ● ASH_FLIP : ash-protocol.h ● ASH_FRAME_LEN_ACK : ash-protocol.h ● ASH_FRAME_LEN_DATA_MIN : ash-protocol.h ● ASH_FRAME_LEN_ERROR : ash-protocol.h ● ASH_FRAME_LEN_NAK : ash-protocol.h ● ASH_FRAME_LEN_RST : ash-protocol.h ● ASH_FRAME_LEN_RSTACK : ash-protocol.h ● ASH_FRMNUM_BIT : ash-protocol.h ● ASH_FRMNUM_MASK : ash-protocol.h ● ASH_GET_ACKNUM : ash-protocol.h ● ASH_GET_FRMNUM : ash-protocol.h ● ASH_GET_NFLAG : ash-protocol.h ● ASH_GET_RFLAG : ash-protocol.h ● ASH_HOST_CONFIG_EM2XX_EM3XX_115200_RTSCTS : ash-host.h ● ASH_HOST_CONFIG_EM2XX_EM3XX_57600_XONXOFF : ash-host.h ● ASH_HOST_SHFRAME_RX_LEN : ash-protocol.h ● ASH_HOST_SHFRAME_TX_LEN : ash-protocol.h ● ASH_MAX_DATA_FIELD_LEN : ash-protocol.h ● ASH_MAX_FRAME_LEN : ash-protocol.h ● ASH_MAX_FRAME_WITH_CRC_LEN : ash-protocol.h ● ASH_MAX_TIMEOUTS : ash-host.h ● ASH_MAX_WAKE_TIME : ash-host.h ● ASH_MIN_DATA_FIELD_LEN : ash-protocol.h ● ASH_MIN_DATA_FRAME_LEN : ash-protocol.h ● ASH_MIN_FRAME_LEN : ash-protocol.h ● ASH_MIN_FRAME_WITH_CRC_LEN : ash-protocol.h ● ASH_NCP_SHFRAME_RX_LEN : ash-protocol.h ● ASH_NCP_SHFRAME_TX_LEN : ash-protocol.h ● ASH_NCP_TYPE_EM2XX_EM3XX : ash-host.h ● ASH_NFLAG_BIT : ash-protocol.h ● ASH_NFLAG_MASK : ash-protocol.h ● ASH_NR_TIMER_BIT : ash-common.h ● ASH_PFLAG_BIT : ash-protocol.h ● ASH_PFLAG_MASK : ash-protocol.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x61.htm (2 of 5) [10/29/2010 2:44:50 PM]

689

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 690: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

● ASH_PORT_LEN : ash-host.h ● ASH_RESET_METHOD_CUSTOM : ash-host.h ● ASH_RESET_METHOD_DTR : ash-host.h ● ASH_RESET_METHOD_NONE : ash-host.h ● ASH_RESET_METHOD_RST : ash-host.h ● ASH_RFLAG_BIT : ash-protocol.h ● ASH_RFLAG_MASK : ash-protocol.h ● ASH_SHFRAME_MASK : ash-protocol.h ● ASH_SUB : ash-protocol.h ● ASH_VERSION : ash-protocol.h ● ASH_WAKE : ash-protocol.h ● ASH_XOFF : ash-protocol.h ● ASH_XON : ash-protocol.h ● ashAckPeriod : ash-common.h ● ashAckTimer : ash-common.h ● ashAckTimerHasExpired() : ash-common.h ● ashAckTimerIsNotRunning : ash-common.h ● ashAckTimerIsRunning : ash-common.h ● ashAddQueueTail() : ash-host-queues.h ● ashAdjustAckPeriod() : ash-common.h ● ashAllocBuffer() : ash-host-queues.h ● AshBuffer : ash-host-queues.h ● ashClearCounters() : ash-host-ui.h ● ashCount : ash-host.h ● ashCountFrame() : ash-host-priv.h ● ashDebugFlush() : ash-host-io.h ● ashDebugPrintf : ash-host-io.h ● ashDebugVfprintf : ash-host-io.h ● ashDecodeByte() : ash-common.h ● ashDecodeInProgress : ash-common.h ● ashEncodeByte() : ash-common.h ● ashError : ash-host.h ● ashErrorString() : ash-host-ui.h ● ashEzspErrorString() : ash-host-ui.h ● ashFreeBuffer() : ash-host-queues.h ● ashFreeListLength() : ash-host-queues.h ● ashGetAckPeriod : ash-common.h ● ashHostConfig : ash-host.h ● ashInitQueues() : ash-host-queues.h ● ashIsConnected() : ash-host.h ● ashNrTimer : ash-common.h ● ashNrTimerHasExpired() : ash-common.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x61.htm (3 of 5) [10/29/2010 2:44:50 PM]

690

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 691: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

● ashNrTimerIsNotRunning : ash-common.h ● ashOkToSleep() : ash-host.h ● ashPrintCounters() : ash-host-ui.h ● ashPrintUsage() : ash-host-ui.h ● ashProcessCommandOptions() : ash-host-ui.h ● ashQueueHead() : ash-host-queues.h ● ashQueueIsEmpty() : ash-host-queues.h ● ashQueueLength() : ash-host-queues.h ● ashQueueNthEntry() : ash-host-queues.h ● ashQueuePrecedingEntry() : ash-host-queues.h ● ashRandomizeArray() : ash-common.h ● ashReadConfig : ash-host.h ● ashReadConfigOrDefault : ash-host.h ● ashReceive() : ash-host.h ● ashReceiveExec() : ash-host.h ● ashRemoveQueueEntry() : ash-host-queues.h ● ashRemoveQueueHead() : ash-host-queues.h ● ashResetCustom() : ash-host-io.h ● ashResetDtr() : ash-host-io.h ● ashResetNcp() : ash-host.h ● ashSelectHostConfig() : ash-host.h ● ashSend() : ash-host.h ● ashSendExec() : ash-host.h ● ashSerialClose() : ash-host-io.h ● ashSerialGetFd() : ash-host-io.h ● ashSerialInit() : ash-host-io.h ● ashSerialOutputIsIdle() : ash-host-io.h ● ashSerialReadAvailable() : ash-host-io.h ● ashSerialReadByte() : ash-host-io.h ● ashSerialReadFlush() : ash-host-io.h ● ashSerialWriteAvailable() : ash-host-io.h ● ashSerialWriteByte() : ash-host-io.h ● ashSerialWriteFlush() : ash-host-io.h ● ashSetAckPeriod : ash-common.h ● ashSetAndStartAckTimer : ash-common.h ● ashStart() : ash-host.h ● ashStartAckTimer() : ash-common.h ● ashStartNrTimer() : ash-common.h ● ashStop() : ash-host.h ● ashStopAckTimer : ash-common.h ● ashStopNrTimer : ash-common.h ● ashTraceArray() : ash-host-priv.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x61.htm (4 of 5) [10/29/2010 2:44:50 PM]

691

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 692: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

● ashTraceDisconnected() : ash-host-priv.h ● ashTraceEvent() : ash-host-ui.h ● ashTraceEventRecdFrame() : ash-host-priv.h ● ashTraceEventTime() : ash-host-priv.h ● ashTraceEzspFrameId() : ash-host-priv.h ● ashTraceEzspVerbose() : ash-host-priv.h ● ashTraceFrame() : ash-host-priv.h ● ashWakeUpNcp() : ash-host.h ● ashWriteConfig : ash-host.h ● assert : iar.h ● ATOMIC : iar.h ● ATOMIC_LITE : iar.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x61.htm (5 of 5) [10/29/2010 2:44:50 PM]

692

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 693: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

Index - _ - a ● b - c - d - e - f - h - i - j - l - m - n - o - p - r - s - t - u - w - z -

- b -

● BASIC_DEBUG : ember-debug.h ● BIGENDIAN_CPU : iar.h ● BIND_REQUEST : ember-types.h ● BIND_RESPONSE : ember-types.h ● BINDING_TABLE_REQUEST : ember-types.h ● BINDING_TABLE_RESPONSE : ember-types.h ● blState : bootload-utils.h ● BOARD_ACTIVITY_LED : dev0470.h , host.h , dev0473.h ● BOARD_HEARTBEAT_LED : host.h , dev0470.h , dev0473.h ● BOARDLED0 : dev0470.h , dev0473.h , host.h ● BOARDLED1 : dev0470.h , dev0473.h , host.h ● BOARDLED2 : host.h ● BOARDLED3 : host.h ● BOARDLED4 : host.h ● BOARDLED5 : host.h ● BOARDLED_MASK : dev0473.h , dev0470.h ● boolean : iar.h ● BOOTLOAD_AUTH_CHALLENGE_SIZE : bootload-utils.h ● BOOTLOAD_AUTH_COMMON_SIZE : bootload-utils.h ● BOOTLOAD_AUTH_RESPONSE_SIZE : bootload-utils.h ● BOOTLOAD_HARDWARE_TAG_SIZE : bootload-utils.h ● BOOTLOAD_MODE_NONE : bootload-utils.h ● BOOTLOAD_MODE_PASSTHRU : bootload-utils.h ● BOOTLOAD_STATE_DELAY_BEFORE_START : bootload-utils.h ● BOOTLOAD_STATE_DONE : bootload-utils.h ● BOOTLOAD_STATE_NORMAL : bootload-utils.h ● BOOTLOAD_STATE_QUERY : bootload-utils.h ● BOOTLOAD_STATE_SENDING_IMAGE : bootload-utils.h ● BOOTLOAD_STATE_START_BROADCAST_BOOTLOAD : bootload-utils.h ● BOOTLOAD_STATE_START_SENDING_IMAGE : bootload-utils.h ● BOOTLOAD_STATE_START_UNICAST_BOOTLOAD : bootload-utils.h ● BOOTLOAD_STATE_WAIT_FOR_AUTH_CHALLENGE : bootload-utils.h ● BOOTLOAD_STATE_WAIT_FOR_AUTH_RESPONSE : bootload-utils.h ● BOOTLOAD_STATE_WAIT_FOR_COMPLETE_ACK : bootload-utils.h ● BOOTLOAD_STATE_WAIT_FOR_IMAGE_ACK : bootload-utils.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x62.htm (1 of 2) [10/29/2010 2:44:51 PM]

693

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 694: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

● BOOTLOADER_MODE_CLONE : bootloader-interface-standalone-v1.h ● BOOTLOADER_MODE_CLONE_RECOVERY : bootloader-interface-standalone-v1.h ● BOOTLOADER_MODE_MENU : bootloader-interface-standalone-v1.h ● BOOTLOADER_MODE_PASSTHROUGH : bootloader-interface-standalone-v1.h ● BOOTLOADER_MODE_PASSTHROUGH_RECOVERY : bootloader-interface-

standalone-v1.h ● BOOTLOADER_TYPE_STANDALONE : bootloader-interface-standalone-v1.h ● bootloadEzspLastError : bootload-ezsp-utils.h ● bootloadMode : bootload-utils.h ● bootloadState : bootload-utils.h ● bootloadUtilInit() : bootload-utils.h ● bootloadUtilLaunchRequestHandler() : bootload-utils.h ● bootloadUtilQueryResponseHandler() : bootload-utils.h ● bootloadUtilSendAuthResponse() : bootload-utils.h ● bootloadUtilSendQuery() : bootload-utils.h ● bootloadUtilSendRequest() : bootload-utils.h ● bootloadUtilStartBootload() : bootload-utils.h ● bootloadUtilTick() : bootload-utils.h ● BUMP_HOST_COUNTER : ash-host.h , ash-host-ui.h ● BUTTON0 : dev0473.h , dev0470.h , host.h ● BUTTON0_CONFIG_FALLING_EDGE : dev0470.h , dev0473.h ● BUTTON0_CONFIG_RISING_EDGE : dev0473.h , dev0470.h ● BUTTON0_DDR : dev0470.h , dev0473.h ● BUTTON0_INT : dev0470.h , dev0473.h ● BUTTON0_INT_VECT : dev0473.h , dev0470.h ● BUTTON0_PIN : dev0470.h , dev0473.h ● BUTTON0_PORT : dev0470.h , dev0473.h ● BUTTON1 : host.h , dev0470.h , dev0473.h ● BUTTON1_CONFIG_FALLING_EDGE : dev0470.h , dev0473.h ● BUTTON1_CONFIG_RISING_EDGE : dev0473.h , dev0470.h ● BUTTON1_DDR : dev0473.h , dev0470.h ● BUTTON1_INT : dev0473.h , dev0470.h ● BUTTON1_INT_VECT : dev0470.h , dev0473.h ● BUTTON1_PIN : dev0470.h , dev0473.h ● BUTTON1_PORT : dev0470.h , dev0473.h ● BUTTON_PRESSED : button.h ● BUTTON_RELEASED : button.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x62.htm (2 of 2) [10/29/2010 2:44:51 PM]

694

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 695: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

Index - _ - a - b ● c - d - e - f - h - i - j - l - m - n - o - p - r - s - t - u - w - z -

- c -

● CLUSTER_ID_RESPONSE_MINIMUM : ember-types.h ● CommandAction : command-interpreter.h ● COMPLEX_DESCRIPTOR_REQUEST : ember-types.h ● COMPLEX_DESCRIPTOR_RESPONSE : ember-types.h ● control : ember-types.h ● CRC32_END : crc.h ● CRC32_START : crc.h ● CUSTOM : hal/micro/serial.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x63.htm [10/29/2010 2:44:51 PM]

695

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 696: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

Index - _ - a - b - c ● d - e - f - h - i - j - l - m - n - o - p - r - s - t - u - w - z -

- d -

● DEBUG_LEVEL : iar.h ● DEBUG_STREAM : ash-host-io.h ● debugPrintf() : bootload-ezsp-utils.h ● DECLARE_INTERRUPT_STATE : iar.h ● DECLARE_INTERRUPT_STATE_LITE : iar.h ● DEFINE_BAUD : hal/micro/serial.h ● DEFINE_ERROR : error.h ● DIRECT_JOIN_REQUEST : ember-types.h ● DIRECT_JOIN_RESPONSE : ember-types.h ● DISABLE_INTERRUPTS : iar.h ● DISABLE_INTERRUPTS_LITE : iar.h ● DISCOVERY_CACHE_REQUEST : ember-types.h ● DISCOVERY_CACHE_RESPONSE : ember-types.h ● DISCOVERY_REGISTER_REQUEST : ember-types.h ● DISCOVERY_REGISTER_RESPONSE : ember-types.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x64.htm [10/29/2010 2:44:52 PM]

696

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 697: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

Index - _ - a - b - c - d ● e - f - h - i - j - l - m - n - o - p - r - s - t - u - w - z -

- e -

● EEPROM : iar.h ● EMBER_ACTIVE_SCAN : ember-types.h ● EMBER_ADC_CONVERSION_BUSY : error-def.h ● EMBER_ADC_CONVERSION_DEFERRED : error-def.h ● EMBER_ADC_CONVERSION_DONE : error-def.h ● EMBER_ADC_NO_CONVERSION_PENDING : error-def.h ● EMBER_ADDRESS_TABLE_ENTRY_IS_ACTIVE : error-def.h ● EMBER_ADDRESS_TABLE_INDEX_OUT_OF_RANGE : error-def.h ● EMBER_ADDRESS_TABLE_SIZE : ember-configuration-defaults.h ● EMBER_AES_HASH_BLOCK_SIZE : ember-types.h ● EMBER_ALL_802_15_4_CHANNELS_MASK : ember-types.h ● EMBER_ALLOW_KEY_REQUESTS : ember-types.h ● EMBER_API_MAJOR_VERSION : ember-configuration-defaults.h ● EMBER_API_MINOR_VERSION : ember-configuration-defaults.h ● EMBER_APP_HANDLES_UNSUPPORTED_ZDO_REQUESTS : ember-types.h ● EMBER_APP_HANDLES_ZDO_BINDING_REQUESTS : ember-types.h ● EMBER_APP_HANDLES_ZDO_ENDPOINT_REQUESTS : ember-types.h ● EMBER_APP_LINK_KEY_ESTABLISHED : ember-types.h ● EMBER_APP_MASTER_KEY_ESTABLISHED : ember-types.h ● EMBER_APP_RECEIVES_SUPPORTED_ZDO_REQUESTS : ember-types.h ● EMBER_APPLICATION_ERROR_0 : error-def.h ● EMBER_APPLICATION_ERROR_1 : error-def.h ● EMBER_APPLICATION_ERROR_10 : error-def.h ● EMBER_APPLICATION_ERROR_11 : error-def.h ● EMBER_APPLICATION_ERROR_12 : error-def.h ● EMBER_APPLICATION_ERROR_13 : error-def.h ● EMBER_APPLICATION_ERROR_14 : error-def.h ● EMBER_APPLICATION_ERROR_15 : error-def.h ● EMBER_APPLICATION_ERROR_2 : error-def.h ● EMBER_APPLICATION_ERROR_3 : error-def.h ● EMBER_APPLICATION_ERROR_4 : error-def.h ● EMBER_APPLICATION_ERROR_5 : error-def.h ● EMBER_APPLICATION_ERROR_6 : error-def.h ● EMBER_APPLICATION_ERROR_7 : error-def.h ● EMBER_APPLICATION_ERROR_8 : error-def.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x65.htm (1 of 14) [10/29/2010 2:44:54 PM]

697

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 698: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

● EMBER_APPLICATION_ERROR_9 : error-def.h ● EMBER_APPLICATION_LINK_KEY : ember-types.h ● EMBER_APPLICATION_MASTER_KEY : ember-types.h ● EMBER_APS_ENCRYPTION_ERROR : error-def.h ● EMBER_APS_OPTION_DESTINATION_EUI64 : ember-types.h ● EMBER_APS_OPTION_DSA_SIGN : ember-types.h ● EMBER_APS_OPTION_ENABLE_ADDRESS_DISCOVERY : ember-types.h ● EMBER_APS_OPTION_ENABLE_ROUTE_DISCOVERY : ember-types.h ● EMBER_APS_OPTION_ENCRYPTION : ember-types.h ● EMBER_APS_OPTION_FORCE_ROUTE_DISCOVERY : ember-types.h ● EMBER_APS_OPTION_FRAGMENT : ember-types.h ● EMBER_APS_OPTION_NONE : ember-types.h ● EMBER_APS_OPTION_POLL_RESPONSE : ember-types.h ● EMBER_APS_OPTION_RETRY : ember-types.h ● EMBER_APS_OPTION_SOURCE_EUI64 : ember-types.h ● EMBER_APS_OPTION_ZDO_RESPONSE_REQUIRED : ember-types.h ● EMBER_APS_UNICAST_MESSAGE_COUNT : ember-configuration-defaults.h ● EMBER_ASSERT_SERIAL_PORT : ember-configuration-defaults.h ● EMBER_BAD_ARGUMENT : error-def.h ● EMBER_BINDING_HAS_CHANGED : error-def.h ● EMBER_BINDING_INDEX_OUT_OF_RANGE : error-def.h ● EMBER_BINDING_IS_ACTIVE : error-def.h ● EMBER_BINDING_TABLE_SIZE : ember-configuration-defaults.h ● EMBER_BINDING_TABLE_TOKEN_SIZE : ember-configuration-defaults.h ● EMBER_BROADCAST_ADDRESS : ember-types.h ● EMBER_BROADCAST_ALARM_CLUSTER : ember-types.h ● EMBER_BROADCAST_ALARM_DATA_SIZE : ember-configuration-defaults.h ● EMBER_BROADCAST_ENDPOINT : ember-types.h ● EMBER_BROADCAST_TABLE_SIZE : ember-configuration-defaults.h ● EMBER_CACHED_UNICAST_ALARM_CLUSTER : ember-types.h ● EMBER_CANNOT_JOIN_AS_ROUTER : error-def.h ● EMBER_CERTIFICATE_SIZE : ember-types.h ● EMBER_CERTIFICATE_TABLE_SIZE : ember-configuration-defaults.h ● EMBER_CHANNEL_CHANGED : error-def.h ● EMBER_CHILD_TABLE_SIZE : ember-configuration-defaults.h ● EMBER_CHILD_TABLE_TOKEN_SIZE : ember-configuration-defaults.h ● EMBER_CMD_ERR_ARGUMENT_OUT_OF_RANGE : command-interpreter.h ● EMBER_CMD_ERR_ARGUMENT_SYNTAX_ERROR : command-interpreter.h ● EMBER_CMD_ERR_NO_BINARY_STRING_TERMINATOR : command-interpreter.h ● EMBER_CMD_ERR_NO_BUFFER_AVAILABLE : command-interpreter.h ● EMBER_CMD_ERR_NO_SUCH_COMMAND : command-interpreter.h ● EMBER_CMD_ERR_PORT_PROBLEM : command-interpreter.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x65.htm (2 of 14) [10/29/2010 2:44:54 PM]

698

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 699: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

● EMBER_CMD_ERR_STRING_TOO_LONG : command-interpreter.h ● EMBER_CMD_ERR_TOO_MANY_COMMAND_ARGUMENTS : command-interpreter.h ● EMBER_CMD_ERR_WRONG_COMMAND_ARGUMENTS : command-interpreter.h ● EMBER_CMD_SUCCESS : command-interpreter.h ● EMBER_COMMENT_CHARACTER : command-interpreter.h ● EMBER_COORDINATOR : ember-types.h ● EMBER_COST_NOT_KNOWN : error-def.h ● EMBER_COUNTER_ALLOCATE_PACKET_BUFFER_FAILURE : ember-types.h ● EMBER_COUNTER_APS_DATA_RX_BROADCAST : ember-types.h ● EMBER_COUNTER_APS_DATA_RX_UNICAST : ember-types.h ● EMBER_COUNTER_APS_DATA_TX_BROADCAST : ember-types.h ● EMBER_COUNTER_APS_DATA_TX_UNICAST_FAILED : ember-types.h ● EMBER_COUNTER_APS_DATA_TX_UNICAST_RETRY : ember-types.h ● EMBER_COUNTER_APS_DATA_TX_UNICAST_SUCCESS : ember-types.h ● EMBER_COUNTER_APS_DECRYPTION_FAILURE : ember-types.h ● EMBER_COUNTER_APS_FRAME_COUNTER_FAILURE : ember-types.h ● EMBER_COUNTER_APS_LINK_KEY_NOT_AUTHORIZED : ember-types.h ● EMBER_COUNTER_ASH_FRAMING_ERROR : ember-types.h ● EMBER_COUNTER_ASH_OVERFLOW_ERROR : ember-types.h ● EMBER_COUNTER_ASH_OVERRUN_ERROR : ember-types.h ● EMBER_COUNTER_ASH_XOFF : ember-types.h ● EMBER_COUNTER_CHILD_REMOVED : ember-types.h ● EMBER_COUNTER_JOIN_INDICATION : ember-types.h ● EMBER_COUNTER_MAC_RX_BROADCAST : ember-types.h ● EMBER_COUNTER_MAC_RX_UNICAST : ember-types.h ● EMBER_COUNTER_MAC_TX_BROADCAST : ember-types.h ● EMBER_COUNTER_MAC_TX_UNICAST_FAILED : ember-types.h ● EMBER_COUNTER_MAC_TX_UNICAST_RETRY : ember-types.h ● EMBER_COUNTER_MAC_TX_UNICAST_SUCCESS : ember-types.h ● EMBER_COUNTER_NEIGHBOR_ADDED : ember-types.h ● EMBER_COUNTER_NEIGHBOR_REMOVED : ember-types.h ● EMBER_COUNTER_NEIGHBOR_STALE : ember-types.h ● EMBER_COUNTER_NWK_DECRYPTION_FAILURE : ember-types.h ● EMBER_COUNTER_NWK_FRAME_COUNTER_FAILURE : ember-types.h ● EMBER_COUNTER_ROUTE_DISCOVERY_INITIATED : ember-types.h ● EMBER_COUNTER_STRINGS : ember-types.h ● EMBER_COUNTER_TYPE_COUNT : ember-types.h ● EMBER_CURRENT_NETWORK_KEY : ember-types.h ● EMBER_DELIVERY_FAILED : error-def.h ● EMBER_DENY_JOIN : ember-types.h ● EMBER_DENY_KEY_REQUESTS : ember-types.h ● EMBER_DEVICE_LEFT : ember-types.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x65.htm (3 of 14) [10/29/2010 2:44:54 PM]

699

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 700: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

● EMBER_DEVICE_UPDATE_STRINGS : ember-types.h ● EMBER_DISCOVERY_ACTIVE_NODE_ID : ember-types.h ● EMBER_DISCOVERY_TABLE_SIZE : ember-configuration-defaults.h ● EMBER_DISTRIBUTED_TRUST_CENTER_MODE : ember-types.h ● EMBER_DISTRIBUTED_TRUST_CENTER_MODE_ : ember-types.h ● EMBER_EEPROM_MFG_STACK_VERSION_MISMATCH : error-def.h ● EMBER_EEPROM_MFG_VERSION_MISMATCH : error-def.h ● EMBER_EEPROM_STACK_VERSION_MISMATCH : error-def.h ● EMBER_ENCRYPTION_KEY_SIZE : ember-types.h ● EMBER_END_DEVICE : ember-types.h ● EMBER_END_DEVICE_BIND_TIMEOUT : ember-configuration-defaults.h ● EMBER_END_DEVICE_POLL_TIMEOUT : ember-configuration-defaults.h ● EMBER_END_DEVICE_POLL_TIMEOUT_SHIFT : ember-configuration-defaults.h ● EMBER_ENERGY_SCAN : ember-types.h ● EMBER_ERR_BOOTLOADER_NO_IMAGE : error-def.h ● EMBER_ERR_BOOTLOADER_TRAP_TABLE_BAD : error-def.h ● EMBER_ERR_BOOTLOADER_TRAP_UNKNOWN : error-def.h ● EMBER_ERR_FATAL : error-def.h ● EMBER_ERR_FLASH_ERASE_FAIL : error-def.h ● EMBER_ERR_FLASH_PROG_FAIL : error-def.h ● EMBER_ERR_FLASH_VERIFY_FAILED : error-def.h ● EMBER_ERR_FLASH_WRITE_INHIBITED : error-def.h ● EMBER_ERROR_CODE_COUNT : error.h ● EMBER_EVENT_INACTIVE : ember-types.h ● EMBER_EVENT_MINUTE_TIME : ember-types.h ● EMBER_EVENT_MS_TIME : ember-types.h ● EMBER_EVENT_QS_TIME : ember-types.h ● EMBER_EVENT_ZERO_DELAY : ember-types.h ● EMBER_FRAGMENT_DELAY_MS : ember-configuration-defaults.h ● EMBER_FRAGMENT_MAX_WINDOW_SIZE : ember-configuration-defaults.h ● EMBER_FRAGMENT_WINDOW_SIZE : ember-configuration-defaults.h ● EMBER_GET_LINK_KEY_WHEN_JOINING : ember-types.h ● EMBER_GET_PRECONFIGURED_KEY_FROM_INSTALL_CODE : ember-types.h ● EMBER_GLOBAL_LINK_KEY : ember-types.h ● EMBER_GLOBAL_LINK_KEY_ : ember-types.h ● EMBER_HAVE_NETWORK_KEY : ember-types.h ● EMBER_HAVE_PRECONFIGURED_KEY : ember-types.h ● EMBER_HAVE_TRUST_CENTER_EUI64 : ember-types.h ● EMBER_HAVE_TRUST_CENTER_LINK_KEY : ember-types.h ● EMBER_HIGH_RAM_CONCENTRATOR : ember-types.h ● EMBER_HIGH_SECURITY_SECURED_REJOIN : ember-types.h ● EMBER_HIGH_SECURITY_UNSECURED_JOIN : ember-types.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x65.htm (4 of 14) [10/29/2010 2:44:54 PM]

700

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 701: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

● EMBER_HIGH_SECURITY_UNSECURED_REJOIN : ember-types.h ● EMBER_INCOMING_BROADCAST : ember-types.h ● EMBER_INCOMING_BROADCAST_LOOPBACK : ember-types.h ● EMBER_INCOMING_MULTICAST : ember-types.h ● EMBER_INCOMING_MULTICAST_LOOPBACK : ember-types.h ● EMBER_INCOMING_UNICAST : ember-types.h ● EMBER_INCOMING_UNICAST_REPLY : ember-types.h ● EMBER_INCOMPATIBLE_STATIC_MEMORY_DEFINITIONS : error-def.h ● EMBER_INDEX_OUT_OF_RANGE : error-def.h ● EMBER_INDIRECT_TRANSMISSION_TIMEOUT : ember-configuration-defaults.h ● EMBER_INPUT_CLUSTER_LIST : ember-types.h ● EMBER_INSUFFICIENT_RANDOM_DATA : error-def.h ● EMBER_INVALID_BINDING_INDEX : error-def.h ● EMBER_INVALID_CALL : error-def.h ● EMBER_INVALID_ENDPOINT : error-def.h ● EMBER_INVALID_SECURITY_LEVEL : error-def.h ● EMBER_JOIN_DECISION_STRINGS : ember-types.h ● EMBER_JOIN_FAILED : error-def.h ● EMBER_JOINED_NETWORK : ember-types.h ● EMBER_JOINED_NETWORK_NO_PARENT : ember-types.h ● EMBER_JOINING_NETWORK : ember-types.h ● EMBER_KEY_ESTABLISHMENT_TIMEOUT : ember-types.h ● EMBER_KEY_HAS_INCOMING_FRAME_COUNTER : ember-types.h ● EMBER_KEY_HAS_OUTGOING_FRAME_COUNTER : ember-types.h ● EMBER_KEY_HAS_PARTNER_EUI64 : ember-types.h ● EMBER_KEY_HAS_SEQUENCE_NUMBER : ember-types.h ● EMBER_KEY_INVALID : error-def.h ● EMBER_KEY_IS_AUTHORIZED : ember-types.h ● EMBER_KEY_NOT_AUTHORIZED : error-def.h ● EMBER_KEY_TABLE_FULL : ember-types.h ● EMBER_KEY_TABLE_INVALID_ADDRESS : error-def.h ● EMBER_KEY_TABLE_SIZE : ember-configuration-defaults.h ● EMBER_KEY_TABLE_TOKEN_SIZE : ember-configuration-defaults.h ● EMBER_LEAVING_NETWORK : ember-types.h ● EMBER_LIBRARY_NOT_PRESENT : error-def.h ● EMBER_LOW_RAM_CONCENTRATOR : ember-types.h ● EMBER_MAC_ACK_HEADER_TYPE : error-def.h ● EMBER_MAC_BAD_SCAN_DURATION : error-def.h ● EMBER_MAC_COMMAND_TRANSMIT_FAILURE : error-def.h ● EMBER_MAC_INCORRECT_SCAN_TYPE : error-def.h ● EMBER_MAC_INDIRECT_TIMEOUT : error-def.h ● EMBER_MAC_INVALID_CHANNEL_MASK : error-def.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x65.htm (5 of 14) [10/29/2010 2:44:54 PM]

701

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 702: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

● EMBER_MAC_JOINED_NETWORK : error-def.h ● EMBER_MAC_NO_ACK_RECEIVED : error-def.h ● EMBER_MAC_NO_DATA : error-def.h ● EMBER_MAC_PASSTHROUGH_APPLICATION : ember-types.h ● EMBER_MAC_PASSTHROUGH_EMBERNET : ember-types.h ● EMBER_MAC_PASSTHROUGH_EMBERNET_SOURCE : ember-types.h ● EMBER_MAC_PASSTHROUGH_NONE : ember-types.h ● EMBER_MAC_PASSTHROUGH_SE_INTERPAN : ember-types.h ● EMBER_MAC_SCANNING : error-def.h ● EMBER_MAC_TRANSMIT_QUEUE_FULL : error-def.h ● EMBER_MAC_UNKNOWN_HEADER_TYPE : error-def.h ● EMBER_MANY_TO_ONE_BINDING : ember-types.h ● EMBER_MANY_TO_ONE_ROUTE_FAILURE : error-def.h ● EMBER_MAX_802_15_4_CHANNEL_NUMBER : ember-types.h ● EMBER_MAX_COMMAND_LENGTH : command-interpreter.h ● EMBER_MAX_DEPTH : ember-configuration-defaults.h ● EMBER_MAX_END_DEVICE_CHILDREN : ember-configuration-defaults.h ● EMBER_MAX_HOPS : ember-configuration-defaults.h ● EMBER_MAX_INDIRECT_TRANSMISSION_TIMEOUT : ember-configuration-defaults.

h ● EMBER_MAX_MESSAGE_LIMIT_REACHED : error-def.h ● EMBER_MAX_NEIGHBOR_TABLE_SIZE : ember-configuration-defaults.h ● EMBER_MAXIMUM_ALARM_DATA_SIZE : ember-configuration-defaults.h ● EMBER_MESSAGE_TOO_LONG : error-def.h ● EMBER_MIN_802_15_4_CHANNEL_NUMBER : ember-types.h ● EMBER_MOBILE_END_DEVICE : ember-types.h ● EMBER_MOBILE_NODE_POLL_TIMEOUT : ember-configuration-defaults.h ● EMBER_MOVE_FAILED : error-def.h ● EMBER_MULTICAST_BINDING : ember-types.h ● EMBER_MULTICAST_NODE_ID : ember-types.h ● EMBER_MULTICAST_TABLE_SIZE : ember-configuration-defaults.h ● EMBER_NEIGHBOR_TABLE_SIZE : ember-configuration-defaults.h ● EMBER_NETWORK_BUSY : error-def.h ● EMBER_NETWORK_DOWN : error-def.h ● EMBER_NETWORK_UP : error-def.h ● EMBER_NEXT_NETWORK_KEY : ember-types.h ● EMBER_NO_ACTION : ember-types.h ● EMBER_NO_BEACONS : error-def.h ● EMBER_NO_BUFFERS : error-def.h ● EMBER_NO_FRAME_COUNTER_RESET : ember-types.h ● EMBER_NO_LINK_KEY_RECEIVED : error-def.h ● EMBER_NO_NETWORK : ember-types.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x65.htm (6 of 14) [10/29/2010 2:44:54 PM]

702

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 703: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

● EMBER_NO_NETWORK_KEY_RECEIVED : error-def.h ● EMBER_NO_TRUST_CENTER_MODE : ember-types.h ● EMBER_NODE_ID_CHANGED : error-def.h ● EMBER_NOT_JOINED : error-def.h ● EMBER_NULL_ADDRESS_TABLE_INDEX : ember-types.h ● EMBER_NULL_BINDING : ember-types.h ● EMBER_NULL_NODE_ID : ember-types.h ● EMBER_NUM_802_15_4_CHANNELS : ember-types.h ● EMBER_NWK_ALREADY_PRESENT : ember-types.h ● EMBER_NWK_TABLE_FULL : ember-types.h ● EMBER_NWK_UNKNOWN_DEVICE : ember-types.h ● EMBER_OPERATION_IN_PROGRESS : error-def.h ● EMBER_OTA_CERTIFICATE_UPGRADE_CLUSTER : ember-types.h ● EMBER_OUTGOING_BROADCAST : ember-types.h ● EMBER_OUTGOING_DIRECT : ember-types.h ● EMBER_OUTGOING_MULTICAST : ember-types.h ● EMBER_OUTGOING_VIA_ADDRESS_TABLE : ember-types.h ● EMBER_OUTGOING_VIA_BINDING : ember-types.h ● EMBER_OUTPUT_CLUSTER_LIST : ember-types.h ● EMBER_PACKET_BUFFER_COUNT : ember-configuration-defaults.h ● EMBER_PAN_ID_CHANGED : error-def.h ● EMBER_PAN_ID_CONFLICT_REPORT_THRESHOLD : ember-configuration-defaults.

h ● EMBER_PHY_ACK_RECEIVED : error-def.h ● EMBER_PHY_INVALID_CHANNEL : error-def.h ● EMBER_PHY_INVALID_POWER : error-def.h ● EMBER_PHY_OSCILLATOR_CHECK_FAILED : error-def.h ● EMBER_PHY_TX_BUSY : error-def.h ● EMBER_PHY_TX_CCA_FAIL : error-def.h ● EMBER_PHY_TX_INCOMPLETE : error-def.h ● EMBER_PHY_TX_UNDERFLOW : error-def.h ● EMBER_PRECONFIGURED_KEY_REQUIRED : error-def.h ● EMBER_PRECONFIGURED_NETWORK_KEY_MODE : ember-types.h ● EMBER_PRIVATE_KEY_SIZE : ember-types.h ● EMBER_PRIVATE_PROFILE_ID : ember-types.h ● EMBER_PUBLIC_KEY_SIZE : ember-types.h ● EMBER_RECEIVED_KEY_IN_THE_CLEAR : error-def.h ● EMBER_REPORT_AND_CLEAR_COUNTERS_REQUEST : ember-types.h ● EMBER_REPORT_AND_CLEAR_COUNTERS_RESPONSE : ember-types.h ● EMBER_REPORT_COUNTERS_REQUEST : ember-types.h ● EMBER_REPORT_COUNTERS_RESPONSE : ember-types.h ● EMBER_REQUEST_KEY_TIMEOUT : ember-configuration-defaults.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x65.htm (7 of 14) [10/29/2010 2:44:54 PM]

703

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 704: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

● EMBER_REQUIRE_ENCRYPTED_KEY : ember-types.h ● EMBER_RESERVED_MOBILE_CHILD_ENTRIES : ember-configuration-defaults.h ● EMBER_ROUTE_TABLE_SIZE : ember-configuration-defaults.h ● EMBER_ROUTER : ember-types.h ● EMBER_RX_ON_WHEN_IDLE_BROADCAST_ADDRESS : ember-types.h ● EMBER_SECURITY_CONFIGURATION_INVALID : error-def.h ● EMBER_SECURITY_LEVEL : ember-configuration-defaults.h ● EMBER_SECURITY_STATE_NOT_SET : error-def.h ● EMBER_SEND_KEY_IN_THE_CLEAR : ember-types.h ● EMBER_SERIAL_BUFFER : hal/micro/serial.h ● EMBER_SERIAL_FIFO : hal/micro/serial.h ● EMBER_SERIAL_INVALID_BAUD_RATE : error-def.h ● EMBER_SERIAL_INVALID_PORT : error-def.h ● EMBER_SERIAL_LOWLEVEL : hal/micro/serial.h ● EMBER_SERIAL_RX_EMPTY : error-def.h ● EMBER_SERIAL_RX_FRAME_ERROR : error-def.h ● EMBER_SERIAL_RX_OVERFLOW : error-def.h ● EMBER_SERIAL_RX_OVERRUN_ERROR : error-def.h ● EMBER_SERIAL_RX_PARITY_ERROR : error-def.h ● EMBER_SERIAL_TX_OVERFLOW : error-def.h ● EMBER_SERIAL_UNUSED : hal/micro/serial.h ● EMBER_SIGNATURE_SIZE : ember-types.h ● EMBER_SIGNATURE_VERIFY_FAILURE : error-def.h ● EMBER_SIM_EEPROM_ERASE_PAGE_GREEN : error-def.h ● EMBER_SIM_EEPROM_ERASE_PAGE_RED : error-def.h ● EMBER_SIM_EEPROM_FULL : error-def.h ● EMBER_SIM_EEPROM_INIT_1_FAILED : error-def.h ● EMBER_SIM_EEPROM_INIT_2_FAILED : error-def.h ● EMBER_SIM_EEPROM_INIT_3_FAILED : error-def.h ● EMBER_SLEEP_INTERRUPTED : error-def.h ● EMBER_SLEEPY_BROADCAST_ADDRESS : ember-types.h ● EMBER_SLEEPY_END_DEVICE : ember-types.h ● EMBER_SMAC_SIZE : ember-types.h ● EMBER_SOURCE_ROUTE_FAILURE : error-def.h ● EMBER_SOURCE_ROUTE_TABLE_SIZE : ember-configuration-defaults.h ● EMBER_STACK_AND_HARDWARE_MISMATCH : error-def.h ● EMBER_STACK_PROFILE : ember-configuration-defaults.h ● EMBER_STANDARD_SECURITY_MODE : ember-types.h ● EMBER_STANDARD_SECURITY_MODE_ : ember-types.h ● EMBER_STANDARD_SECURITY_SECURED_REJOIN : ember-types.h ● EMBER_STANDARD_SECURITY_UNSECURED_JOIN : ember-types.h ● EMBER_STANDARD_SECURITY_UNSECURED_REJOIN : ember-types.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x65.htm (8 of 14) [10/29/2010 2:44:54 PM]

704

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 705: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

● EMBER_SUCCESS : error-def.h ● EMBER_TABLE_ENTRY_ERASED : error-def.h ● EMBER_TABLE_ENTRY_UNUSED_NODE_ID : ember-types.h ● EMBER_TABLE_FULL : error-def.h ● EMBER_TASK_COUNT : ember-configuration-defaults.h ● EMBER_TC_APP_KEY_SENT_TO_REQUESTER : ember-types.h ● EMBER_TC_FAILED_TO_SEND_APP_KEYS : ember-types.h ● EMBER_TC_FAILED_TO_STORE_APP_KEY_REQUEST : ember-types.h ● EMBER_TC_NO_LINK_KEY_FOR_REQUESTER : ember-types.h ● EMBER_TC_NON_MATCHING_APP_KEY_REQUEST_RECEIVED : ember-types.h ● EMBER_TC_RECEIVED_FIRST_APP_KEY_REQUEST : ember-types.h ● EMBER_TC_REJECTED_APP_KEY_REQUEST : ember-types.h ● EMBER_TC_REQUEST_KEY_TYPE_NOT_SUPPORTED : ember-types.h ● EMBER_TC_REQUESTER_EUI64_UNKNOWN : ember-types.h ● EMBER_TC_RESPONDED_TO_KEY_REQUEST : ember-types.h ● EMBER_TC_RESPONSE_TO_KEY_REQUEST_FAILED : ember-types.h ● EMBER_TC_TIMEOUT_WAITING_FOR_SECOND_APP_KEY_REQUEST : ember-types.

h ● EMBER_TOO_SOON_FOR_SWITCH_KEY : error-def.h ● EMBER_TRUST_CENTER_EUI_HAS_CHANGED : error-def.h ● EMBER_TRUST_CENTER_LINK_KEY : ember-types.h ● EMBER_TRUST_CENTER_LINK_KEY_ESTABLISHED : ember-types.h ● EMBER_TRUST_CENTER_MASTER_KEY : ember-types.h ● EMBER_TRUST_CENTER_MASTER_KEY_NOT_SET : error-def.h ● EMBER_TRUST_CENTER_NODE_ID : ember-types.h ● EMBER_TRUST_CENTER_USES_HASHED_LINK_KEY : ember-types.h ● EMBER_TRUST_CENTER_USES_HASHED_LINK_KEY_ : ember-types.h ● EMBER_TX_POWER_MODE_ALTERNATE : ember-types.h ● EMBER_TX_POWER_MODE_BOOST : ember-types.h ● EMBER_TX_POWER_MODE_BOOST_AND_ALTERNATE : ember-types.h ● EMBER_TX_POWER_MODE_DEFAULT : ember-types.h ● EMBER_UNICAST_ALARM_CLUSTER : ember-types.h ● EMBER_UNICAST_ALARM_DATA_SIZE : ember-configuration-defaults.h ● EMBER_UNICAST_BINDING : ember-types.h ● EMBER_UNKNOWN_DEVICE : ember-types.h ● EMBER_UNKNOWN_NODE_ID : ember-types.h ● EMBER_UNUSED_BINDING : ember-types.h ● EMBER_USE_MAC_ASSOCIATION : ember-types.h ● EMBER_USE_NWK_COMMISSIONING : ember-types.h ● EMBER_USE_NWK_REJOIN : ember-types.h ● EMBER_USE_NWK_REJOIN_HAVE_NWK_KEY : ember-types.h ● EMBER_USE_PRECONFIGURED_KEY : ember-types.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x65.htm (9 of 14) [10/29/2010 2:44:54 PM]

705

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 706: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

● EMBER_ZDO_ENDPOINT : ember-types.h ● EMBER_ZDO_PROFILE_ID : ember-types.h ● EMBER_ZDP_DEVICE_NOT_FOUND : ember-types.h ● EMBER_ZDP_INSUFFICIENT_SPACE : ember-types.h ● EMBER_ZDP_INVALID_ENDPOINT : ember-types.h ● EMBER_ZDP_INVALID_REQUEST_TYPE : ember-types.h ● EMBER_ZDP_NETWORK_MANAGER : ember-types.h ● EMBER_ZDP_NO_DESCRIPTOR : ember-types.h ● EMBER_ZDP_NO_ENTRY : ember-types.h ● EMBER_ZDP_NO_MATCH : ember-types.h ● EMBER_ZDP_NOT_ACTIVE : ember-types.h ● EMBER_ZDP_NOT_AUTHORIZED : ember-types.h ● EMBER_ZDP_NOT_PERMITTED : ember-types.h ● EMBER_ZDP_NOT_SUPPORTED : ember-types.h ● EMBER_ZDP_PRIMARY_BINDING_TABLE_CACHE : ember-types.h ● EMBER_ZDP_PRIMARY_DISCOVERY_CACHE : ember-types.h ● EMBER_ZDP_PRIMARY_TRUST_CENTER : ember-types.h ● EMBER_ZDP_SECONDARY_BINDING_TABLE_CACHE : ember-types.h ● EMBER_ZDP_SECONDARY_DISCOVERY_CACHE : ember-types.h ● EMBER_ZDP_SECONDARY_TRUST_CENTER : ember-types.h ● EMBER_ZDP_SUCCESS : ember-types.h ● EMBER_ZDP_TABLE_FULL : ember-types.h ● EMBER_ZDP_TIMEOUT : ember-types.h ● EMBER_ZIGBEE_COORDINATOR_ADDRESS : ember-types.h ● emberActiveEndpointsRequest() : zigbee-device-common.h ● EmberApsOption : ember-types.h ● emberBindingTableRequest() : zigbee-device-common.h ● EmberBindingType : ember-types.h ● emberBindRequest() : zigbee-device-common.h ● emberBufferCommandArgument : command-interpreter.h ● emberCalculateSmacs() : cbke-crypto-engine.h ● emberCalculateSmacsHandler() : cbke-crypto-engine.h ● emberCalibrateVref() : adc.h ● emberCertificateContents() : ember-types.h ● emberChannelChangeRequest() : zigbee-device-stack.h ● emberClearTemporaryDataMaybeStoreLinkKey() : cbke-crypto-engine.h ● EmberClusterListId : ember-types.h ● emberCommandErrorNames : command-interpreter.h ● emberCommandName : command-interpreter.h ● emberCommandReaderInit() : command-interpreter.h ● EmberCommandState : command-interpreter.h ● EmberCommandStatus : command-interpreter.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x65.htm (10 of 14) [10/29/2010 2:44:54 PM]

706

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 707: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

● EmberCounterType : ember-types.h ● EmberCurrentSecurityBitmask : ember-types.h ● emberDebugAssert() : ember-debug.h ● emberDebugBinaryPrintf() : ember-debug.h ● emberDebugError() : ember-debug.h ● emberDebugInit : ember-debug.h ● emberDebugMemoryDump() : ember-debug.h ● emberDebugPrintf() : ember-debug.h ● emberDebugReportOff() : ember-debug.h ● emberDebugReportRestore() : ember-debug.h ● EmberDeviceUpdate : ember-types.h ● emberDsaSign() : cbke-crypto-engine.h ● emberDsaSignHandler() : cbke-crypto-engine.h ● emberDsaVerify() : cbke-crypto-engine.h ● emberDsaVerifyHandler() : cbke-crypto-engine.h ● emberEnableDualChannelScan : form-and-join.h ● emberEnergyScanRequest() : zigbee-device-stack.h ● EmberEUI64 : ember-types.h ● EmberEventData : ember-types.h ● EmberEventUnits : ember-types.h ● emberFormAndJoinEnergyScanResultHandler() : form-and-join.h ● emberFormAndJoinIsScanning() : form-and-join.h ● emberFormAndJoinNetworkFoundHandler() : form-and-join.h ● emberFormAndJoinRunTask() : form-and-join.h ● emberFormAndJoinScanCompleteHandler() : form-and-join.h ● emberFormAndJoinTaskInit() : form-and-join.h ● emberFormAndJoinTick() : form-and-join.h ● emberGenerateCbkeKeys() : cbke-crypto-engine.h ● emberGenerateCbkeKeysHandler() : cbke-crypto-engine.h ● emberGetCertificate() : cbke-crypto-engine.h ● emberGetLastZigDevRequestSequence() : zigbee-device-common.h ● emberGetStackCertificateEui64() : cbke-crypto-engine.h ● emberGetZigDevRequestRadius() : zigbee-device-common.h ● emberIeeeAddressRequest() : zigbee-device-stack.h , zigbee-device-host.h ● EmberIncomingMessageType : ember-types.h ● emberInitializeNetworkParameters : ember-types.h ● EmberInitialSecurityBitmask : ember-types.h ● emberJoinableNetworkFoundHandler() : form-and-join.h ● EmberJoinDecision : ember-types.h ● EmberJoinMethod : ember-types.h ● emberKeyContents() : ember-types.h ● EmberKeyStatus : ember-types.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x65.htm (11 of 14) [10/29/2010 2:44:54 PM]

707

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 708: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

● EmberKeyStructBitmask : ember-types.h ● EmberKeyType : ember-types.h ● emberLeaveRequest() : zigbee-device-common.h ● EmberLibraryStatus : ember-types.h ● EmberLinkKeyRequestPolicy : ember-types.h ● emberLqiTableRequest() : zigbee-device-common.h ● EmberMacPassthroughType : ember-types.h ● EmberMessageBuffer : ember-types.h ● EmberMulticastId : ember-types.h ● emberNetworkAddressRequest() : zigbee-device-host.h , zigbee-device-stack.h ● EmberNetworkScanType : ember-types.h ● EmberNetworkStatus : ember-types.h ● emberNodeDescriptorRequest() : zigbee-device-common.h ● EmberNodeId : ember-types.h ● EmberNodeType : ember-types.h ● EmberOutgoingMessageType : ember-types.h ● EmberPanId : ember-types.h ● emberPermitJoiningRequest() : zigbee-device-common.h ● emberPowerDescriptorRequest() : zigbee-device-common.h ● emberPrivateKeyContents() : ember-types.h ● emberProcessCommandInput : command-interpreter.h ● emberProcessCommandString() : command-interpreter.h ● emberPublicKeyContents() : ember-types.h ● emberRoutingTableRequest() : zigbee-device-common.h ● emberScanErrorHandler() : form-and-join.h ● emberScanForJoinableNetwork() : form-and-join.h ● emberScanForNextJoinableNetwork() : form-and-join.h ● emberScanForUnusedPanId() : form-and-join.h ● emberSendDeviceAnnouncement() : zigbee-device-stack.h ● emberSerialBufferTick() : app/util/serial/serial.h ● emberSerialCleanup() : linux-serial.h ● emberSerialCommandCompletionInit() : linux-serial.h ● emberSerialCommandCompletionInitCli() : linux-serial.h ● emberSerialFlushRx() : app/util/serial/serial.h ● emberSerialGetInputFd() : linux-serial.h ● emberSerialGuaranteedPrintf() : app/util/serial/serial.h ● emberSerialInit() : app/util/serial/serial.h ● emberSerialPrintCarriageReturn() : app/util/serial/serial.h ● emberSerialPrintf() : app/util/serial/serial.h ● emberSerialPrintfLine() : app/util/serial/serial.h ● emberSerialPrintfVarArg() : app/util/serial/serial.h ● emberSerialReadAvailable() : app/util/serial/serial.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x65.htm (12 of 14) [10/29/2010 2:44:54 PM]

708

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 709: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

● emberSerialReadByte() : app/util/serial/serial.h ● emberSerialReadLine() : app/util/serial/serial.h ● emberSerialReadPartialLine() : app/util/serial/serial.h ● emberSerialSetPrompt() : linux-serial.h ● emberSerialWaitSend() : app/util/serial/serial.h ● emberSerialWriteAvailable() : app/util/serial/serial.h ● emberSerialWriteBuffer() : app/util/serial/serial.h ● emberSerialWriteByte() : app/util/serial/serial.h ● emberSerialWriteData() : app/util/serial/serial.h ● emberSerialWriteHex() : app/util/serial/serial.h ● emberSerialWriteString() : app/util/serial/serial.h ● emberSerialWriteUsed : app/util/serial/serial.h ● emberSetNetworkManagerRequest() : zigbee-device-stack.h ● emberSetPreinstalledCbkeData() : cbke-crypto-engine.h ● emberSetZigDevRequestRadius() : zigbee-device-common.h ● emberSignatureContents() : ember-types.h ● emberSignedCommandArgument : command-interpreter.h ● emberSimpleDescriptorRequest() : zigbee-device-common.h ● emberSmacContents() : ember-types.h ● EmberStatus : error.h , ember-types.h ● EmberTaskId : ember-types.h ● emberUnbindRequest() : zigbee-device-common.h ● emberUnsignedCommandArgument : command-interpreter.h ● emberUnusedPanIdFoundHandler() : form-and-join.h ● EmberZdoConfigurationFlags : ember-types.h ● EmberZdoServerMask : ember-types.h ● EmberZdoStatus : ember-types.h ● emDebugSendVuartMessage() : ember-debug.h ● emPrintfFlushHandler : app/util/serial/serial.h ● emPrintfInternal() : app/util/serial/serial.h ● emSerialBufferNextBlockIsr() : hal/micro/serial.h ● emSerialBufferNextMessageIsr() : hal/micro/serial.h ● END_DEVICE_ANNOUNCE : ember-types.h ● END_DEVICE_ANNOUNCE_RESPONSE : ember-types.h ● END_DEVICE_BIND_REQUEST : ember-types.h ● END_DEVICE_BIND_RESPONSE : ember-types.h ● EUI64_SIZE : ember-types.h ● EVEN : hal/micro/serial.h ● EXT_SRAM_END : 128/reserved-ram.h ● EXTENDED_PAN_ID_SIZE : ember-types.h ● EZSP_HOST_ASH_RX_POOL_SIZE : ezsp-host-configuration-defaults.h ● EZSP_HOST_FORM_AND_JOIN_BUFFER_SIZE : ezsp-host-configuration-defaults.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x65.htm (13 of 14) [10/29/2010 2:44:54 PM]

709

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 710: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

● EZSP_HOST_SOURCE_ROUTE_TABLE_SIZE : ezsp-host-configuration-defaults.h ● ezspDecodeAddressResponse() : zigbee-device-host.h ● ezspEndDeviceBindRequest() : zigbee-device-host.h ● ezspFragmentIncomingMessage() : fragment-host.h ● ezspFragmentInit() : fragment-host.h ● ezspFragmentMessageSent() : fragment-host.h ● ezspFragmentMessageSentHandler() : fragment-host.h ● ezspFragmentSendUnicast() : fragment-host.h ● ezspFragmentSourceRouteHandler() : fragment-host.h ● ezspFragmentTick() : fragment-host.h ● ezspMatchDescriptorsRequest() : zigbee-device-host.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x65.htm (14 of 14) [10/29/2010 2:44:54 PM]

710

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 711: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

Index - _ - a - b - c - d - e ● f - h - i - j - l - m - n - o - p - r - s - t - u - w - z -

- f -

● FIFO_DEQUEUE : hal/micro/serial.h ● FIFO_ENQUEUE : hal/micro/serial.h ● FIND_NODE_CACHE_REQUEST : ember-types.h ● FIND_NODE_CACHE_RESPONSE : ember-types.h ● FORM_AND_JOIN_CROSSTALK_SCAN : form-and-join3_2.h ● FORM_AND_JOIN_ENERGY_SCAN : form-and-join3_2.h ● FORM_AND_JOIN_JOINABLE_SCAN : form-and-join3_2.h ● FORM_AND_JOIN_NOT_SCANNING : form-and-join3_2.h ● FORM_AND_JOIN_PAN_ID_SCAN : form-and-join3_2.h ● formAndJoinScanType : form-and-join3_2.h ● formZigbeeNetwork3_2() : form-and-join3_2.h ● FULL_DEBUG : ember-debug.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x66.htm [10/29/2010 2:44:55 PM]

711

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 712: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

Index - _ - a - b - c - d - e - f ● h - i - j - l - m - n - o - p - r - s - t - u - w - z -

- h -

● HAL_RESERVED_RAM_BANDS : 128/reserved-ram.h ● HAL_RESERVED_RAM_BOOTLOADER_KEY : 128/reserved-ram.h ● HAL_RESERVED_RAM_CHANNEL : 128/reserved-ram.h ● HAL_RESERVED_RAM_CSTACK_H : 128/reserved-ram.h , 32/reserved-ram.h ● HAL_RESERVED_RAM_CSTACK_L : 32/reserved-ram.h , 128/reserved-ram.h ● HAL_RESERVED_RAM_EUI64_ID : 128/reserved-ram.h ● HAL_RESERVED_RAM_GATEWAY_ID : 128/reserved-ram.h ● HAL_RESERVED_RAM_MODE : 128/reserved-ram.h ● HAL_RESERVED_RAM_NODE_ID : 128/reserved-ram.h ● HAL_RESERVED_RAM_PAN_ID : 128/reserved-ram.h ● HAL_RESERVED_RAM_PC_DIAG : 32/reserved-ram.h , 128/reserved-ram.h ● HAL_RESERVED_RAM_POWER : 128/reserved-ram.h ● HAL_RESERVED_RAM_RESET_CAUSE : 128/reserved-ram.h , 32/reserved-ram.h ● HAL_RESERVED_RAM_RESET_CAUSE_B : 32/reserved-ram.h , 128/reserved-ram.h ● HAL_RESERVED_RAM_RSTACK_H : 128/reserved-ram.h , 32/reserved-ram.h ● HAL_RESERVED_RAM_RSTACK_L : 32/reserved-ram.h , 128/reserved-ram.h ● halAdcCalibrate() : adc.h ● HalBoardLed : led.h ● HalBoardLedPins : host.h , dev0470.h , dev0473.h ● halBootloadAdjustFlash : bootloader-interface-standalone-v1.h ● halBootloadAppStart : bootloader-interface-standalone-v1.h ● halButtonIsr() : button.h ● halButtonPinState() : button.h ● halButtonState() : button.h ● halClearLed() : led.h ● halCommonCrc16() : crc.h ● halCommonCrc32() : crc.h ● halCommonGetInt16uMillisecondTick() : system-timer.h ● halCommonGetInt16uQuarterSecondTick() : system-timer.h ● halCommonGetInt32uMillisecondTick() : system-timer.h ● halCommonGetRandom() : random.h ● halCommonIdleForMilliseconds() : system-timer.h ● halCommonInitSpi() : spi.h ● halCommonSetSystemTime() : avr-atmega/32/system-timer.h ● halCommonSpiRead() : spi.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x68.htm (1 of 3) [10/29/2010 2:44:55 PM]

712

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 713: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

● halCommonSpiReadWrite() : spi.h ● halCommonSpiWrite() : spi.h ● halConvertValueToVolts() : adc.h ● halGetEm2xxResetInfo : micro.h ● halGetResetInfo() : micro.h ● halGetResetString() : micro.h ● halGetStandaloneBootloaderVersion() : bootloader-interface-standalone.h ● halIdleForMilliseconds : system-timer.h ● halInternalAdjustFlashBlock() : bootloader-interface-standalone-v1.h ● halInternalAssertFailed() : micro.h , iar.h ● halInternalForceReadUartByte() : hal/micro/serial.h ● halInternalForceWriteUartData() : hal/micro/serial.h ● halInternalInitAdc() : adc.h ● halInternalInitBoard : dev0473.h , dev0470.h , host.h ● halInternalInitButton() : button.h ● halInternalInitLed() : led.h ● halInternalPowerDownBoard : host.h , dev0470.h , dev0473.h ● halInternalPowerDownUart() : hal/micro/serial.h ● halInternalPowerUpBoard : dev0470.h , host.h , dev0473.h ● halInternalPowerUpUart() : hal/micro/serial.h ● halInternalRestartUart() : hal/micro/serial.h ● halInternalSleepAdc() : adc.h ● halInternalStandaloneBootloaderTrap() : bootloader-interface-standalone-v1.h ● halInternalStartSystemTimer() : system-timer.h ● halInternalStartUartTx() : hal/micro/serial.h ● halInternalStopUartTx() : hal/micro/serial.h ● halInternalUart1FlowControlRxIsEnabled() : hal/micro/serial.h ● halInternalUart1TxIsIdle() : hal/micro/serial.h ● halInternalUart1XonRefreshDone() : hal/micro/serial.h ● halInternalUartFlowControl : hal/micro/serial.h ● halInternalUartInit() : hal/micro/serial.h ● halInternalUartRxPump : hal/micro/serial.h ● halInternalWaitUartTxComplete() : hal/micro/serial.h ● halLaunchStandaloneBootloader() : bootloader-interface-standalone.h ● halLaunchStandaloneBootloaderV1() : bootloader-interface-standalone-v1.h ● halNcpFrame : spi-protocol.h ● halNcpHardReset() : spi-protocol.h ● halNcpHardResetReqBootload() : spi-protocol.h ● halNcpHasData() : spi-protocol.h ● halNcpIsAwakeIsr() : spi-protocol.h ● halNcpPollForResponse() : spi-protocol.h ● halNcpSendCommand() : spi-protocol.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x68.htm (2 of 3) [10/29/2010 2:44:55 PM]

713

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 714: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

● halNcpSendRawCommand() : spi-protocol.h ● halNcpSerialInit() : spi-protocol.h ● halNcpSerialPowerdown() : spi-protocol.h ● halNcpSerialPowerup() : spi-protocol.h ● halNcpSpipErrorByte : spi-protocol.h ● halNcpVerifySpiProtocolActive() : spi-protocol.h ● halNcpVerifySpiProtocolVersion() : spi-protocol.h ● halNcpWakeUp() : spi-protocol.h ● halPlayTune_P() : buzzer.h ● halReadAdcBlocking() : adc.h ● halRequestAdcData() : adc.h ● halResetWatchdog : iar.h ● halSetLed() : led.h ● halSleepForMilliseconds() : system-timer.h ● halSleepForQuarterSeconds() : system-timer.h ● halStackIndicateActivity() : led.h ● halStackIndicatePresence() : buzzer.h ● halStackProcessBootCount() : micro.h ● halStackReceiveVuartMessage() : hal/micro/serial.h ● halStackSeedRandom() : random.h ● halStackTriggerDebugTimeSyncCapture() : avr-atmega/32/micro.h , avr-atmega/128/

micro.h ● halStartAdcConversion() : adc.h ● halToggleLed() : led.h ● halUart0InitTiny : uart.h ● halUart0ReadByteTimeoutTiny() : uart.h ● halUart0WriteByteTiny : uart.h ● HANDLE_PENDING_INTERRUPTS : iar.h ● handler : ember-types.h ● hostBootloadReinitHandler() : bootload-ezsp-utils.h ● hostBootloadUtilLaunchRequestHandler() : bootload-ezsp-utils.h ● hostBootloadUtilQueryResponseHandler() : bootload-ezsp-utils.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x68.htm (3 of 3) [10/29/2010 2:44:55 PM]

714

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 715: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

Index - _ - a - b - c - d - e - f - h ● i - j - l - m - n - o - p - r - s - t - u - w - z -

- i -

● IEEE_ADDRESS_REQUEST : ember-types.h ● IEEE_ADDRESS_RESPONSE : ember-types.h ● ignoreNextEzspError : bootload-ezsp-utils.h ● INC8 : ash-protocol.h ● INITIAL_CRC : crc.h ● int16s : iar.h ● int16u : iar.h ● int32s : iar.h ● int32u : iar.h ● int8s : iar.h ● int8u : iar.h ● INTER_COMMAND_SPACING : dev0470.h , dev0473.h ● INTER_PAN_BROADCAST : ami-inter-pan.h , ami-inter-pan-host.h ● INTER_PAN_MULTICAST : ami-inter-pan-host.h , ami-inter-pan.h ● INTER_PAN_UNICAST : ami-inter-pan.h , ami-inter-pan-host.h ● INTERRUPTS_ARE_OFF : iar.h ● INTERRUPTS_OFF : iar.h ● INTERRUPTS_ON : iar.h ● INTERRUPTS_WERE_ON : iar.h ● IS_BOOTLOADING : bootload-utils.h ● isTheSameEui64() : bootload-ezsp-utils.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x69.htm [10/29/2010 2:44:56 PM]

715

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 716: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

Index - _ - a - b - c - d - e - f - h - i ● j - l - m - n - o - p - r - s - t - u - w - z -

- j -

● joinZigbeeNetwork3_2() : form-and-join3_2.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x6a.htm [10/29/2010 2:44:56 PM]

716

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 717: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

Index - _ - a - b - c - d - e - f - h - i - j ● l - m - n - o - p - r - s - t - u - w - z -

- l -

● LEAVE_REQUEST : ember-types.h ● LEAVE_REQUEST_REJOIN_FLAG : ember-types.h ● LEAVE_REQUEST_REMOVE_CHILDREN_FLAG : ember-types.h ● LEAVE_RESPONSE : ember-types.h ● LED_DDR : dev0473.h , dev0470.h ● LED_PORT : dev0473.h , dev0470.h ● LQI_TABLE_REQUEST : ember-types.h ● LQI_TABLE_RESPONSE : ember-types.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x6c.htm [10/29/2010 2:44:57 PM]

717

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 718: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

Index - _ - a - b - c - d - e - f - h - i - j - l ● m - n - o - p - r - s - t - u - w - z -

- m -

● MAIN_FUNCTION_ARGUMENTS : iar.h ● MAIN_FUNCTION_PARAMETERS : iar.h ● makeInterPanMessage() : ami-inter-pan-host.h , ami-inter-pan.h ● MATCH_DESCRIPTORS_REQUEST : ember-types.h ● MATCH_DESCRIPTORS_RESPONSE : ember-types.h ● MAX_INTER_PAN_HEADER_SIZE : ami-inter-pan.h , ami-inter-pan-host.h ● MAX_INTER_PAN_MAC_SIZE : ami-inter-pan.h , ami-inter-pan-host.h ● MAX_STUB_APS_SIZE : ami-inter-pan.h , ami-inter-pan-host.h ● MILLISECOND_TICKS_PER_SECOND : avr-atmega/128/micro.h , avr-atmega/32/

micro.h ● MOD8 : ash-protocol.h ● MULTICAST_BINDING : ember-types.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x6d.htm [10/29/2010 2:44:57 PM]

718

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 719: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

Index - _ - a - b - c - d - e - f - h - i - j - l - m ● n - o - p - r - s - t - u - w - z -

- n -

● NameOfType : hal/micro/serial.h ● ncpError : ash-host.h ● ncpSleepEnabled : ash-host.h ● NETWORK_ADDRESS_REQUEST : ember-types.h ● NETWORK_ADDRESS_RESPONSE : ember-types.h ● NETWORK_DISCOVERY_REQUEST : ember-types.h ● NETWORK_DISCOVERY_RESPONSE : ember-types.h ● NM_CHANNEL_MASK : network-manager.h ● NM_WARNING_LIMIT : network-manager.h ● NM_WATCHLIST_SIZE : network-manager.h ● NM_WINDOW_SIZE : network-manager.h ● nmUtilChangeChannelRequest() : network-manager.h ● nmUtilProcessIncoming() : network-manager.h ● nmUtilWarningHandler() : network-manager.h ● NO_BOOTLOADER_MODE : bootloader-interface-standalone.h ● NO_DEBUG : ember-debug.h ● NO_STRIPPING : iar.h ● NODE_DESCRIPTOR_REQUEST : ember-types.h ● NODE_DESCRIPTOR_RESPONSE : ember-types.h ● nodeBlVersion : bootload-ezsp-utils.h ● nodeMicro : bootload-ezsp-utils.h ● nodePhy : bootload-ezsp-utils.h ● nodePlat : bootload-ezsp-utils.h ● NONE : hal/micro/serial.h ● NOTE_A3 : buzzer.h ● NOTE_A4 : buzzer.h ● NOTE_A5 : buzzer.h ● NOTE_Ab3 : buzzer.h ● NOTE_Ab4 : buzzer.h ● NOTE_Ab5 : buzzer.h ● NOTE_B3 : buzzer.h ● NOTE_B4 : buzzer.h ● NOTE_B5 : buzzer.h ● NOTE_Bb3 : buzzer.h ● NOTE_Bb4 : buzzer.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x6e.htm (1 of 2) [10/29/2010 2:44:58 PM]

719

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 720: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

● NOTE_Bb5 : buzzer.h ● NOTE_C3 : buzzer.h ● NOTE_C4 : buzzer.h ● NOTE_C5 : buzzer.h ● NOTE_D3 : buzzer.h ● NOTE_D4 : buzzer.h ● NOTE_D5 : buzzer.h ● NOTE_Db3 : buzzer.h ● NOTE_Db4 : buzzer.h ● NOTE_Db5 : buzzer.h ● NOTE_E3 : buzzer.h ● NOTE_E4 : buzzer.h ● NOTE_E5 : buzzer.h ● NOTE_Eb3 : buzzer.h ● NOTE_Eb4 : buzzer.h ● NOTE_Eb5 : buzzer.h ● NOTE_F3 : buzzer.h ● NOTE_F4 : buzzer.h ● NOTE_F5 : buzzer.h ● NOTE_G3 : buzzer.h ● NOTE_G4 : buzzer.h ● NOTE_G5 : buzzer.h ● NOTE_Gb3 : buzzer.h ● NOTE_Gb4 : buzzer.h ● NOTE_Gb5 : buzzer.h ● NUM_ADC_USERS : adc.h ● NWK_UPDATE_REQUEST : ember-types.h ● NWK_UPDATE_RESPONSE : ember-types.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x6e.htm (2 of 2) [10/29/2010 2:44:58 PM]

720

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 721: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

Index - _ - a - b - c - d - e - f - h - i - j - l - m - n ● o - p - r - s - t - u - w - z -

- o -

● ODD : hal/micro/serial.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x6f.htm [10/29/2010 2:44:58 PM]

721

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 722: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

Index - _ - a - b - c - d - e - f - h - i - j - l - m - n - o ● p - r - s - t - u - w - z -

- p -

● parseInterPanMessage() : ami-inter-pan.h , ami-inter-pan-host.h ● PERFORM_BOUNDS_CHECKING : command-interpreter.h ● PERMIT_JOINING_REQUEST : ember-types.h ● PERMIT_JOINING_RESPONSE : ember-types.h ● PGM : iar.h ● PGM_NO_CONST : iar.h ● PGM_P : iar.h ● PGM_PU : iar.h ● PLATCOMMONOKTOINCLUDE : iar.h ● PointerType : iar.h ● POWER_DESCRIPTOR_REQUEST : ember-types.h ● POWER_DESCRIPTOR_RESPONSE : ember-types.h ● printBigEndianEui64() : bootload-ezsp-utils.h ● printLittleEndianEui64() : bootload-ezsp-utils.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x70.htm [10/29/2010 2:44:58 PM]

722

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 723: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

Index - _ - a - b - c - d - e - f - h - i - j - l - m - n - o - p ● r - s - t - u - w - z -

- r -

● readAckRx() : ash-host-priv.h ● readAckTx() : ash-host-priv.h ● readAshTimeouts() : ash-host-priv.h ● readFrmReTx() : ash-host-priv.h ● readFrmRx() : ash-host-priv.h ● readFrmTx() : ash-host-priv.h ● readRxControl() : ash-host-priv.h ● readTxControl() : ash-host-priv.h ● RESET_ASSERT : avr-atmega/32/micro.h , avr-atmega/128/micro.h ● RESET_BOOTLOADER : avr-atmega/128/micro.h , avr-atmega/32/micro.h ● RESET_BOOTLOADER_IMG_BAD : avr-atmega/32/micro.h , avr-atmega/128/micro.

h ● RESET_BROWNOUT : avr-atmega/32/micro.h , avr-atmega/128/micro.h ● RESET_CAUSE_ASSERT_BIT : 32/reserved-ram.h , 128/reserved-ram.h ● RESET_CAUSE_BOOTLOADER_BIT : 32/reserved-ram.h , 128/reserved-ram.h ● RESET_CAUSE_CSTACK_BIT : 32/reserved-ram.h , 128/reserved-ram.h ● RESET_CAUSE_RSTACK_BIT : 128/reserved-ram.h , 32/reserved-ram.h ● RESET_CAUSE_SELF_WDOG : 32/reserved-ram.h , 128/reserved-ram.h ● RESET_CAUSE_SOFTWARE_BIT : 128/reserved-ram.h , 32/reserved-ram.h ● RESET_CSTACK : avr-atmega/128/micro.h , avr-atmega/32/micro.h ● RESET_EXTERNAL : avr-atmega/32/micro.h , avr-atmega/128/micro.h ● RESET_FLASH_VERIFY_FAIL : avr-atmega/32/micro.h , avr-atmega/128/micro.h ● RESET_FLASH_WRITE_INHIBIT : avr-atmega/128/micro.h , avr-atmega/32/micro.h ● RESET_JTAG : avr-atmega/32/micro.h , avr-atmega/128/micro.h ● RESET_PC_ROLLOVER : avr-atmega/128/micro.h , avr-atmega/32/micro.h ● RESET_POWERON : avr-atmega/128/micro.h , avr-atmega/32/micro.h ● RESET_PROTFAULT : avr-atmega/128/micro.h , avr-atmega/32/micro.h ● RESET_RSTACK : avr-atmega/128/micro.h , avr-atmega/32/micro.h ● RESET_SOFTWARE : avr-atmega/128/micro.h , avr-atmega/32/micro.h ● RESET_UNKNOWN : avr-atmega/32/micro.h , avr-atmega/128/micro.h ● RESET_WATCHDOG : avr-atmega/32/micro.h , avr-atmega/128/micro.h ● RESTORE_INTERRUPTS : iar.h ● RESTORE_INTERRUPTS_LITE : iar.h ● reTxQueue : ash-host-queues.h ● ROUTING_TABLE_REQUEST : ember-types.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x72.htm (1 of 2) [10/29/2010 2:44:59 PM]

723

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 724: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

● ROUTING_TABLE_RESPONSE : ember-types.h ● RX_FREE_HWM : ash-host-queues.h ● RX_FREE_LWM : ash-host-queues.h ● rxFree : ash-host-queues.h ● rxQueue : ash-host-queues.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x72.htm (2 of 2) [10/29/2010 2:44:59 PM]

724

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 725: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

Index - _ - a - b - c - d - e - f - h - i - j - l - m - n - o - p - r ● s - t - u - w - z -

- s -

● scanError() : form-and-join3_2.h ● SERIAL_PORT_CLI : linux-serial.h ● SERIAL_PORT_RAW : linux-serial.h ● SerialBaudRate : hal/micro/serial.h ● SIGNED_ENUM : iar.h ● SIMPLE_DESCRIPTOR_REQUEST : ember-types.h ● SIMPLE_DESCRIPTOR_RESPONSE : ember-types.h ● simulatedSerialTimePasses : iar.h ● simulatedTimePasses : iar.h ● simulatedTimePassesMs : iar.h ● SPIP_MISO : dev0470.h , dev0473.h ● SPIP_MISO_DDR : dev0470.h , dev0473.h ● SPIP_MISO_PORT : dev0470.h , dev0473.h ● SPIP_MOSI : dev0470.h , dev0473.h ● SPIP_MOSI_DDR : dev0473.h , dev0470.h ● SPIP_MOSI_PORT : dev0473.h , dev0470.h ● SPIP_nHOST_INT : dev0470.h , dev0473.h ● SPIP_nHOST_INT_DDR : dev0473.h , dev0470.h ● SPIP_nHOST_INT_PIN : dev0470.h , dev0473.h ● SPIP_nHOST_INT_PORT : dev0470.h , dev0473.h ● SPIP_nRESET : dev0470.h , dev0473.h ● SPIP_nRESET_DDR : dev0473.h , dev0470.h ● SPIP_nRESET_PORT : dev0473.h , dev0470.h ● SPIP_nSSEL : dev0473.h , dev0470.h ● SPIP_nSSEL_DDR : dev0473.h , dev0470.h ● SPIP_nSSEL_PORT : dev0473.h , dev0470.h ● SPIP_nWAKE : dev0470.h , dev0473.h ● SPIP_nWAKE_DDR : dev0470.h , dev0473.h ● SPIP_nWAKE_PORT : dev0470.h , dev0473.h ● SPIP_SCLK : dev0470.h , dev0473.h ● SPIP_SCLK_DDR : dev0473.h , dev0470.h ● SPIP_SCLK_PORT : dev0473.h , dev0470.h ● spipTest() : spi-protocol.h ● SRAM_BASE : 128/reserved-ram.h , 32/reserved-ram.h ● SRAM_END : 32/reserved-ram.h , 128/reserved-ram.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x73.htm (1 of 2) [10/29/2010 2:44:59 PM]

725

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 726: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

● STANDALONE_BOOTLOADER_NORMAL_MODE : bootloader-interface-standalone.h

● STANDALONE_BOOTLOADER_RECOVERY_MODE : bootloader-interface-standalone.h

● START_ATOMIC_CLOCK : iar.h ● STARTUP_TIMEOUT_COUNT : dev0473.h , dev0470.h ● STARTUP_TIMEOUT_SINGLE : dev0470.h , dev0473.h ● STOP_ATOMIC_CLOCK : iar.h ● STUB_NWK_FRAME_CONTROL : ami-inter-pan.h , ami-inter-pan-host.h ● STUB_NWK_SIZE : ami-inter-pan-host.h , ami-inter-pan.h ● SYSTEM_SERVER_DISCOVERY_REQUEST : ember-types.h ● SYSTEM_SERVER_DISCOVERY_RESPONSE : ember-types.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x73.htm (2 of 2) [10/29/2010 2:44:59 PM]

726

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 727: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

Index - _ - a - b - c - d - e - f - h - i - j - l - m - n - o - p - r - s ● t - u - w - z -

- t -

● TCCR1B_CONFIGURATION : dev0470.h , dev0473.h ● TEMP_GREATER_THAN_MAX_ARG_SIZE : command-interpreter.h ● TEMP_SENSOR_ADC_CHANNEL : dev0470.h , host.h , dev0473.h ● TEMP_SENSOR_SCALE_FACTOR : host.h , dev0473.h , dev0470.h ● TICKS_PER_QUARTER_SECOND : bootload-ezsp-utils.h ● TRACE_EVENTS : ash-host.h ● TRACE_EZSP : ash-host.h ● TRACE_EZSP_VERBOSE : ash-host.h ● TRACE_FRAMES_BASIC : ash-host.h ● TRACE_FRAMES_VERBOSE : ash-host.h ● TX_POOL_BUFFERS : ash-host-queues.h ● txFree : ash-host-queues.h ● txQueue : ash-host-queues.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x74.htm [10/29/2010 2:45:00 PM]

727

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 728: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

Index - _ - a - b - c - d - e - f - h - i - j - l - m - n - o - p - r - s - t ● u - w - z -

- u -

● UNBIND_REQUEST : ember-types.h ● UNBIND_RESPONSE : ember-types.h ● UNICAST_BINDING : ember-types.h ● UNICAST_MANY_TO_ONE_BINDING : ember-types.h ● UNUSED : iar.h ● USER_DESCRIPTOR_CONFIRM : ember-types.h ● USER_DESCRIPTOR_REQUEST : ember-types.h ● USER_DESCRIPTOR_RESPONSE : ember-types.h ● USER_DESCRIPTOR_SET : ember-types.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x75.htm [10/29/2010 2:45:00 PM]

728

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 729: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

Index - _ - a - b - c - d - e - f - h - i - j - l - m - n - o - p - r - s - t - u ● w - z -

- w -

● WAIT_SECTION_TIMEOUT : dev0470.h , dev0473.h ● WAKE_HANDSHAKE_TIMEOUT : dev0473.h , dev0470.h ● WITHIN_RANGE : ash-protocol.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x77.htm [10/29/2010 2:45:00 PM]

729

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved

Page 730: EmberZNet API Reference: For the EM260 Co · PDF fileEmberZNet API Reference: For the EM260 Co-Processor: ... This data structure contains a DSA signature. ... EMBER_REPORT_COUNTERS_REQUEST

EmberZNet API Reference: For the EM260 Co-Processor: Data Fields

Index - _ - a - b - c - d - e - f - h - i - j - l - m - n - o - p - r - s - t - u - w ● z -

- z -

● ZDO_MESSAGE_OVERHEAD : zigbee-device-common.h

file:///C|/dev/perforce/software/v2/tephra-park/doxygen/Output/API_EM260_forPDF/globals_0x7a.htm [10/29/2010 2:45:01 PM]

730

EmberZNet API EM260 120-3020-000K Copyright © 2006-2010 Ember Corporation. All rights reserved