Sending ADC data over Zigbee Protocol - JN5169

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Sending ADC data over Zigbee Protocol - JN5169

1,805 Views
matthew3
Contributor III

Hi,

   I have a program that reads from one of the JN5169 ADC channels and i am wanting now to send that data to a Raspberry pi which as a Conbee Zigbee USB dongle attached to one of its USB ports. 

Firstly i want to add to my code or add my code into some code that sends the ADC reading over zigbee and secondly how do i go about interpreting the data sent on the Raspberry pi end.

Much help is appreciated.

Regards

Matthew

Labels (2)
6 Replies

1,340 Views
mario_castaneda
NXP TechSupport
NXP TechSupport

Hi Matthew,

Firstly I want to add to my code or add my code into some code that sends the ADC reading over ZigBee and secondly how do I go about interpreting the data sent on the Raspberry pi end.

The ADC values that you want to send. I am assuming that is a sensor, for example, temperature. You could implement the Temperature Cluster and depend on the frequency that you want to get these values, you could set a reporting this attribute.

Could you please provide more details about your final application?

Regards,

Mario

0 Kudos

1,340 Views
matthew3
Contributor III

Hi Mario,

Yes the ADC values are from a Sensor that is inside a bolt to detect tension. Wanting to send the data over to a Raspberry Pi. Why using zigbee? We originally was using Arduino’s to do this but they were on the big side for the application. By using the JN5169 chip it as everything in one chip for what we need. Plus it needs to be wireless due to what the bolt is on is moving so no wires can be used to the master (Raspberry Pi - Coordinator).

Hopefully this as explained in a bit more detail what I am trying to achieve.

Regards

Matthew

0 Kudos

1,340 Views
mario_castaneda
NXP TechSupport
NXP TechSupport

Hi Matthew,

Depending on the sensor that you have. You could select a Cluster. 

Please look at the next community post  ZigBee 3.0: Adding Clusters.

But, if you want to implement your own cluster. Please look at the JN-AN-1229 example that implements a Custom cluster 0x1234, The  ZigBee Cluster Library (for ZigBee 3.0) User Guide  6. ZCL Structures. You will define the endpoint for this cluster, and depending on the values that you want, you could set the attributes.

Please let me know if you have questions about this.

Regards,

Mario

0 Kudos

1,340 Views
matthew3
Contributor III

Hi Mario,

   Thank you for all the help. Just another question. In the example JN-AN-1229 which implements a Custom Cluster i can see where the custom cluster as been added to the zpscfg file but does it get declared anywhere in any of the source / header files? Cannot see where abouts it gets declared if it does at all. Looked at other examples and in those the clusters for example "Temperature Measurement" get declared in the zcl_options.h file and in the Jn-AN-1229 example this file does not exsist. Am i being dumb? Sorry for all the questions but i am trying to get my head around how these are put togeather. Will in the meantime look at ZigBee 3.0: Adding Clusters.

Regards

Matthew

0 Kudos

1,340 Views
mario_castaneda
NXP TechSupport
NXP TechSupport

Hi Matthew,

If you are measuring tension, you could look at the 30. Electrical Measurement Cluster.  The  ZigBee Cluster Library (for ZigBee 3.0) User Guide

I think this cluster match with your application.

Regards,

Mario

0 Kudos

1,340 Views
matthew3
Contributor III

Hi Mario,

   Thank you will look at this along with various User Guides that you have pointed me to.

Regards

Matthew