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

RX_DR interrupt doesn't fire when ACK payload is in FIFO

Hello,

I have some problem with NRF24L01+. I'm trying to make bidirectional connection between two devices with this chip. When I'm sending payload with ACK, TX_DS interrupt on PRX fire but RX_DR on PTX doesn't. I know that i have got this data because FIFO RX isn't empty. What condition should be fulfilled to RX_DR interrupt fire on ongoing data with ACK? Should I manually change state to PRIM_RX for checking moment?

Parents
  • It sounds like you are receiving the ACK and the payload at the same time. This will cause the STATUS register to be 0x6? (bit 5 and 6 set). If you do not clear this properly by reading the register, masking with 0x70, then writing back, the bit will always be set. If you then read out a payload from the FIFO (which is not there), you will execute an illegal operation seen from the radio statemachine.

    Can you post your code?

  • Ok, i found my mistake. Very dumb mistake. After TX_DS interrupt fire, I was cleaning it. Clearing by getting old STATUS value (0x30 well RX_DR was ok), mask it with (1 << TX_DS) and write to STATUS. When I get old value, I was cleaning also RX_DR. :( So everything is ok.

    But I have one more question. Now I get RX_DR interrupt, then getting RX FIFO and my RX_DR is clearing automatically with buffor. Is it normal, or I'm making another mistake? ;)

Reply
  • Ok, i found my mistake. Very dumb mistake. After TX_DS interrupt fire, I was cleaning it. Clearing by getting old STATUS value (0x30 well RX_DR was ok), mask it with (1 << TX_DS) and write to STATUS. When I get old value, I was cleaning also RX_DR. :( So everything is ok.

    But I have one more question. Now I get RX_DR interrupt, then getting RX FIFO and my RX_DR is clearing automatically with buffor. Is it normal, or I'm making another mistake? ;)

Children
No Data
Related