ST STEVAL-IDZ301V1 Скачать руководство пользователя страница 21

UM1454

Install and run the sink-sensor application

Doc ID 022085 Rev 2

21/28

Install and run the sink-sensor application

The sink-sensor application included in the IDZ3LIB is provided to allow the STEVAL user to 
easily set up a ZigBee network by using the hardware included in the kit. The sink-sensor is 
derived from the homonymous application included in the EmberZnet package libraries and 
shows the basic features of a distributed sensor network for remote monitoring.

The sink-sensor application requires the use of at least two different STEVALs (or other 
compatible hardware), respectively running sink and sensor applications in the same 
network.

3.1 

Sink-sensor sample application

The sensor-sink application is an example of a complete application that implements a 
distributed sensor network with one or more data collection points (called “sensors”) and 
one data storage point (called “sink”). This application uses a “push” style of communication, 
where the sensor periodically sends reports to the sink without needing to be asked for this 
data.

In this specific case, sensors capture temperature data measured by the sensor that is 
integrated in the STEVAL and sends that data to a sink that is connected to a PC. Data 
collected by the sink are then available at serial ports associated to the STEVAL when it is 
connected to a PC and they can be used by every kind of application running on it.

The sink node is also set up to be the ZigBee coordinator device, and it forms the network 
automatically on first startup, therefore retaining these settings across reboots. The sink 
sends out advertisements (SINK_ADVERTISE) at regular intervals using a multicast (after 
making a many-to-one route request). If the joining procedure is activated by pushing a 
button on the board, a not joined sensor hearing a SINK_ADVERTISE sends a message 
(SENSOR_SELECT_SINK) requesting to use that sink (after setting its address table entry 
to the sink). If the sink has a free address table entry it responds with a sink ready message 
(SINK_READY) and, at that point, the sensor is free to send data (DATA) to the sink at fixed 
intervals (as set by SEND_DATA_RATE).

The sink sensor communication is set with the following network parameters:

CHANNEL - 26

PANID   0x01ff

APP_EXTENDED_PANID {'s','e','n','s','o','r',0,0}.

The payload of the packet sent by the sensor is 12 bytes long and it includes:

8 bytes corresponding to the 64-bit address of the sender

2 bytes corresponding to the temperature values as captured by the sensor integrated 
in the STEVAL

2 bytes corresponding to the voltage level as measured on the voltage meter integrated 
in the STEVAL.

The sensor-sink application allows the user to interact with STEVAL by sending commands 
through a serial port (the COM associated to STEVAL when connected to the PC). Refer to 
the sink and sensor source files for the list of supported commands and implementation.

www.BDTIC.com/ST

Содержание STEVAL-IDZ301V1

Страница 1: ...RO Zigbee RF4CE and simplified MAC on the STM32W108CB microcontroller The STEVAL IDZ3xxV HW integrates an RF module belonging to the SPZB32W1x2 x series together with an extended number of external co...

Страница 2: ...4 2 5 3 Configurable button 14 2 5 4 Voltage battery meter 14 2 5 5 Temperature sensor 15 2 5 6 Ground points 15 2 5 7 Test points 15 2 5 8 Setting up STEVAL 16 2 5 9 Powering setup 16 2 5 10 Serial c...

Страница 3: ...sensor application 21 3 1 Sink sensor sample application 21 3 2 Load sink sensor on the STEVAL 22 3 3 Setting up a network and running the sink sensor application 22 4 RoHS compliance 25 Appendix A S...

Страница 4: ...ble 1 The STEVAL IDZ3xxV1 versions 6 Table 2 Abbreviations 6 Table 3 Recommended operating conditions 10 Table 4 Board connections and configuration 11 Table 5 STEVAL interfaces maximum voltage config...

Страница 5: ...mper positioning 16 Figure 9 External power supply JP conf 16 Figure 10 Mini USB power supply JP conf 16 Figure 11 Mini USB connection JP conf 17 Figure 12 RS 232 connection JP conf 17 Figure 13 Boot...

Страница 6: ...ctor STEVAL integrates the following An RF module belonging to the series of ZigBee 802 15 4 SPZB32W1x2 x modules A 20 pin JTAG connector for programming and debugging purposes Hardware support for ap...

Страница 7: ...dded Workbench IDE for ARM is a very powerful integrated development environment used for developing and managing complete embedded application projects Note For programming and or debugging using the...

Страница 8: ...ly tested with the following libraries and ToolSuite versions EmberZnet package versions 4 0 2 and 4 3 0 STM32W_flasher 1 1 0 available on the CD of the kit Sink Sensor example Included in the kit IAR...

