• Share
  • Email
  • Embed
  • Like
  • Save
  • Private Content
Zig Bee
 

Zig Bee

on

  • 6,517 views

ZigBee in Industrial Automation

ZigBee in Industrial Automation

Statistics

Views

Total Views
6,517
Views on SlideShare
6,492
Embed Views
25

Actions

Likes
19
Downloads
0
Comments
18

8 Embeds 25

http://www.techgig.com 8
http://www.tradehub.tw 7
http://tradehub.tw 3
http://techgig.in 2
http://www.linkedin.com 2
http://rajbasu.wordpress.com 1
http://115.112.206.131 1
http://localhost 1
More...

Accessibility

Categories

Upload Details

Uploaded via as Microsoft PowerPoint

Usage Rights

© All Rights Reserved

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel

110 of 18 previous next Post a comment

  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
  • please email this to raghutc1125@gmail.com

    Thanks in adavnce
    Are you sure you want to
    Your message goes here
    Processing…
  • pls email this presentation to mham1156@gmail.com

    thanks
    Are you sure you want to
    Your message goes here
    Processing…
  • please mail this ppt sajith.vijesekara@gmail.com
    Are you sure you want to
    Your message goes here
    Processing…
  • Could you please email this ppt to amulyakamineni@gmail.com ?
    Are you sure you want to
    Your message goes here
    Processing…
  • pls mail ppt to sajith.vijesekara@gmail.com
    Are you sure you want to
    Your message goes here
    Processing…

110 of 18 previous next

