Suggestions for Designing ZigBee Purposes

Suggestions for Designing ZigBee Purposes

So that you suppose you need to develop a ZigBee utility, however you will have some questions. What’s necessary in a ZigBee improvement? What instruments do I would like? What steps are concerned? How a lot time will it take? What sort of funding is required? What are the unexpected questions?

The information introduced right here cannot reply all of those questions for everyone, however they are going to present a tutorial for the event of your ZigBee utility.

The primary and maybe most necessary step in growing your utility is to find out whether or not ZigBee is suitable to your product. The ZigBee radio customary boasts many benefits over different wi-fi choices. With a public ZigBee profile and conformant platform, interoperability with different vendor gadgets is assured. ZigBee was outlined to help extraordinarily low energy and remarkably lengthy battery life. However the ZigBee knowledge charges are low relative to different wi-fi choices. And whereas considerably smaller than Bluetooth or 802.11/WiFi, the ZigBee stack shouldn’t be a easy piece of software program.

After deciding that you just need to develop a ZigBee utility, you have to select a ZigBee supplier associate. A ZigBee associate will provide the ZigBee stack software program together with a radio chip and baseband microcontroller. Traditionally, these have been two chip options. Not too long ago, although, distributors have been introducing single chip ZigBee gadgets with loads of extra assets to help your utility code. A high quality ZigBee associate will even provide you with continuous updates on the latest options.

A number of ZigBee suppliers can be found, and every has invested many person-years of improvement to reach at their ZigBee resolution. In selecting a associate, it is best to think about technical points (the price vs. functionality of their chipset, supported options) and enterprise points of the supplier (firm historical past, licensing prices, technical help). The ZigBee suppliers will even need to learn about you – info corresponding to your earlier product improvement expertise and the variety of gadgets that you just plan to promote. When this alternate of data is full, it is best to fairly shortly be capable to discover a ZigBee supplier keen to collaborate in your utility.

After you will have chosen a ZigBee supplier, you have to then determine how one can implement the ZigBee radio – as a module linked to the remainder of the system or as a chip built-in into the circuitry of your board.

Utilizing a ZigBee radio module affords many benefits. A module often results in a shorter improvement cycle. The RF design is already accomplished for you – so that you needn’t change into an RF skilled. As well as, a module might carry FCC Modular Approval, which suggests you will not need to take your product by the FCC’s intentional radiator approval course of.

Disadvantages to utilizing a ZigBee radio module versus an built-in ZigBee chip embody a better per-unit product value. A module design additionally requires extra bodily area contained in the housing and imposes extra constraints on the commercial design of the product. What’s extra, a module might have restricted antenna choices, which can be unsuitable to your product.

The ultimate structure job is to utterly outline your ZigBee community construction. The ZigBee customary helps a number of topologies so that you can select from. These embody mesh, star, and cluster tree community configurations, that are proven in Determine 1.

The standard ZigBee community configuration is comprised of low energy lowered operate finish level gadgets, typically referred to as sensors. The sensors talk with full operate community management gadgets that deal with the routing of packets over the community.

ZigBee radios will be carried out in a number of RF bands. These working within the 2.4 – 2.48 GHz band are the most typical since that is the one RF band that’s usable worldwide. In North America, 915 MHz is obtainable for ZigBee radios and affords just a few benefits over 2.4 GHz, corresponding to barely higher vary. Fewer chip suppliers can be found who supply the decrease frequency vary, as a result of antennas are typically bigger and the over-the-air knowledge price is decrease. The 868 MHz model of ZigBee additionally affords priceless options, although it’s obtainable to be used solely in Europe.

Now that each one the structure choices have been made, it’s time to open the event system offered by your ZigBee associate and dig in. An instance is proven in Determine 2. The event system could have pattern utility code to reference. Your remaining utility will probably resemble this pattern as a result of you’ll apply the identical Utility Programming Interface (API) that the pattern makes use of. You may additionally use the identical working system, system calls, and interrupts. Typical API instructions are “FormNetwork()”, “JoinNetwork()”, “SendMessage()”, and “ZigBeeStackTick().” Study to like this API – you’ll reside with it for the subsequent couple of months.

