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

Problem about proprietary protocol and ack

Hi,

In my develop environment , there have many proprietary device.  One device is working on PTX mode, and the other devices is working in PRX mode.

If the PTX device send a broadcast proprietary packet (need ACK), all of PRX devices may  send ACK message back. Does it correct?

How can "PTX device" know the "ACK message" is send from which PRX device?

Thank you,

Chianglin

  • Hi  Hung,

    Thank you for you detail explain.

    If I configure all PRX to have same address, say number 3. And one PTX has address configure to 3 and send a packet out.  All of three PRX will ACK this packet, is it right?

    If the PTX silt had enable ACK receive and the three ACK packet do not collided, the PTX will receive three ACK packet, is it correct?

    About the "random delay", does it implement in PRX site?  Would you please tell me how can I implement this function?

    Thank you,

    Chianglin

  • No, the PTX wouldn't receive 3 ACKs. As I mentioned several times, PTX stops receiving ACK after the first ACK it receives. 

    We don't make the ESB for this use case. PRXs will immediately retransmit and 3 ACK packets will most probably collide. You would need to add the random delay on your own. 

    That's why I suggest don't do the normal ACK. 

    What you do is to configure all 4 devices as PRX, all listen to address 3. When a node (we call it NODE A) want to transmit it switch itself to PTX mode, send a NOACK packet, and then switch back to PRX mode again. Other nodes (B, C, D) when receiving that packet (and check if it's for him) will switch to PTX and send another NOACK response packet , this NOACK contain the ACK and the ID of the PRX. 

    "NODE A" now in PRX mode, and can receive those response packets and can detect which PRX send the response. 

    This way it's much easier to implement as you don't have to modify the ESB protocol to receive ACK from multiple nodes. 

     

  • Hi Hung,

    When PTX (name Node-A) broadcast a packet without ACK, all of the three PRX (name Node B, C, D) will receive this packet.

    By your recommend, node-B, C, D should be delay a random time before switch to PTX and send a packet back to node-A.

    If  node B 's PTX buffer already have a packet (name packet-A), and it need to send a new packet (name packet-B) to Node-A, how can I drop packet-A when I execute "nrf_esb_write_payload()" function?

    Thank you,

    Chianglin

  • Hi Hung,

    Continue the previous question.  Node-A is working in PTX and Node-B,is working in PRX.

    If Node B's TX FIFO have one packet (name packet-A), and Node-A send a packet to Node-B.  Node-B will send ACK packet (the content is packet-A) no meter Node-A's "noack" flag is turn-on or turn-off. 

    Would you please tell me how to solve this problem?

    Thank you,

    Chianglin

Related