Waspmote Digimesh. Networking Guide
|
|
|
- Egbert Short
- 10 years ago
- Views:
Transcription
1 Waspmote Digimesh Networking Guide
2 Index Document version: v1.0-11/2012 Libelium Comunicaciones Distribuidas S.L. INDEX 1. Hardware General Considerations Waspmote Libraries Waspmote XBee Files Constructor API Functions API extension Waspmote reboot Constants pre-defined XBee modules supported Initialization Initializing Setting ON Setting OFF Node Parameters MAC Address PAN ID Node Identifier Channel Network Hops Network Delay Slots Network Route Requests Mesh Network Retries Packet Parameters Structure used in packets Maximum payloads Power Gain and Sensibility Power Level Received Signal Strength Indicator Connectivity Topologies DigiMesh Architecture Routing Route Discovery Process v1.0
3 Index 7.3. Connections Unicast Broadcast Sending Data API Frame Structure Application Header Fragmentation Structure packetxbee Sending without API header Examples Receiving Data Examples Discovering and Searching Nodes Structure used in Discovery Searching specific nodes Node discovery to a specific node Starting a Network Choosing a channel Choosing a PAN ID Joining an Existing Network Network parameters are known Channel PAN ID Network parameters are unknown Node Discovery Node Discovery Function Node Discovery Time Sleep Options Sleep Modes Asynchronous Cyclic Sleep Synchronous Cyclic Sleep Sleep Parameters Sleep Mode Sleep Period Time Before Sleep Sleep Options Sleep Status Missed synchronizations count Operational sleep period Operational wake period ON/OFF Modes v1.0
4 Index 11. Synchronizing the Network Operation Synchronization Messages Becoming a Sleep Coordinator Synchronization Messages Nomination and Election Changing Sleep Parameters Configuration Starting a Sleeping Network Adding a New Node to an Existing Network Changing Sleep Parameters Rejoining Nodes Which Have Lost Sync Security and Data Encryption DigiMesh Security and Data encryption Overview Security in API libraries Encryption Enable Encryption Key Maximum Data Payloads Security in a network Creating a network enabling security Joining a security enabled network Code examples and extended information v1.0
5 Hardware 1. Hardware The XBee and XBee-900 modules can use an optional firmware (DigiMesh) so that they are able of creating mesh networks instead of the usual Star topoplogy. This firmware has been developed by Digi aimed for allowing modules to sleep, synchronise themselves and work on equal terms, avoiding the use of node routers or coordinators that have to be permanently powered on. Characteristics of the implemented protocol: Self Healing: any node can join or leave the network at any moment. P2P architecture: all nodes are equal. There are no father-son relationships. Silent protocol: reduced routing heading due to using a reactive protocol similar to AODV (Ad hoc On-Demand Vector Routing). Route discovery: instead of keeping a route map, routes are discovered when they are needed. Selective ACKs: only the recipient responds to route messages. Reliability: the use of ACKs ensures data transmission reliability. Sleep Modes: low energy consumption modes with synchronisation to wake at the same time. The classic topology of this type of network is mesh, as the nodes can establish point to point connections with brother nodes through the use of parameters such as the MAC or network address or by making multi-jump connections. Figure 1: Mesh topology DigiMesh 2.4GHz Module Frequency Tx Power Sensitivity Channels Distance Normal 2,40 2,48GHz 1mW -92dBm m PRO 2,40 2,48GHz 100mW -100dBm m The XBee DigiMesh modules share the hardware module with the XBee , being able to pass from one to the other by changing the firmware. For this reason, the characteristics relating to the hardware are the same, changing those related with the protocol used. The XBee DigiMesh modules are based on the standard IEEE that supports functionalities enabling mesh topology use. -5- v1.0
6 Hardware DigiMesh 900MHz Frequency Tx Power Sensitivity Channels Distance MHz 50mW -100dBm 12 10km The XBee DigiMesh modules share the hardware module with the XBee-900, being able to pass from one to the other by changing the firmware. For this reason, the characteristics relating to the hardware are the same, changing those related with the protocol used. -6- v1.0
7 General Considerations 2. General Considerations 2.1. Waspmote Libraries Waspmote XBee Files WaspXBeeCore.h ; WaspXBeeCore.cpp, WaspXBeeDM.h, WaspXBeeDM.cpp Constructor To start using the Waspmote XBee DigiMesh library, an object from class WaspXBeeDM must be created. This object, called xbeedm, is created inside the Waspmote XBee DigiMesh library and it is public to all libraries. It is used through the guide to show how Waspmote XBee DigiMesh library works. When creating this constructor, some variables are defined with a value by default API Functions Through the guide there are many examples of using parameters. In these examples, API functions are called to execute the commands, storing in their related variables the parameter value in each case. Example of use xbeedm.getownmaclow(); // Get 32 lower bits of MAC Address xbeedm.getownmachigh(); // Get 32 upper bits of MAC Address Related Variables xbeedm.sourcemachigh[0-3] stores the 32 upper bits of MAC address xbeedm.sourcemaclow [0-3] stores the 32 lower bits of MAC address When returning from xbeedm.getownmaclow the related variable xbeedm.sourcemaclow will be filled with the appropriate values. Before calling the function, the related variable is created but it is empty. There are three error flags that are filled when the function is executed: error_at: it stores if some error occurred during the execution of an AT command function error_rx: it stores if some error occurred during the reception of a packet error_tx: it stores if some error occurred during the transmission of a packet All the functions return a flag to know if the function called was successful or not. Available values for this flag: 0: Success. The function was executed without errors and the variable was filled. 1: Error. The function was executed but an error occurred while executing. 2: Not executed. An error occurred before executing the function. -1: Function not allowed in this module. To store parameter changes after power cycles, it is needed to execute the writevalues function. Example of use xbeedm.writevalues(); // Keep values after rebooting -7- v1.0
8 General Considerations 2.3. API extension All the relevant and useful functions have been included in the Waspmote API, although any XBee command can be sent directly to the transceiver using the sendcommandat function. Example of use xbeedm.sendcommandat( CH# ); // Executes command ATCH Related Variables xbeedm.commandat[0-100] stores the response given by the module up to 100 bytes 2.4. Waspmote reboot When Waspmote is rebooted or it wakes up from a deep sleep state (battery is disconnected) the application code will start again, creating all the variables and objects from the beginning Constants pre-defined There are some constants pre-defined in a file called WaspXBeeConstants.h. These constants define some parameters like the size of each fragment or maximum data size. The most important constants are explained next: MAX_DATA: it defines the maximum available data size for a packet. This constant must be equal or bigger than the data is sent on each packet. This size shouldn t be bigger than DATA_MATRIX: it defines the data size for each fragment. As the maximum payload is 100bytes, there is no reason to make it bigger. MAX_PARSE: it defines the maximum data that is received in each call to treatdata. If more data are received, they will be stored in the UART buffer until the next call to treatdata. However, if the UART buffer is full, the following data will be written on the buffer, so be careful with this matter. MAX_BROTHERS: it defines the maximum number of brothers that can be stored. MAX_FRAG_PACKETS: it defines the maximum number of fragments that can be received from a global packet. If a packet is divided in more fragments, when it is detected all the fragments will be deleted and the packet will be discarded. MAX_FINISH_PACKETS: it defines the maximum number of finished packets that can be stored. DATA_OFFSET: it is used as an input parameter in setdestinationparams. It specifies that the data given as a parameter must be added at the end of the packet. It allows the generation of one packet from several calls to setdestinationparams with different types of data. DATA_ABSOLUTE: it is used as an input parameter in setdestinationparams. It specifies that the data given as a parameter are the data to send. It also sets the addresses to the packet. XBEE_LIFO: it specifies the LIFO replacement policy. If one packet is received and the finished packets array is full, this policy will free the previous packet received and it will store the data from the last packet. XBEE_FIFO: it specifies the FIFO replacement policy. If one packet is received and the finished packets array is full, this policy will free the first packet received and it will store the data from the last packet. XBEE_OUT: it specifies the OUT replacement policy. If one packet is received and the finished packets array is full, this policy will discard this packet XBee modules supported DigiMesh can be used on two XBee modules: XBee and XBee 900MHz. There are some differences between both modules as the frequency used (2.4GHz vs 900MHz) or the power transmission. -8- v1.0
9 Initialization 3. Initialization Before starting to use a module, it needs to be initialized. During this process, the UART to communicate with the module has to be opened and the XBee switch has to be set on Initializing It initializes all the global variables that will be used later. It returns nothing. The initialized variables are: protocol: specifies the protocol used (DigiMesh in this case). freq: specifies the frequency used (2,4GHz or 900MHz in this case). model: specifies the model used. XBee Series I has two possible models: Normal (2mW) or PRO (50mW) and XBee 900MHz has one model (50mW). totalfragmentsreceived: specifies the number of fragments expected from a packet. pendingpackets: specifies the packets pending of fragments to be completed. pos: specifies the position to use in received packets. discoveryoptions: specifies the options in Node Discovery. awaketime: specifies the time to be awake before go sleeping. sleeptime: specifies the time to be sleeping. scanchannels: specifies the channels to scan. scantime: specifies the time to scan each channel. timeenergychannel: specifies the time the channels will be scanned. encryptmode: specifies if encryption mode is enabled. powerlevel: specifies the power transmission level. timerssi: specifies the time RSSI LEDs are on. sleepoptions: specifies the options for sleeping. networkhops: specifies the maximum number of hops expected to be seen in a network route. netdelayslots: specifies the maximum random number of network delay slots before rebroadcasting a network packet. netrouterequest: specifies the maximum number of route discovery retries allowed to find a path to the destination node. meshnetretries: specifies the maximum number of network packet delivery attempts. Example of use xbeedm.init(digimesh,freq2_4g,normal); // initializes the variables Expansion Radio Board (XBee Digimesh) The new Expansion Board allows to connect two radios at the same time in the Waspmote sensor platform. This means a lot of different combinations are now possible using any of the six radios available for Waspmote: , ZigBee, Bluetooth, RFID, Wifi, GPRS, 868 MHz and 900 MHz. Some of the possible combinations are: ZigBee - Bluetooth ZigBee - RFID ZigBee - Wifi ZigBee - GPRS Bluetooth - RFID RFID - GPRS etc. Remark: the GPRS module does not need the Expansion Board to be connected to Waspmote. It can be plugged directly in the GPRS socket. -9- v1.0
10 Initialization In the next photo you can see the sockets available along with the UART assigned. On one hand, SOCKET0 allows to plug any kind of radio module through the UART0. On the other hand, SOCKET1 permits to connect a radio module through the UART1. The API provides a function in order to initialize the XBee module called init. This function supports a new parameter which permits to select the UART. It is possible to choose between UART0 or UART1. The initialization function is the following: xbeedm.init(digimesh,freq2_4g,normal,uart); Selecting UART0: xbeedm.init(digimesh,freq2_4g,normal,uart0); Selecting UART1: xbeedm.init(digimesh,freq2_4g,normal,uart1); In case two XBee Digimesh modules are needed (each one in each socket), it will be necessary to create a new object from WaspXBeeDM class. By default, there is already an object called xbeedm normally used for UART0 regular socket. In order to create a new object it is necessary to put the following declaration in your Waspmote code: WaspXBeeDM xbeedm_2 = WaspXBeeDM(); Finally, it is necessary to initialize both modules. For example, xbeedm is initialized in UART0 and xbeedm_2 in UART1 as follows: xbeedm.init(digimesh,freq2_4g,normal,uart0); xbeedm_2.init(digimesh,freq2_4g,normal,uart1); The rest of functions are used the same way as they are used with older API versions. In order to understand them we recommend to read this guide v1.0
11 Initialization WARNING: Avoid to use DIGITAL7 pin when working with Expansion Board. This pin is used for setting the XBee into sleep. Avoid to use DIGITAL6 pin when working with Expansion Board. This pin is used as power supply for the Expansion Board. Incompatibility with Sensor Boards: Gases Board: Incompatible with SOCKET4 and NO 2 /O 3 sensor. Agriculture Board: Incompatible with Sensirion and the atmospheric pressure sensor. Smart Metering Board: Incompatible with SOCKET11 and SOCKET13. Smart Cities Board: Incompatible with microphone and the CLK of the interruption shift register. Events Board: Incompatible with interruption shift register Setting ON It opens the UART and switches the XBee ON. The baud rate used to open the UART is defined on the library (38400bps by default). Example of use xbeedm.on(); // Opens the UART and switches the XBee ON 3.3. Setting OFF It closes the UART and switches the XBee OFF. Example of use xbeedm.off(); // Closes the UART and switches the XBee OFF -11- v1.0
12 Node Parameters 4. Node Parameters When configuring a node, it is necessary to set some parameters which will be used lately in the network, and some parameters necessary for using the API functions MAC Address A 64-bit RF module s unique IEEE address. It is divided in two groups of 32 bits (High and Low). It identifies uniquely a node inside a network due to it can not be modified and it is given by the manufacturer. Example of use xbeedm.getownmaclow(); // Get 32 lower bits of MAC Address xbeedm.getownmachigh(); // Get 32 upper bits of MAC Address Related Variables xbeedm.sourcemachigh[0-3] stores the 32 upper bits of MAC address xbeedm.sourcemaclow [0-3] stores the 32 lower bits of MAC address 4.2. PAN ID A 16-bit number that identifies the network. It must be unique to differentiate a network. All the nodes in the same network should have the same PAN ID. Example of use panid=0x33,0x31; // array containing the PAN ID xbeedm.setpan(panid); // Set PANID xbeedm.getpan(); // Get PANID Related Variables xbeedm.pan_id[0-7] stores the 16-bit PAN ID. It is stored in the two first positions Node Identifier A max 20-character ASCII string which identifies the node in a network. It is used to identify a node in the application level. It is also used to search a node using its NI. Example of use xbeedm.setnodeidentifier( forrestnode-01# ); // Set forrestnode-01 as NI xbeedm.getnodeidentifier(); // Get NI Related Variables xbeedm.nodeid[0-19] stores the 20-byte max string Node Identifier -12- v1.0
13 Node Parameters 4.4. Channel This parameter defines the frequency channel used by the module to transmit and receive. When working on 2,4GHz band, DigiMesh defines 16 channels to be used: GHz : 16 channels Figure 2: Operating Frequency Bands on 2,4GHz However, 900MHz band can also be used with DigiMesh, defining 12 channels: MHz : 12 channels Figure 3: Operating Frequency Bands on 2,4GHz Channel Number Frequency Supported by 0x0B Channel 11 2,400 2,405 GHz Normal 0x0C Channel 12 2,405 2,410 GHz Normal / PRO 0x0D Channel 13 2,410 2,415 GHz Normal / PRO 0x0E Channel 14 2,415 2,420 GHz Normal / PRO 0x0F Channel 15 2,420 2,425 GHz Normal / PRO 0x10 Channel 16 2,425 2,430 GHz Normal / PRO 0x11 Channel 17 2,430 2,435 GHz Normal / PRO 0x12 Channel 18 2,435 2,440 GHz Normal / PRO 0x13 Channel 19 2,440 2,445 GHz Normal / PRO 0x14 Channel 20 2,445 2,450 GHz Normal / PRO 0x15 Channel 21 2,450 2,455 GHz Normal / PRO 0x16 Channel 22 2,455 2,460 GHz Normal / PRO 0x17 Channel 23 2,460 2,465 GHz Normal / PRO 0x18 Channel 24 2,465 2,470 GHz Normal 0x19 Channel 25 2,470 2,475 GHz Normal 0x1A Channel 26 2,475 2,480 GHz Normal Figure 4: Channel Frequency Numbers on 2,4GHz -13- v1.0
14 Node Parameters Channel Number 0x01 Channel 1 0x02 Channel 2 0x03 Channel 3 0x04 Channel 4 0x05 Channel 5 0x06 Channel 6 0x07 Channel 7 0x08 Channel 8 0x09 Channel 9 0x0A Channel 10 0x0B Channel 11 0x0C Channel 12 Frequency ,16 GHz 904,16 906,32 GHz 906,32 908,48 GHz 908,48 910,64 GHz 910,64 912,80 GHz 912,80 914,96 GHz 914,96 917,12 GHz 917,12 919,28 GHz 919,28 921,44 GHz 921,44 923,6 GHz 923,6 925,76 GHz 925, GHz Figure 5: Channel Frequency Numbers on 902MHz Example of use xbeedm.setchannel(0x0c); // Set channel xbeedm.getchannel(); // Get Channel Related Variables xbeedm.channel stores the operating channel 4.5. Network Hops It specifies the maximum number of hops expected to be seen in a network route. Example of use xbeedm.setnetworkhops(0x07); // Set network hops xbeedm.getnetworkhops(); // Get network hops Related Variables xbeedm.networkhops stores the number of hops selected 4.6. Network Delay Slots It specifies the maximum random number of network delay slots before rebroadcasting a network packet. Example of use xbeedm.setnetworkdelayslots(0x03); // Set network delay slots xbeedm.getnetworkdelayslots(); // Get network delay slots Related Variables xbeedm.netdelayslots stores the number of delay slots -14- v1.0
15 Node Parameters 4.7. Network Route Requests It specifies the maximum number of route discovery retries allowed to find a path to the destination node. Example of use xbeedm.setnetworkrouterequests(0x03); // Set network route requests xbeedm.getnetworkrouterequests(); // Get network route requests Related Variables xbeedm.netrouterequest stores the number of route requests 4.8. Mesh Network Retries It specifies the maximum number of network packet delivery attempts. Example of use xbeedm.setmeshnetworkretries(0x01); // Set mesh network retries xbeedm.getmeshnetworkretries(); // Get mesh network retries Related Variables xbeedm.meshnetretries stores the number of network packet delivery attempts -15- v1.0
16 Packet Parameters 5. Packet Parameters 5.1. Structure used in packets Packets are structured in API libraries using a defined structure called packetxbee. This structure has many fields to be filled by the user or the application: /************ IN ***********/ uint8_t macdl[4]; // 32b Lower Mac Destination uint8_t macdh[4]; // 32b Higher Mac Destination uint8_t mode; // 0=unicast ; 1=broadcast ; 2=cluster ; 3=synchronization uint8_t address_type; // 0=16B ; 1=64B uint8_t nad[2]; // 16b Network Address Destination char data[max_data]; // Data of the sent message. All the data here, even when > Payload uint16_t data_length; // Data sent length. Real used size of vector data[max_data] uint16_t frag_length; // Fragment length. Used to send each fragment of a big packet uint8_t SD; // Source Endpoint uint8_t DE; // Destination Endpoint uint8_t CID[2]; // Cluster Identifier uint8_t PID[2]; // Profile Identifier uint8_t MY_known; // 0=unknown net address ; 1=known net address uint8_t opt; // options: 0x08=Multicast transmission /******** APLICATION *******/ uint8_t packetid; // ID for the packet uint8_t macsl[4]; // 32b Lower Mac Source uint8_t macsh[4]; // 32b Higher Mac Source uint8_t nas[2]; // 16b Network Address Source uint8_t macol[4]; // 32b Lower Mac Origin Source uint8_t macoh[4]; // 32b Higher Mac Origin Source uint8_t nao[2]; // 16b Network Address origin char nio[20]; // Node Identifier Origin. To use in transmission, it must finish #. uint8_t RSSI; // Receive Signal Strength Indicator uint8_t address_types; // 0=16B ; 1=64B uint8_t typesourceid; // 0=naS ; 1=macSource ; 2=NI uint8_t numfragment; // Number of fragment to order the global packet uint8_t endfragment; // Specifies if this fragment is the last fragment of a global packet uint8_t time; // Specifies the time when the first fragment was received /******** OUT **************/ uint8_t deliv_status; // Delivery Status uint8_t discov_status; // Discovery Status uint8_t true_nad[2]; // Network Address the packet has been really sent to uint8_t retries; // Retries needed to send the packet macdl & macdh 64-bit destination address. It is used to specify the MAC address of the destination node. It is used in 64-bit unicast transmissions. mode Transmission mode chosen to transmit that packet. Available values: 0: Unicast transmission 1: Broadcast transmission 2: Application binding transmission, using clusters and endpoints(not used in this protocol) 3: Synchronization packet address_type Address type chosen, between 16-bit and 64-bit addresses v1.0
17 Packet Parameters 0: 16-bit address 1: 64-bit address nad 16-bit Destination Network Address. It is used in 16-bit unicast transmissions. data Data to send in the packet. It is used to store the data to send in unicast or broadcast transmissions to other nodes. All the data to send must be stored in this field. The API function responsible for sending data will take care of fragmenting the packet if it exceeds the maximum payload. Its max size is defined by MAX_DATA, a constant defined in API libraries. data_length Data really sent in the packet. Due to data field is an array of max defined size, each packet could have a different size. frag_length Fragment data length. It is used by the API function responsible for sending data in the internal process of fragmenting packets. SD Not used in DigiMesh. DE Not used in DigiMesh. CID Not used in DigiMesh. PID Not used in DigiMesh. MY_known Not used in DigiMesh. opt Options for the transmitted packet. Options available in DigiMesh are: 0x08: Enables Multicast transmission. packetid ID used in the application level to identify the packet. It is filled by the transmitter and it is used by the receiver to manage the received packet and the pending fragments. macsl & macsh 64-bit Source MAC Address. It is filled by the receiver, and it specifies the address of the node which has delivered the message. It is useful in multi-hops networks to know which node has delivered the message. nas 16-bit Source Network Address. It is filled by the receiver, and it specifies the address of the node which has delivered the message. It is useful in multi-hops networks to know which node has delivered the message. macol & macoh 64-bit Origin MAC Address. It is filled by the receiver, and it specifies the address of the node which has sent originally the packet. It is useful in multi-hops networks to know which node has created and sent the message. nao 16-bit Origin Network Address. It is filled by the receiver, and it specifies the address of the node which has sent originally the packet. It is useful in multi-hops networks to know which node has created and sent the message v1.0
18 Packet Parameters nio Origin Node Identifier. It is filled by the receiver, and it specifies the node identifier of the node which has sent originally the packet. It is useful in multi-hops networks to know which node has created and sent the message. RSSI Received Signal Strength Indicator. It specifies in dbm the RSSI of the last received packet via RF. In a fragmented packet, it contains the average of all received fragments RSSI. address_types Address type used to send the packet by the transmitter. 0: 16-bit transmission 1: 64-bit transmission typesourceid Source ID type used to send the packet. It is filled by the transmitter and it specifies the ID at application level. 0: 16-bit Network Address ID 1: 64-bit MAC Address ID 2: Node Identifier ID numfragment Number of the fragment indicating the position in the fragmented packet to order them at receiver. endfragment Specifies if the sent fragment is the last fragment of a packet. It is filled by the transmitter. time Specifies the time when the first fragment was received. deliv_status Delivery status returned when transmitting a packet. It specifies the success or failure reason of the last packet sent: 0x00: Success 0x02: CCA failure 0x15: Invalid Destination Endpoint 0x21: Network ACK failure 0x22: Not Joined to the Network 0x23: Self-addressed 0x24: Address not found 0x25: Route not found discov_status Discovery stats returned when transmitting a packet. It specifies the processes executed to find the destination node: 0x00: No Discovery Overhead 0x01: Address Discovery 0x02: Route Discovery 0x03: Address and Route Discovery true_nad 16-bit Network Address the packet was delivered to (if success). If not success, this address matches the 16-bit address given in the transmission packet. retries The number of application transmission retries that took place v1.0
19 Packet Parameters 5.2. Maximum payloads Depending on the way of transmission, a maximum data payload is defined: Unicast Broadcast Encrypted 73Bytes 73Bytes Un-Encrypted 73Bytes 73Bytes Figure 6: Maximum Payloads Size -19- v1.0
20 Power Gain and Sensibility 6. Power Gain and Sensibility When configuring a node and a network, one important parameter is related with power gain and sensibility Power Level Power level(dbm) at which the RF module transmits conducted power. This command is only valid using XBee , not in XBee 900MHz. XBee are divided in Normal model and PRO model. Its possible values are: Figure 7: Power Output Level on XBee Series I module Parameter XBee XBee-PRO XBee-PRO International 0-10dBm 10dBm PL=4 : 10dBm 1-6dBm 12dBm PL=3 : 8dBm 2-4dBm 14dBm PL=2 : 2dBm 3-2dBm 16dBm PL=1 : -3dBm 4 0dBm 18dBm PL=0 : -3dBm NOTE: dbm is a standard unit to measure power level taking as reference a 1mW signal. Values expressed in dbm can be easily converted to mw using the next formula: mw = 10^(value dbm/10) Graphics about transmission power are exposed next: dbm XBee Output Power Level -12 0,1 0,25 0,4 0,63 1 mw Figure 8: XBee Output Power Level dbm XBee-PRO Output Power Level ,85 25,12 39,81 63,1 mw Figure 9: XBee-PRO Output Power Level Example of use xbeedm.setpowerlevel(0); // Set Power Output Level to the minimum value xbeedm.getpowerlevel(); // Get Power Output Level Related Variables xbeedm.powerlevel stores the power output level selected -20- v1.0
21 Power Gain and Sensibility 6.2. Received Signal Strength Indicator It reports the Received Signal Strength of the last received RF data packet. It only indicates the signal strength of the last hop, so it does not provide an accurate quality measurement of a multihop link. Example of use: xbeedm.getrssi(); // Get the Receive Signal Strength Indicator Related Variables xbeedm.valuerssi stores the RSSI of the last received packet The ideal working mode is getting maximum coverage with the minimum power level. Thereby, a compromise between power level and coverage appears. Each application scenario will need some tests to find the best combination of both parameters v1.0
22 Connectivity 7. Connectivity 7.1. Topologies DigiMesh provides different topologies to create a network: Star: a star network has a central node, which is linked to all other nodes in the network. The central node gathers all data coming from the network nodes. Figure 10: Star Topology Mesh: all the nodes are connected among them. DigiMesh provides a Network Layer to route packets among nodes out of sight. Figure 11: Mesh Topology 7.2. DigiMesh Architecture Mesh networking allows messages routing through several different nodes to a final destination. In the event that one RF connection between nodes is lost (due to power-loss, environmental obstructions, etc.) critical data can still reach its destination due to the mesh networking capabilities embedded inside the modules. DigiMesh contains the following features Self-healing: any node may enter or leave the network at any time without causing the network as a whole to fail. Peer-to-peer architecture: no hierarchy and no parent-child relationships are needed. Quiet Protocol: routing overhead will be reduced by using a reactive protocol similar to AODV. Route Discovery: rather than maintaining a network map, routes will be discovered and created only when needed. Selective acknowledgments: only the destination node will reply to route requests. Reliable delivery: reliable delivery of data is accomplished by means of acknowledgements. Sleep Modes: low power sleep modes with synchronized wake up are supported, with variable sleep and wake up times v1.0
23 Connectivity Routing A module within a mesh network is able to determine reliable routes using a routing algorithm and table. The routing algorithm uses a reactive method derived from AODV (Ad-hoc On-demand Distance Vector). An associative routing table is used to map a destination node address with its next hop. By sending a message to the next hop address, either the message will reach its destination or be forwarded to an intermediate node which will route the message on to its destination. A message with a Broadcast address is broadcast to all neighbors. All receiving neighbors will rebroadcast the message and eventually the message will reach all corners of the network. Packet tracking prevents a node from resending a broadcast message twice Route Discovery Process If the source node doesn t have a route to the requested destination, the packet is queued to await a route discovery (RD) process. This process is also used when a route fails. A route fails when the source node uses up its network retries without ever receiving an ACK. This results in the source node initiating RD. RD begins by the source node broadcasting a route request (RREQ). Any node that receives the RREQ that is not the ultimate destination is called an intermediate node. Intermediate nodes may either drop or forward an RREQ, depending on whether the new RREQ has a better route back to the source node. If so, information from the RREQ is saved and the RREQ is updated and broadcast. When the ultimate destination receives the RREQ, it unicasts a route reply (RREP) back to the source node along the path of the RREQ. This is done regardless of route quality and regardless of how many times an RREQ has been seen before. This allows the source node to receive multiple route replies. The source node selects the route with the best round trip route quality, which it will use for the queued packet and for subsequent packets with the same destination address Connections Every RF data packet sent over-the-air contains a Source Address and Destination Address field in its header. DigiMesh supports long 64-bit addresses. A unique 64-bit IEEE source address is assigned at the factory and can be read with the functions explained in chapter 3. DigiMesh supports Unicast and Broadcast transmission Unicast When transmitting in Unicast communications, reliable delivery of data is accomplished using retries and acknowledgements. The number of retries is determined by the Network Retries (NR) parameter (explained in chapter 4). RF data packets are sent up to NR + 1 times and ACKs (acknowledgements) are transmitted by the receiving node upon receipt. If a network ACK is not received within the time it would take for a packet to traverse the network twice, a retransmission occurs Broadcast Broadcast transmissions will be received and repeated by all nodes in the network. Because ACKs are not used the originating node will send the broadcast four times. Essentially the extra transmissions become automatic retries without acknowledgments. This will result in all nodes repeating the transmission four times as well. In order to avoid RF packet collisions, a random delay is inserted before each node relays the broadcast message. This time is specified by Network Delay Slots, explained in chapter Sending Data Sending data is a complex process which needs some special structures and functions to carry out. Due to the limit on maximum payloads (see chapter 5) it is usual the packet fragmentation, so an application header has been created to deal with this process. This application header is sent inside RF Data, following the API Frame Structure API Frame Structure The structure used to transmit packets via RF is specified by the used modules. The application header has been added to that defined structured as shown below: -23- v1.0
24 Connectivity Figure 12: 64-bit API Frame Structure Application Header This application header is filled by the transmitter (internal Waspmote operation) and it is used by the receiver to treat the packet or fragment. It is sent in data field, so the maximum payload is reduced in a variable length (depending on the source ID type chosen). Figure 13: Data field in an API frame To add some application level features to the receiver, some fields have been added like ID or Source ID. Source ID identifies the origin node which created the packet. It is useful in multi-hops networks, to identify the origin node to answer. To identify this node, three ID can be chosen: MAC Address: 64-bit MAC Source Address Network Address: 16-bit Network Address Node Identifier: 20-byte max string NI The different fields of this header and its structure inside the data field used in an API frame is represented in figure 13 ID: specifies the ID at application level. It allows to identify the packet among various packets in the receiver. Frag Num: specifies the position of the fragment in its packet. The first fragment shows the total number of fragments of the packet. [#]: optional field that is included in the first fragment to indicate it is the first fragment. Source Type: specifies the source ID type chosen. The possibilities are MAC, 16-bit or NI. Source ID: specifies the source ID of the origin node. It is related with the previous field. Data: stores the data sent in each fragment or packet v1.0
25 Connectivity Fragmentation When the data length of a packet exceeds the maximum payload, the packet has to be fragmented to reach the destination. If the packet is not fragmented, the module will discard it without even transmitting the packet. NOTE: Due to restricted memory in Waspmote, the maximum recommended data in a packet is 1500 Bytes (to be fragmented) Structure packetxbee It is the structure used for the packet to send. It was explained in chapter 5. The process to send a packet is explained next: 1. A structure packetxbee is created to contain the packet to send. 2. That structure is filled with the correct data into the corresponding fields. 3. The API function responsible of sending data is called, using the previously created structure as the input. The API function takes care of the rest of the process, returning the process successful or failure Sending without API header There is a function to send raw data without the API header. This mode has been designed to send simple data to a gateway when the API features are not necessary. Broadcast and Unicast transmissions are supported, as well as encryption Examples To simplify the examples and make them easy to read, there are some lines doesn t work exactly in C/C++ Sending a packet of 50 bytes without API header. char* data; for(int c=0;c<50;c++) // Set the data data[c]= A ; xbeedm.send( 0013A F66A,data); Sending a packet of 50 bytes. Unicast 64-bit Mode. 16-bit NA Source ID. packetxbee* paq_sent; // create packet to send char* data; paq_sent->mode=unicast; // set Unicast mode paq_sent->packetid=0x52; // set ID application level paq_sent->opt=0x00; // set options. No option selected. for(int c=0;c<50;c++) // Set the data data[c]= A ; xbeedm.setoriginparams(paq_sent, 1221, MY_TYPE); // sets Origin Parameters xbeedm.setdestinationparams(paq_sent, 0013A F686, data, MAC_TYPE, DATA_ABSOLUTE); state=xbeedm.sendxbee(paq_sent); // Call function responsible to send data -25- v1.0
26 Connectivity The data field in the API frame generated by the function sendxbee will be: Figure 14: API Application Header Sending a 50-bytes packet. Unicast 64-bit Mode. 64-bit MAC Source ID. packetxbee* paq_sent; // create packet to send char* data; paq_sent->mode=unicast; // set Unicast mode paq_sent->packetid=0x52; // set ID application level paq_sent->opt=0x00; // set options. No option selected. for(int c=0;c<50;c++) // Set the data data[c]= A ; xbeedm.setoriginparams(paq_sent, 0013A F66A, MAC_TYPE); xbeedm.setdestinationparams(paq_sent, 0013A F686, data, MAC_TYPE, DATA_ABSOLUTE); state=xbeedm.sendxbee(paq_sent); // Call function responsible to send data The data field in the API frame generated by the function sendxbee will be: Figure 15: API Application Header Sending a 50-bytes packet. Broadcast Mode. Node Identifier Source ID Type. packetxbee* paq_sent; // create packet to send char* data; paq_sent->mode=broadcast; // set Broadcast mode paq_sent->packetid=0x52; // set ID application level paq_sent->opt=0x00; // set options. No option selected. for(int c=0;c<50;c++) // Set the data data[c]= A ; xbeedm.setoriginparams(paq_sent, forrestnode-01, NI_TYPE); xbeedm.setdestinationparams(paq_sent, FFFF, data, MAC_TYPE, DATA_ABSOLUTE); state=xbeedm.sendxbee(paq_sent); // Call function responsible to send data The data field in the API frame generated by the function sendxbee will be: Figure 16: API Application Header -26- v1.0
27 Connectivity Sending a 200-bytes packet. Unicast 64-bit Mode. 16-bit Source ID Type. packetxbee* paq_sent; // create packet to send char* data; paq_sent->mode=unicast; // set Broadcast mode paq_sent->packetid=0x52; // set ID application level paq_sent->opt=0x00; // set options. No option selected. for(int c=0;c<200;c++) // Set the data data[c]= A ; xbeedm.setoriginparams(paq_sent, 1221, MY_TYPE); xbeedm.setdestinationparams(paq_sent, 0013A F686, data, MAC_TYPE, DATA_ABSOLUTE); state=xbeedm.sendxbee(paq_sent); // Call function responsible to send data Due to the amount of data, the packet needs to be fragmented before being sent. The maximum data payload is 73Bytes (see chapter 5) and the application header will occupy a maximum of 6 Bytes (in the first fragment), so there will be three fragments, sending 67Bytes (data) in the first fragment, 68Bytes (data) in the second fragment and 65Bytes (data) in the third fragment. Figure 17: API Application Header 7.5. Receiving Data Receiving data is a complex process which needs some special structures to carry out. These operations are transparent to the API user, so it is going to be explained the necessary information to be able to read properly a received packet. Before any packet has been received, a multidimensional array of matrix structures pointers, an array of index structures pointers and an array of packetxbee structures pointers are created. The size of these arrays is defined by some constants in compilation time, so it is necessary to adequate its value to each scenario before compile the code: MAX_FINISH_PACKETS: max number of finished packets pending of treatment. It specifies the size of the array of finished packets. MAX_FRAG_PACKETS: max number of fragments per packet. It specifies the number of columns in the multidimensional array of pending fragments. The number of rows is specified by MAX_FINISH_PACKETS. When a packet or fragment is received, the algorithm used in reception API function is: 1. Check if the fragment is a new packet or belongs to an existing packet. If it is a new packet, an structure index is created and linked to the array index previously created. The application level information is stored in that structure. If it belongs to an existing packet, it doesn t store any information. 2. Create an structure matrix and link it to the corresponding position in the multidimensional matrix array. The position is calculated basing on the information stored in the index array. 3. Store the data in the corresponding position of the matrix v1.0
28 Connectivity 4. Check if the packet is complete. If the packet is complete, a packetxbee structure is created and linked to the corresponding position in the array of finished packets. The different fragments are ordered and copied to this structure, as the application level information. The index and row of matrix are released, to free memory. If the packet is not complete, goes to next step. 5. Exit the function. When a packet is received via RF, the module will send the data via UART, so it is recommended to check periodically if data is available. The API function responsible of reading packets can read more than one fragment, but the XBee module may overflow its buffer, so it is recommended to read packets one by one. When a packet is completed, it will be stored in a finished packets array called packet_finished. This array should be used by the application to read the received packet. A variable called pos is used to know if there are pending received packets: if pos =0, there is no packet available; if pos >0, there will be as many pending packets as its value (pos=3, 3 pending packets) Examples Received 50-bytes data packet. Unicast. 16-bit NA Source ID Type state=xbeedm.treatdata(); // Read a packet when XBee has noticed it to us if( xbeedm.pos>0 ) /* Available info: (there are more available information) */ network_address[0]=packet_finished[xbeedm.pos-1]->nas[0]; network_address[1]=packet_finished[xbeedm.pos-1]->nas[1]; Available Information packet_finished[xbeedm.pos-1]->nas: stores the 16-bit network address of the sender. packet_finished[xbeedm.pos-1]->macsh: stores the 32 upper bits of MAC sender address. packet_finished[xbeedm.pos-1]->macsl: stores the 32 lower bits of MAC sender address. packet_finished[xbeedm.pos-1]->nao: stores the 16-bit network address of the origin sender. packet_finished[xbeedm.pos-1]->mode: stores the transmission mode. Unicast in this case. packet_finished[xbeedm.pos-1]->data: stores the data received. Max size MAX_DATA. packet_finished[xbeedm.pos-1]->packetid: stores the packet ID of the received message. 0x52 in this case. packet_finished[xbeedm.pos-1]->typesourceid: stores the source type ID used in the message. After receiving the packet, due to there is only one fragment, it will be completed, so variable pos will be greater than zero. This variable is used to index the array where the received packet is stored. The information that has been stored is indicated in the example. Received 50-bytes data packet. Unicast. 64-bit MAC Address Source ID Type state=xbeedm.treatdata(); // Read a packet when XBee has noticed it to us if( xbeedm.pos>0 ) /* Available info: (there are more available information) */ source_address[0]=packet_finished[xbeedm.pos-1]->macsh[0];... source_address[3]=packet_finished[xbeedm.pos-1]->macsh[3]; -28- v1.0
29 Connectivity Available Information packet_finished[xbeedm.pos-1]->nas: stores the 16-bit network address of the sender. packet_finished[xbeedm.pos-1]->macsh: stores the 32 upper bits of MAC sender address. packet_finished[xbeedm.pos-1]->macsl: stores the 32 lower bits of MAC sender address. packet_finished[xbeedm.pos-1]->macoh: stores the 32 upper bits of MAC origin sender address. packet_finished[xbeedm.pos-1]->macol: stores the 32 lower bits of MAC origin sender address. packet_finished[xbeedm.pos-1]->mode: stores the transmission mode. Unicast in this case. packet_finished[xbeedm.pos-1]->data: stores the data received. Max size MAX_DATA. packet_finished[xbeedm.pos-1]->packetid: stores the packet ID of the received message. 0x52 in this case. packet_finished[xbeedm.pos-1]->typesourceid: stores the source type ID used in the message. After receiving the packet, due to there is only one fragment, it will be completed, so variable pos will be greater than zero. This variable is used to index the array where the received packet is stored. The information that has been stored is indicated in the example. Received 50-bytes data packet. Broadcast. Node Identifier Source ID Type state=xbeedm.treatdata(); // Read a packet when XBee has noticed it to us if( xbeedm.pos>0 ) /* Available info: (there are more available information) */ source_address[0]=packet_finished[xbeedm.pos-1]->macsh[0];... source_address[3]=packet_finished[xbeedm.pos-1]->macsh[3]; Available Information packet_finished[xbeedm.pos-1]->nas: stores the 16-bit network address of the sender. packet_finished[xbeedm.pos-1]->macsh: stores the 32 upper bits of MAC sender address. packet_finished[xbeedm.pos-1]->macsl: stores the 32 lower bits of MAC sender address. packet_finished[xbeedm.pos-1]->nio: stores 20-byte max string used to Node Identifier of the origin sender packet_finished[xbeedm.pos-1]->mode: stores the transmission mode. Unicast in this case. packet_finished[xbeedm.pos-1]->data: stores the data received. Max size MAX_DATA. packet_finished[xbeedm.pos-1]->packetid: stores the packet ID of the received message. 0x52 in this case. packet_finished[xbeedm.pos-1]->typesourceid: stores the source type ID used in the message. After receiving the packet, due to there is only one fragment, it will be completed, so variable pos will be greater than zero. This variable is used to index the array where the received packet is stored. The information that has been stored is indicated in the example. Received 200-bytes data packet. Unicast. 16-bit NA Source ID Type state=xbeedm.treatdata(); // Read a packet when XBee has noticed it to us if( xbeedm.pos>0 ) /* Available info: (there are more available information) */ network_address[0]=packet_finished[xbeedm.pos-1]->nas[0]; network_address[1]=packet_finished[xbeedm.pos-1]->nas[1]; -29- v1.0
30 Connectivity Available Information packet_finished[xbeedm.pos-1]->nas: stores the 16-bit network address of the sender. packet_finished[xbeedm.pos-1]->macsh: stores the 32 upper bits of MAC sender address. packet_finished[xbeedm.pos-1]->macsl: stores the 32 lower bits of MAC sender address. packet_finished[xbeedm.pos-1]->nao: stores the 16-bit network address of the origin sender. packet_finished[xbeedm.pos-1]->mode: stores the transmission mode. Unicast in this case. packet_finished[xbeedm.pos-1]->data: stores the data received. Max size MAX_DATA. packet_finished[xbeedm.pos-1]->packetid: stores the packet ID of the received message. 0x52 in this case. packet_finished[xbeedm.pos-1]->typesourceid: stores the source type ID used in the message. After receiving the first packet, due to there are three fragments, it will not be completed, so variable pos will be zero. It is recommended to set a delay in the transmitter so as to the receiver doesn t receive more than one packet at once. When the three fragments have been received, variable pos will change its value and the information in the packet_finished array will be available. NOTE: Due to memory restrictions, it is recommended when a pending packet is treated and it is not necessary to store it any more, to release this pointer. If don t, memory may overflow and crash the application. It is not possible having in a receiver node more than 1500Bytes. It is referred to a single big packet or many smaller packets in parallel Discovering and Searching Nodes As explained in chapter 4, an extra Digi header enables some features discovering and searching nodes Structure used in Discovery Discovering nodes is used to discover and report all modules on its current operating channel and PAN ID. To store the reported information by other nodes, an structure called Node has been created. This structure has the next fields: uint8_t MY[2]; uint8_t SH[4]; uint8_t SL[4]; char NI[20]; uint8_t PMY[2]; uint8_t DT; uint8_t ST; uint8_t PID[2]; uint8_t MID[2]; uint8_t RSSI; // 16b Network Address // 32b Lower Mac Source // 32b Higher Mac Source // Node Identifier // Parent 16b Network Address // Device Type: 0=End 1=Router 2=Coord // Status: Reserved // Profile ID // Manufacturer ID // Receive Signal Strength Indicator MY 16-bit Network Address of the reported module. SH & SL 64-bit MAC Source Address of the reported module. NI Node Identifier of the reported module PMY Parent 16-bit network address. It specifies the 16-bit network address of its parent. DT Device Type. It specifies if the node is a Coordinator, Router or End Device. ST Status. Reserved by DigiMesh v1.0
31 Connectivity PID Profile ID. Profile ID used to application layer addressing. MID Manufacturer ID. ID set by the manufacturer to identify the module. RSSI Not returned in DigiMesh. To store the found brothers, an array called scannedbrothers has been created. It is an array of structures Node. To specify the maximum number of found brothers, it is defined a constant called MAX_BROTHERS. It is also defined a variable called totalscannedbrothers that indicates the number of brothers have been discovered. Using this variable as index in the scannedbrothers array, it will be possible to read the information about each node discovered. Example of use: xbeedm.scannetwork(); // Discovery nodes Related variables xbeedm.totalscannedbrothers stores the number of brothers have been discovered. xbeedm.scannedbrothers Node structure array that stores in each position the info related to each found node. For example, xbeedm.scannedbrothers[0].my should store the 16-bit Network Address of the first found node Searching specific nodes Another possibility for discovering a node is searching for a specific one. This search is based on using the Node Identifier. The NI of the node to discover is used as the input in the API function responsible of this purpose. Example of use packetxbee* paq_sent; xbeedm.nodesearch( forrestnode-01,14,paq_sent); // 14 is string length Related variables paq_sent Stores the 16-bit and 64-bit addresses of the searched. For example paq_sent->my[0] & paq_sent->my[1] stores the 16-bit NA of the searched node Node discovery to a specific node When executing a Node Discovery all the nodes respond to it. If its Node Identifier is known, a Node Discovery using its NI as an input can be executed. Example of use xbeedm.scannetwork( forrestnode-01 ); // Performs a ND to that specific node Related variables xbeedm.totalscannedbrothers stores the number of brothers have been discovered. In this case its value will be 1 xbeedm.scannedbrothers Node structure array that stores in each position the info related to each found node. It will store in the first pos -31- v1.0
32 Starting a Network 8. Starting a Network To create a network only two parameters are necessary: channel and PAN ID. These parameters are the base of a network and we need to be careful choosing them. There are more parameters used to create a network like security parameters, which are not necessary but recommended (see chapter 12). Two nodes are in the same network if they are using the same channel and PAN ID Choosing a channel As explained in chapter 4, there are different channels to choose. In XBee Series 1, a random value between 0x0B - 0x1A (XBee- PRO values are 0x0C-0x17) should be chosen. However, if XBee 900 is used, a random value between 0x01-0x0C should be chosen. This value will be used as the input parameter in the API function responsible of setting the channel. Example of use xbeedm.setchannel(0x0c); // Set channel 8.2. Choosing a PAN ID A network must have an unique PAN ID. This PAN ID is a 16-bit number which values are comprised among 0-0xFFFF. To set a valid PAN ID it is necessary to select a random number and use the API function responsible of setting this parameter. Any value comprised between 0-0xFFFF could be valid, but it should be used only by one network to avoid conflicts between them. Example of use PANID=0x33,0x31; // array containing the PAN ID xbeedm.setpan(panid); // Set PANID NOTE: If two different networks are using the same PAN ID, it doesn t mean there will be interferences between them. Interferences will appear if both networks are transmitting in the same channel. If that happens, it will mean the two different networks will become the same network because both are using same PAN ID and channel frequency v1.0
33 Joining an Existing Network 9. Joining an Existing Network Joining an existing network process requires some knowledge about the network to join. Three parameters are needed: channel, PAN ID and security (explained in chapter 12) Network parameters are known When these three parameters are known, the process is reduced to set the parameters in the node Channel To set channel, use the API function responsible of that matter. Example of use xbeedm.setchannel(0x0c); // Set Channel the network is working on PAN ID To set PAN ID, use the API function responsible of that matter. Example of use PANID=0x33,0x31; // array containing PAN ID the network is using xbeedm.setpan(panid); // Set PANID Once these two parameters are set in the node, it will be part of the network, receiving messages from other nodes Network parameters are unknown If channel or PANID are not known, it is not possible to join a DigiMesh network. The unique solution if channel is not known is launching ND in all the channels waiting for an answer, selecting the channel where it occurs Node Discovery Once these parameters have been set, the node is part of the network, so now we can discover other nodes in the network. Some parameters are involved in a node discovery process Node Discovery Function Performs a node discovery returning the found brothers in the network stored in an array of structures that contain information about the nodes as explained in chapter 7 Example of use: xbeedm.scannetwork(); // Discovery nodes if(xbeedm.totalscannedbrothers>0) /* Available info (There are more available information) */ network_address[0]=scannedbrothers[totalscannedbrothers-1].my[0]; network_address[1]=scannedbrothers[totalscannedbrothers-1].my[1]; -33- v1.0
34 Joining an Existing Network Available Information scannedbrothers[totalscannedbrothers-1].my stores 16-bit NA of each module scannedbrothers[totalscannedbrothers-1].sh stores the 32 upper bits of MAC address scannedbrothers[totalscannedbrothers-1].sl stores the 32 lower bits of MAC address scannedbrothers[totalscannedbrothers-1].ni stores the Node Identifier scannedbrothers[totalscannedbrothers-1].pmy stores the 16-bit NA of its parent scannedbrothers[totalscannedbrothers-1].dt stores the device type(c, R or E) scannedbrothers[totalscannedbrothers-1].st stores the status. Reserved by module. scannedbrothers[totalscannedbrothers-1].mid stores the 16-bit manufacturer ID scannedbrothers[totalscannedbrothers-1].pid stores the 16-bit Profile ID Node Discovery Time It is the amount of time a node will wait for responses from other nodes when performing a ND. Example of use: uint8_t time[2]=0x19,0x00;// In DigiMesh is only used first array position xbeedm.setscanningtime(time); // Set Scanning Time in ND xbeedm.getscanningtime(); // Get Scanning Time in ND Available Information xbeedm.scantime stores the time a node will wait for responses v1.0
35 Sleep Options 10. Sleep Options Sleep Modes All the nodes in a DigiMesh network can sleep, entering in a low power consumption mode. There are several sleep modes characterized as either asynchronous or synchronous. Asynchronous sleeping modes should not be used in a synchronous sleeping network, and vice versa Asynchronous Cyclic Sleep Asynchronous sleep modes can be used to control the sleep state on a module by module basis. Modules operating in an asynchronous sleep mode should not be used to route data Synchronous Cyclic Sleep A node in synchronous cyclic sleep mode sleeps for a programmed time, wakes up in unison with other nodes, exchanges data and synchronization messages, and then returns to sleep. All synchronized cyclic sleep nodes enter and exit a low power state at the same time. This forms a cyclic sleeping network. While asleep, it cannot receive RF messages, neither will it read commands from the UART port Sleep Parameters There are some parameters involved in setting a node to sleep Sleep Mode Sets the sleep mode for a module. Its available values are: 0: Normal Mode. The node will not sleep. Normal mode modules are not compatible with nodes configured for sleep. Excepting the case of adding a new node to a sleep-compatible network, a network should consist of either only normal nodes or only sleep-compatible nodes. 1: Asynchronous Pin Sleep Mode: Pin sleep allows the module to sleep and wake according to the state of the Sleep_RQ pin (pin 9). When Sleep_RQ is set high, the module will finish any transmit or receive operations and enter a low-power state. The module will wake from pin sleep when the Sleep_RQ pin is set low. 4: Asynchronous cyclic sleep. In this mode, the module periodically sleeps and wakes based on the SP and ST commands. 5: Asynchronous cyclic sleep with pin wake-up. In this mode, the module acts in the same way as asynchronous cyclic sleep with the exception that the module will prematurely terminate a sleep period when a falling edge of the SLEEP_RQ line is detected. 7: Synchronous Sleep Support Mode. The node will synchronize itself with a sleeping network but will not sleep. They are especially useful when used as preferred sleep coordinator nodes and as aids in adding new nodes to a sleeping network. 8: Synchronous Cyclic Sleep Mode. The node sleeps for a programmed time, wakes in unison with other nodes, exchanges data and sync messages, and then returns to sleep. Example of use: xbeedm.setsleepmode(8); // Set Sync Cyclic Sleep Mode xbeedm.getsleepmode(); // Get the Sleep Mode used Related Variables xbeedm.sleepmode stores the sleep mode in a module -35- v1.0
36 Sleep Options Sleep Period It determines how long a node will sleep per period, with a maximum 4 hours. In the parent, it determines how long it will buffer a message for the sleeping device. Time in units of 10ms represented in hexadecimal. Example of use: uint8_t asleep[3]=0x15,0xf9,0x00; xbeedm.setsleeptime(asleep); // Set Sleep period to 4 hours Related Variables xbeedm.sleeptime stores the sleep period the module will be sleeping Time Before Sleep It determines the time a module will be awake waiting before sleeping. It resets each time data is received via RF or serial. Once the timer expires, the device will enter low-power state. Time in units of ms represented in hexadecimal. Example of use: uint8_t awake[3]=0x36,0xee,0x80; xbeedm.setawaketime(awake); // Set time the module remains awake: 1hour Related Variables xbeedm.awaketime stores the time the module remains awake Sleep Options It configures options for sleeping modes. Possible values are read as a bitmask (Bit 0 and Bit 1 cannot be set at the same time). For synchronous sleep modules, the following sleep options are defined: bit 0: Preferred sleep coordinator. The node always acts as sleep coordinator bit 1: Non-sleep coordinator. Node never acts as a sleep coordinator bit 2: Enable API sleep status messages bit 3: Disable early wake-up for missed synchronizations bit 4: Enable node type equality bit 5: Disable coordinator rapid synchronization deployment mode. For asynchronous sleep modules, the following sleep options are defined: bit 8: Always wake for ST time Example of use: xbeedm.setsleepoptions(0x01); // Set the node to be the preferred sleep coordinator Related Variables xbeedm.sleepoptions stores the sleep option chosen -36- v1.0
37 Sleep Options Sleep Status It queries a number of Boolean values describing the status of the module. Possible values are read as a bitmask: Bit 0: If it is true, the network is in its wake state Bit 1: If it is true, the node is currently acting as a network sleep coordinator Bit 2: If it is true, the node has ever received a valid sync message Bit 3: If it is true, the node has received a sync message in the current wake cycle Bit 4: If it is true, the user has altered the sleep settings on the module so that the node will nominate itself and send a sync message with the new settings at the beginning of the next wake cycle Bit 5: This bit will be true if the user has requested that the node nominate itself as the sleep coordinator (using the commissioning button or the CB2 command). bit 6: This bit will be true if the node is currently in deployment mode. All other bits: Reserved - All non-documented bits can be any value and should be ignored. Example of use: xbeedm.getsleepstatus(); Related Variables xbeedm.sleepstatus stores the sleep status of the module Missed synchronizations count It determines the number of syncs that have been missed. This value can be reset to 0. When the value reaches 0xFFFF it will not be incremented anymore. Example of use: xbeedm.getmissedsynccount(); Related Variables xbeedm.missedsyncs stores the missed synchronizations Operational sleep period It determines the sleep period that the node is currently using. This number will oftentimes be different from the SP parameter if the node has synchronized with a sleeping router network. Example of use: xbeedm.getopsleepperiod(); Related Variables xbeedm.opsleepperiod stores the current sleep period -37- v1.0
38 Sleep Options Operational wake period It determines the wake period that the node is currently using. This number will oftentimes be different from the ST parameter if the node has synchronized with a sleeping router network. Example of use: xbeedm.getopwakeperiod(); Related Variables xbeedm.opwakeperiod stores the current wake period ON/OFF Modes In addition to the XBee sleep modes, Waspmote provides the feature of controlling the power state with a digital switch. This means that using one function included in the Waspmote API, any XBee module can be powered up or down (0uA). Example of use: Xbee.setMode(XBEE_ON); // Powers XBee up XBee.setMode(XBEE_OFF); // Powers XBee down -38- v1.0
39 Synchronizing the Network 11. Synchronizing the Network Sleeping routers under DigiMesh allow to all nodes in the network to synchronize their sleep and wake up times. All synchronized nodes enter and exit into low power state at the same time. This forms a cyclic sleeping network. Nodes synchronize by receiving an special RF packet called synch message which is sent by a sleep coordinator. Any node in the network can become an sleep coordinator through a process called nomination. The sleep coordinator will send one synch message at the beginning of each wake up period. The synch message to broadcast category is repeated by each node in the network, since it belongs Operation One node in a sleeping network acts as the sleeping coordinator. At the beginning of a wake cycle the sleep coordinator will send a sync message as a broadcast to all nodes in the network. This message contains synchronization information and the wake and sleep times for the current cycle. All cyclic sleep nodes receiving a sync message will remain awake for the wake time and then sleep for the sleep period specified Synchronization Messages Nodes which have not been synchronized or that have lost sync will send messages requesting sync information. Synchronized nodes which receive one of these messages will respond with a synchronization packet. Deployment mode (set by default) is used by sleep compatible nodes when they are first powered up and the sync message has not been relayed. A sleep coordinator in deployment mode will rapidly send sync messages until it receives a relay of one of those messages. If a node which has exited deployment mode receives a sync message from a sleep coordinator which is in deployment mode, the sync will be rejected and a corrective sync will be sent to the sleep coordinator. Deployment mode can be disabled using the sleep options command (SO). A sleep coordinator which is not in deployment mode or which has had deployment mode disabled will send a sync message at the beginning of the wake cycle The sleep coordinator will then listen for a neighboring node to relay the sync. If the relay is not heard, the sync coordinator will send the sync one additional time Becoming a Sleep Coordinator A node can become a sleep coordinator in one of several ways: Synchronization Messages A node can be specified to always act as a sleep coordinator. This is done by setting the preferred sleep coordinator bit (bit 0) in the sleep operations parameter (SO) to 1. A node with the sleep coordinator bit set will always send a sync message at the beginning of a wake cycle. For this reason, it is imperative that no more than one node in the network has this bit set. Although it is not necessary to specify a preferred sleep coordinator, it is often useful to select a node for this purpose to improve network performance. The preferred sleep coordinator bit should be used with caution. The advantages of using the option become weaknesses when used on a node that is not positioned or configured properly Nomination and Election Nomination is the process where a node becomes a sleep coordinator at the start of a sleeping network or in the event a sleep coordinator fails as a replacement. This process is automatic with any sleeping node being eligible to become the sleep coordinator for the network. This process can be managed through Sleep Options by allowing a node to alter the algorithm used for nomination giving the node a greater chance to become the sleep coordinator. This option is designed for maintenance purposes and is not necessary for cyclic sleep operation. If the node has the preferred sleep coordinator option-enabled ( Sleep Options =1), then it will poll during its first cycle for a synch message. If it becomes synched by receiving a synch message, it will cycle back to sleep and will not become the sleep coordinator. If it does not become synched during that first cycle, then it will nominate itself as the sleep coordinator and will start sending synch messages at the start of its second cycle v1.0
40 Synchronizing the Network Any sleeping node, if it does not receive a message for three cycles, may nominate itself to act as a replacement sleep coordinator. Depending on the platform and other configured options, such a node will eventually nominate itself after a number of cycles without a sync. A nominated node will begin acting as the new network sleep coordinator. If multiple nodes nominate themselves at the same time, then an election will take place to resolve which node will function as network s sleep coordinator. A node will disable synching if it receives a synch message from a senior node. A node running in normal mode (with preferred sleep coordinator option enabled) is senior to any node operating in sleep mode. A node with the largest MAC address value is senior to any other node operating in the same mode Changing Sleep Parameters Any sleep compatible node in the network which does not have the non-sleep coordinator sleep option set can be used to make changes to the network s sleep and wake times. If a node s SP and/or ST are changed to values different from those that the network is using, that node will become the sleep coordinator. That node will begin sending sync messages with the new sleep parameters at the beginning of the next wake cycle Configuration Starting a Sleeping Network By default, all new nodes operate in normal (non-sleep) mode. To start a sleeping network, follow these steps: 1. Enable the preferred sleep coordinator option on one of the nodes, and set its SM to a sleep compatible mode (7 or 8) with its SP and ST set to a quick cycle time. 2. Next, power on the new nodes within range of the sleep coordinator. The nodes will quickly receive a sync message and synchronize themselves to the short cycle SP and ST. 3. Configure the new nodes in their desired sleep mode as cyclic sleeping nodes (SM8) or sleep support nodes (SM7). 4. Set the SP and ST values on the sleep coordinator to the desired values for the deployed network. 5. Wait a cycle for the sleeping nodes to sync themselves to the new SP and ST values. 6. Disable the preferred sleep coordinator option bit on the sleep coordinator (unless a preferred sleep coordinator is desired). 7. Deploy the nodes to their positions Adding a New Node to an Existing Network To add a new node to the network, the node must receive a sync message from a node already in the network. On power-up, an unsynchronized sleep compatible node will periodically send a broadcast requesting a sync message and then sleep for its SP period. Any node in the network that receives this message will respond with a sync. Because the network can be asleep for extended periods of time, and as such cannot respond to requests for sync messages, there are methods that can be used to sync a new node while the network is asleep. e.g. Power the new node on within range of a sleep support node. Sleep support nodes are always awake and will be able to respond to sync requests promptly Changing Sleep Parameters Changes to the sleep and wake cycle of the network can be made by changing the SP and/or ST of the sleep coordinator. If the sleep coordinator is not known, any node that does not have the non-sleep coordinator sleep option bit set, can be used. When changes are made to a node s sleep parameters, that node will become the network s sleep coordinator (unless it has the non-sleep coordinator option selected) and will send a sync message with the new sleep settings to the entire network at the beginning of the next wake cycle. The network will immediately begin using the new sleep parameters after this sync is sent. Changing sleep parameters increases the chances that nodes will lose sync. If a node does not receive the sync message with the new sleep settings, it will continue to operate on its old settings. To minimize the risk of a node losing sync and to facilitate the resyncing of a node that does lose sync, the following precautions can be taken: -40- v1.0
41 Synchronizing the Network 1. Whenever possible, avoid changing sleep parameters. 2. Enable the missed sync early wake up sleep option (SO). This command is used to tell a node to wake up progressively earlier based on the number of cycles it has gone without receiving a sync. This will increase the probability that the unsynced node will be awake when the network wakes up and sends the sync message. Note: using this sleep option increases reliability but may decrease battery life. 3. When changing between two sets of sleep settings, choose settings so that the wake periods of the two sleep settings will happen at the same time. In other words, try to satisfy the following equation: (SP1 + ST1) = N * (SP2 + ST2), where SP1/ST1 and SP2/ST2 are the desired sleep settings and N is an integer. Figure 18: Sleep setting examples Rejoining Nodes Which Have Lost Sync It is recommended to build the network with redundant mesh nodes to increase robustness. If a scenario exists such that the only route connecting a subnet to the rest of the network depends on a single node and that node fails, then multiple subnets may arise while using the same wake/sleep intervals. When this occurs the first task is to repair, replace, and strengthen the weak link with new and/or redundant modules to fix the problem and prevent it from occurring in the future. Subnets can drift out of phase with each other if the network is configured in one of the following ways: If multiple modules in the network have had the non-sleep coordinator sleep option bit disabled and are thus eligible to be nominated as a sleep coordinator. If the modules in the network are not using the auto early wake-up sleep option. If a network has multiple subnets that have drifted out of phase with each other, get the subnets back in phase with the following steps: 1. Place a sleep support node in range of both subnets. 2. Select a node in the subnet that you want the other subnet to sync up with. Use this node to slightly change the sleep cycle settings of the network (increment ST, for example). 3. Wait for the subnet s next wake cycle. During this cycle, the node selected to change the sleep cycle parameters will send the new settings to the entire subnet it is in range of, including the sleep support node which is in range of the other subnet. 4. Wait for the out-of-sync subnet to wake up and send a sync. When the sleep support node receives this sync, it will reject it and send a sync to the subnet with the new sleep settings. 5. The subnets will now be in sync. The sleep support node can be removed. If desired, the sleep cycle settings can be changed back to what they were. In the case that only a few nodes need to be replaced, this method can also be used: 1. Reset the out-of-sync node and set its sleep mode to cyclic sleep. Set it up to have a short sleep cycle. 2. Place the node in range of a sleep support node or wake a sleeping node with the commissioning button. 3. The out-of-sync node will receive a sync from the node which is synchronized to the network and sync to the network sleep settings v1.0
42 12. Security and Data Encryption DigiMesh Security and Data encryption Overview Security and Data Encryption The encryption algorithm used in DigiMesh is AES (Advanced Encryption Standard) with a 128b key length (16 Bytes). The AES algorithm is not only used to encrypt the information but to validate the data which is sent. This concept is called Data Integrity and it is achieved using a Message Integrity Code (MIC) also named as Message Authentication Code (MAC) which is appended to the message. This code ensures integrity of the MAC header and payload data attached. It is created encrypting parts of the IEEE MAC frame using the Key of the network, so if we receive a message from a non trusted node we will see that the MAC generated for the sent message does not correspond to the one what would be generated using the message with the current secret Key, so we can discard this message. The MAC can have different sizes: 32, 64, 128 bits, however it is always created using the 128b AES algorithm. Its size is just the bits length which is attached to each frame. The more large the more secure (although less payload the message can take). Data Security is performed encrypting the data payload field with the 128b Key. Figure 19: IEEE Frame Security in API libraries As explained previously, DigiMesh provides secure communications inside a network using 128-bit AES encryption. The API functions enable using security and data encryption Encryption Enable Enables the 128-bit AES encryption in the modules. Example of use: xbeedm.encryptionmode(1); // Enable encryption mode Related Variables xbeedm.encryptmode stores if security is enabled or not The mode used to encrypt the information is AES-CTR. In this mode all the data is encrypted using the defined 128b key and the AES algorithm. The Frame Counter sets the unique message ID,and the Key Counter (Key Control subfield) is used by the application layer if the Frame Counter max value is reached v1.0
43 Security and Data Encryption Figure 20: AES-CTR Encryption Frame Encryption Key 128-bit AES encryption key used to encrypt/decrypt data. The entire payload of the packet is encrypted using the key and the CRC is computed across the ciphertext. When encryption is enabled, each packet carries an additional 16 Bytes to convey the random CBC Initialization Vector (IV) to the receivers. A module with the wrong key (or no key) will receive encrypted data, but the data driven out the serial port will be meaningless. A module with a key and encryption enabled will receive data sent from a module without a key and the correct unencrypted data output will be sent out the serial port. Example of use char* KEY= WaspmoteLinkKey! xbeedm.setlinkkey(key); // Set Encryption Key Related Variables xbeedm.linkkey stores the key that has been set in the network Maximum Data Payloads As explained in chapter 5, maximum data payloads are not changed when using cyphering. Unicast Broadcast Encrypted 73Bytes 73Bytes Un-Encrypted 73Bytes 73Bytes Figure 21: Maximum Payloads -43- v1.0
44 Security and Data Encryption Security in a network When creating or joining a network, using security is highly recommended to prevent the network from attacks or intruder nodes. As explained previously, security prevents a network from being attacked by an stranger node. The node Discovery process will not work without knowing security key Creating a network enabling security When creating a network, as explained in chapter 8, security measures can be set. After choosing PAN ID and channel, to enable security a key should be chosen. This key is a 128-bit AES encryption key that has to be the same in all the nodes of the same network. Example of use: panid=0x33,0x31; xbeedm.setchannel(0x0c); // Set Channel xbeedm.setpan(panid); // Set PAN ID char* KEY= WaspmoteLinkKey! xbeedm.encryptionmode(1); // Enable encryption mode xbeedm.setlinkkey(key); // Set Link Key Available Information xbeedm.channel it will store the channel selected xbeedm.pan_id it will store the PAN ID selected xbeedm.encryptmode it will store if security is enabled xbeedm.linkkey it will store the selected key Joining a security enabled network When joining a network with security enabled, PAN ID and channel has to be set in the node, as explained in chapter 9, but security parameters have to be enabled for a full communication. The joining node should know the 128-bit AES encryption key and enable security setting this key. Example of use: panid=0x33,0x31; xbeedm.setchannel(0x0c); // Set Channel xbeedm.setpan(panid); // Set PAN ID char* KEY= WaspmoteLinkKey! ; xbeedm.encryptionmode(1); // Enable encryption mode xbeedm.setlinkkey(key); // Set Link Key Available Information xbeedm.channel it will store the channel selected xbeedm.pan_id it will store the PAN ID selected xbeedm.encryptmode it will store if security is enabled xbeedm.linkkey it will store the selected key -44- v1.0
45 13. Code examples and extended information For more information about the Waspmote hardware platform go to: Code examples and extended information -45- v1.0
Bluetooth for device discovery. Networking Guide
Bluetooth for device discovery Networking Guide Index Document Version: v4.4-11/2014 Libelium Comunicaciones Distribuidas S.L. INDEX 1. Introduction... 3 1.1. General description...3 2. Hardware... 5 2.1.
Building a Basic Communication Network using XBee DigiMesh. Keywords: XBee, Networking, Zigbee, Digimesh, Mesh, Python, Smart Home
Building a Basic Communication Network using XBee DigiMesh Jennifer Byford April 5, 2013 Keywords: XBee, Networking, Zigbee, Digimesh, Mesh, Python, Smart Home Abstract: Using Digi International s in-house
Supporting ZDOs with the XBee API
Supporting ZDOs with the XBee API The ZigBee Device Profile is a management and discovery service layer supported on all ZigBee devices. Like all other profiles, the ZigBee Device Profile defines a set
APPLICATION NOTE. AVR2130: Lightweight Mesh Developer Guide. Atmel MCU Wireless. Features. Description
APPLICATION NOTE AVR2130: Lightweight Mesh Developer Guide Atmel MCU Wireless Features Atmel Lightweight Mesh stack specification and APIs Lightweight Mesh Software Development Kit (SDK) Description This
An Overview of ZigBee Networks
An Overview of ZigBee Networks A guide for implementers and security testers Matt Hillman Contents 1. What is ZigBee?... 3 1.1 ZigBee Versions... 3 2. How Does ZigBee Operate?... 3 2.1 The ZigBee Stack...
AN1066. MiWi Wireless Networking Protocol Stack CONSIDERATIONS INTRODUCTION TERMINOLOGY FEATURES
MiWi Wireless Networking Protocol Stack Author: INTRODUCTION Implementing applications with wireless networking is becoming commonplace. From consumer devices to industrial applications, there is a growing
Waspmote Encryption Libraries. Programming guide
Waspmote Encryption Libraries Programming guide Index Document version: v4.3-01/2015 Libelium Comunicaciones Distribuidas S.L. INDEX 1. General Concepts... 4 2. Integrity... 7 2.1. Waspmote Libraries...7
Figure 1. The Example of ZigBee AODV Algorithm
TELKOMNIKA Indonesian Journal of Electrical Engineering Vol.12, No.2, February 2014, pp. 1528 ~ 1535 DOI: http://dx.doi.org/10.11591/telkomnika.v12i2.3576 1528 Improving ZigBee AODV Mesh Routing Algorithm
XBee Series 2 OEM RF Modules
XBee Series 2 OEM RF Modules XBee Series 2 OEM RF Modules ZigBee Networks RF Module Operation RF Module Configuration Appendices Product Manual v1.x.1x - ZigBee Protocol For OEM RF Module Part Numbers:
Computer Network. Interconnected collection of autonomous computers that are able to exchange information
Introduction Computer Network. Interconnected collection of autonomous computers that are able to exchange information No master/slave relationship between the computers in the network Data Communications.
Waspmote. Quickstart Guide
Waspmote Quickstart Guide Index Document version: v4.3-11/2014 Libelium Comunicaciones Distribuidas S.L. INDEX 1. Introduction... 3 2. General and safety information... 4 3. Waspmote s Hardware Setup...
The Wireless Network Road Trip
The Wireless Network Road Trip The Association Process To begin, you need a network. This lecture uses the common logical topology seen in Figure 9-1. As you can see, multiple wireless clients are in
A Transport Protocol for Multimedia Wireless Sensor Networks
A Transport Protocol for Multimedia Wireless Sensor Networks Duarte Meneses, António Grilo, Paulo Rogério Pereira 1 NGI'2011: A Transport Protocol for Multimedia Wireless Sensor Networks Introduction Wireless
Wireless Mesh Networks under FreeBSD
Wireless Networks under FreeBSD Rui Paulo [email protected] The FreeBSD Project AsiaBSDCon 2010 - Tokyo, Japan Abstract With the advent of low cost wireless chipsets, wireless mesh networks became much
www.mindteck.com 6LoWPAN Technical Overview
www.mindteck.com 6LoWPAN Technical Overview 6LoWPAN : Slide Index Introduction Acronyms Stack Architecture Stack Layers Applications IETF documents References Confidential Mindteck 2009 2 6LoWPAN - Introduction
Performance of ZigBee PRO Mesh Networks with Moving Nodes
Performance of ZigBee PRO Mesh Networks with Moving Nodes Chester Hamilton Texas A&M University Email: [email protected] Varun Sampath University of Pennsylvania Email: [email protected] July
Performance Evaluation of AODV, OLSR Routing Protocol in VOIP Over Ad Hoc
(International Journal of Computer Science & Management Studies) Vol. 17, Issue 01 Performance Evaluation of AODV, OLSR Routing Protocol in VOIP Over Ad Hoc Dr. Khalid Hamid Bilal Khartoum, Sudan [email protected]
Customer Specific Wireless Network Solutions Based on Standard IEEE 802.15.4
Customer Specific Wireless Network Solutions Based on Standard IEEE 802.15.4 Michael Binhack, sentec Elektronik GmbH, Werner-von-Siemens-Str. 6, 98693 Ilmenau, Germany Gerald Kupris, Freescale Semiconductor
Behavior Analysis of TCP Traffic in Mobile Ad Hoc Network using Reactive Routing Protocols
Behavior Analysis of TCP Traffic in Mobile Ad Hoc Network using Reactive Routing Protocols Purvi N. Ramanuj Department of Computer Engineering L.D. College of Engineering Ahmedabad Hiteishi M. Diwanji
Using Xbee 802.15.4 in Serial Communication
Using Xbee 802.15.4 in Serial Communication Jason Grimes April 2, 2010 Abstract Instances where wireless serial communication is required to connect devices, Xbee RF modules are effective in linking Universal
10. XBee Command Reference Tables
. XBee Command Reference Tables Addressing Addressing Commands Type Parameter Range Default DH DL MY MP NC Destination Address High.Set/Get the upper 32 bits of the 64-bit destination address. When combined
Power Characterisation of a Zigbee Wireless Network in a Real Time Monitoring Application
Power Characterisation of a Zigbee Wireless Network in a Real Time Monitoring Application Arrian Prince-Pike A thesis submitted to Auckland University of Technology in fulfilment of the requirements for
UG103.5 EMBER APPLICATION DEVELOPMENT FUNDAMENTALS: SECURITY
EMBER APPLICATION DEVELOPMENT FUNDAMENTALS: SECURITY This document introduces some basic security concepts, including network layer security, trust centers, and application support layer security features.
CSE331: Introduction to Networks and Security. Lecture 6 Fall 2006
CSE331: Introduction to Networks and Security Lecture 6 Fall 2006 Open Systems Interconnection (OSI) End Host Application Reference model not actual implementation. Transmits messages (e.g. FTP or HTTP)
MeshBee Open Source ZigBee RF Module CookBook
MeshBee Open Source ZigBee RF Module CookBook 2014 Seeed Technology Inc. www.seeedstudio.com 1 Doc Version Date Author Remark v0.1 2014/05/07 Created 2 Table of contents Table of contents Chapter 1: Getting
Demystifying Wireless for Real-World Measurement Applications
Proceedings of the IMAC-XXVIII February 1 4, 2010, Jacksonville, Florida USA 2010 Society for Experimental Mechanics Inc. Demystifying Wireless for Real-World Measurement Applications Kurt Veggeberg, Business,
An Efficient QoS Routing Protocol for Mobile Ad-Hoc Networks *
An Efficient QoS Routing Protocol for Mobile Ad-Hoc Networks * Inwhee Joe College of Information and Communications Hanyang University Seoul, Korea iwj oeshanyang.ac.kr Abstract. To satisfy the user requirements
A Non-beaconing ZigBee Network Implementation and Performance Study
A Non-beaconing ZigBee Network Implementation and Performance Study Magnus Armholt Email: [email protected] Sakari Junnila Email: [email protected] Irek Defee Email: [email protected] Abstract
ZIGBEE 802.15.4. ECGR-6185 Advanced Embedded Systems. Charlotte. University of North Carolina-Charlotte. Chaitanya Misal Vamsee Krishna
ECGR-6185 Advanced Embedded Systems ZIGBEE 802.15.4 University of North Carolina-Charlotte Charlotte Chaitanya Misal Vamsee Krishna WPAN A personal area network (PAN) is a computer network used for communication
WASP User Manual. Revision: 1.6. (c) 2012 North Pole Engineering, Inc.
Revision: 1.6 2 1 Introduction WASP is a standalone unit providing a bridge for ANT+ devices to communicate wirelessly through Wi-Fi networks, to other devices on the local network or over the Internet.
CS698T Wireless Networks: Principles and Practice
CS698T Wireless Networks: Principles and Practice Topic 10 IEEE 802.15.4 Bhaskaran Raman, Department of CSE, IIT Kanpur http://www.cse.iitk.ac.in/users/braman/courses/wless-spring2007/ Personal Area Networks
Optimization of AODV routing protocol in mobile ad-hoc network by introducing features of the protocol LBAR
Optimization of AODV routing protocol in mobile ad-hoc network by introducing features of the protocol LBAR GUIDOUM AMINA University of SIDI BEL ABBES Department of Electronics Communication Networks,
LoRa FAQs. www.semtech.com 1 of 4 Semtech. Semtech Corporation LoRa FAQ
LoRa FAQs 1.) What is LoRa Modulation? LoRa (Long Range) is a modulation technique that provides significantly longer range than competing technologies. The modulation is based on spread-spectrum techniques
Data sheet Wireless UART firmware version 4.02
Data sheet Wireless UART firmware version 4.02 BLUETOOTH is a trademark owned by Bluetooth SIG, Inc., U.S.A. and licensed to Free2move Rev: 22 December 2008 Table of contents 1 GENERAL INFORMATION...4
UG103.2: Application Development Fundamentals: ZigBee
UG103.2: Application Development Fundamentals: ZigBee This document describes the key features and characteristics of a ZigBee solution. It also includes a section on ZigBee 3.0. Silicon Labs Application
Internet Firewall CSIS 4222. Packet Filtering. Internet Firewall. Examples. Spring 2011 CSIS 4222. net15 1. Routers can implement packet filtering
Internet Firewall CSIS 4222 A combination of hardware and software that isolates an organization s internal network from the Internet at large Ch 27: Internet Routing Ch 30: Packet filtering & firewalls
Lab Exercise 802.11. Objective. Requirements. Step 1: Fetch a Trace
Lab Exercise 802.11 Objective To explore the physical layer, link layer, and management functions of 802.11. It is widely used to wireless connect mobile devices to the Internet, and covered in 4.4 of
Industrial Networks & Databases
Industrial Networks & Databases LONWORKS KNX 1 HVAC and BEMS HVAC - Heating, Ventilation & Air Conditioning BEMS - Building & Energy Management Systems 2 3 4 LONWORKS (Local Operating Networks) Open solution
UG103.9 EMBER APPLICATION DEVELOPMENT FUNDAMENTALS: ZLL
EMBER APPLICATION DEVELOPMENT FUNDAMENTALS: ZLL This document compares the ZLL stack and network with the EmberZNet PRO stack and network, with notes about considerations when implementing a ZLL solution.
COMPARATIVE ANALYSIS OF ON -DEMAND MOBILE AD-HOC NETWORK
www.ijecs.in International Journal Of Engineering And Computer Science ISSN:2319-7242 Volume 2 Issue 5 May, 2013 Page No. 1680-1684 COMPARATIVE ANALYSIS OF ON -DEMAND MOBILE AD-HOC NETWORK ABSTRACT: Mr.Upendra
UNIT 8:- Mobile Ad-Hoc Networks, Wireless Sensor Networks
UNIT 8:- Mobile Ad-Hoc Networks, Wireless Sensor Networks a Mobile Ad hoc NETwork (MANET) is one that comes together as needed, not necessarily with any support from the existing infrastructure or any
VXLAN: Scaling Data Center Capacity. White Paper
VXLAN: Scaling Data Center Capacity White Paper Virtual Extensible LAN (VXLAN) Overview This document provides an overview of how VXLAN works. It also provides criteria to help determine when and where
ZigBee Technology Overview
ZigBee Technology Overview Presented by Silicon Laboratories Shaoxian Luo 1 EM351 & EM357 introduction EM358x Family introduction 2 EM351 & EM357 3 Ember ZigBee Platform Complete, ready for certification
Fast and Secure Data Transmission by Using Hybrid Protocols in Mobile Ad Hoc Network
Middle-East Journal of Scientific Research 15 (9): 1290-1294, 2013 ISSN 1990-9233 IDOSI Publications, 2013 DOI: 10.5829/idosi.mejsr.2013.15.9.11514 Fast and Secure Data Transmission by Using Hybrid Protocols
CROSS LAYER BASED MULTIPATH ROUTING FOR LOAD BALANCING
CHAPTER 6 CROSS LAYER BASED MULTIPATH ROUTING FOR LOAD BALANCING 6.1 INTRODUCTION The technical challenges in WMNs are load balancing, optimal routing, fairness, network auto-configuration and mobility
Verifying Detection of Asset Tags in WLAN Controllers
APPENDIXB Verifying Detection of Asset Tags in WLAN Controllers Asset Tags Detection The protocol analyzer trace in Figure B-1 provides important information with regard to how asset tags compliant with
Bidirectional wireless communication using EmbedRF
Bidirectional wireless communication using EmbedRF 1. Tools you will need for this application note... 2 2. Introduction... 3 3. Connect EmbedRF Board to USB Interface Board... 3 4. Install and Run EmbedRF
AN965. Microchip Stack for the ZigBee Protocol ASSUMPTION INTRODUCTION FEATURES LIMITATIONS
Microchip Stack for the ZigBee Protocol AN965 Author: INTRODUCTION ZigBee is a wireless network protocol specifically designed for low data rate sensors and control networks. There are a number of applications
Dynamic Source Routing in Ad Hoc Wireless Networks
Dynamic Source Routing in Ad Hoc Wireless Networks David B. Johnson David A. Maltz Computer Science Department Carnegie Mellon University 5000 Forbes Avenue Pittsburgh, PA 15213-3891 [email protected] Abstract
Ethernet. Ethernet. Network Devices
Ethernet Babak Kia Adjunct Professor Boston University College of Engineering ENG SC757 - Advanced Microprocessor Design Ethernet Ethernet is a term used to refer to a diverse set of frame based networking
ACHILLES CERTIFICATION. SIS Module SLS 1508
ACHILLES CERTIFICATION PUBLIC REPORT Final DeltaV Report SIS Module SLS 1508 Disclaimer Wurldtech Security Inc. retains the right to change information in this report without notice. Wurldtech Security
MCB3101 (Class I) WiRobot Serial Bluetooth Wireless Module User Manual
MCB3101 (Class I) WiRobot Serial Bluetooth Wireless Module User Manual Version: 1.0.1 Dec. 2005 Table of Contents I. Introduction 2 II. Operations 2 II.1. Theory of Operation 2 II.2. Configuration (PC-PC
How To Make A Multi-User Communication Efficient
Multiple Access Techniques PROF. MICHAEL TSAI 2011/12/8 Multiple Access Scheme Allow many users to share simultaneously a finite amount of radio spectrum Need to be done without severe degradation of the
Study And Comparison Of Mobile Ad-Hoc Networks Using Ant Colony Optimization
Study And Comparison Of Mobile Ad-Hoc Networks Using Ant Colony Optimization 1 Neha Ujala Tirkey, 2 Navendu Nitin, 3 Neelesh Agrawal, 4 Arvind Kumar Jaiswal 1 M. Tech student, 2&3 Assistant Professor,
XBEE 802.15.4 PROTOCOL COMPARISON
Connect with Confidence XBEE 802.15.4 PROTOCOL COMPARISON Abstract Creating wireless networks can be done using a variety of RF protocols. Some protocols are proprietary to individual vendors, others are
M2M I/O Modules. To view all of Advantech s M2M I/O Modules, please visit www.advantech.com/products.
M2M I/O Modules 14 M2M I/O Modules Overview 14-2 M2M I/O Modules Selection Guide 14-6 ADAM-2510Z Wireless Router Node 14-8 ADAM-2520Z Wireless Modbus RTU Gateway 14-9 ADAM-2031Z ADAM-2632Z ADAM-2017Z ADAM-2018Z
Introduction to Zibgbee Technology
Introduction to Zibgbee Technology Ankur Tomar Global Technology Centre Volume 1, July 2011 1. Introduction ZigBee is the most popular industry wireless mesh networking standard for connecting sensors,
Based on Computer Networking, 4 th Edition by Kurose and Ross
Computer Networks Ethernet Hubs and Switches Based on Computer Networking, 4 th Edition by Kurose and Ross Ethernet dominant wired LAN technology: cheap $20 for NIC first widely used LAN technology Simpler,
Design and Implementation of Ad-hoc Communication and Application on Mobile Phone Terminals
Design and Implementation of Ad-hoc Communication and Application on Mobile Phone Terminals Yujin Noishiki Hidetoshi Yokota Akira Idoue KDDI R&D Laboratories, Inc. 2-1-15 Ohara, Fujimino-Shi, Saitama,
Serial Communications
Serial Communications 1 Serial Communication Introduction Serial communication buses Asynchronous and synchronous communication UART block diagram UART clock requirements Programming the UARTs Operation
Security in Ad Hoc Network
Security in Ad Hoc Network Bingwen He Joakim Hägglund Qing Gu Abstract Security in wireless network is becoming more and more important while the using of mobile equipments such as cellular phones or laptops
Wireless Communication With Arduino
Wireless Communication With Arduino Using the RN-XV to communicate over WiFi Seth Hardy [email protected] Last Updated: Nov 2012 Overview Radio: Roving Networks RN-XV XBee replacement : fits in the
Introduction to Z-Wave. An Introductory Guide to Z-Wave Technology
Introduction to Z-Wave An Introductory Guide to Z-Wave Technology Table of Contents Z-Wave Overview and Functionality... 3 Z-Wave Technology Quick Overview... 3 Radio Specifications... 3 Network and Topology...
Attenuation (amplitude of the wave loses strength thereby the signal power) Refraction Reflection Shadowing Scattering Diffraction
Wireless Physical Layer Q1. Is it possible to transmit a digital signal, e.g., coded as square wave as used inside a computer, using radio transmission without any loss? Why? It is not possible to transmit
Performance Evaluation of Large-Scale Wireless Sensor Networks Communication Protocols that can be Integrated in a Smart City
Performance Evaluation of Large-Scale Wireless Sensor Networks Communication Protocols that can be Integrated in a Smart City A. Lavric 1, V. Popa 2 PhD.,Computers, Department of Electronics and Automation,
Mac Protocols for Wireless Sensor Networks
Mac Protocols for Wireless Sensor Networks Hans-Christian Halfbrodt Advisor: Pardeep Kumar Institute of Computer Science Freie Universität Berlin, Germany [email protected] January 2010 Contents
Wireless Home Networks based on a Hierarchical Bluetooth Scatternet Architecture
Wireless Home Networks based on a Hierarchical Bluetooth Scatternet Architecture W. Lilakiatsakun'. 2, A. Seneviratne' I School of Electrical Engineering and Telecommunication University of New South Wales,
Encryption Libraries
Encryption Libraries Index Document version: v0.1-11/2012 Libelium Comunicaciones Distribuidas S.L. INDEX 1. General Concepts...4 2. Integrity...9 2.1. Waspmote Libraries...9 2.1.1. Waspmote Hash Files...9
Setting Up the ZigBee Ethernet Gateway
Setting Up the ZigBee Ethernet Gateway MAN-01-00030-1.4 This manual describes how to install and set up ZigBee communication between a SolarEdge device (Inverters or Safety and Monitoring Interface) and
BLUETOOTH SMART CABLE REPLACEMENT
BLUETOOTH SMART CABLE REPLACEMENT APPLICATION NOTE Monday, 15 October 2012 Version 1.5 Copyright 2000-2012 Bluegiga Technologies All rights reserved. Bluegiga Technologies assumes no responsibility for
Maximizing Range and Battery Life in Low-Cost Wireless Networks
Maximizing Range and Battery Life in Low-Cost Wireless Networks The proliferation of cost-effective wireless technology has led to the rise of entirely new types of networks across a wide range of applications
EETS 8316 Wireless Networks Fall 2013
EETS 8316 Wireless Networks Fall 2013 Lecture: WiFi Discovery, Powersave, and Beaconing http://lyle.smu.edu/~skangude/eets8316.html Shantanu Kangude [email protected] Discovery and Beaconing Discovery?
TECHNICAL NOTE. GoFree WIFI-1 web interface settings. Revision Comment Author Date 0.0a First release James Zhang 10/09/2012
TECHNICAL NOTE GoFree WIFI-1 web interface settings Revision Comment Author Date 0.0a First release James Zhang 10/09/2012 1/14 Web interface settings under admin mode Figure 1: web interface admin log
Comparison of WCA with AODV and WCA with ACO using clustering algorithm
Comparison of WCA with AODV and WCA with ACO using clustering algorithm Deepthi Hudedagaddi, Pallavi Ravishankar, Rakesh T M, Shashikanth Dengi ABSTRACT The rapidly changing topology of Mobile Ad hoc networks
NetworkPathDiscoveryMechanismforFailuresinMobileAdhocNetworks
Global Journal of Computer Science and Technology: E Network, Web & Security Volume 14 Issue 3 Version 1.0 Year 2014 Type: Double Blind Peer Reviewed International Research Journal Publisher: Global Journals
Professur Technische Informatik Prof. Dr. Wolfram Hardt. Network Standards. and Technologies for Wireless Sensor Networks. Karsten Knuth 16.07.
Network Standards and Technologies for Wireless Sensor Networks Karsten Knuth 16.07.2008 Index 1. Motivation 2. Introduction 3. Bluetooth 4. ZigBee 5. nanonet 6. Roundup 16.07.2008 Network Standards 2
Wiereless LAN 802.11
Tomasz Kurzawa Wiereless LAN 802.11 Introduction The 802.11 Architecture Channels and Associations The 802.11 MAC Protocol The 802.11 Frame Introduction Wireless LANs are most important access networks
Achieving Energy Efficiency in MANETs by Using Load Balancing Approach
International Journal of Computer Networks and Communications Security VOL. 3, NO. 3, MARCH 2015, 88 94 Available online at: www.ijcncs.org E-ISSN 2308-9830 (Online) / ISSN 2410-0595 (Print) Achieving
Microchip Technology. February 2008 Valerio Moretto Slide 1
Microchip Technology February 2008 Valerio Moretto Slide 1 Connectivity Solutions Wired Wireless February 2008 Valerio Moretto Slide 2 Microchip Solutions More complex software Operating Systems >40 MIPS
Simulation Analysis of Different Routing Protocols Using Directional Antenna in Qualnet 6.1
Simulation Analysis of Different Routing Protocols Using Directional Antenna in Qualnet 6.1 Ankit Jindal 1, Charanjeet Singh 2, Dharam Vir 3 PG Student [ECE], Dept. of ECE, DCR University of Science &
QoS issues in Voice over IP
COMP9333 Advance Computer Networks Mini Conference QoS issues in Voice over IP Student ID: 3058224 Student ID: 3043237 Student ID: 3036281 Student ID: 3025715 QoS issues in Voice over IP Abstract: This
Wireless Personal Area Networks (WPANs)
Wireless Personal Area Networks (WPANs) Bluetooth, ZigBee Contents Introduction to the IEEE 802 specification family Concept of ISM frequency band Comparison between different wireless technologies ( and
A Comparison Study of Qos Using Different Routing Algorithms In Mobile Ad Hoc Networks
A Comparison Study of Qos Using Different Routing Algorithms In Mobile Ad Hoc Networks T.Chandrasekhar 1, J.S.Chakravarthi 2, K.Sravya 3 Professor, Dept. of Electronics and Communication Engg., GIET Engg.
LAN Switching. 15-441 Computer Networking. Switched Network Advantages. Hubs (more) Hubs. Bridges/Switches, 802.11, PPP. Interconnecting LANs
LAN Switching 15-441 Computer Networking Bridges/Switches, 802.11, PPP Extend reach of a single shared medium Connect two or more segments by copying data frames between them Switches only copy data when
Web Site: www.parallax.com Forums: forums.parallax.com Sales: [email protected] Technical: [email protected]
Web Site: www.parallax.com Forums: forums.parallax.com Sales: [email protected] Technical: [email protected] Office: (916) 624-8333 Fax: (916) 624-8003 Sales: (888) 512-1024 Tech Support: (888) 997-8267
Implementation of Wireless Gateway for Smart Home
Communications and Network, 2013, 5, 16-20 doi:10.4236/cn.2013.51b005 Published Online February 2013 (http://www.scirp.org/journal/cn) Implementation of Wireless Gateway for Smart Home Yepeng Ni 1, Fang
Firmware version: 1.10 Issue: 7 AUTODIALER GD30.2. Instruction Manual
Firmware version: 1.10 Issue: 7 AUTODIALER GD30.2 Instruction Manual Firmware version: 2.0.1 Issue: 0.6 Version of the GPRS transmitters configurator: 1.3.6.3 Date of issue: 07.03.2012 TABLE OF CONTENTS
DESIGN AND DEVELOPMENT OF LOAD SHARING MULTIPATH ROUTING PROTCOL FOR MOBILE AD HOC NETWORKS
DESIGN AND DEVELOPMENT OF LOAD SHARING MULTIPATH ROUTING PROTCOL FOR MOBILE AD HOC NETWORKS K.V. Narayanaswamy 1, C.H. Subbarao 2 1 Professor, Head Division of TLL, MSRUAS, Bangalore, INDIA, 2 Associate
ADAPTIVE LINK TIMEOUT WITH ENERGY AWARE MECHANISM FOR ON-DEMAND ROUTING IN MANETS
ADAPTIVE LINK TIMEOUT WITH ENERGY AWARE MECHANISM FOR ON-DEMAND ROUTING IN MANETS M. Tamilarasi 1, T.G. Palanivelu 2, 1, 2 Department of ECE, Pondicherry Engineering College, Puducherry-605014. Email:
Mobile Security Wireless Mesh Network Security. Sascha Alexander Jopen
Mobile Security Wireless Mesh Network Security Sascha Alexander Jopen Overview Introduction Wireless Ad-hoc Networks Wireless Mesh Networks Security in Wireless Networks Attacks on Wireless Mesh Networks
Waspmote RTC. Programming Guide
Waspmote RTC Programming Guide Index Document Version: v0.4-06/2012 Libelium Comunicaciones Distribuidas S.L. INDEX 1. General Considerations... 3 1.1. Waspmote Libraries...3 1.1.1. Waspmote RTC Files...3
The BSN Hardware and Software Platform: Enabling Easy Development of Body Sensor Network Applications
The BSN Hardware and Software Platform: Enabling Easy Development of Body Sensor Network Applications Joshua Ellul [email protected] Overview Brief introduction to Body Sensor Networks BSN Hardware
CCNA R&S: Introduction to Networks. Chapter 5: Ethernet
CCNA R&S: Introduction to Networks Chapter 5: Ethernet 5.0.1.1 Introduction The OSI physical layer provides the means to transport the bits that make up a data link layer frame across the network media.
LoRaWAN. What is it? A technical overview of LoRa and LoRaWAN. Technical Marketing Workgroup 1.0
LoRaWAN What is it? A technical overview of LoRa and LoRaWAN Technical Marketing Workgroup 1.0 November 2015 TABLE OF CONTENTS 1. INTRODUCTION... 3 What is LoRa?... 3 Long Range (LoRa )... 3 2. Where does
PERA: Ad-Hoc Routing Protocol for Mobile Robots
PERA: Ad-Hoc Routing Protocol for Mobile Robots Carlos Agüero Vicente Matellán Pedro de-las-heras-quirós José M. Cañas DIET (Departamento de Informática, Estadística y Telemática) Universidad Rey Juan
UG105 ADVANCED APPLICATION PROGRAMMING WITH THE STACK AND HAL APIS
ADVANCED APPLICATION PROGRAMMING WITH THE STACK AND HAL APIS This manual supports developers whose applications require functionality not available through Ember AppBuilder and the Ember application framework,
Wireless Networks. Reading: Sec5on 2.8. COS 461: Computer Networks Spring 2011. Mike Freedman
1 Wireless Networks Reading: Sec5on 2.8 COS 461: Computer Networks Spring 2011 Mike Freedman hep://www.cs.princeton.edu/courses/archive/spring11/cos461/ 2 Widespread Deployment Worldwide cellular subscribers
Process Control and Automation using Modbus Protocol
Process Control and Automation using Modbus Protocol Modbus is the fundamental network protocol used in most industrial applications today. It is universal, open and an easy to use protocol. Modbus has
DCP COMMAND. bringing two-way communications to your DCPs
DCP COMMAND bringing two-way communications to your DCPs DCP COMMAND Project Goals Bring affordable, reliable two way communications to DCPs Facilitate remote management of the DCP including setup and
