This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Zigbee Light example custom values send and receive

#define ZB_ZCL_ON_OFF_SEND_REQ( \
buffer, addr, dst_addr_mode, dst_ep, ep, prof_id, dis_default_resp, command_id, cb) \
{ \
zb_uint8_t* ptr = ZB_ZCL_START_PACKET_REQ(buffer) \
ZB_ZCL_CONSTRUCT_SPECIFIC_COMMAND_REQ_FRAME_CONTROL(ptr, dis_default_resp) \
ZB_ZCL_CONSTRUCT_COMMAND_HEADER_REQ(ptr, ZB_ZCL_GET_SEQ_NUM(), command_id); \
ZB_ZCL_PACKET_PUT_DATA8_VAL(ptr, 0x0A); \
ZB_ZCL_PACKET_PUT_DATA8_VAL(ptr, 0x0B); \
ZB_ZCL_FINISH_PACKET(buffer, ptr) \
ZB_ZCL_SEND_COMMAND_SHORT( \
buffer, addr, dst_addr_mode, dst_ep, ep, prof_id, ZB_ZCL_CLUSTER_ID_ON_OFF, cb); \
}

I have added this in End device and sending packets.

I want to receive and how can I receive this on the router or co ordinator I am referring to Zigbee light example. PLease help

Parents
  • Hello,

    I would recommend that you start by trying to read these using the example found in SDK\examples\zigbee\experimental\cli\cli_agent_router.

    If you check out the test description for the multi sensor example, you can see how to use the CLI example to subscribe to zigbee attributes. 

    Hints:

    The command to find the device with an on_off cluster is:

    > zdo match_desc 0xffff 0xffff 0x0104 1 0x0006 0

    But perhaps the multi sensor example is a better starting point if you want to send custom commands. Either way, I would recommend that you go through the test description for the link using the multi sensor example to get familiar with the CLI example, and how the clusters work.

    BR,
    Edvin

Reply
  • Hello,

    I would recommend that you start by trying to read these using the example found in SDK\examples\zigbee\experimental\cli\cli_agent_router.

    If you check out the test description for the multi sensor example, you can see how to use the CLI example to subscribe to zigbee attributes. 

    Hints:

    The command to find the device with an on_off cluster is:

    > zdo match_desc 0xffff 0xffff 0x0104 1 0x0006 0

    But perhaps the multi sensor example is a better starting point if you want to send custom commands. Either way, I would recommend that you go through the test description for the link using the multi sensor example to get familiar with the CLI example, and how the clusters work.

    BR,
    Edvin

Children
No Data
Related