Страница 9: ...R UMPER 3UPPLY MAIN VOLTAGE REGULATOR 4 30 7 X 34 4EMPERATURE SENSOR 4 ONNECTOR 2ESET 0USH UTTON 3 0USH UTTONS 5 24 0 XT CONNECTOR UMPER FOR 3ERIAL OOT 53 5 24 RIDGE 3ERIAL 3ELECTOR UMPER MINI53 3ERIA...

Страница 10: ...ons Table 3 Recommended operating conditions Symbol Parameter Conditions Min Typ Max Unit J1 Ext VIN Main board supply voltage 20 C T 70 C 4 5 6 V J2 Ext VIN Alternate board ext battery supply voltage...

Страница 11: ...10 Extension connector PB7 STM32W108CB signal 11 Extension connector PB5 STM32W108CB signal 12 Extension connector PB0 STM32W108CB signal 13 Extension connector PA5 STM32W108CB signal 14 Extension con...

Страница 12: ...able boot jumper See Section 2 5 11 for configuration cases JP3 Jumper Configurable serial jumper RTS pin on the Zigbee module See Section 2 5 10 for configuration cases JP4 Jumper Configurable serial...

Страница 13: ...UM1454 HW description Doc ID 022085 Rev 2 13 28 2 4 STEVAL layout Figure 4 STEVAL layout Figure 5 STEVAL mechanical dimensions mm V V www BDTIC com ST...

Страница 14: ...r Pin 1 Max 6 V external power supply voltage may be used also as supply input if selected by user using the proper jumper positioning This pin is totally user settable pay attention to avoid power su...

Страница 15: ...cations of the device 2 5 6 Ground points The A and B ground points shown in Figure 6 facilitate the stacking of a daughterboard Figure 6 Ground points for daughterboard connection 2 5 7 Test points T...

Страница 16: ...is recommended to use only one power source supply at a time and in particular to remove any other supplier when the mini USB is selected with JP1 Figure 9 and 10 show how the J1 jumper must be config...

Страница 17: ...serial connection by configuring the JP2 jumper as shown in Figure 13 and 14 The Flasher utility integrated in the kit is used to run the boot function as explained in Section 2 6 6 of this manual Fig...

Страница 18: ...hardware configuration files for STEVAL documentation idz3lib contains documents related to the kit and the SPZB32W1x2 x series of modules tools idz3lib contains flasher utility to be used with STEVAL...

Страница 19: ...hen the driver is correctly installed it is possible to see the COM associated to the STEVAL listed in the Ports field of the computer management utility of the PC see Figure 15 If you want to connect...

Страница 20: ...mand syntax Also refer to the batch file contained in tools idz3lib for the syntax of the command to be used to run the flasher Remember to configure the options in the batch file by specifying the co...

Страница 21: ...can be used by every kind of application running on it The sink node is also set up to be the ZigBee coordinator device and it forms the network automatically on first startup therefore retaining the...

Страница 22: ...images on the STEVAL 3 3 Setting up a network and running the sink sensor application This section describes how to use the STEVAL to run the sink sensor application Refer to the source code files fo...

Страница 23: ...join the network set up by the STEVAL sink press the SW3 button on STEVAL sink and the SW3 button on STEVAL sensor in an interval shorter than 60 seconds If this join operation sequence runs successfu...

Страница 24: ...eshold controls how many message timeouts can be permitted between the sensor and sink before the sensor decides to attach itself to a different sink For a sink this controls how many data reports can...

Страница 25: ...d density ZigBee limits the number of broadcasts that can be active in a network to 10 to minimize the network disruption and loss of bandwidth As this network increases in size or density the rate of...

Страница 26: ...RING CIRCUIT 6 MAX 6EXT 2 3 4 053 544 OOTLOADER NABLE 4 5 4 2 4 2 37 37 053 544 37 37 053 544 N N 2 2 2 2 0 0 2 HM 2 HM 5 0 4 44 5 0 4 44 6IN 6OUT N N 2 2 N N N N 2 HM 2 HM 2 2 U 6 U 6 53 4 2 53 4 2 U...

Страница 27: ...on history Doc ID 022085 Rev 2 27 28 Revision history Table 6 Document revision history Date Revision Changes 29 Nov 2011 1 Initial release 12 Dec 2011 2 Minor text changes to improve readability www...

Страница 28: ...OF MERCHANTABILITY FITNESS FOR A PARTICULAR PURPOSE AND THEIR EQUIVALENTS UNDER THE LAWS OF ANY JURISDICTION OR INFRINGEMENT OF ANY PATENT COPYRIGHT OR OTHER INTELLECTUAL PROPERTY RIGHT UNLESS EXPRES...

Отзывы: