Thewireless control market has a number of unique needs for which ZigBee is

ideallysuited, because ZigBee is:

●Highly reliable

●Cost-effective

●Able to achieve very lowpower

●Highly secure

●An open global standard

Toachieve the low power and low cost criteria, ZigBee added a constraint to the

technology:

Low data rate

Now, why would a networking standard want to encourage low data rates?Because

ZigBee is all about wireless monitoring and control. Think of a lightswitch. How often

does it need to communicate? Ten times per day? Or perhaps, not at all, ona given day?

Howlarge is that data set? By keeping focused on the appropriate technology forwireless

control,ZigBee achieves an elegant solution that makes sense and fits a set of markets

verywell. Just don’t expect to stream voice or video over ZigBee. Yes, I have seen

companiesstream voice over ZigBee, but that’s not the intended use, and it consumes

way too much bandwidthfor most ZigBee networks


ZigBeeachieves high reliability in a number of ways:

●IEEE 802.15.4 withO-QPSK and DSSS

●CSMA-CA

●16-bit CRCs

●Acknowledgments at eachhop

●Mesh networking to findreliable route

●End-to-endacknowledgments to verify data made it to the destination

 

 

ZIGBEE的15 2025 26与 WIFI不干扰

Often, when defining a private profileapplication, I’ll select channels 15, 20, 25, and

26, as these channels aren’t the same as oncommon WiFi installations. I do this not for

ZigBee’s sake, but for WiFi’s. If theapplication gets too chatty, it could cause WiFi to

miss a packet or two, and degrade theperformance of WiFi

WIFI

中心频率如下,总带宽为22,每个信道的有效宽度是 20MHz,另外还有2MHz的强制隔离频带(类似于公路上的隔离带),所以相邻的信道会有重叠

1                2    3           4          5        6         7     8      9           10    11

2412    2417    2422      2427    2432    2437 2442  2447 2452  2457  2462

2401~2423 2406~2428 2411~2433           2416~24382421~2443 2426~2448 2431~2453 2436~2458 2441~2463 2446~2468 2451~2473

12        13

2467  2472

2456~2478 2461~2483

ZIGBEE中心频率如下,有效带宽为2MHZ

Fc= 2405 + 5 (k–11) in megahertz, fork= 11, 12, …, 26kis the channel number.

11          12   13      14   15     16        17     18    19  20   21          22   23   24    25    26

2405       2410 2415 2420 2425  2430 2435 2440 2445 2450 2455 2460 2465 24702475 2480

Clusters encapsulateboth commands and data (类似每个Cluster都是一个对象,里面有方法和属性)

Clusters only havemeaning within a particular profile

(Profile包含了多个Cluster,Cluster给Profile提供使用)

Eg:

Clusterscontain both code (commands) and data (attributes). Commands cause action.

Attributeskeep track of the current state of that cluster. A good example of this is theHA

DimmingLight.It supports both the OnOff Cluster (0x0006) and the LevelControl Cluster

(0x0008).There are commands to turn the light on, off, or toggle it on the OnOffCluster;

butto control the dimming function, commands on the LevelControl Cluster are used.

Thedata on the OnOff Cluster is simply a field: Is the light on, or off. The dataon the

LevelControlCluster indicates what dimming level the light is (or will be) at when it is in

the “ on ” state.

Thinkof clusters as an object, including both code (commands) and data (attributes).

Clusters may have anymeaning in a private profile

Commands

Publicprofiles use the ZigBee Cluster Library. ZCL introduces two new concepts

intoZigBee that you won’t find in the main ZigBee stack specification: commands

andattributes. ZCL makes it easy to get or to set attributes through a common setof

commands,and provides a simple mechanism for issuing cluster-specific commands.

Commandsare identified by an 8-bit number, and are either cluster-specific, orcrosscluster.

Cluster-specificcommands depend on the cluster number, and generally start at

0x00.For example, 0x00 is the “ off ” command in the OnOff Cluster, whereas 0x00 is

“move-to-level ” command in the LevelControl Cluster.

ZCLis used in (nearly) all of the ZigBee public profiles, but is not required forprivate

profiles.Considerable code space can be saved by leaving out ZCL, but then of course,

thefeatures of ZCL are left out, too.

Over-the-air,ZCL frames are the payload of the APS frame. Take a look at the

followingZCL:

ZigBee APS

FrameControl: 0x00

DestinationEndpoint: 0x08www.newnespress.com

ClusterIdentifier: On/off (0x0006)

ProfileIdentifier: HA (0x0104)

SourceEndpoint: 0x08

