This is an attempt to gather complete information regarding IAS Zone enrollment process implementation using ZBOSS Stack.
- The primary reference, as mentioned in previous post is Official Zigbee ZCL specification (chapter 8.2).
- Another interesting reference worth mentioning is HA API -> HA Devices -> IAS Zone sample, however, it is more related to IAS Zone server and incompatible with current SDK version.
- Another bit of information could be found in this post. It is based on relevant SDK version, but again, it is related to IAS Zone server and incomplete.
That's all I have found for now. The rest, like IAS Zone cluster API is just pile of declarations wrapped into html, which does not help at all.
Let's consider one mandatory enrollment method: 'Trip-to-Pair'.
TX < zdo simple_desc_req 0x9CC5 1
RX > src_addr=0x9CC5 ep=1 profile_id=0x0104 app_dev_id=0x402 app_dev_ver=0x1 in_clusters=0x0000,0x000A,0x0500,0x0001 out_clusters=0x0019
zb_zdo_simple_desc_req()
called from zigbee_cli_cmd_zdo.c
TX < zcl attr write 0x9CC5 1 0x0500 0x0104 0x0010 0xF0 0xF4CE36089BA25E4A
RX > Done
0x0000 > 0xf230 | ZCL: Write Attributes, Seq: 4, Cmd: Write Attributes (0x02)
0xf230 > 0x0000 | ZCL: Write Attributes Response, Seq: 4, Cmd: Write Attributes Response (0x04), Status: Success (0x00)
...
0xf230 > 0x0000 | ZCL IAS Zone: Zone Status Change Notification, Seq: 81, Cmd: Zone Status Change Notification (0x00), Extended Status: 0x00
0x0000 > 0xf230 | ZCL: Default Response, Seq: 81, Cmd: Default Response (0x0b), Status: Unsupported Cluster (0xc3)
...
0xf230 > 0x0000 | ZCL IAS Zone: Zone Enroll Request, Seq: 82, Cmd: Zone Enroll Request (0x01), ZoneType: Water sensor (0x002a)
0x0000 > 0xf230 | ZCL: Default Response, Seq: 82, Cmd: Default Response (0x0b), Status: Unsupported Cluster (0xc3)
TX < zcl cmd 0xF230 1 0x0500 -p 0x0104 0x00 -l 0x0001
RX > Done
0x0000 > 0xf230 | ZCL IAS Zone: Zone Enroll Response, Seq: 9, Cmd: Zone Enroll Resp(0x00), Enroll resp code: Success (0x00), Zone ID: 0x01
0xf230 > 0x0000 | APS: Ack, Dst Endpt: 1, Src Endpt: 1
TX < zcl attr read 0xF230 1 0x0500 0x0104 0x0000
RX > ID: 0x0000 Type: 0x30 Value: 1
TX < zdo bind on 0x5C0272FFFEB9F593 1 0xF4CE36089BA25E4A1 0x0500 0x9CC5
RX > Done
However, the fist problem, is that Responces to 'IAS Zone Report' and 'IAS Zone Enrollment Request' are 'unsupported cluster', so obvously someting else has to be done on the ZC side to instruct ZBOSS stack to to handle 'IAS Zone'-related packets. And the second problem is that system does receive 'Zone Status Change' reports, but never reflects that in log or CLI.
Note that above communication resulted in after calling zb_zcl_ias_zone_init_client(),
after calling zboss_start_no_autostart()
.
I find references to non-existent files/foldes with essential information, like "The complete set of IAS Zone samples can be found in /application/ias_zone_sensor" in the "documentation" at infocenter.nordicsemi.com and in source files/header and wonder why is it removed/hidden? It is among necessary algorithms, required by multiple types of standard sensors, yet unavailable wouthout any options.
Finally, the general question is: how do you (Nordic Developers) expect us (users / 3d party developers) to figure out the sequence of variable decalarations, function calls and callbacks registrations without detaild documentation and examples? Trial-Error? I'm afraid reading headers with minimal comments like "This functions is for that." does not really help, since we still don't undestand what are the prerequisites for that function, what are the inputs/outputs, limitations, etc.
Most probably, I am missing something, but I have already spent significant amount of time digging though all available sources of information, so I would really appreciate if you could direct me.