Post Comment
Edit your comment
  • Among these radio technologies only 802.15.4 has the low power consumption that long-lived battery powered industrial products will need. Before ZigBee, there hasn’t been a wireless network standard that meets the unique needs of sensors and control devices. Sensors and controls don’t need high bandwidth but they do need low latency and very low energy consumption for long battery lives and for large device arrays. Despite the increasing popularity of IEEE 802.11 wireless LAN systems (WiFi) and Bluetooth systems, wireless communication has not made significant inroads in industrial applications. And while wireless systems seem like an obvious solution for industrial applications, in reality the cure can be worse than the disease. Solutions based on these standards were not designed with the industrial environment in mind. Industrial users need a network architecture that takes the unique challenges of the industrial environment into account. WLAN , Wireless Local Area Network WLAN: IEEE 802.11: WiFi (Ethernet matching speed, long range ~100m and high data rate 2-11 Mbps) WPAN , Wireless Personal Area Network WPAN Eg: IEEE 802.15: Bluetooth, RFID, ZigBee, etc., (Low cost, low power, short range, small size) WMAN , Wireless Metropolitan Area Network WMAN IEEE 802.16: WiMAX WPAN: The IEEE 802.15 working group is formed to create WPAN standard. This group has currently defined three classes of WPANs that are differentiated by data rate, battery drain and quality of service(QoS) . The high data rate WPAN( IEEE 802.15.3 ) is suitable for multi-media applications that require very high QoS. Medium rate WPANs ( IEEE 802.15.1 /Blueetooth) will handle a variety of tasks ranging from cell phones to PDA communications and have QoS suitable for voice communications. The low rate WPANs ( IEEE 802.15.4 /LR-WPAN) is intended to serve a set of industrial, residential and medical applications with very low power consumption. and with relaxed needs for data rate and QoS. This low data rate enables the LR-WPAN to consume very little power.
  • What is ZigBee ? The origin of the term ZigBee lies in the domestic honeybee, the future of whose colony is dependent upon the continuous communication of vital information between every member of the colony. The technique that honeybee uses to communicate new found food sources to other members of the colony is referred to as the ZigBee principle. Using this silent and powerful communication system, where by bee dances in zigzag pattern, she is able to share information such as location, direction of a new food source to fellow colony. The ZigBee Alliance is not pushing a technology; rather it is providing a standardized base set of solutions for sensor and control systems.
  • ZigBee’s addressing scheme is capable of supporting over 64,000 nodes per ‘network coordinator’, and multiple network coordinators can be linked together to support extremely large networks. The logical size of a ZigBee network ultimately depends on which frequency band is selected, how often each device on the network needs to communicate, how much data loss or retransmissions can be tolerated by the application. Key solution requirements for successful ZigBee deployment include ease of integration, redundancy, scalability, power efficiency .
  • Wireless networks for industrial control and sensing, must be reliable , adaptable , and scalable . Because industrial sensors send only a few of bits of data per second or minute, providing information like temperature, pressure and flow, data rates of 11 Mbps or even 54 Mbps are rarely needed. Although speed is often the focus for data networks, the primary design objectives for industrial control and sensing networks are reliability, adaptability and scalability . Three factors determine the signal reliability between a radio transmitter and receiver: Path loss RF interference Transmit power The network should adapt to the existing environment. The environment should not have to be altered to make the system "wireless ready." Any network, wired or wireless, should scale gracefully as the number of endpoints increases.
  • ? What is selectable latency in IEEE 802.15.4 or ZigBee. IEEE 802.15.4 specifies how individual packets are structured, and the interaction between two ends of a data link. IEEE 802.15.4 also specifies 27 RF channels in the three frequency bands
  • ZigBee operates at three frequency bands: 868 MHz: At this frequency single channel between 868 to 868.6 . Support in Europe and at rate of 20 Kbps . 915 MHz: At this frequency 10 channels between 902 MHz to 928 MHz . Supports in North America and Australia at rate of 40 Kpbs . 2.4GHz: Supports 16 channels between 2.4 and 2.4835 GHz . All over the world. It allows dynamic channel selection. Channel selection scan function that step through a list of supported channels in search of beacon, receiver energy detection, link quality indication, channel switching. Like Wi-Fi, Zigbee uses DSSS in the 2.4GHz band, with offset-quadrature phase-shift keying modulation . Channel width is 2MHz with 5MHz channel spacing at 2.4GHZ band. Overall 16 RF channels. The 868 and 900MHz bands also use DSSS but with binary-phase-shift keying modulation. The IEEE 802.15.4 channels do not directly coincide with Wi-Fi channels . Therefore, IEEE 802.15.4 systems can coexist with Wi-Fi systems with little physical separation.
  • FSK (Frequency Shift Keying) is a far less efficient, but simpler to implement modulation technique that is used in Bluetooth The fundamental of O-QPSK method is to sum the in-phase signals with quadrature phase signal delayed by half a cycle in order to avoid the sudden phase shift changed.
  • Typical design consist of RF IC and 8-bit microprocessor with peripherals connected to an application sensor or actuators.
  • The physical layer was designed to accommodate the need for a low cost yet allowing for high levels of integration. The use of direct sequence allows the analog circuitry to be very simple and very tolerant towards inexpensive implementations. Some of the key features of physical layer is energy and link quality detection, clear channel assessment for improved coexistence with other wireless networks. The MAC layer was designed to allow multiple topologies without complexity. The power management operation doesn’t require multiple modes of operation. The MAC allows a reduced functionality device (RFD) that needn’t have flash nor large amounts of ROM or RAM. The MAC was designed to handle large numbers of devices without requiring them to be “parked”. The network layer has been designed to allow the network to spatially grow without requiring high power transmitters. The network layer also can handle large amounts of nodes with relatively low latencies. In ZigBee network routing schemes are designed to ensure power conservation and low latency through guaranteed time slots. A unique feature of ZigBee network layer is communication redundancy eliminating single point of failure in mesh networks. Application Support Layer provides the following services: Discovery: The ability to determine which other devices are operating in the personal operating space of a device. Binding: The ability to match two or more devices together based on their services and their needs and forwarding messages between bound devices. ZigBee Device Object Defines the role of the device within the network (e.g., ZigBee coordinator or end device) Initiates and/or responds to binding requests Establishes a secure relationship between network devices selecting one of ZigBee’s security methods such as public key, symmetric key, etc. ZigBee applications are modeled by application objects . Application objects communicate with each other through the mapping of object attributes or sets of object attributes that are called clusters. At the highest level applications are defined by an application profile. An application profile includes a series of named services and capabilities. ZigBee also requires a set of basic device methods that every application object must implement. Each ZigBee device can support multiple applications that are identified by a numbered “endpoint” designation. There can be 240 endpoints per ZigBee device, but each endpoint can support only one profile. Application profiles are identified by a unique number that is administered by the ZigBee Alliance. Data communication between objects is implemented in compressed XML to ensure hardware independence .
  • A PAN Coordinator always have network address “ 0000 ”.
  • Devices that wish to join the network will do so by first issuing beacon requests to solicit beacons from devices that could potentially allow them to join the network. Initially, only the PAN coordinator will respond. In addition to the PAN coordinator, any device capable of allowing other devices to join the network is a ZigBee router. What ensues is a series of message exchanges that will determine whether a device may join the network. In 802.5.4, this process is called “ association ”. A key factor in such a determination is a router’s capacity to accept additional devices as its child. Where 802.15.4 differs from other wireless technologies, such as 802.11/Wi-Fi, is in permitting a hierarchy of associations , rather than a single parent-children structure. For instance, a device joining the coordinator could itself be a router (i.e., it can have childrens), and that device could permit other devices to join it. As a result, multiple levels of associations can be achieved. But in the case of Wi-Fi it not possible. d
  • Where 802.15.4 differs from other wireless technologies, such as 802.11/Wi-Fi, is in permitting a hierarchy of associations , rather than a single parent-children structure. For instance, a device joining the coordinator could itself be a router (i.e., it can have childrens), and that device could permit other devices to join it. As a result, multiple levels of associations can be achieved. But in the case of Wi-Fi it not possible. The beacons are used to synchronize the attached devices, to identify the PAN and to describe the structure of the superframe . All 802.15.4 devices have a 64-bit (long) IEEE address , which uniquely identifies the device. In order to extend battery life, shorter addresses are used to shorten the packet sizes and hence the time a device is actively communicating. ZigBee requires that all communications after joining the network be made on a 6-bit (short) network address. The 16-bit network address of a newly joining device is assigned by its parent during the association . ZigBee specifies an algorithm (often called “ Cskip ”) that provides address ranges to routers and coordinators, to be assigned to joining devices based on their location within the network hierarchy. In addition to managing network joining and address assignment, the network formation process also provides a routing algorithm called “ tree routing ”
  • A small network is shown in Figure 1. In this case, the PAN coordinator (which always has network address “0000”) has three devices associated to it, and of these, two of them (with network addresses “000” and “07e”), acting as routers , have a device associated to them. Tkey characteristics of the network are defined by the parameters. Some of the parameters are: Depth of network. Maximum number of childrens per router. Maximum of children routers per router.
  • MAC Data Service: It enables the transmission and reception of MAC Protocol Data Unit (MPDU) across the PHY data service. Wired devices can listen during their own transmissions and employ CSMA with collision detection (CSMA/CD), stations in wireless networks usually cannot listen to their own transmissions, and consequently colliding transmissions can only be detected after they have been completed. Thus wireless devices use CSMA with collision avoidance ( CSMA/CA or CSMA-CA ). The beacons are used to synchronize the attached devices, to identify the PAN, and to describe the structure of the superframes . GTS = Guaranteed Time Slot mgmt. Low latency applications may choose to the guaranteed time slot (GTS) option. GTS is a method of QoS in that it allows each device a specific duration of time each Superframe to do whatever it wishes to do without contention or latency.
  • PHY Data Service enables the transmission and reception of PHY Protocol Data Unit ( PPDU ) across physical radio channel. Energy detection report will be two byte length. 0x00 to 0xff. The minimum ED value 0 indicates that received power less then 10 dB . The range of received power spanned by the ED value shall be at least 40 dB .
  • In ZigBee network routing schemes are designed to ensure power conservation and low latency through guaranteed time slots. A unique feature of ZigBee network layer is communication redundancy eliminating single point of failure in mesh networks.
  • A FFD can talk to RFD ( Reduced Functional Device) or FFD ( Full Functional Device ) whereas RFD can talk to FFD only .
  • In ZigBee, network addresses are assigned either by a network coordinator or by a ZigBee router using a tree-structured algorithm. At the highest level the structure of a network is defined by an entity known as a "stack profile". This stack profile includes a parameter set that includes Definition of the maximum network depth.. The maximum number of child routers at any depth in the network, and the maximum number of "children" who can communicate with an individual router. These parameters broadly determine the “shape” of the resulting network tree. ZigBee end devices (ZEDs) do not participate in routing. End devices communicate with a single router, which is their parent device.
  • Most of the wireless sensor networks adopting this network only. This network has a central node (i.e., coordinator), which is linked to all other nodes in the network. All messages travel via the coordinator. To implement a star network you don’t need to use ZigBee network layer, since a star network topology is provided by the IEEE 802.15.4 layer. So if you are using IEEE 802.15.4 layer then the application program reside in the coordinator is responsible for relaying the messages. But in case of ZigBee network layer the Coordinator passes routes the messages transparent to application program. ZigBee uses a basic master-slave configuration suited to static star networks of many infrequently used devices that talk via small data packets. It allows up to 254 nodes.
  • In sending messages from one node to another, the message must travel from the source node up the tree to the nearest common ancestor and then down the tree to the destination node. Here message propagation is handled be ZigBee stack and is transparent to the application program.
  • This Mesh network has a tree like structure in which some levels are directly linked. Messages can travel across the tree, when a suitable route is available. This Mesh topology consists of a Coordinator, and a set of Routers and End devices. Like Tree topology, in this topology also message propagation is handled by ZigBee protocol stack and it is transparent to application program.
  • Sequence number for maintain the freshness information. The source node initiates path discovery by broadcasting a route request (RREQ) packet to its neighbors, which includes source addr, source sequence number, broadcast id, dest address, dest sequence number, hop count . The pair source addr, broadcast id uniquely identifies a RREQ , where broadcast id is incremented whenever the source issues a new RREQ.
  • The pair source addr, broadcast id uniquely identifies a RREQ , Here broadcast id is incremented whenever the source issues a new RREQ. When an intermediate node receives a RREQ, if it has already received a RREQ with the same broadcast id and source address , it drops the redundant RREQ and does not rebroadcast it. Otherwise, it rebroadcasts it to its own neighbors after increasing hop cnt . Each node keeps the following information: destination IP address, source IP address , broadcast id , expiration time for reverse path route entry and source node’s sequence numbe r. These reverse path route entries are maintained for at least enough time for the RREQ to traverse the network and produce a reply to the sender. Each routing table entry includes the following fields: destination, next hop, number of hops ( metric ), sequence number for the destination , active neighbors for this route , expiration time for the route table entry.
  • DD stands for Designated Device.
  • Presently available profiles are: ■ Commercial Building Automation ■ Home Automation ■ Industrial plant monitoring. ■ Wireless sensor applications Feature standard profiles are: ■ Telecom ■ Automatic Metere Reading ■ Medical and Personal health care ■ Automotive.
  • Binding is the ability to match two devices together based on their services and their needs and forwarding messages between bound devices Discovery , is the ability to determine which other devices are operating in the personal operating space of a device.
  • A cluster is a message or a collection of similar messages.
  • The ZDO provides control and management commands. One application profile defined per end point.
  • Several limitations exist with direct binding . The device must have sufficient memory to store all this information about all its peer applications and devices. However, this might not be possible (or too expensive) for a simple device. When the device fails, the binding information stored within the device may be lost. Should its peer device be replaced or fail, updating this information in the device will be difficult.
  • Device Discovery: Commands offer the means to determine what devices are on the network, their addresses and the list of their children devices. They can also provide information about the device, including whether it is coordinator, router or end device , manufacturer or product information and even its power source and current battery level. Service Discovery: Commands, in contrast, enable the determination of services offered by devices. Using these commands, it possible to determine which endpoints are active on a device, what profiles are associated with each endpoint (i.e., the device descriptor, as mentioned earlier) and to match device descriptors between two devices. Binding Management: Commands offer the means to manage bindings between devices. Network Management: Commands provide a way to collect information and control devices for network management purposes. They provide information such as the list of ZigBee networks that a device is able to detect, the quality of the radio link with its neighbors, and the contents of its routing and binding tables. For control purposes, there are commands to instruct a device to join or leave the network.
  • An IEEE 802.15.4/ZigBee network requires at least one full function device as a network coordinator , but endpoint devices may be reduced functionality devices to reduce system cost. All devices must have 64 bit IEEE addresses Short (16 bit) addresses can be allocated to reduce packet size Addressing modes: Network + device identifier (star) Source/destination identifier (peer-peer)
  • Complete PHY Packet is called PPDU . Preamble contains 32-bits of “0” for packet detection and synchronization in the receiver. Start of Frame Delimiter ( SFD ) value is “11100101” = 0xE5.
  • There are four frame types for IEEE 802.15.4 transmissions: Data, ACK, MAC Command, Beacon. The data frame provides a payload of up to 104 bytes . The frame is numbered to ensure that all packets are tracked. A frame-check sequence ensures that packets are received without error. A MAC command frame provides the mechanism for remote control and configuration of client nodes. The PHY Header is 8-bits length. Within this 8-bits, 7-bits are used to indicate PSDU ( PHY Service Data Unit ) Length and 1 bit for reserved.
  • Here FCS stands for Frame Check Sequence. Four different types of MAC frames defined. Data, ACK, Beacon and MAC Command .
  • In Ethernet ( not in IEEE 802.15.4) the preamble frame consists of a 56-bit (7-byte) pattern of alternating 1 and 0 bits , which allows devices on the network to easily detect a new incoming frame. In PHY header 0-7 bits are used for PPDU length . (so PPDU length is max of 127 bytes ) and 1 bit for reserved .
  • The beacons are used to: Synchronize the attached devices Identify the PAN coordinator Describe the structure of superframe A beacon frame used by coordinator to transmit beacons. The structure of the superframe is determined by two variables The Superframe Orde r (SO) and the Beacon Order (BO). SO determines the length of the superframe. BO determines the beacon interval. Network coordinator to transmit beacons at predetermined intervals (multiples of 15.38ms , up to 252s ) Beacon timings are different between each device.
  • Provides up to 104 byte data play load capacity. Data Sequence numbering to ensure that packets are tracked. Frame Check Sequence (FCS) validates error-free data. Each PPDU packet consists of the following basic components: SHR : It allows receiving device to synchronize and lock into the bit stream. PHR : It contains frame length information. A variable length play load (Max of 104 bytes), which carries the MAC sub layer frame . The Physical Protocol Data Unit is the total information sent over the air. As shown in the illustration above the Physical layer adds the following overhead: Preamble Sequence 4 Octets Start of Frame Delimiter 1 Octet Frame Length 1 Octet The MAC adds the following overhead: Frame Control 2 Octets Data Sequence Number 1 Octet Address Information 4 – 20 Octets Frame Check Sequence 2 Octets In summary the total overhead for a single packet is therefore 15 -31 octets It has robust structure so improves reception in difficult condition.
  • Ack frame length is 11 bytes. It provides active feedback from receiver to sender that packet was received without error. Short packet that takes advantage of standards-specific “quiet time” immediately after data packet transmission.
  • A MAC command frame, used for handling all MAC peer entity control transfers .
  • In indirect addressing mode endpoint address fields are either included are not included. This will be done from frame control. Similarly cluster identifier or profile identifier fields are not included for command frames.
  • For transmissions of data frames in the contention access period , the slotted mode of the CSMA-CA algorithm is used Transmissions in the contention free period take place according to pre-assigned guaranteed timeslots. PANs not wishing to use Superframe structure always use unslotted CSMA-CA to access channel and are always active. Any device wishing to communicate during the contention access period (CAP) between two beacons shall compete with other devices using a slotted CSMA-CA mechanism. All transactions shall be completed by the time of the next network beacon.
  • However, a sufficient portion of the CAP (Contention Access Period) shall remain for contention based access of other networked devices or new devices wishing to join the network. All contention based transactions shall be complete before the CFP begins. Also each device transmitting in a GTS shall ensure that its transaction is complete before the time of the next GTS or the end of the CFP. During the CAP, MAC is ruled by the slotted CSMA/CA mechanism .
  • The mechanism for each of these transfers depends on whether the network supports transmission of Beacon or not. For graphical representation see in next slide.
  • The applications transfers are completely controlled by the devices on a PAN rather than by the coordinator. This provides the energy-conservation feature of the ZigBee network.
  • aTurnaroundTime is the time to switch from sending to receiving mode and vice versa. This value will be 12 symbol period . If the originator receives an acknowledgement from the recipient within a time of macAckWaitDuration , the data transfer has been successful. If no acknowledge is received within that time, the frame will be retransmitted up to a maximum of aMaxFrameRetries times, after which the protocol terminates and a communications failure is issued. The macAckWaitDuration 120 symbols period for channels 0 to 10 (863 or 910 MHz) or 54 symbols for channel 11 to 26 (2.4 GHz) .
  • The applications transfers are completely controlled by the devices on a PAN rather than by the coordinator. This provides the energy-conservation feature of the ZigBee network. The device acknowledged the successful reception of the data by transmitting an acknowledgement frame. Upon receiving the acknowledgement, the message is removed from the list of pending messages in the beacon.
  • In integrity options 64 is the default.
  • In integrity options 64 is the default.
  • If trust centre is assigned to a dedicated device it may be possible for a portable device . Residential Mode: ► The trust center allows devices to join the network, but does not establish keys with network devices ► The trust center cannot update keys periodically because it does not maintain keys with network devices ► The memory cost in the trust center is minimal and does not scale with the size of the network Commercial Mode: ► The trust center establishes and maintains keys and freshness counters with every device in the network ► This allows centralized control and update of keys ► Cost memory in the trust center could scale with the size of the network
  • All the three keys can also be factory installed option.
  • When transmitting a frame, if integrity is required, the MAC header and payload data are used in calculations to create a Message Integrity Code (MIC) consisting of 4, 8 , or 16 octets . This MIC is right appended to the MAC payload. Upon receipt of a frame, if a MIC is present, then it is verified. If confidentiality is required, the MAC frame payload is also left appended with frame and sequence counts (data used to form a nonce). The nonce is used when encrypting the payload and also ensures freshness to prevent replay attacks . Unpon receipt if a play load is encrypted then it is decrypted. Sending devices will increase the frame count with every message sent and receiving devices will keep track of the last received count from each sending device. If a message with an old count is detected, it is flagged with a security error.
  • Similar to the MAC layer frame format, a frame sequence count and MIC may be added to secure a NWK frame . Also, the use of CCM* in all security suites allows a single key to be used for different suites. Since a key is not strictly bound to a single security suite. An application has the flexibility to specify the actual security suite to apply to each NWK frame, not just whether security is enabled or disabled. When the NWK layer transmits (receives) a frame using a particular security suite it uses the Security Services Provider (SSP) to process the frame. The SSP looks at the destination (source) of the frame, retrieves the key associated with that destination (source), and then applies the security suite to the frame. The SSP provides the NWK layer with a primitive to apply security to outgoing frames and a primitive to verify and remove security from incoming frames. The NWK layer is responsible for the security processing, but the upper layers control the processing by setting up the keys and determining which CCM* security suite to use for each frame.
  • These values are taking after adding 6 octet overhead of physical layer. 1 Symbol = 4 bits at 250 Kbps and 1 bit at other speeds.
  • 1 Unit Back Off period = 20 symbols at 250 Kbps. 1 Symbol = 4 bits = 16 Micro Second Duration. So 1 Unit Backoff Period = 16 * 20 = 320 Micro Seconds.
  • 1 symbol = 4 bits at 250 Kbps.
  • Conclusion on Power consumption: ZigBee devices can quickly attach, exchange information, detach, and then go to deep sleep to achieve a very long battery life . Bluetooth devices require about ~100X the energy for this operation. ZigBee and Bluetooth are two solutions for two different application areas: The differences are from their approach to their desired application. Bluetooth has addressed a voice application by embodying a fast frequency hopping system with a master slave protocol. ZigBee has addressed sensors, controls , and other short message applications by embodying a direct sequence system with a star or peer to peer protocols. Minor changes to Bluetooth or ZigBee won’t change their inherent behavior or characteristics. The different behaviors come from architectural differences. ZigBee supports DSSS ( Direct Sequence Spread Spectrum) allows devices to sleep without the requirement for close synchronization. Whereas in Bluetooth uses FHSS ( Frequency Hopping Spread Spectrum) is extremely difficult to create extended networks without large synchronization cost.
  • If IEEE 802.11 and IEEE 802.15.4 are existed at the same network area, then IEEE 802.11 network dominates over the IEEE 802.15.4 networks and consequently the frames of IEEE 802.15.4 frames are destroyed . There clearly is a coexistence issue in the 2.4 GHz band. Especially the impact of IEEE802.11 stations with high duty cycle against IEEE802.15.4 stations may be extremely critical, if the same carrier frequencies are selected. This scenario will lead to a timeout of the physical layer.