Through the improvement part, you’ll face many design challenges. Many will contain typical embedded improvement points, whereas others will come up since you’ve added a brand new design factor – the ZigBee stack.

ZigBee advertises extremely low energy. That is nice for the radio – however it’s important to broaden that to incorporate your whole system design. To totally optimize energy utilization and battery life, the firmware, electrical, and RF groups should commit a great deal of time to optimizing energy consumption. As a part of this effort, microcontroller sleep modes have to be outlined and carried out. Remember that your improvement system might not work correctly whereas the system is in sleep mode. You might want to make use of the old style “GPIO toggle and scope tracing” debug strategies.

In case your system might be battery-powered, understand that ZigBee radios don’t violate the legal guidelines of physics. ZigBee radios use the present required to transmit on the chosen energy degree – usually within the vary of 20-50 mA. Reaching multi-year battery life is very depending on the utilization state of affairs. Pay specific consideration to how often the radio must get up, how lengthy it takes to get up, and the way a lot present it consumes whereas asleep. You might discover {that a} ZigBee supplier’s knowledge sheets are solely useful to a restricted extent on this space, and you’ll find yourself making your personal measurements on present consumption.

Normally, the principal tradeoff it is advisable to make is knowledge latency versus battery life. It appears counterintuitive; nonetheless, since ZigBee transmissions are at low RF energy – within the vary of a milliwatt – battery energy utilization throughout transmit and obtain modes are comparable. Do not assume {that a} radio mode will use little energy if it spends more often than not in obtain mode.

The ZigBee improvement system you begin with will most likely not match your remaining {hardware}. This implies you’ll be designing new interfaces to your gadgets – buttons, shows, reminiscence, and many others. You may additionally want so as to add a communication channel to a different system, corresponding to a system monitor PC program. That is the place taking the time to completely perceive the API and your improvement system’s place to begin helps, as a result of you will want to merge these new interfaces with the remainder of the present design.

With a purpose to confirm interoperability of your machine, you could must swallow your satisfaction and buy a competitor’s product. Use of one other ZigBee accepted system throughout improvement might show you how to uncover how your product’s efficiency can finest be optimized. An alternative choice to check interoperability is to take part in one of many ZigBee Alliance’s quarterly interoperability occasions referred to as ZigFests. To take part in a ZigFest your organization have to be at the least an Adopter class member of the ZigBee Alliance. There are additionally certification corporations that may present a pre-certification testing setting.

Do not forget that, luckily, the ZigBee radio shouldn’t be a frequency hopper like Bluetooth. Earlier than the community types, the community coordinator scans the obtainable channels to search out the “clearest” one. A operate to carry out this automated frequency choice is often included with the ZigBee stack you buy, however is simple to implement if not. The community coordinator can then be programmed to periodically check the community to find out if the chosen frequency stays the best choice. If not, the community coordinator can transfer the community to a special channel with out operator intervention. This insures the community will carry out optimally always.

If knowledge safety is required to your utility, ZigBee contains provisions for robust knowledge encryption. ZigBee knowledge safety is predicated on the 128-bit AES algorithm. If you’re utilizing a public ZigBee profile then the safety choices have already been made and are pre-defined within the profile.

For a customized utility that requires knowledge safety, you will have choices concerning the place the safety is utilized – within the utility code or within the decrease layers of the ZigBee stack. In case your utility wants the strongest safety attainable, safe it in your utility code. The ZigBee stack defines non-compulsory safety within the decrease layers of the stack, which can be utilized to validate every knowledge packet that’s exchanged in your ZigBee community.

Your improvement will almost certainly embody the event of two ends of a system – the sensors, which can be lowered performance ZigBee finish gadgets, and the gadgets with which they need to talk. Every finish of the system will current its personal design challenges. Energy optimization is usually the biggest design problem for the sensors, whereas message administration is the biggest for the ZigBee routers.

