Vous êtes sur la page 1sur 7

Understand the ZigBee spec, from A to Z

From design through certification, following the steps set out by the Alliance can made a
designer's job a lot easier.
By Jon Adams, Freescale emiconductor
!ireless "et #esign$ine
%&'()*(+&&, ,-&& A. /#01
Building wireless into an application isn't a simple thing2it ta3es an understanding of
radio performance, propagation, modulation, coding, protocol, and more to ma3e a good
wireless lin3. 4t's no wonder that so many designers throw up their hands in despair when
attempting to get rid of a simple serial connection. Until recently, the wireless choices
were either e5pensi6e, proprietary, and ill7suited to the de6eloper's need, or less
e5pensi6e, proprietary, with no hope of broader interoperability, etc. 8owe6er, ZigBee
and 4/// 9&+.),.: may put an end to those problems.
0he ZigBee Alliance is a rapidly growing, open alliance of o6er );& companies that ha6e
a common goal, namely cost7effecti6e, simple, ubi<uitous wireless connecti6ity between
nearly any de6ices. =ost7effecti6e means that uncomplicated products at retail could be
>+& or less. imple means that the time it ta3es from idea to engineering sample is
measured in wor37wee3s, not wor37years. And ubi<uitous means that if the solution
meets the first two re<uirements, then nearly anything that has sensing ability or control
needs can be made wireless effecti6ely and <uic3ly.
IEEE 802.15.4: the wheels and chassis for ZigBee wireless
.any of the indi6iduals that wor3 Alliance members are also 6oters in the 4/// 9&+
standards group, specifically the 9&+.), !ireless ?ersonal Area "etwor3ing group.
0hrough their efforts o6er the past fi6e or so years, these engineers created the 9&+.),.:
wireless standard which ser6es as the basis of ZigBee, and made sure that the world had
an open, wireless standard that made good on broad applicability, low7cost, and low
comple5ity. Because of their efforts, there are already many silicon radio platform
6endors building and selling 9&+.),.: radios with competition heating up and dri6ing
down prices. !hile at first generation silicon right now, the prices are already on par with
current fourth7generation Bluetooth silicon, primarily because of ZigBee technology's
lower comple5ity (Fig. 1).
1. ZigBee technology sits on top of the IEEE radio.
4/// 9&+.),.: is the undercarriage of the ZigBee 6ehicle, so ZigBee networ3ing counts
on the 4/// standard to deli6er the robustness and reliability that one e5pects from a
wireless networ3. #e6eloped to be a low7duty cycle, ac3nowledgement7based protocol,
the spec brings together multiple @F channels in the 9;97, *),7, and +:&&7.8A bands.
!hile the lower bands ha6e some attracti6e performance characteristics, it's the +:&&7
.8A band that attracted the most interest, not only because of the worldwide a6ailability
of that band for unlicensed operation, but also because of the performance of the products
de6eloped for that band (Fig. 2).
2. Shown are the available channels and the nlicensed natre of each band..
ZigBee wireless technology ta3es ad6antage of the robustness inherent in the 4/// radio
and layers upon it a strong mesh networ3 that can self7form and self7heal, route messages
<uic3ly and accurately, pro6ide interoperability mechanisms and testing capabilities to
ensure that li3e de6ices can tal3 to li3e de6ices, and that all de6ices ha6e can ta3e
ad6antage of the ZigBee networ3. 0he networ3 functions allow for three de6ice classes,
the coordinator, the router, and end de6ice. 0here are some important differences in the
home space for these de6ices. 0he coordinator, of which only one is needed per networ3,
sets up the initial address space and networ3 configuration.
Profiles and device descriptions
ZigBee specifies how a de6ice, li3e a light switch, must beha6e in a gi6en en6ironment.
0hese beha6iors are in documents published by the Alliance and a6ailable on the !eb.
0he Alliance di6ides up functionality according to mar3ets. For e5ample, the home space
differs from the industrial controls space, as installing a control(sensor networ3 in a home
presumes a different competence than would be e5pected in an industrial setting. 0he
home space must be consumer7friendly, and that means B/.s can't e5pect consumers to
ha6e 3nowledge of %or e6en care about1 networ3ing, radios, de6ice functionality, etc. 4t
must be simple to be successful, yet with the right features presented in a straightforward
manner so that consumers won't return it after the out7of7the7bo5 e5perience.
0he ZigBee !eb site pro6ides the necessary documentation to de6elop an application.
For e5ample, the 8ome7=ontrol7$ighting %8=$1 profile document specifies the o6erall
home control lighting en6ironment, types of de6ices, and cluster 4#s used to transmit
information. 0he 8=$ witch7@emote7=ontrol %@=1 specifies the re<uired ZigBee7
specific physical de6ice 4(Bs. 0hese two documents, a6ailable to the general public,
pro6ide the core of what the de6ice needs to do to be considered a ZigBee product.
esigning a ZigBee prod!ct
As an e5ample design, let's choose a battery7operated, remote7control light pad with one
push button for the home controls space. "ote that the de6ice uses the imple Binding
process. 4n the @= de6ice document %Figure ;b1 we disco6er that the BnBff@= cluster
has an attribute called BnBff, with three possible data 6alues. &5&& specifies BFF, &5FF
specifies B", and &5F& means 0BCC$/ %if it was on, turn it off, and 6ice76ersa1. For the
simple light switch, we'll use only the 0BCC$/ 6alue, because we'6e only got a
momentary switch on a faceplate. 0he code will issue a ZigBee pac3et that specifies the
=luster 4# of &5)D and a data 6alue of &5F& e6ery time the button is pushed (Fig. !).
!. "a#en fro$ the %&' (rofile doc$ent) this figre diagra$s the S*& device) with the
$andatory and optional interfaces.
According to the specification %paragraph ).:.+.+ /nd #e6ice Bind B6er6iew1, simple
binding means- ?ro6ides the ability for an application to support Esimple bindingE where
user inter6ention is employed to identify command(control de6ice pairs. 0ypical usage
would be where a user is as3ed to push buttons on two de6ices for installation purposes.
0his is an intuiti6e method of binding and one that's used in many applications. 4n our
light7switch product, this method may be cast as an instruction to the user- E8old down
the button on the remote light switch for fi6e seconds, then push the bind button on the
master home controller within ;& seconds.E 0here could also be other physical
instantiations of the re<uired approach, but it's always essentially the same.
0he binding comes from user physical input to both the de6ice that can issue the
command %the switch1 and the de6ice that will respond to the command %the load
control1. 0his binding information will then be stored, at a minimum, in the ZigBee
coordinator assigned to the networ3, and may also be stored in the end de6ices as a
fallbac3.
Feeping the tas3 as straightforward and simple as practical, you may choose to start with
someone else's ZigBee =ompliant ?latform, where they'6e already demonstrated to the
Alliance that the silicon platform with the appropriate software meets the Alliance's
technical specification re<uirements. As of April +&&,, four manufacturers offered a
compliant platform.
Using the de6elopment tools pro6ided by the silicon 6endor or a third party, craft the
ZigBee7specific parts of the application code while maintaining your o6erall loo3 and
feel that differentiates your product from others on the mar3et. pend the majority of
your time on how the product interacts with the user. Using a compliant platform allows
you to not worry as much about the other re<uired Eunder the hoodE parts.
Interopera"ilit# and $ertification %esting
Before releasing the product, the designer should chec3 to ensure that it interoperates
with other ZigBee de6ices, first at a basic 4/// 9&+.),.: le6el, then at a ZigBee networ3
le6el, and finally at the de6ice profile and description le6el. 0he Alliance schedules
<uarterly interoperability e6ents called ZigFests, in which de6elopers can perform
interoperability and functionality testing in a secure en6ironment.
Bnce the product reaches engineering sample stage in its final form factor, it's time to
bring it to a ZigBee Alliance certified test house to 6erify its adherence to the chosen
profile. 0his is an important step and necessary for two reasons- )1 Gou want your
customers to 3now that the product is compatible with other ZigBee7certified products in
their en6ironment, and +1 0he Alliance wants to ensure that a product that wearing the
ZigBee logo has been chec3ed for adherence to the same specs that other similar de6ices
ha6e undergone. =ertification is a two7way street, one that benefits both the de6eloper
and the consumer.
For the simple battery7operated light switch, the certification testing is probably less than
a day's wor3 at a test house. But in those si5 to eight hours, many things are chec3ed. 4t
starts with <uic3 spot chec3s, li3e @F fre<uency and basic functionality, li3e whether the
product wor3s on all the fre<uencies allocated for that band, whether the modulation is
clean enough, whether the range is sufficient, and so on. Bnce the basic functional tests
ha6e been completed, the majority of the effort is spent ma3ing sure that the de6ice under
test meets the re<uirements of both the ZigBee profile and de6ice description documents.
0he testing wraps up with a written report and the de6eloper and Alliance notified that a
light switch has successfully passed the certification testing.
After recei6ing the certification notification, the de6eloper may re<uest the use of the
ZigBee logo for that particular product. 0he de6eloper must supply the product part
number and as long as the Alliance has proof from the test house that the product passed
the certification testing and the de6eloper has demonstrated interoperability at least at one
ZigFest, the Alliance can issue authoriAation for logo usage.
Because it's a wireless de6ice, the de6eloper must also ensure that it meets the radio
regulatory rules for the countries in which it'll be sold or used. For the U.. and =anada,
that means at a minimum getting transmitter testing done at an F==(4=7certified test
house. Fortunately for the de6eloper, the ZigBee7authoriAed test houses are also
regulatory type7certification test houses, as are many other companies. 0his testing is
generally lengthier than the ZigBee certification testing, but for a simple de6ice, not
much more so. 0his testing is a re<uirement for all wireless de6ices sold commercially,
whether ZigBee or not.
Zigbee wireless mesh technology uses a simple, cost7effecti6e and battery7efficient
approach to pro6ide sensor and control applications with robust, reliable, self7configuring
and self7healing networ3s. 0he Zigbee Alliance ratified a specification last year that adds
mesh networ3ing with security to the 4/// 9&+.),.: short7range wireless protocol.
Zigbee networ3ing sits atop the physical and media7access layers to pro6ide the re<uired
functionality to create and manage mesh networ3s. !hen a node is acti6ated for the first
time, the networ3 commands the media access control to search all channels for an
a6ailable networ3. Bnce a net is found, the .A= can pro6ide that information to the
networ3 layer and let the end application determine whether to join, or the node can join
the net automatically. 0he networ3's Zigbee coordinator7or one of the routers7then assigns
a );7bit address to the node according to rules based on the parameters contained in the
Zigbee stac3 profile.
Zigbee networ3s use the concept of generations of a family. Bnly fully functional
9&+.),.: de6ices may Eprocreate,E and at $ayer $ma5 no de6ice may procreate. Zigbee
de6ices that may procreate are considered Zigbee routers %Z@s1. 0hose that may not or
cannot procreate are Zigbee end de6ices %Z/#s1. $ayer & contains only the Zigbee
coordinator %Z=1.
0he coordinator determines the networ3 addressing according to the three networ3
parameters7layers, children and routers. $ayers specify the ma5imum radius for any
Zigbee networ3. For an $ma5 H D networ3, no node may be more than three physical @F
hops from the coordinator.
=hildren define the number of nodes in a gi6en layer that may be directly connected to a
parent router in $ayer n7). @outers %@1 can be limited in number. For any procreating
Zigbee parent, the first @ address bloc3s are reser6ed for router children, while the
remaining =ma57@ma5 addresses are reser6ed for end7de6ice children.
.ost products that are mains7powered, fully functional 4/// 9&+.),.: de6ices can be
parents. But, as defined abo6e, any de6ice in the outermost layer may not procreate by
networ3 rule, whether a fully functional de6ice or not.
defines the ma5imum number of nodes in a gi6en Zigbee networ3. 4n an e5ample
networ3 where $ma5 H D, =ma5 H +& and @ma5 H ;, a designer can ha6e a total of 9;)
nodes. 0here is no limit defined to $ma5, =ma5 and @ma5 e5cept that "total cannot
e5ceed appro5imately +);.
4n a networ3 with $ma5 H ;, =ma5 H ; and @ma5 H ;, all children may be routers. 0he
ma5imum number of nodes in the networ3 e5ceeds ,,,&&&. 0he physical radius of the
net7e6en assuming only )& meters per hop7could be )+& meters, or about :&& feet,
potentially co6ering many acres of office or factory floor.
For a networ3 described by $ma5 H )&, =ma5 H ;& and @ma5 H +, where there are a lot
of sensors and a well7placed routing infrastructure, the ma5imum number of nodes is well
o6er ;),&&&. "etwor3s that are physically larger than this are generally bro3en into
multiple subnetwor3s, just as 4nternet addresses are di6ided into subdomains, partially for
ease of use and also for added robustness and networ3 capacity.
!hile an initial networ3 address allocation creates a default tree networ3, 6ery soon
afterward the networ3 routing de6ices begin to learn additional routes among themsel6es.
4n this manner Zigbee nets create a mesh networ3 that may actually do the majority of the
routing, depending on routing performance.
Because of the topology of a mesh networ3, latency 6aries depending on the number of
hops re<uired. But latency may not be an issue for most systems that interact with
humans.
ingle7hop times, including ac3nowledgement, are in the se6eral7millisecond range. o
e6en with networ3 processing o6erhead, typical hop times are on the order of tens of
milliseconds, allowing <uic3 reaction times e6en in multihop networ3s.
4n short, Zigbee technology pro6ides a strong yet simple networ3ing technology. 4t runs
on simple microcontrollers, can last for months to years on standard batteries, and has the
built7in ability to self7configure and self7heal robust mesh networ3s.

Vous aimerez peut-être aussi