Counter:0x3f

ZigBeeZCL

FrameControl: 0x01

......01 = Frame Type: Command is specific to a cluster (0x01)

.....0.. = Not Manufacturer Specific

....0... = Direction: From the client side to the server side

0000.... = Reserved: Reserved (0x00)

TransactionSequence Number: 0x48

CommandIdentifier: Off (0x00)

Profiles

Everydata request in ZigBee is sent (and received) on an Application Profile.Application

ProfileIDs are 16-bit numbers and range from 0x0000 to 0x7fff for public profiles and

0xbf00 to 0xffff formanufacturer specific profiles

Profiles包括Public Profile(ZIGBEE联盟标准规定为了互联互通)和Private Profile(厂商自定义不能兼容其它厂家设备),不同的Profile属于不同的EndPoint

Anynumber of Application Profiles, both public and manufacturer-specific, mayexist in

asingle ZigBee network. In fact, any number of profiles may exist in a singlenode on the

network, separated ondifferent endpoints.

Device IDs

Every endpoint includes a profileidentifier and a device identifier.Think of a device as

aphysical thing: a light, temperature sensor, thermostat, or the like. Onephysical widget

mightcontain multiple devices. For example, a ZigBee thermostat sold at Home Depot

maycontain a temperature sensor, a thermostat, and a heating/cooling unitcontroller.

FromZigBee’s standpoint, these are separate devices. From a packaging standpoint,they

areall in one SKU (Shelf-Keeping Unit).

ZigBee Device IDs rangefrom 0x0000 to 0xffff

Each ZigBee PublicProfile contains a specific list of devices.

an endpoint defines an application.

ZigBee Application Support Sublayer (APS)

(APS相当于TCP/IP中的传输层,但APS还包括了应用层的东西在里面)(APS包括了TCP的一些东西如端口及重传、确认、端到端可靠传输)

Whilethe MAC layer provides per-hop acknowledgments, the APS layer is what provides

end-to-endacknowledgments, also called ACKs.

Okay.Don’t ask me why the Application Support Sublayer uses the three-letter acronym

APS.It’s obvious, but don’t ask me.

TheApplication Support Sublayer, or APS, sits above the NWK layer, and is thelayer in

ZigBeewhich understands applications. The APS frame over-the-air includes endpoints,

clusters,profile IDs, and even groups.

APSis responsible for the following activities:

●Filtering out packets for non-registered endpoints, or profiles that don’tmatch

●Generating end-to-end acknowledgment with retries

●Maintaining the local binding table

●Maintaining the local groups table

●Maintaining the local address map

APShas the job of filtering out packets for endpoints that don’t exist in thenode. APS

filterspackets that don’t match profile IDs. APS also filters duplicate packets, whichcan

happenin a network that supports automatic retries.

It’sthe job of APS to perform automatic retries, if acknowledgment is requested bythe

sender,to maximum the chance of successful transmission andto inform the sender

whether or not the packet was delivered.wnespress.com

APS also maintains a variety of application-level tables. Binding is allabout connecting

an endpoint on this node to one or more endpoints on other nodes. Groupsare all about

an arbitrary collection of applications residing on an arbitrary set ofnodes throughout

the network. The address map associates a 64-bit MAC address with a ZigBee16-bit

NwkAddr.

APS and the Application Framework (AF) together form the ZigBee interfaceused by

applications (seeFigure 4.26). Lower layers are not called upon directly,but are used by

APS and ZDO.

ZDO:

The ZigBee Device Object (ZDO, shown inFigure 5.1) is simply the applicationrunning

on endpoint 0 in everyZigBee device. (Remember, application endpoints are numbered

1 through 240.)

This application, ZDO, keeps track of the state of the ZigBee device onand off the

network, and provides an interface to the ZigBee Device Profile (ZDP), aspecialized

Application Profile (with profile ID 0x0000) for discovering, configuring,and

maintainingZigBee devices and services on the network.

ZigBee and IEEE 802.15.4

What802.15.4 doesnotspecify is anything todo with multi-hop communications,

addressassignment, or application level interoperability.

Ifthe network you have in mind to build only needs a single hop (that is, allradios in the

networkcan hear each other), then the 802.15.4 MAC/PHY may be all that you need. In

fact,Freescale and other silicon vendors offer an 802.15.4 application environmentthat

doesn’trequire ZigBee at all.

Asidefrom ZigBee, many other network protocols have been built on the 802.15.4

standard,some which are mesh or multi-hop, some which are single-hop or star networks.

Someexamples of non-ZigBee network protocols on 802.15.4 include MicroChip

