ESB receive the data sent by itself

Hi all,

Question preconditions:

nRF52832, SDK 17.1.0, use FreeRTOS.

1 PTX and 2 PRX, PTX send heart beat to every PRX to receive the data from PRX.

Two PRX enable different pipe by nrf_esb_enable_pipes(bit_n).

.

Question.

I use the ESB to send data to two PRX every ms, when I use fixed data to accumulate and send it to PRX, It works fine I can receive data correctly in each side.

But when I send the data from UART to two PRX, the PRX side will not receive the correct data(from PTX) but will receive the data sent by itself.

I find the same question in Sometimes receiving the packages I am sending over ESB. But it didn't reply to fix the problem.

Hope you can give some suggestion.

Best regards,

Lurn

Parents Reply Children
  • Hi,

    Lurn_Z said:

     I get this problem again. And this problem will only appear when it is transmitted in two -way.

    Can you give me some suggestions?

    Not sure if you have made any progress on this. But, since it seems very application-specific, I think I would need an stripped down example of this, that reproducers the issue on 2-DK's to investigate this further.

  • Hi,

    Thanks for your reply, but now this problem is solved, I changed the buffer_t struct to use a uint8_t array for data rather than a pointer in IRQ callback, and do a memcpy to copy the data into this array before push it to the queue.

    The problem is that I'm not pushing the actual data into the queue, just pushing the pointers to the data. Then later on the original buffers where the data was stored might be overwritten as upload or receive something else, and then the data pointed to by the item in the queue will be different. 

    Best regards

    Lurn

Related