Low Power Networking Application

This sample shows how to collect data transmitted from low-power devices, employing the simplest power management strategy. There must be one and only coordinator, and the rest of nodes must be configured as end devices. At least 2 nodes are participating, but up to 8 nodes (coordinator and 7 end devices) can be engaged.

For simple node identification, define unique logical addresses by DIP switches. When setting 8 possible DIP combinations, keep in mind that:

NodeDIP switches
SW4:1SW4:2SW4:3
0OFFOFFOFF
1ONOFFOFF
2OFFONOFF
3ONONOFF
4OFFOFFON
5ONOFFON
6OFFONON
7ONONON

To start the application and to initiate the network push SW1 button on each node, starting with coordinator. Green LED is switched ON if the network is started successfully.

Coordinator organizes the network with its own 'unique' PAN ID which is determined by its MAC address (considering the 16 least significant bits). Besides, user can set PAN ID in flash memory or EEPROM. In order to join, end devices are scanning the network.

End device measures temperature each 10 seconds and sends data to coordinator if the absolute increment of the measured value exceeds 0.5°C. Flashing red LED indicates data transmission, while receiving data is labelled with yellow LED. After the transmission is completed, the end device falls asleep. Unconditionally, the current temperature value is also sent if SW2 button is pressed on an end device, regardless the current node mode (sleeping or active). Do not abuse the device with quick series of multiple clicks, since this may cause unstable work.

Coordinator never sleeps; it keeps sending the received temperature data to UART via USB (see connection settings).

In order to help understanding the application code easier, two different image files are supplied, intended for programming the coordinator and end device, correspondingly.

Configuration parameters

Parameters valid for all devices:
APP_CHANNEL_MASKSpecifies channels to be tried by nodes for network operation
APP_COORD_UIDCoordinator UID; is used as coordinator MAC address and extended PANID. Must be similar for all devices in a network
TIMER_STARTING_NETWORKLED blinking interval during network start (ms)
Parameters specific for end devices:
APP_USE_APS_ACKIndicates whether the APS level ack will be used or not
CHANGES_THRESHOLDThreshold for temperature difference (values above that should be reported to coordinator if observed)
APP_SLEEP_PERIODInterval between regular wake-ups and temperature difference checks

The source codes for coordinator and end device of Low Power Test application are located at [ZDK]\Sample Applications\LowPower directory.


Generated on Tue Mon Oct 6 15:37:54 2008 for BitCloud Stack Documentation by  doxygen 1.5.1-p1