MiWi™,Synap SNAP, 6LoWPAN (an IETF standard), Tiny O/S (an open source

project), and San JuanSoftware PopNet™.

ZigBeespecifies all the layers above MAC and PHY, including the NWK (network)

layer,APS, ZDO, and security layers. It’s ZigBee that provides the mesh networking

andmulti-hop capabilities, enhances the reliability of data packet delivery, andspecifies

application-to-applicationinteroperability.

ZigBeedoes not use all of the 802.15.4 MAC/PHY specification; only a small subset.

Thisallows stack vendors to offer smaller solutions (less RAM and flash) byproviding

a limited MAC for theirZigBee stacks. For example, ZigBee does not use any of the

802.15.4beaconing methods, or guaranteed time slots. ZigBee is asynchronous.

Anynode may transmit at any time. Only the CSMA-CA (carrier-sense multiple-access

withcollision avoidance), a MAC-level mechanism, prevents nodes from talking over

each other.

Forming, Joining, and Rejoining ZigBee Networks

Beforeany ZigBee node may communicate on a network, it must either form a new

networkor join an existing network. Only the ZigBee Coordinator may form a network.

OnlyZigBee Routers and ZigBee End-Devices may join a network. Many stack vendors

offerthe ability to have a node designated as a ZC, ZR, or ZED at compile time (tosave

code and RAM) or atrun-time (to reduce OEM-manufactured parts).

Every node starts out with a unique 64-bitIEEE (aka MAC or long) address, assigned by

theOEM during manufacturing. During the process of joining the network, each nodeis

assigneda unique (within that network) 16-bit short address (aka NwkAddr) to use when

communicatingto other nodes across the network. The 16-bit address is used for nearly

allcommunications, to reduce over-the-air protocol overhead, leaving more room for

application payload.

ZigBee Over-the-Air Frames(协议报文)

Anessential part of understanding ZigBee is understanding over-the-air frames. Infact,

over-the-airframes are all that the ZigBee Alliance cares about for compatibility testing.

Certainframes are sent over-the-air and certain replies are expected, but the rest isa

black box.

There are a variety of “ layers ” involved in any given over-the-airpacket, including the

MAC, NWK, APS, ZCL, and data. Over-the-air, these layers create a seriesof bytes,

framing (on either side) the rest of the bytes in the packet. That’s whyit’s called a frame.

The next higher layer frame is always inside the lower layer frameover-the-air. So the

NWK frame is inside the MAC frame, the APS frame is inside the NWK frame,and so on.

A full ZigBee data packet could contain all of the following frames (MAC,NWK, APS,

and ZCL), asshown inFigure 7.19.

The size of each frame header (MAC, NWK, APS, etc.) is variable, dependingon

parameters. Every frame header begins with what is called a frame control(FC) field,

which describes the optional fields in that frame.

The MAC frame ends with the Frame Check-Sum (FCS). The NWK frame ends with

the optional NWK Auxiliary Message Integrity Code (MIC). The NWK AUX HDR and

NWK MIC are present only in a secure network. The APS frame also may havesecurity

applied, with an APS AUX HDR and APS MIC.

The first two headers are node-oriented: that is, the MAC and NWK headers.The MAC

header controls the per-hop protocol, and the NWK header controls theend-to-end

protocol (seeFigure 7.20).

Notice how both the MAC and NWK headers contain destination and sourceaddresses.

Think of node A sending a packet multi-hop to node F. The first hop wouldbe from A to B.

The next hop would be from B to C, and so on. The final hop would be fromE to F. The

MAC source and destination would change along this entire journey, but theNWK source

anddestination addresses would not.

All ZigBee data packets are sent using the 16-bit short addresses, butother packets are

not. For example, when joining a network, the association request andresponse are sent

with the long (64-bit IEEE) addresses.

The next two headers, APS and ZCL, are application-level headers (seeFigure 7.21).

They describe application-level information including endpoints,application profile,

and for ZCL, the specific command for the cluster (reading and writingattributes, or

commanding the application to do something such as turning on a light).

All of the addressing fields in APS are within the node, so as to send thepacket to the

right application, as opposed to the NWK layer which addresses betweennodes. The ZCL

frame isoptional, but is present in all ZigBee public profiles.

