cancel
Showing results for 
Search instead for 
Did you mean: 

S2-LP How to RX IEEE 802.15.4g packet format?

JKo
Associate III

How do I get the expected payload length from the PHR?

The PHR isn't expected to be available after the SYNC_WORD detected interrupt so either the FIFO_RXAF threshold interrupt or RX_DATA_READY interrupt should indicate data in the RX FIFO and the length should have been saved from the PHR.

Is the PHR length during RX saved to the RX_PCKT_LEN registers (0xa4 & 0xa5) or the PCKTLEN registers (0x31 & 0x32)?

Is RX_DATA_READY interrupt actually generated when the number of bytes received matches length indicated by the PHR?

1 REPLY 1
JKo
Associate III

Answering my own question again. Through experimentation and debugging.

The PCKTLEN registers are not valid during RX.

The RX_PCKT_LEN registers are only valid when RX_DATA_READY interrupt is generated and contains the length from the PHR. RX_DATA_READY is only generated when the complete frame is written to the FIFO.

Since the length from the PHR includes the FCS the data available from the FIFO will be FCS length bytes less.

So to receive an IEEE 802.15.4g packet the RX_FIFO_STATUS number of bytes need to be read from the RX FIFO whenever RX_FIFO_ALMOST_FULL and RX_DATA_READY interrupts are indicated.