Zig Bee Zig Bee Presentation Transcript

  • Presentation on
    • ZigBee
    • Wireless Protocol
    • ( Wireless Control that Simply Works )
    • By
    • Ch.Vishwa Mohan
  • Agenda
    • ZigBee Introduction
    • ZigBee Applications
    • ZigBee Lighting Control System Demo
    • ZigBee Features Set
    • ZigBee Protocol Stack Architecture
    • ZigBee Traffic & Frames
    • ZigBee Security
    • ZigBee Descriptors & Commands
    • CSMA/CA Algorithm
    • Comparison of ZigBee with Other Wireless Protocols
  • Today What Industry is Looking?
    • Industry wants to move from wire to wireless networks with ubiquitous communication with focus on interoperability, plug and play, self organizing networks and low power.
    • Wireless systems for industry have mostly used cell phone-style radio links, using point-to-point or point-to-multipoint transmission.
    • In addition to the above industry also looks on:
      • High Quality AV Streaming.
      • Bits/Hz/Watts
      • Mobility
  • Parting Thought
    • “Just as the personal computer was a symbol of
    • the '80s, and the symbol of the '90s is the World
    • Wide Web, the next nonlinear shift, is going to be
    • the advent of Wireless networks .”
  • The 802 Wireless Space
    • For sensor network applications key design requirement revolve around long battery life, low cost, small foot print and mesh network (to support large number of devices).
    • Large networks (large number of devices and large coverage area) that can form autonomously and that will operate very reliably for years without any operator intervention
    • Very long battery life (years off of a AA cell), very low infrastructure cost (low device & setup costs) and very low complexity and small size
    • Device data rate and QoS needs are low
    • Standardized protocols are necessary to allow multiple vendors to interoperate.
    Sensor/Control Network Requirements
  • What is ZigBee ?
    • ZigBee is a robust, light weight wireless networking protocol that builds upon IEEE 802.15.4 standard.
      • This IEEE 802.15.4 standard defines a short range, low-power, low data rate wireless interface specially designed for small devices that have limited power, CPU and memory resources.
    • ZigBee technology is a low data rate, low power consumption, low cost, wireless networking protocol targeted towards automation, remote monitoring and control applications.
    • ZigBee stack is a more then communication protocol.
    • ZigBee = Protocol + Application Framework .
  • What is ZigBee ?
    • ZigBee was designed for the hostile RF environment ( i.e., ISM Band 2.5 G.Hz.). Utilizing Direct Sequence Spread Spectrum with the following features:
      • Collision Avoidance
      • Receiver Energy Detection
      • Link Quality Indication
      • Clear Channel Assessment
      • Acknowledgement
      • Security
      • Support for guaranteed time slots.
      • Packet Freshness.
  • What is the origin of ZigBee Name
    • Using communication system, whereby the bee dances in a zig-zag pattern, worker bee is able to share information such as the location, distance, and direction of a newly discovered food source to her fellow colony members.
    • Instinctively implementing the ZigBee Principle, bees around the world industriously sustain productive hives and foster future generations of colony members.
  • What is ZigBee Alliance?
    • Needed an organization with a mission to define a complete open global standard for reliable, cost-effective, low-power, wirelessly networked products addressing monitoring and control
    • Alliance provides
      • upper layer stack and application profiles
      • compliance and certification testing
      • branding
    • Result is a set of recognizable, interoperable solutions
  • Who is supporting the ZigBee Alliance?
    • Eight promoter companies
      • Chipcon, Ember, Freescale, Honeywell, Mitsubishi, Motorola, Philips and Samsung
    • A rapidly growing list (Now over 175) of industry leaders from 29 countries spanning 6 continents committed to providing ZigBee-compliant products and solutions
      • Companies include chip suppliers, wireless IP providers, OEMs, test equip manufacturers and end users
  • ZigBee Alliance Members:
  • IEEE 802.15.4 Basics:
    • IEEE 802.15.4 defined simple data packet protocol for lightweight wireless networks.
    • IEEE 802.15.4 defines specific RF frequencies, modulation formats, data rates and coding techniques.
    • Here Primary channel access is via Carrier Sense Multiple Access with Collision Avoidance (CSMA-CA).
      • This CSMA-CA reduces the probability of interfering with other users. It also supports automatic retransmission of data ensures robustness .
    • Support for message acknowledgment and an optional beacon structure.
    • Multi-level security.
    • Works well for long battery life.
    • Selectable latency for controllers, sensors, remote monitoring and portable electronics.
    • Excellent performance in low SNR (Signal-to-Noise Ratio) environments.
  • ZigBee Operating Frequency Bands
  • ZigBee Radio Characteristics
    • IEEE 802.15.4 relies upon a very robust modulation technique known as Phase-Shift Keying (PSK) ,
    • The 2400 MHz band uses Offset Quadrature-PSK (O-QPSK) .
    • Lower frequency bands uses Binary PSK ( BPSK ) .
    • Both modulation modes offer extremely good low bit error rate (BER) performance at low Signal-to-Noise Ratios (SNR).
    ZigBee technology relies upon IEEE 802.15.4, which has excellent performance in low SNR environments
  • What ZigBee do?
    • ZigBee does provide network-level services as TCP/IP does.
    • The impressive set of services provided by ZigBee are:
      • Network formation and configuration,
      • Device discovery,
      • Service discovery,
      • Network address assignment,
      • Joining and leaving the network,
      • Application data binding,
      • Security,
      • Network management,
      • Legacy protocol encapsulation.
    • What ZigBee does not provides:
      • Data transport services,
      • Standardized application execution environment,
      • Standardized device configuration,
      • Over-the-air device download and update,
      • Hardware independence for application developers.
  • The ZigBee Platform IEEE 802.15.4 Public Application Profile ZigBee Stack Certified Product Compliant Platform
  • Why ZigBee?
    • Supports large number of nodes
    • Ultra low power consumption ( i.e., long battery life)
    • Secure
    • Reliable and self healing
    • Low cost
    • Easy to deploy
    • Interoperability and world wide usability.
    • Very small protocol stack.
    • Standard based wireless technology.
  • Advantages of ZigBee over proprietary solutions?
    • Product interoperability
    • Vendor independence
    • Increased product innovation as a result of industry standardization
    • A common platform is more cost effective than creating a new proprietary solution from scratch every time
    • Companies can focus their energies on finding and serving customers
  • ZigBee Applications
  • 802.15.4 Application Space
    • Sensors & Controls:
    • Home Automation
    • Industrial Automation
    • Remote Metering
    • Automotive Networks
    • Interactive Toys
    • Active RFID/ asset tracking
    • Medical
  • World is Moving Towards Wireless (Home Automation)
  • ZigBee Applications ZigBee Wireless Control that Simply Works RESIDENTIAL/ LIGHT COMMERCIAL CONTROL CONSUMER ELECTRONICS TV VCR DVD/CD remote security HVAC lighting control access control lawn & garden irrigation PC & PERIPHERALS INDUSTRIAL CONTROL asset mgt process control environmental energy mgt PERSONAL HEALTH CARE BUILDING AUTOMATION security HVAC AMR lighting control access control mouse keyboard joystick patient monitoring fitness monitoring
  • Typical ZigBee Enabled Device:
  • ZigBee Application Model
    • Application Profiles are an agreement on a series of messages defining an application space (for example, “Home Automation”)
    • Endpoints are a logical extension added to a single ZigBee radio which permits support for multiple applications, addressed by the Endpoint number (1-240)
    • Key Relationships:
    • ► Maximum of 240 Endpoints per ZigBee Device (0 is reserved to describe the generic device capabilities and 255 is reserved for broadcasting to all endpoints, 241-254 are reserved for future use)
    • ► One Application Profile described per Endpoint.
  • ZigBee Lighting Control System Demo
  • ZigBee Mesh Networking
  • ZigBee Mesh Networking
  • ZigBee Mesh Networking
  • ZigBee Mesh Networking
  • ZigBee Mesh Networking
    • Microprocessor based devices with embedded radios
    • Lighting Ballasts become control and communication nodes
    • Utilizes an open protocol for communication – ZigBee
    • Mesh Network - Scalable, flexible up to 65,000 network nodes
    • 100% digital component based network of devices with the lighting infrastructure providing the DLN backbone
    • Software and UI’s determine the user experience
    • Distributed control of lighting – From personal space to enterprise control
    Characteristics of a ZigBee Lighting Control System
  • ZigBee Features Set
  • ZigBee Features are:
    • Ad-hoc and self forming networks
      • Mesh, Cluster Tree and Star Topologies.
      • Reliable broadcast messages.
      • Non-guaranteed message delivery.
    • Logical Device Types
      • Coordinator
      • Router
      • End Devices
  • ZigBee Features are:
    • Applications
      • Device and Service Discovery
      • Optional Acknowledgement service.
      • Messaging with optional response.
      • Mechanism to support mix of public and private profiles in the same network, all supported by standard ZigBee network and application features.
    • Security
      • Symmetric key with AES-128
      • Authentication and Encryption at MAC, NWK, and Application levels.
      • Key Hierarchies: Master keys, Network keys and Link keys.
  • ZigBee Architecture
  • ZigBee Application Layer
    • ZigBee applications are modeled by “ application objects ”.
    • Application objects communicate with each other through the mapping of object attributes sets of object attributes that are called clusters .
    • At the highest-level applications are defined by an application profile .
    • Data communication between objects is implemented in compressed XML to ensure hardware independence.
    • ZigBee also requires a set of basic device methods that every application object must implement.
    • Each ZigBee device can support multiple applications that are identified by a numbered “ end point ” designation.
      • There can be 240 endpoints per ZigBee device, but each end point can support only one profile.
  • ZigBee Network Layer
    • This is a critical component in the ZigBee Stack.
    • The functionality of network layer depends on its role as a Co-ordinator, Router or End Device.
    • The network layer performs device management functions for each device on the network.
    • This layer also performs route discovery and maintenance along with basic frame handling for transfer of network packets. Also supports Message Routing .
    • If a device wants to join in a network it will require a logical network address . This address is provided by a network coordinator or ZigBee router.
    • This layer also supports Security.
  • ZigBee Network Layer
    • ZigBee End devices don’t participate routing. End devices communicate with a single router, which is their parent device.
    • When the coordinator permits new devices to join the network these devices join through a process called “ association ”.
    • Devices that lose contact with their parent device can rejoin a network through a process known as “ orphaning ”.
    • Some ZigBee network can operate with a beacon frame. This is a feature of IEEE 802.15.4 that allows a network to synchronize.
  • How Devices Join in Network?
    • Devices that wish to join the network will do so by first issuing beacon requests to solicit beacons from devices that could potentially allow them to join the network. Initially, only the PAN coordinator will respond. In addition to the PAN coordinator, any device capable of allowing other devices to join the network is a ZigBee router.
      • What ensues is a series of message exchanges that will determine whether a device may join the network.
      • In 802.5.4, this process is called “ association ”. At the time of association the newly joining device will get 16-bit address.
      • A key factor in such a determination is a router’s capacity to accept additional devices as its child.
      • In 802.15.4 Hierarchy of association is possible whereas in Wi-Fi it’s not possible. (Also called Multiple level of association ).
        • In this case a device (eg: router) joining in to the network can have children's so network need to permit all the children’s to be join or reject.
  • Hierarchy of Association:
  • ZigBee MAC Layer
    • This layer responsible for addressing for outgoing data. This layer also referred Data Link Layer or MAC Layer .
    • The ZigBee MAC sub layer provides two services:
      • MAC Data Service
      • MAC Management Service
    • The features of MAC Sub layer are:
      • Beacon Management
      • CSMA-CA Channel Access
      • GTS Management
      • Frame Validation
      • ACK frame delivery
      • PAN Association and disassociation.
  • ZigBee Physical Layer
    • The ZigBee Physical layer supports two services:
      • PHY Data Services:
      • PHY Management Entity
    • The features of PHY are:
      • Activation and deactivation of radio transceiver.
      • Energy Detection
      • Link Quality Indication
      • Channel Selection
      • Clear Channel Assessment
      • Transmitting and receiving packets across physical medium.
  • ZigBee Network Topologies PAN coordinator Full Function Device Reduced Function Device Star Mesh Cluster Tree
    • 65,536 network (client) nodes
    • Optimized for timing-critical applications and power management
      • Time to Join Network: <30ms
      • Sleeping to active: <15ms
      • Channel access time: <15ms
    • Full Mesh Networking Support
    Basic Network Characteristics Network coordinator Full Function node Reduced Function node Communications flow Virtual links
  • ZigBee Device Types
    • ZigBee Coordinator (ZC)
      • One and only one required for each ZB network.
      • Initiates network formation.
      • Acts as 802.15.4 2003 PAN coordinator (FFD).
      • May act as router once network is formed.
    • ZigBee Router (ZR or FFD)
      • Optional network component.
      • May associate with ZC or with previously associated ZR.
      • Acts as 802.15.4 2003 coordinator (FFD).
      • Participates in multihop routing of messages.
    • ZigBee End Device (ZED or RFD)
      • Optional network component.
      • Shall not allow association.
      • Shall not participate in routing.
  • ZigBee Device Types
  • ZigBee Device Functionalities
    • Designed for battery powered or high energy savings
    • Searches for available networks
    • Transfers data from its application as necessary
    • Determines whether data is pending
    • Requests data from the network coordinator
    • Can sleep for extended periods
    • Sets up a network
    • Transmits network beacons
    • Manages network nodes
    • Stores network node information
    • Routes messages between paired nodes
    • Typically operates in the receive state
    The ZigBee Network Node The ZigBee Network Coordinator
  • ZigBee Network Topologies
    • Star networks support a single ZigBee coordinator with one or more
    • ZigBee End Devices (up to 65,536 in theory)
    • Cluster tree networks provide for a beaconing multi-hop network
    • ► Permits battery management of coordinator and routers
    • ► Must tolerate high latency due to beacon collision avoidance
    • ► Must use “netmask” type tree routing
    • Mesh network routing permits path formation from any source device to any destination device
    • ► Radio Receivers on coordinator and routers must be on at all times
    • ► Employs ZigBee joint routing solution including tree and table driven routing
    • ► Table routing employs a simplified version of Ad Hoc On Demand Distance Vector Routing (AODV). This is an Internet Engineering Task Force (IETF) Mobile Ad Hoc Networking (MANET) submission.
  • Star Network:
    • Simplest type of network. Consists only coordinator and end devices.
    • The disadvantage of this network is the network can extend to only two hops (end device, coordinator, end device).
      • This limits the coverage of a single network.
    • It also requires a reliable link between all end devices and the ZigBee coordinator.
    • Here all the messages traveled via coordinator.
    • No alternate route if the link between target devices and coordinator broken.
    • Also coordinator have bottleneck and causes congestion.
  • Tree Network:
    • Unlike star network it can allow multi-hop communication and thus can extended the network coverage.
    • The Coordinator and Routers can have children, and End devices can’t have children.
    • Nodes with the same parent are called siblings. Similarly nodes with the same grandparent are called cousins.
    • Some of the communication rules:
      • A child can only direct communicate with its parent (and with no other node). A parent can only direct communicate with its children and with its own parent.
      • The disadvantage of this topology is that there is no alternate route if a necessary link fails.
  • ZigBee Tree Network Example:
  • Mesh Network:
    • This network allows multi-hop communication and also support multiple paths between network nodes for increased reliability.
    • Routers on mesh networks are able to discover and characterize the alternative routes available to them and choose the best path.
    • Mesh networks can extend widely.
    • The drawback of this networks are that the router nodes must be powered on at all times and also router nodes must also be capable of storing route information and discovering routes.
    • Latencies of mesh networks are difficult to estimate.
    • The network structure is same as tree topology. However the communication rules are more flexible as described below:
      • Router nodes within range of each other can communicate directly.
      • Route discovery feature is provided.
  • Mesh Network:
    • Mesh Network overcomes barriers in wireless networks (i.e., Overcomes line of sight fear):
      • Barrier 1: Reliability
        • Peoples can move when wireless reception is poor, machines typically can’t.
      • Barrier 2: Wireless Expertise
        • Customers and some installers don’t want to be wireless experts.
        • Wants “wireless control that simply works”.
  • ZigBee Mesh Network Example:
  • ZigBee – Highly Reliable
    • Mesh and tree networking protocol provides redundant paths
    • Automatic retries and acknowledgements
    • Broadcast delivery scheme ensures reliable broadcasts across the network
    • Parents keep track of messages for sleeping children
    • High intrinsic interference tolerance
      • Multiple channels
      • Frequency agility
      • Robust modulation
  • ZigBee Routing:
    • ZigBee routing algorithm is Ad hoc On Demand Distance Vector (AODV) and Cluster Tree algorithm .
    • Ad hoc On Demand Distance Vector:
      • This is a pure on-demand route acquisition algorithm: nodes that don’t lie in active path neither maintaining any routing information nor participate any periodic routing table exchange.
      • Also a node doesn’t have to discover another node until the two needs to communicate, unless further node is offering a services as an intermediate forwarding station to maintain connectivity between two other nodes.
    • Whenever a source needs to communicate with another node for which no routing information in its table, then the Path Discovery process is initiated.
    • Every node maintains two separate counters: Sequence number and Broadcast id.
  • AODV Routing:
  • Cluster Tree Algorithm:
    • Protocol of logical link and network layers
    • Forms single/multi cluster tree networks
    • Forms self-organizing network with redundancy and self-repair capabilities
    • Nodes select cluster heads and form clusters in a self-organized manner.
    • Self-developed clusters then connect to each other through a designated Device (DD)
  • Cluster Tree Algorithm: Multi cluster network with DD border nodes
  • ZigBee Profiles
    • What is a Profile ?
      • An agreement of series of messages defined in application space.
    • Why we need profile?
      • Need a command language for exchanging data.
      • Need a well defined set of processing actions
      • Device interoperability across different manufacturers
      • Allows solid conformance test programmes to be created
      • Simplicity and reliability for the end users
      • Realistic application specifications developed through OEM experience
    • Different types of profiles?
      • Standard ( Defined by ZigBee alliance )
      • Private profile ( Vendor defined ) .
  • ZigBee Protocol Stack
  • ZigBee Stack Architecture
  • ZigBee Stack Architecture
    • Using layered communication architecture, ZigBee makes use of IEEE 802.15.4 MAC and Physical layers and ZigBee itself defines Network along with application layers and security components.
      • The PHY, MAC and NWK layers are used to create and maintain the communication network interconnecting between individual ZigBee devices.
      • The Application support (APS) sub layer is used to communicate application layer information between devices.
    • ZigBee Stack System Requirements:
      • 8-bit Micro controller (Eg: 80 C51).
      • Full protocol stack < 32K
      • Simple node only stack ~ 6K.
      • Coordinator requires extra RAM for Node device database, Transaction table and Pairing table.
  • Responsibilities of ZigBee Network Layer:
    • Starting a network: Ability to successfully establish a new network.
    • Joining and leaving a network : The ability to gain membership (join) or relinquish membership (leave) a network.
    • Configuring a new device: The ability to sufficiently configure the stack for operation as required.
    • Addressing: The ability of a ZigBee coordinator to assign addresses to devices joining the network.
    • Synchronization within a network: The ability for a device to achieve synchronization with another device either through tracking beacons or by polling.
    • Security: applying security to outgoing frames and removing security to terminating frames
    • Routing: routing frames to their intended destinations.
  • Responsibilities of ZigBee Application Layer:
    • The ZigBee application layer consists of
      • APS Sub Layer
      • ZDO
      • Manufacture defined application objects.
    • Responsibilities of APS sub layer:
      • Maintaining tables for binding.
      • Forwarding messages between bound devices.
      • Discovery.
    • Responsibilities of the ZDO include:
      • Defining the role of the device within the network (e.g., ZigBee coordinator, router or end device),
      • Initiating and/or responding to binding requests.
      • Establishing a secure relationship between network devices by selecting one of the security method by selecting public key or symmetric key.
    • The manufacturer-defined application objects implement the actual applications.
  • ZigBee Stack Architecture
    • An application profile describes the collection of devices employed for a specific application and implicitly the messaging scheme between the devices.
      • Eg: Home Automation application profile, Industrial Automation application profile, etc.,.
      • A profile ID is allocated for each application to uniquely identify that application.
    • Devices within a application profile communicate with each other by means of clusters , which may be input to or output from the device.
      • Eg: In home automation system there is a cluster (group of predefined functions) dedicated to the control of lighting subsystem.
      • A cluster ID uniquely identify the clusters within the scope of a particular profile.
  • ZigBee Stack Architecture
    • An end point defines a communication entry within a device through which a specific application is carried.
      • In a device you can use maximum of 240 endpoints.
      • End point 0 dedicated to ZigBee Device Object (ZDO).
      • Eg: End point 5 for control of light in bed room, endpoint 8 to manage the heating and air conditioning system and 12 for controlling security system etc.,
    • It is also possible to define the private application profiles also and implicitly need to define device and cluster definitions.
  • ZigBee Device Binding
    • Bindings are connections between two end points, with each binding supporting a specific application profile , and each message type is represented by a cluster (within that profile).
    • When combined with the network source and destination address (which identifies a particular radio), an APS frame containing the source and/or the destination endpoint, cluster ID and profile ID uniquely identifies a specific message type within a specific profile between two application endpoints associated with two specific devices.
    • The above binding information will be stored within the source device. This type of binding is called as direct binding or source binding .
  • ZigBee Device Binding
  • Direct & Indirect Binding
    • The above left fig shows direct binding . Here source contain all the necessary information to construct a packet and send it to peer device.
    • The other type of binding is called indirect binding . In this type of binding all the binding information will be stored in a intermediate device that provides a lookup table mapping the source endpoint and address to the corresponding destination endpoint and address.
  • ZigBee Lighting Applications Addressing & Binding Example:
  • ZigBee Device Binding
    • Bindings establishes the relationship between the nodes of a ZigBee network.
      • Eg: Which switch controls which light, etc.,
    • Types of bindings that can be achieved are:
      • one-to-one,
      • one-to-many
      • many-to-one.
    • Some of the characteristics of bindings are:
      • Binding is independent of network topology.
      • Some times Bindings are factory configured and stored in application image.
      • Some times Bindings are automatically created during network installation.
      • In some cases bindings are created manually by the system integrator or installation technician.
  • ZigBee Device Object (ZDO)
    • The ZigBee Device Object (ZDO) is a special application common to all ZigBee devices. This application (ZDO) resides in the application layer of node at endpoint 0 .
    • ZDO has the following Roles:
      • Defines the type of networked device (Coordinator, router or end device). Also Initialize the nodes to allow application to run.
      • Performs Device and Service Discovery process.
      • Implements the processes needed to allow a Coordinator to create a network, and Routers and End devices to join and leave a network.
      • Initiate and respond to binding requests.
      • Provides security services which allow security relationships to be established between applications.
      • Allow remote nodes to retrieve information from the node, such as routing and binding tables, etc.,,
  • ZigBee Device Object (ZDO)
    • The ZDO provides management commands common to all ZigBee applications and devices and it is implemented on end point 0 of each device.
    • The definitions of clusters used by ZDO are described by the ZigBee Device Profile (ZDP) . At present the following functions are supported by this profile.
      • Device and Service Discovery
      • Binding Management.
      • Network Management.
    • In short ZDO is resides in the application layer and responsible for defining the role of the device within the network (e.g., Coordinator or End device), initiating and/or responding to binding and discovery requests and establishing a secure relationship between network devices.
  • ZigBee Traffic & Frames
  • ZigBee/IEEE802.15.4 - Typical Traffic Types Addressed
    • ZigBee/IEEE 802.15.4 addresses three typical traffic types. IEEE 802.15.4 MAC can accommodate all types.
      • Periodic data : The application dictates the rate, and the sensor activates, checks for data and deactivates.
      • Intermittent data : Application/external stimulus defined rate (e.g., light switch). The device needs to connect to the network only when communication is necessitated. This type enables optimum saving on energy.
      • Repetitive low latency data: Here the rate is fixed a priori. Depending on allotted time slots, called GTS devices operate for fixed durations.
        • Time slot allocated for a device Eg: mouse.
  • PHY Packet Overview:
    • PHY Packet Field:
      • Preamble (32 bits) – synchronization 4-bit Symbols.
      • Start of Frame Delimiter (8 bit) – Sync Byte. Used to indicate starting point of packet.
      • PHY Header (8 bits) – PSDU length. Max of 127 bytes.
      • PSDU (0 to 1016 bits) – Data field (Max of 127 bytes PSDU).
    • PHY Responsible for:
      • Activation and deactivation of the radio transceiver
      • ED within the current channel
      • LQ Indication for received packets
      • CCA for CSMA-CA
      • Channel frequency selection
      • Data transmission and reception
  • Different Frames in IEEE 802.15.4
    • The IEEE 802.15.4 MAC defines four frame structures:
      • Beacon Frame: Used by a coordinator to transmit beacons.
      • Data frame: Used for all transfers of data.
      • Acknowledgment Frame: Used for confirming successful frame reception.
      • MAC Command Frame: Used for handling all MAC peer entity control transfers.
  • ZigBee all Four Frame Formats:
  • MAC Frame:
    • Each MAC frame consists following components:
      • MHR : Consists Frame control, Sequence number and address.
      • MAC Play Load: It is variable length contains information specific to frame type. Acknowledgement frames doesn’t contain this play load.
      • MFR: Which contains FCS.
  • Frame Commonality:
    • All the frames have the following common components:
      • Preamble Sequence: All of the frames begin with a 32-bit preamble that helps the receiving station to pick the transmission out of noisy environments.
      • Start Frame Delimiter : It consists a 8-bit.
      • Frame Length Field: Tells the receiving station exactly how long the frame is. 8-bit length. (i.e., PHY Header )
      • Sequence Number : An 8-bit value that is incremented each time a device transmits a new, unique frame.
      • Frame Check Sequence (FCS) : Each frame ends with a 16-bit mathematical sequence that allows the receiving station to validate that the packet was received without error.
  • Beacon Frame:
  • Data Frame:
  • Acknowledgement Frame:
  • MAC Command Frame:
  • IEEE 802.15.4 & ZigBee Frame Formats
  • General APDU Frame Format:
  • Super Frame:
    • The superframe is bounded by network beacons is sent by the coordinator and is divided into 16 equally sized slots.
      • The format of the superframe is defined by the coordinator.
      • The beacon frame is transmitted in the first slot of each superframe.
      • If a coordinator does not wish to use a superframe structure it may turn off the beacon transmissions.
    • The beacons are used to synchronize the attached devices, to identify the PAN, and to describe the structure of superframes .
    Super Frame without GTS
  • Super Frame:
    • For a low latency applications or applications requires specific data band width, the PAN coordinator may dedicate portions of the active superframe to that application. These portions are called Guaranteed Time Slots (GTS’s) .
      • The guaranteed time slots comprise the contention free period (CFP), which always appears at the end of the active superframe starting at a slot boundary immediately following the CAP,
      • The PAN coordinator may allocate up to seven of these GTSs and a GTS may occupy more than one slot period.
    Super Frame with GTS
  • Super Frame & Beacon
    • A Zigbee router can announce a beacon to start a superframe
    • Each superframe consists of an active portion followed by an inactive portion .
    • Each active portion consists of 16 equal-length slots and can further partitioned into a Contention Access Period (CAP) and a Contention Free Period (CFP).
      • CAP : Slotted CSMA/CA is used in CAP
      • CFP : FFDs which require fixed transmission rates can ask for guarantee time slots (GTSs). ( As many as 7 slots for GTS transmission ).
    • On receiving parent router’s beacon, and end device has to wake up for an active portion to sense the environment and communication with its coordinator.
    • To avoid collision with its neighbor, a router should shift its active portion by a certain amount.
  • Data Transfer Modes in ZigBee
    • ZigBee employs either of two modes to enable the to-and-fro data traffic.
      • Beacon Mode : Max Power saving. When coordinator runs on batteries this mode is used.
      • Non-beacon Mode : Here coordinator is main powered.
    • In the beacon mode , a device watches out for the coordinator's beacon that gets transmitted at periodically, locks on and looks for messages addressed to it. If message transmission is complete, the coordinator dictates a schedule for the next beacon so that the device ‘goes to sleep';
      • In fact, the coordinator itself switches to sleep mode.
    • While using the beacon mode , all the devices in a mesh network know when to communicate with each other. In this mode, necessarily, the timing circuits have to be quite accurate, or wake up sooner to be sure not to miss the beacon.
  • Data Transfer Modes in ZigBee
    • The non-beacon mode will be included in a system where devices are ‘asleep' nearly always.
      • Eg: In smoke detectors and burglar alarms.
      • The devices wake up and confirm their continued presence in the network at random intervals.
      • On detection of activity, the sensors ‘jumps to attention', as it were, and transmit to the ever-waiting coordinator's receiver (since it is mains-powered).
    • In tree networks coordinator and router can announce beacons. However in mesh networks regular beacons are not allowed.
    • Beacons are important mechanism to support power management.
    • So Tree topology is preferred for energy saving is a desirable feature.
  • Data Transfer Types in ZigBee
    • Three types of data transfer transactions exists:
      • Coordinator to Device
      • Device to Coordinator
      • Between two peer devices
    • In non-beacon enabled network when device wants to transfer a data it simply transmits its data frame using the un-slotted CSMA-CA, to the coordinator.
      • Optionally acknowledgement at the end.
    • In a peer-to-peer network, every device can communicate with any other device in its transmission radius. There are two options:
      • In the first case, the node will listen constantly and transmit its data using un slotted CSMA-CA.
      • In the second case, the nodes synchronize with each other so that they can save power.
  • MAC Data Service Diagrams Non-Beacon Network Communication Beacon Network Communication:
  • Data Transfer Coordinator to Device (NonBeacon-Enabled)
    • Coordinator stores pending data and waits for request
    • Device requests data using unslotted CSMA-CA at application-defined rate
    • Coordinator acknowledges request
    • Data sent from coordinator to device
    • Finally Device acknowledges.
  • Data Exchange Scenario in Non-Beacon Enabled Networks:
    • Steps to exchange data with ACK between stations A and B :
      • Station A checks the RF channel to ensure that another station is not transmitting.
      • Station A transmits a data frame addressed to Station B.
      • Station B receives the frame, and uses the FCS to make sure that the packet was received without error.
      • After the aTurnaroundTime end of A’s transmission, B responds with the Acknowledgement packet which is addressed to A, and contains the Frame Number specified in A’s original frame.
        • It allows A to know that B received the data without error.
      • If this ACK is not received within “ macAckWaitDuration” , then the process begins a new with A transmitting the Data Frame.
    • Ev en with multiple retransmissions, the entire process takes well under 10 m.sec , (So R obust, Timely, Efficient data exchange).
  • Beacon communication from coordinator to device:
    • When a coordinator wishes to transfer data to a device in a beacon-enabled network, it indicates in the network beacon that the data message is pending. The device periodically listens to the network beacon , and if a message is pending, device transmits a MAC command requesting this data, using slotted CSMA-CA. The pending data frame is then sent using slotted CSMA-CA by coordinator.
    Here Both the ACK’s are optional.
  • Steps required for transmitting data from Coordinator to Device (Beacon enabled) network
    • The coordinator has data and it need to be transmitted to the device.
    • The Coordinator indicates in beacon message that data is pending.
    • Devices tracking the beacons, decode the pending address fields.
    • If a device finds its address listed among the pending address fields, it realizes it has data to be received from the coordinator
    • Device issues a Data-Request Command to the coordinator using slotted CSMA-CA.
    • The coordinator replies with an acknowledgement.
    • If there is data to be sent to the device, Coordinator will transmits the data.
    • If acknowledgements are not optional, the device would respond with an acknowledgement.
  • Data Transmission from a device to a Coordinator in Beacon enabled network
    • The device first listens to the beacon.
    • On finding the beacon, it synchronizes first to the superframe structure. This process lets it know the start and end time of the Contention access period.
    • The device will now compete with its peers for a share of the channel.
    • On its turn, it will transmit the data to the coordinator.
    • The coordinator may reply back with an acknowledgement, if it is not optional.
  • ZigBee Security
  • ZigBee – Highly Secure
    • Utilizes AES 128-bit encryption
    • Concept of a “trust center”
    • Link and network keys
    • Authentication and encryption
    • Security can be customized for the application
    • Keys can be “hard-wired” into application
    • Security defined at MAC, NWK and APS layers.
  • ZigBee Security Architecture
  • ZigBee Security
    • ZigBee networks are highly secure. The security toolbox offering into the ZigBee network are:
      • Access Control Lists: Only free defined friendly nodes can join in the network.
      • 128-bit AES-based encryption: A very high-security key-based encryption system preventing external agents from interpreting the ZigBee network data .
      • Message Freshness Timers: Timed-out messages are rejected, and Freshness check prevents the message replay attacks on the network.
  • ZigBee Security
    • ZigBee Security specifications are built upon capabilities of the IEEE 802.15.4 specification.
    • ZigBee provides 4 fundamental security mechanisms: freshness, message integrity, authentication, and encryption .
    • Freshness: ZigBee devices maintained freshness counters for incoming and outgoing messages. These counters are designed to prevent “replay attacks”, where an attacker replays messages it recorded previously.
      • Counter is reset when new key is created.
      • Devices that communicate once per second will not overflow their freshness counters for 136 years.
  • ZigBee Security
    • Message Integrity: It ensures that the message has not been modified during transit.
      • Integrity options of 0, 32, 64 and 128 bit integrity. 64 is default.
      • Integrity options allows tradeoff between message protection and communication overhead required to support the protection.
    • Authentication: It provides the assurance as to the identify of the originator of any message. In ZigBee authentication can be performed at the network level or the device level .
      • Network authentication is performed using a common network key . This prevents outsider attacks while adding very little memory cost.
      • Device authentication uses unique link keys between pairs of devices. This prevents inside and outsider attacks but has higher memory cost.
  • ZigBee Security
    • Encryption: It prevents eavesdroppers from being able to understand the contents of messages.
      • ZigBee uses 128-bit AES encryption.
    • Similar to authentication ZigBee encryption is implemented at either network level or the device level using variable key lengths.
      • Network level encryption is achieved by using a common network key. This prevents outsider attacks while adding very little memory cost.
      • Device level encryption is achieved by using unique key links between pairs of devices. This prevents inside and outsider attacks but has higher memory cost.
    • Encryption can be turned off without impacting Freshness , Integrity or Authentication .
  • Trust Centre concept in ZigBee
    • Trust centre allows the devices into the network and distributes keys.
      • ZigBee Coordinator assumed to be the trust centre.
      • It is possible for the trust centre to be a dedicated device.
    • Trust centre has the following roles:
      • Trust Manager: It authenticate the device that join to the network.
      • Network Manager: Maintains and distributes network keys.
      • Configuration Manager: Enables end-to-end security between devices.
    • Trust centre has the following modes:
      • Residential Mode: Doesn’t establish keys with network devices.
      • Commercial Mode: Establishes and maintains keys with every device in the network.
  • Fundamental Key types in ZigBee
    • Master Key : Basis for long-term security between two devices. Eavesdropping should be prevented when this is setup.
      • This key can be setup over the air or using the out-of-band mechanisms. ( Also have factory installed option ).
      • Master keys are installed first. These are sent from Trust center.
    • Link Key: Basis of security between two devices.
    • Network Key: Basis of security across the network ( i.e., protects against outsiders ).
    • Link and Network keys can be updated periodically.
      • These keys either can be installed in factory or out-of band.
      • These keys are transport from trust center.
    • If two devices have a link key it is always used instead of network key .
    • Storage cast can be reduced by using network keys . However this reduces the security since the network key is used in many devices and can’t be prevented insider attacks.
  • Example: New device joining into the network:
    • Keys need to be setup with and between new devices that join the network.
  • Example: New device joining into the network:
    • If keys are setup over the air only the last link is vulnerable to a one time eavesdropper attack.
  • Example: New device joining into the network:
    • After device joins into the network it needs to store multiple keys.
  • Example: Key distribution in ZigBee networks:
    • In below key distribution keys with trust center allows periodic update of network keys.
  • ZigBee Frame with Security
    • ZigBee security could add headers to the data frames at the MAC, NWK, and APS Layers.
  • Security at MAC Layer
    • When security of MAC layer frames is desired, ZigBee uses MAC layer security to secure MAC command, beacon, and ACK frames.
      • The MAC Layers uses AES as its core cryptographic algorithm and describes variety of security suites that use the AES.
      • The MAC layer does the security processing, but the upper layers, set up the keys and determine the security levels to use, control this processing.
    • ZigBee may secure messages transmitted over a single hop using secured MAC data frames, but for multi-hop messaging ZigBee relies upon upper layers (Eg: NWK layer) for security.
    • When the MAC layer transmits (receives) a frame with security enabled, it retrieves the key associated with that destination (source), and then uses this key to process the frame.
      • Specify security enabled or disable, MAC frame header has a bit.
  • Security at MAC Layer
    • The MAC layer security suites are based on three modes of operation.
      • Encryption at the MAC layer is done using AES in Counter ( CTR ) mode.
      • Integrity is done using AES in Cipher Block Chaining ( CBC- MAC ) mode.
      • A combination of encryption and integrity is done using a mixture of CTR and CBC- MAC modes called the CCM mode.
  • Security at NWK Layer
    • The NWK layer also makes use of the AES. Unlike the MAC layer, the security suites are all based on the CCM* mode of operation.
      • The CCM* mode of operation is a minor modification of the CCM used by the MAC layer.
      • It includes all of the capabilities of CCM and additionally offers encryption-only and integrity-only capabilities so simplifies NWK security, by eliminating the need for CTR and CBC-MAC modes.
  • Security policies are not defined in ZigBee
    • Out of band methods for key setup.
    • Cost/security tradeoff for number of link keys needed.
    • Handling security error conditions.
    • Handling loss of counter synchronization.
    • Handling loss of key synchronization.
    • Policy of expiration and update of keys.
    • Policy for accepting new devices.
  • ZigBee Descriptors & Commands
  • Descriptors used in ZigBee User-definable information O User Further information about the device descriptions (one per active endpoint) O Complex Device descriptions contained in the node (one per active endpoint) M Simple Node power characteristics M Node power Type and capabilities of the node (one per device) M Node Description Mandatory/ Optional Name
  • ZigBee Node Descriptor Allocated by the ZigBee Alliance 16 Manufacturer code Alternative PAN coordinator, MAC logical device type, power source, receiver on when idle, security capability 8 MAC capability flags 868MHz, 915MHz, 2.4GHz 5 Frequency band ZigBee coordinator, router, end-device 3 Logical type Description Length (bits) Field name
  • ZigBee Simple Descriptor Number of output clusters 8 Application output cluster count List of supported output clusters 8*o Application output cluster list Description Length (bits) Field name The endpoint to which this descriptor refers 8 Endpoint The profile implemented on this endpoint 16 Application profile ID The device description implemented on this endpoint 16 Application device ID Version 1.0 4 Application device version Complex, user descriptor available 4 Application flags List of supported input clusters 8* i Application input cluster list Number of input clusters 8 Application input cluster count
  • Device & Service Discovery Commands
  • Binding Commands
  • Network Mgmt Commands
  • CSMA/CA Algorithm
  • Some of Important Parameters: 12 symbol periods aMinSIFSPeriod 40 symbol periods aMinLIFSPeriod 440 symbol periods aMinCAPLength 18 octets aMaxSIFSFrameSize 3 aMaxFrameRetries 5 aMaxBE 60 symbol periods aBaseSlotDuration 15--133 octets PHY data frame length 23--100 octets PHY beacon frame length 11 octets PHY acknowledgement frame length 8 symbol periods CCA duration Value Attribute
  • Some of Important Parameters: 0-15 (default 15) macSuperframeOrder 0-3 (default 3) macMinBE 0-5 (default 4) macMaxCSMABackoffs 0-15 (default 15) macBeaconOrder 120 or 54 symbol periods (channels 0 to 10 and 11 to 26, respectively) macAckWaitDuration 20 symbol periods aUnitBackoffPeriod 12 symbol periods aTurnaroundTime
  • Super Frame :
  • Terminology:
    • Beacon Interval (BI): Time duration between two successive beacons.
    • Super Frame Duration (SD): Active period between two beacons.
    • BI and SD values are determined by two parameters namely Beacon Order (BO) and Super Frame Order (SO) .
    • BI = aBaseSuperFrameDuration * 2 BO for 0 ≤ BO ≤ 14
    • SD = aBaseSuperFrameDuration * 2 SO for 0 ≤SO ≤ BO ≤ 14
    • aBaseSuperFrameDuration denotes the minimum duration of the super frame corresponding SO = O.
      • This duration is fixed to 960 symbols.
    • Slotted CSMA/CA algorithm is based on a basic time unit called Backoff Period (BP), also called as aUnitBackoffPeriod.
    • aUnitBackoffPeriod = 20 Symbols.
  • Slotted CSMA/CA Algorithm:
  • Slotted CSMA/CA Algorithm:
    • First, the number of backoffs (NB) and the contention window (CW) are initialized ( NB = 0 and CW = 2).
    • The backoff exponent is also initialized to BE = 2 or BE = min(2, macMinBE ) depending on the value of the Battery Life Extension MAC attribute.
    • Then, the algorithm starts counting down a random number of BPs uniformly generated within [0, 2 BE -1 ] .
      • The count down must start at the boundary of a BP.
    • When the timer expires, the algorithm then performs one CCA operation at the BP boundary to assess channel activity.
    • If the channel is busy , CW is re-initialized to 2, NB and BE are incremented.
      • BE must not exceed aMaxBE . Which has default value of 5.
      • Incrementing BE increases the probability for having greater backoff delays.
  • Slotted CSMA/CA Algorithm:
    • If the NB reached the value macMaxCSMABackoffs ( default value = 5) is reached, the algorithm reports a failure to the higher layer, otherwise, it goes back to (Step 2) and the backoff operation is restarted.
    • If the channel is sensed as idle , CW is decremented. The CCA is repeated if CW ≠ 0 .
      • This ensures performing two CCA operations to prevent potential collisions of acknowledgement frames.
    • If the channel is again sensed as idle, the node attempts to transmit, provided that the remaining BPs in the current CAP are sufficient to transmit the frame and the subsequent acknowledgement.
    • If not, the CCAs and the frame transmission are both deferred to the next superframe. This is referred to as CCA deference .
  • Unslotted CSMA/CA Algorithm:
  • ZigBee vs Other Wireless Protocols
  • ZigBee vs Bluetooth
    • New slave enumeration: ~ 30ms
    • Sleeping slave changing to active: ~ 15ms
    • Active slave channel access time: ~ 15ms
    • New slave enumeration = >3s to typically 20s
    • Sleeping slave changing to active ~ 3s
    • Active slave channel access time ~ 2ms typically
    • 20 - 250 KBPS
    • 10-100 meters
    • ~1000-3000 KBPS
    • 10 meters
    • DSSS
    • FHSS
    • Controls & Sensors
    • Lots of devices
    • Low duty cycle
    • Small data packets
    • Long battery life is critical
    • Synchronization of cell phone to PDA
    • Hands-free audio
    • PDA to printer
    ZigBee Bluetooth
  • Major Wireless Standards using ISM Band:
  • ZigBee and Other Wireless Standards:
  • More Information
    • ZigBee Alliance Web Site
    • http:// www.ZigBee.org
    • IEEE 802.15 Web Site
    • http://www.ieee802.org/15
    • Freescale Web Site
    • http://www.freescale.com/zigbee
  • More Information:
    • IEEE 2003 version of 802.15.4 MAC & Phy standard
      • http://standards.ieee.org/getieee802/download/802.15.4-2003.pdf
    • ZigBee Specification
      • http:// www.zigbee.org/en/spec_download/download_request.asp
    • ZigBee Technology: Wireless Control that Simply Works
      • http://www.hometoys.com/htinews/oct03/articles/kinney/zigbee.htm
    • Home networking with Zigbee
      • http:// www.embedded.com//showArticle.jhtml?articleID =18902431
    • Can the competition lock ZigBee out of the home?
      • http:// www.techworld.com/mobility/features/index.cfm?FeatureID =1809
  • Questions: ?
  • Thank You !
    • ZigBee
    • Wireless Control that simply works !