Message administration is a vital a part of the applying code. Your utility code will talk with the ZigBee stack by sending messages to the stack by calling stack capabilities and receiving messages from the stack by callback capabilities. The applying code will probably want to watch these messages and will must carry out duties, corresponding to timing messages and purging “misplaced” messages, on prime of its regular community administration job.

As a part of the applying improvement planning course of, you’ll want to embody time to write down check code. Throughout your integration part, check code will assist establish and confirm boundary situations of the function operations. Specialised check code could also be required to place the machine in perpetual transmit mode throughout {hardware} compliance testing. On the manufacturing unit, correctly designed check code can shortly and completely confirm operation of every machine because it comes down the road.

One software important to designing a ZigBee utility is the ZigBee RF sniffer/protocol analyzer. Even when your design makes use of a ZigBee radio module and a public ZigBee profile, you’ll ultimately want to look at instructions as they’re despatched over the air. Many protocol sniffers are at the moment obtainable with a variety of capabilities and value. Selecting the sniffer will rely in your expertise with protocol analyzers, the depth of protocol analyzing required, future anticipated ZigBee work, and the price of every unit. Probably the most logical path is to begin with a fundamental unit and improve later if you happen to want extra capabilities.


If time-to-market is a significant requirement for the system, use of a ZigBee radio module is sort of a given. A module-based design will present the quickest improvement cycle.

Many initiatives require quick time-to-market with a small variety of gadgets to introduce a know-how or a product line. Usually, larger quantity manufacturing comes at a later date. If that’s the case, it might be attainable for a two-phase improvement – the “quick” part utilizing a ZigBee radio module and a “cost-reduced” built-in design part to comply with. This value discount part typically entails merging performance from modules right into a single circuit board. The timing of a two-phase strategy additionally is sensible, as a result of experience is constructed with the know-how earlier than merging the radio chip on the circuit board. Plan forward, and the optimum market rollout is achievable.

Like another digital machine that is dropped at market, your ZigBee utility should meet regulatory requirements. Since a ZigBee machine is an intentional radiator, the machine should meet world requirements. Because the proprietor of the design, you’ll be liable for submitting the product for compliance testing, adjusting the design as wanted to go, and submitting the ultimate design with the suitable company. Plan for a number of rounds of testing as early as attainable within the design part. This features a pre-screening check on the radiated emissions.

Since most ZigBee designs transmit on the low RF energy of about one milliwatt, the elemental RF emissions aren’t more likely to be problematic. Nevertheless, necessities on emission ranges – notably the second and third harmonics that fall into FCC “restricted bands” – should be rigorously monitored. You should additionally display screen much less technical compliance areas, corresponding to product labeling necessities and antenna limitations.

To promote your product as being ZigBee compliant, your design should undergo ZigBee licensed product testing. To submit the product for ZigBee testing, your organization have to be a member of the ZigBee Alliance. Becoming a member of the ZigBee Alliance is a reasonable proposition and needs to be accomplished instantly as a result of membership will enable entry to many ZigBee-related paperwork and discussions. Go to their web site at for extra info.

For every ZigBee product, you will want to generate a novel 802.15.4 MAC handle. The 802.15.4 MAC handle is an eight-byte (64 bit) worth. The primary three bytes (the Organizationally Distinctive Identifier or “OUI”) are licensed to your organization by the IEEE Requirements Affiliation for an annual price. Your organization is then free to uniquely assign the remaining 5 bytes.

Lastly, relying on the manufacturing unit meeting and testing course of, it might be fascinating to have a software-based manufacturing check present the MAC handle to program into every machine. On this case, your utility code might must help a non-violate reminiscence write operate that won’t in any other case be crucial.


ZigBee is a well-defined and feature-rich radio customary; nonetheless, growing a ZigBee product shouldn’t be a trivial train. Many engineering disciplines should work collectively to outline, architect, design, check and prepared the ultimate product on the market. Following the options set forth on this dialogue will allow you to arrange a sensible plan in direction of creation of a ZigBee radio utility.

#Suggestions #Designing #ZigBee #Purposes

Leave a Comment

Your email address will not be published. Required fields are marked *

Scroll to Top