<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://devzone.nordicsemi.com/cfs-file/__key/system/syndication/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>What distinguishes an ACK packet on-air from a regular packet?</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/756/what-distinguishes-an-ack-packet-on-air-from-a-regular-packet</link><description>I would like to implement a simple wireless sensor network, using Enhanced Shockburst with Auto-ACK. The idea is that there will be many sensor nodes (SNs) reporting to one master node (MN). The MN will listen on address P0 (say 0x0011223344) and all</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Mon, 25 Nov 2013 08:43:45 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/756/what-distinguishes-an-ack-packet-on-air-from-a-regular-packet" /><item><title>RE: What distinguishes an ACK packet on-air from a regular packet?</title><link>https://devzone.nordicsemi.com/thread/3815?ContentTypeID=1</link><pubDate>Mon, 25 Nov 2013 08:43:45 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c6c773ef-2cc4-4a40-95bc-343203aa0cde</guid><dc:creator>Bastiaan</dc:creator><description>&lt;p&gt;I use the same application of the module of esb.I also have some questions for that,can I talk about it with you?My QQ is  2962237677.can you add me and talk the problems with you ,thank you !&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: What distinguishes an ACK packet on-air from a regular packet?</title><link>https://devzone.nordicsemi.com/thread/3816?ContentTypeID=1</link><pubDate>Mon, 25 Nov 2013 08:43:45 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:0e67e477-0ecd-45a1-9164-e12e34faeaee</guid><dc:creator>Guest</dc:creator><description>&lt;p&gt;I use the same application of the module of esb.I also have some questions for that,can I talk about it with you?My QQ is  2962237677.can you add me and talk the problems with you ,thank you !&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: What distinguishes an ACK packet on-air from a regular packet?</title><link>https://devzone.nordicsemi.com/thread/3825?ContentTypeID=1</link><pubDate>Tue, 29 Oct 2013 09:42:04 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f88127d3-2dd8-4dae-99df-344cf645cd81</guid><dc:creator>H&amp;#229;kon Alseth</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;It took some digging, and you are correct. The ACK PID will always follow the PTX PID, so it&amp;#39;s reflected throughout the whole transaction.
It&amp;#39;s an added security that the ACK is actually addressed to your previous transmission.&lt;/p&gt;
&lt;p&gt;BR
Håkon&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: What distinguishes an ACK packet on-air from a regular packet?</title><link>https://devzone.nordicsemi.com/thread/3824?ContentTypeID=1</link><pubDate>Mon, 28 Oct 2013 16:09:18 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:7b7dbfe6-c152-4a59-bb12-bea6a702c5c2</guid><dc:creator>Ant Skelton</dc:creator><description>&lt;p&gt;Awesome, thanks!&lt;/p&gt;
&lt;p&gt;Isn&amp;#39;t the ACK PID the same as the PID for the REQ? e.g. section 3.4.10.6 shows &amp;quot;TX PID=1, ACK1, TX PID=1, ACK1, TX_PID=2, ACK2&amp;quot; ?&lt;/p&gt;
&lt;p&gt;I presume ESB will reject an ACK if the ACK_PID doesn&amp;#39;t match the REQ_PID...??&lt;/p&gt;
&lt;p&gt;cheers&lt;/p&gt;
&lt;p&gt;ant&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: What distinguishes an ACK packet on-air from a regular packet?</title><link>https://devzone.nordicsemi.com/thread/3823?ContentTypeID=1</link><pubDate>Mon, 28 Oct 2013 16:01:26 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:46110a29-a4c3-4928-8993-c113589b59f9</guid><dc:creator>H&amp;#229;kon Alseth</dc:creator><description>&lt;p&gt;Sorry, I seem to be a bit slow today.
If you do a &amp;quot;echo&amp;quot; of your payload, then the ACK-pld of 1 byte will be equal to the sent payload.
This means that your &amp;quot;answer B&amp;quot; is correct.&lt;/p&gt;
&lt;p&gt;Note: The PID field may be different, as this is a 2 bit counter which is incremented for every new transmission. You have a 25% chance of these being synchronous on PRX/PTX.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: What distinguishes an ACK packet on-air from a regular packet?</title><link>https://devzone.nordicsemi.com/thread/3822?ContentTypeID=1</link><pubDate>Mon, 28 Oct 2013 15:37:38 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b428abd2-e006-4b85-aad8-57587ec30a87</guid><dc:creator>Ant Skelton</dc:creator><description>&lt;p&gt;Thanks. However, I am interested in the case where I am sending an &lt;strong&gt;ACK&lt;u&gt;with&lt;/u&gt; a &lt;em&gt;payload&lt;/em&gt;&lt;/strong&gt;. This is what I meant by:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;This ACK has a single byte payload. The single byte payload is also the value 0x55, by some strange coincidence.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;.The rev1.6 datasheet says, section 3.4.6.1 &amp;quot;An ACK packet can contain an optional payload from PRX to PTX&amp;quot;.&lt;/p&gt;
&lt;p&gt;Also as per the diagram in section 3.4.10.4, which shows, on the PRX line, &amp;quot;ACK1|PAY&amp;quot;.&lt;/p&gt;
&lt;p&gt;How then is it possible for &amp;quot;len=0 so the payload field will not be present&amp;quot;?? How does PTX get the ACK payload?&lt;/p&gt;
&lt;p&gt;cheers&lt;/p&gt;
&lt;p&gt;ant&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: What distinguishes an ACK packet on-air from a regular packet?</title><link>https://devzone.nordicsemi.com/thread/3821?ContentTypeID=1</link><pubDate>Mon, 28 Oct 2013 15:25:35 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:28ba5e9b-1701-4ad7-b79e-54cffd2c9140</guid><dc:creator>H&amp;#229;kon Alseth</dc:creator><description>&lt;p&gt;The closest is answer B.
However, len = 0, so the payload field will not be present.
And therefore, the CRC will also be different.&lt;/p&gt;
&lt;p&gt;If you setup two PRX with the same RF config (EN_DPL/DYN_ACK enabled), and one PTX that sends whenever it can, you will sooner or later observe a payload of 0 byte on one of the PRX.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: What distinguishes an ACK packet on-air from a regular packet?</title><link>https://devzone.nordicsemi.com/thread/3820?ContentTypeID=1</link><pubDate>Mon, 28 Oct 2013 14:18:18 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:1fd10976-f29e-4c1f-8f25-bc0e80e431a8</guid><dc:creator>Ant Skelton</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;Thank you for the further info; it is interesting and illuminating, and answers the second point in my original post, but I am still unclear as to  &lt;em&gt;what distinguishes an ACK on-air from a regular data packet&lt;/em&gt;. My fault, I am not making the question sufficiently clear.&lt;/p&gt;
&lt;p&gt;A sensor sends a packet with a payload length of 1. EN_DPL is enabled, hence PCF[len] is equal to 1. The single payload byte is 0x55:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;    
PKT: { 
  addr: [011,0x22,0x33],   // three byte address
  PCF: {
     len:1,    // DPL is 1 byte
     PID: 1,                         
     NAK:0    // NO_ACK is FALSE for ESB
  }, 
  payload: [0x55],    // single payload byte
  CRC: x    // some 16-bit value
}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;ie  01010101, 00010001 00100010 00110011, 000001 01 0, 01010101, x&lt;/p&gt;
&lt;p&gt;A co-ordinator node receives this packet and sends an ACK. This ACK has a single byte payload. The single byte payload is also the value 0x55, by some strange coincidence. What does this ACK packet look like?&lt;/p&gt;
&lt;p&gt;Is it like this? (answer A)&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;    
PKT: { 
  addr: [0x11,0x22,0x33],   // return to sender
  PCF: {
    len:1,    //  DPL is 1 byte
    PID: 1,    // ACK PID same as REQ PID
    NAK:1    // NO_ACK is true!!
  }, 
  payload: [0x55],    // single payload byte
  CRC: y    // CRC must therefore be different!
}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;ie 01010101, 00010001 00100010 00110011, 000001 01 &lt;u&gt;1&lt;/u&gt;, 01010101,&lt;u&gt;y&lt;/u&gt;&lt;/p&gt;
&lt;p&gt;Or is it like this? (answer B)&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;    
PKT: { 
  addr: [0x11,0x22,0x33],   // return to sender
  PCF: {
    len:1,    // DPL 1 byte
    PID: 1,    // ACK PID same as REQ PID
    NAK:0    // NO_ACK is false here too!
  }, 
  payload: [0x55],     // single payload byte
  CRC: x    // CRC same as orig, therefore!
}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;ie 01010101, 00010001 00100010 00110011, 000001 01 &lt;u&gt;0&lt;/u&gt;, 01010101, &lt;u&gt;x&lt;/u&gt;&lt;/p&gt;
&lt;p&gt;This is my first question. What&amp;#39;s the format of the ACK? &amp;#39;A&amp;#39; or &amp;#39;B&amp;#39; ? Or something else?&lt;/p&gt;
&lt;p&gt;My second question: if it is &amp;#39;B&amp;#39;, how does PTX&amp;#39;s &lt;em&gt;internal ESB logic&lt;/em&gt; know this is an ACK? How can it tell ACK from a duplicate identical packet (same address, same length, same PID, same NAK, same payload, same CRC) sent by a second sensor, for example?&lt;/p&gt;
&lt;p&gt;Thanks for your help and patience!&lt;/p&gt;
&lt;p&gt;ant&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: What distinguishes an ACK packet on-air from a regular packet?</title><link>https://devzone.nordicsemi.com/thread/3819?ContentTypeID=1</link><pubDate>Mon, 28 Oct 2013 13:40:31 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:923f360d-1d2a-4d63-a9b8-8aa32a7e6e59</guid><dc:creator>H&amp;#229;kon Alseth</dc:creator><description>&lt;p&gt;If you have not enabled dynamic payload length, the payload will be equal to any other payload, except it is &amp;#39;0&amp;#39; in length.&lt;/p&gt;
&lt;p&gt;The whole PFC field will remain the same unless EN_DPL is set.&lt;/p&gt;
&lt;p&gt;Let&amp;#39;s say that two devices send almost at the same time. Host receives payload from Device#1. Both devices goes into RX mode, and receives the host&amp;#39;s ACK.
In this scenario, both devices will get a TX_DS interrupt, while the host only got one of the payloads.&lt;/p&gt;
&lt;p&gt;If you plan to have more devices communicate on the same pipe, with an extended address byte in firmware, then you will have to disable the hardware acking and do this in firmware instead.&lt;/p&gt;
&lt;p&gt;-H&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: What distinguishes an ACK packet on-air from a regular packet?</title><link>https://devzone.nordicsemi.com/thread/3818?ContentTypeID=1</link><pubDate>Mon, 28 Oct 2013 12:16:31 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:feed8090-4ed6-44a8-9397-f1e421ddc5a3</guid><dc:creator>Ant Skelton</dc:creator><description>&lt;p&gt;Hi thanks for the response, it is useful and informative. However, I would still like to know what distinguishes an ACK on-air from a regular data packet.&lt;/p&gt;
&lt;p&gt;Imagine a node has just sent a packet:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;PKT: { addr=[0xaa,0xbb,0xcc], PCF={len:1, NAK:0}, payload=[0x55], CRC=x}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;According to the ESB/PTX flowchart, the PTX is now in &lt;em&gt;&amp;quot;RX mode --&amp;gt; is it an ACK?&amp;quot;&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;Imagine that the ACK to this packet also has a payload, also one byte, also the value &amp;#39;0x55&amp;#39;.&lt;/p&gt;
&lt;p&gt;Does the ACK look like this:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;ACK: { addr=[0xaa,0xbb,0xcc], PCF={len:1, **NAK:0**}, payload=[0x55], CRC=x}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Or does it look like this:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;ACK: { addr=[0xaa,0xbb,0xcc], PCF={len:1, **NAK:1**}, payload=[0x55], **CRC=y**}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;In other words, how is the decision &lt;em&gt;&amp;quot;Is it an ACK?&amp;quot;&lt;/em&gt; actually made?&lt;/p&gt;
&lt;p&gt;And, depending on the answer to that, can the PTX ACK-check be fooled by an identical PKT sent from a different node?&lt;/p&gt;
&lt;p&gt;[I am using a single data-pipe in an attempt to keep the question simple; for my network I plan to use all available pipes as you suggest.]&lt;/p&gt;
&lt;p&gt;cheers&lt;/p&gt;
&lt;p&gt;ant&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: What distinguishes an ACK packet on-air from a regular packet?</title><link>https://devzone.nordicsemi.com/thread/3817?ContentTypeID=1</link><pubDate>Mon, 28 Oct 2013 11:13:05 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:4cf8f17a-cd2b-44e1-9f17-5acae078f668</guid><dc:creator>H&amp;#229;kon Alseth</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;You will get collisions in this scenario.
It is not recommended to have several devices using the same pipe (w/ACKing) communicating with one host.
An ACK payload is just a normal payload with no data. This will then include such things as PID/Addr/CRC etc.
Note that you cannot read out the PID values from the radio. If a valid packet has been received, you will only get the actual payload.&lt;/p&gt;
&lt;p&gt;You will have certain corner cases where Device#1 can get interference from Device#x.
If you were to build up a system like this, then you will have to time-slice the transmission from each device to make sure that they do not collide, which is a complicated thing to implement properly.&lt;/p&gt;
&lt;p&gt;The easiest way is to open more pipes, and have each device communicate using different RF addresses.&lt;/p&gt;
&lt;p&gt;-H&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>