This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

CC2530: CC2530 ZNP - end device example

Part Number: CC2530
Other Parts Discussed in Thread: Z-STACK

Tool/software:

I would like to make a zigbee end device with CC2530 with ZNP interface, but I can't find any example.

I find:  e2e.ti.com/.../cc2530-znp---simple-api---end-device-example

This discussion looks very good but does not have working links to the Ti website.

  • Hello Ondrej Lycka,

    To find the ZNP example please download the Z-stack from TI's website:

    CC2530 data sheet, product information and support | TI.com

    You should also try Zigbee2MQTT, it is a third-party solution, and has good support.

    Thanks,
    Alex F

  • Hello Alex F,

    thanks for your fast answer.

    I searched for z-satck as one of the first sources, but I did not find any example of how to use the ZNP API to create a simple end device, e.g. a switch. In C:\Texas Instruments\Z-Stack 3.0.2\Projects\zstack\HomeAutomation there are some C programming examples with direct calls to z-stack functions, but this cannot be easily converted to ZNP API function calls. From z-stack, I use the excellent z-tool for testing .

    I use Zigbee2MQTT as a coordinator during testing. However, Zigbee2MQTT is not very suitable for studying the ZNP API. Despite this, I can already connect to the coordinator's network using ZNP on my end device. I am currently struggling to send the correct response to zigbee2MQTT to read the ZCL attributes. If there was a sample, for example a script for z-tool, it would be a matter of half a day. Probably the only thing left to do is to get a sniffer and use reverse engineering procedures :-) .

    with best regards

    Ondrej Lycka

  • Hi Ondrej,

    You would use the AF_REGISTER Monitor and Test API to register the on/off cluster at a valid endpoint, then AF_DATA_REQUEST whose data replicates the structure of ZCL on/off commands.  Here are some relevant E2E threads,

    https://e2e.ti.com/f/1/t/683142 
    https://e2e.ti.com/f/1/t/888603 
    https://e2e.ti.com/f/1/t/1039916 

    Hopefully this helps with your Z-Tool scripting, and the CC2530 does support the APIs I've mentioned.

    Regards,
    Ryan