您的位置:首页 > 其它

Zigbee Bind Mechanism

2015-11-28 14:12 399 查看

                                                                                              

ZigBee Bind Mechanism

Beforewe talk about the ZigBee bind mechanism, we should to know some terms about ZigBee.  

Attribute:
Thisis a data entity which represents a physical quantity or state.

Cluster:
Thisis an application message, which may be a container for one or more attributes.

Endpoint:
Thisis a particular component within a unit. Each ZigBee device may support up to240 such components.

Profile ID:
anagreement by convention outside the scope of the ZigBee specification on a setof additional restrictions with respect to features declared optional by thespecification
itself.

 

  
Then, the introduce of bind in ZigBee SPECis like follows:

1、TheAPS
may maintain a binding table, which allows ZigBee devices to establishdesignated destination for frames from a given source endpoint and with a givencluster ID. Each designated destination shall represent either a specificendpoint on a specific device, or
a group address.

2、Thisis
the creation of a unidirectional logical link between a sourceendpoint/cluster identifier pair and a destination endpoint, which may exist onone or more devices.

3、Useunicast.

 

Thisis a demo of ZigBee bind, in the demo, Device 1’s end point 3(switch 1) is bindtogether with Device 2’s end point 5(lamp 1), end point 7(lamp
2), and endpoint 8(lamp 3).

Device1’s end point 21(switch 2) is bind with Device 2’s end point 17(lamp 4).



Thebind Mechanism Between device A and Device B is as follw:



Thedetail of step 3 is as follow:



Thendevice will build a bind table in it’s APS layer, And the Binding TableImplementation means

Adevice designated as containing a binding table shall be able to support abindingtable of implementation-specific length. The binding table shallimplement
thefollowing mapping:

(as,es, cs) = {(ad1|, ed1|), (ad2|, ed2|) . (adn|, edn |)}



Thesemantics of this primitive are as follows:





Thebind’s mainly process is as follow:

DeviceB issue a binding request to device A. The NWK dest address is A, And in therequest payload ,the Source address is A, the dest address is B.

Thedevice A relay a bind response .

Asave device B information to it’s binding table. But device B don’t save deviceA’s information to it’s binding table.

Ifthe device A will send message to device B application. 
If set address mode to 0x00 and set dest endpoint to specific values in the aps data request primitive.

Thedevice A’s aps layer will search the binding table.

Findout device B’s address, then unicast to device B.

Aboutabove process, if the destination is a group address, step 6 will use multicastmode.

Theend device bind is a particular bind mechanism, the introduce of end device bindin ZigBee SPEC is as follows:

Typicallybased on some user action like a button press. the destination address shall bethat of the ZigBee Coordinator.

Whena Coordinator received an end device bind request, It need to do some checks, startoff a timer, save the info, and wait for the next end device bind request tocome in. ED bind
request must come in pairs because two devices will be boundtogether.

Unicast

It’srequest fr0ame is as follow:



BindingTargetis A 16-bit NWK address, the address of the target for the binding. This can beeither the primary binding cache device or the     
short address of the local device.

ProfileIDis which is to be matched between two End_Device_Bind_req received at theZigBee Coordinator within the timeout value pre-configured in the
ZigBeeCoordinator.

Theprocess of end device bind is like this :

内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: