nrf24lu1p PRX can't receive data in pipe4 and pipe5

Hi, I implement a dongle that connects multiple devices with MultiCeiver. pipe 0 used for pair, pipe1 ~pipe5 used for device connect. dongle work in PRX, mode, device work in PTX mode. But when the device assigned pipe4 or pipe5 send payload,  dongle can't receive any data. while dongle can enter rf interrupt, and Data Ready RX FIFO interrupt(RX_DR) being set 1, but Data pipe number(RX_P_NO) is 0.

Parents
  • Hi,

     

    But when the device assigned pipe4 or pipe5 send payload,  dongle can't receive any data. while dongle can enter rf interrupt, and Data Ready RX FIFO interrupt(RX_DR) being set 1, but Data pipe number(RX_P_NO) is 0.

    What addresses are being set on all pipes?

     

    How are you reading out the pipe information?

    Please also take this note in the PS (chapter 8.5) into consideration:

    Note: The 3 bit pipe information in the STATUS register is updated during the IRQ pin high to low
    transition. The pipe information is unreliable if the STATUS register is read during an IRQ pin
    high to low transition.

     

    Kind regards,

    Håkon

Reply
  • Hi,

     

    But when the device assigned pipe4 or pipe5 send payload,  dongle can't receive any data. while dongle can enter rf interrupt, and Data Ready RX FIFO interrupt(RX_DR) being set 1, but Data pipe number(RX_P_NO) is 0.

    What addresses are being set on all pipes?

     

    How are you reading out the pipe information?

    Please also take this note in the PS (chapter 8.5) into consideration:

    Note: The 3 bit pipe information in the STATUS register is updated during the IRQ pin high to low
    transition. The pipe information is unreliable if the STATUS register is read during an IRQ pin
    high to low transition.

     

    Kind regards,

    Håkon

Children
  • Addresses being set as PS(chapter7 Figure 13), pipe 0 is a fixed public  address, pipes 1-5 share the four most significant address bytes generated by dongle, The LSByte is 0x33 + pipe_number。

    The nrf_isr code as follow, data is read out by usb port.

    • NRF_ISR()
      {
          uint8_t irq_flags;
          uint16_t rx_info;
      	uint8_t xdata rf_in_buf[32];
      	uint8_t pipe_src;
      	uint8_t len;
          irq_flags = hal_nrf_get_clear_irq_flags();
      		
      	if(irq_flags & (1 << (uint8_t)HAL_NRF_RX_DR))
      	{
      		
      		while (!hal_nrf_rx_fifo_empty()) 
      		{ 
      			LED = ~LED;
      			rx_info = hal_nrf_read_rx_payload(rf_in_buf);
      			pipe_src = (uint8_t)(rx_info>>9 &  0x07);
      			len = (uint8_t)(rx_info & 0xff);
      #if 1
      			raw_hid_buff[0] = rx_info >> 0xff;
      			raw_hid_buff[1] = len;
      			raw_hid_buff[2] = irq_flags;
      			if(len > 0)
      			{
      				memcpy(raw_hid_buff+3, rf_in_buf, len);
      			}
      			usb_raw_data_send(raw_hid_buff,32);		//
      #endif
      			if(pipe_src <= 5 && len>0)
      			{
      				fap_rx_isr(pipe_src, len, rf_in_buf);
      			}
      			else
      			{
      				hal_nrf_flush_rx();
      				break;
      			}
          }
      	}
      }
  • Hi,

     

    You should read the payload width first, and flush the packet if it is equal to 0 bytes or greater than 32 bytes:

    len = hal_nrf_read_rx_payload_width();
    if (len == 0 || len > 32) {
        /* flush RX FIFO */
    }

     

    SimonYao said:
    pipe 0 is a fixed public  address, pipes 1-5 share the four most significant address bytes generated by dongle,

    It is very important that none of the pipes LSByte are equal, this includes the unique pipe 0. Here from the PS chapter 7.6:

    The LSByte must be unique for all six pipes.

     

    Is the content of the data when you're reading the payload valid?

     

    Kind regards,

    Håkon

Related