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.

Binding (Sensor network application)

Other Parts Discussed in Thread: Z-STACK

Hello all,

I have a small network of an ED and a collector (in sensor network application a gateway) and a router that are based on Zigbee pro. This application is based on the sensor demo app by TI, ED binds to router and router binds to coordinator.

Question: Do they have to refresh their binding status with the coordinator? how often they do that? In my application I can see either router or ED start sending a binding request to a coordinator that it is already bound. This action does not let my ED send data packets out.

Please advice me,

Thanks,

Leila

  • Hello Leila,

    Once a device is bound to other device there is no need to update the binding, in the sensor monitor demo application if you are seeing the binding requests after the network is formed and devices were sending messages before, it may be beacuse of report failures. As explained in the CC2530ZDK sensor demo user guide page 12:

    The sensor report messages are built and sent in the function sendReport(). Each 5th report has the acknowledgement request flag set. This is done in order to minimize traffic on the network and to be able to detect when the reports can not reach the gateway successfully. The number of reports before an acknowledgement is requested is set by the define ACK_REQ_INTERVAL

    When a report fails up to the number of times defined by REPORT_FAILURE_LIMIT the device will stop sending reports to the current gateway. It will then go into a state where it deletes the binding to the current gateway and tries to find a new gateway to bind to. This is initiated in the function zb_SendDataConfirm() .

    Can you check if this is what is happening in your application, causing the end device/router to stop sending the data and start the binding process again

  • Hi,

     

    Yes. It is exactly what is happening in my case. Although the ED and Coordinator are located close by I keep losing my packets. note that I am sending a 99 byte packet every 50 mec. So it is faster compared to the original 2 sec report time interval we had before. Do you have any advice?

    Thanks in advance.

    Leila

  • Hello Leila,

    The sensor monitor application checks for application level acknowledgement every 5th message. The process of accquiring acknowledgement is as follows. The end device sends the 5th message and waits for time specified by the parameter -DRESPONSE_POLL_RATE defined in the file f8wConfig.cfg, by default this value is 100 i.e. end device waits for 100msec before sending a poll message to request for applicaiton acknowledgement from the coordinator. By this time, in your implementation you have already sent a message and this may be causing the error number to increase and eventually making the end device think that it has lost the connection and so it starts the binding process again.

    If you are sending data at such a fast rate it will be hard to implement the application. Can you try sending messages without application level acknowldgements and see if the performance is acceptable and if you want to verify the link by receving the application level acknowledgement you can reduce the value of the -DRESPONSE_POLL_RATE parameter to say 30 and only ask for acknowledgement by suspending the transmit operation say after 100packets or so and then wait for about 150msec (or check how much time you need to receive aps ack - use packet sniffer to see over the air messages) before restarting the transmission. There is some time involved in the transmission and receiving of the messages as well which you have to considering when timing your application send and recieve operations.

    Regards,

    Suyash Jain

  • Thank you for your help. I did what you recommended. with one ED and router and coordinator I could achieve my desired application with out application level ack. I think for now it should be fine unless I want to verify ED and gateway link. Now there is a couple questions: 

    1) without application level ack if the link between ED and coord is not working fine then ED would never know? and will keep sending the data?

    2) After turning off the application level ack, as I see in the packet sniffer the process is :

    sending a packet data from ED to router then receiving ack then router sends the same data packet to gateway and receiving ack .... then after awhile I can see my gateway then router broadcasts a message which I am not sure what is that message and should I turn it off and how.

     

    Sorry for too many questions and thanks in advance.

    Leila

  • Hello Leila,

    1. Yes, one way to verify the link can be to enable the request for application level acknowledgement on a packet and then stop the transmission on the ED after 'x' number of packets until you recieve the application level acknoweldgement back. This way you can verify the link.

    2. The packets that coordinator and router send out should be link status messages and you should see them every 15 seconds. Coordinator and every router in a ZigBee PRO network sends a periodic Link Status message. This message is a one hop broadcast message that contains the sending device’s neighbor list. Please see Z-Stack Developers Guide for more information.

    Regards,

    Suyash Jain

  • Excuse me, where can I find this sensor demo app?

    Best regards.

  • Hi Aldo,

    By googling TI website you may find some of the past posts about your question: http://e2e.ti.com/support/low_power_rf/f/158/p/129577/464136.aspx#464136

    Best,

    Leila