ZIGBEE技术 Zigbee Technology相关推荐

  1. 什么是ZigBee技术

    什么是ZigBee技术 Zigbee在中国被译为"紫蜂",是一种基于IEEE802.15.4协议的最近发展起来的一种短距离无线通信技术,功耗低,被业界认为是最有可能应用在工控场合的 ...

  2. 大杂烩·OSI和TCP/IP协议与ZigBee技术·一

    1.ZigBee技术        ZigBee是基于IEEE802.15.4标准的低功耗局域网协议.根据国际标准规定,ZigBee技术是一种短距离.低功耗的无线通信技术.这一名称(又称紫蜂协议)来源 ...

  3. 新兴的短距离传输技术-zigbee技术

    新兴的短距离传输技术-zigbee技术,欢迎正在做这方面的同学来探讨 Zigbee的基础是IEEE 802.15.4,这是IEEE无线个人区域网(Personal Area Network,PAN)工 ...

  4. 【Zigbee技术入门教程-02】一图读懂ZStack协议栈的核心思想与工作机理

    [Zigbee技术入门教程-02]一图读懂ZStack协议栈的核心思想与工作机理 广东职业技术学院  欧浩源   Z-Stack协议栈是一个基于任务轮询方式的操作系统,其任务调度和资源分配由操作系统抽 ...

  5. ZigBee技术的应用和优势

    ZigBee一词源自蜜蜂群在发现划分位置时,通过跳ZigZag形舞蹈来告知同伴,来达到交换信息的目的.可以说是一种小的低信息量的"无线"通信方式,人们也就借此称呼一种专注于低功耗, ...

  6. lora技术和zigbee技术那个好,两者有啥优势

    ZigBee是基于IEEE802.15.4标准的低功耗局域网协议,LoRa是LPWAN通信技术中的一种,那么lora技术和ZigBee技术哪个好呢?今天我们就来看看具体的介绍. LoRa是LPWAN通 ...

  7. 基于ZigBee技术的智能家居系统实施方案

    智能家居:通常意义上的智能家居是指使用计算机技术.网络技术.综合布线技术.传感器技术和设备自动控制技术建立家庭或楼宇智能化管理平台,通过信息管理平台将与家居生活相关的各种设施管理起来.智能家居信息系统 ...

  8. android zigbee环境监测,基于ZigBee技术的室内定位与环境监测系统

    详细介绍: 1.1 课题背景 采用Zigbee协议形成的多跳自组织网络,由分布在监测区域内中的大量的廉价传感器组成,使用这些传感器监测物理和环境信息.现在的无线传感器网络可以进行双向通信,使得人们可以 ...

  9. ARM及ZigBee技术实现智能家居控制器的设计

      来源:飞象网   2011-7-29 10:08:25     关键词: ARM  ZigBee  智能家居   [提要]本文所介绍的智能家居控制器利用ZigBee技术将家庭中许多相对独立的家用电 ...

最新文章

  1. AI与人类围棋士的差距到底有多大?
  2. access检查为空函数
  3. 给 asp.net core 写一个简单的健康检查
  4. 如果误删谷歌浏览器的书签,怎么恢复
  5. 内核编程小结(引用)
  6. java bytearrayoutputstream 文件_Java ByteArrayInputStream和ByteArrayOutputStream示例
  7. 深度学习图像预处理——分类
  8. lamp 重启mysql_lamp常用命令 --Ubuntu下启动/重启/停止apache,mysql服务器
  9. xmind怎样画流程图_老师是怎样上网课的?
  10. 完美解决github访问速度慢
  11. tf.read_file和tf.image.decode_jpeg处理图片(转)
  12. Oracle学习 第20天 PL/SQL导入
  13. 数值的整数次方(代码的完整性)
  14. JavaWeb框架之Struts2 ---- 系列学习
  15. 色环电阻计算器_色环电感标示法_
  16. C语言练习①一英寸是多少厘米?
  17. 关于python使用系统命令反弹shell的一点记录
  18. macos修改WIFI共享功能的默认网段
  19. Python爬取简单网页内容
  20. 学Java是自学还是报培训班好?

热门文章

  1. Photoshop给河边婚片加上唯美的霞光
  2. Nagios安装与部署
  3. Docker的配置与容器的拉取镜像、端口映射
  4. win8计算机盒盖后无法唤醒,笔记本合盖后无法唤醒如何解决|笔记本合盖后唤醒不了解决方法...
  5. linux 添加spi 驱动,Linux下SPI和IIC驱动免在设备树上添加设备信息的编写方法
  6. Codeforces 496A Minimum Difficulty(暴力)
  7. java之DNF坑爹的强化
  8. 魅族X8可以更新Android10吗,【魅族】Note8/X8永远停在了安卓9 无缘安卓10 11更是遥遥无期...
  9. 绿联怎么样_绿联TWS耳机怎么样?
  10. 网络原理——UDP协议