nrf5340 uart rx buffer size increasing

Hi

I am using NRF5340 chip in my custom board to communicate serially with an external device whose data length is more than 128 bytes.

The chip can receive 243 bytes of the external device in two bursts. The total number of data bytes is correct but the data has become 

corrupted due to some sort of data shifting. The interesting thig is that I can receive data  correctly only once after programing the chip.

Is this because of uart rx buffer size? How can I increase this buffer size in nrf5340. Any data size below 128 bytes can be received 

correctly.

Best Regards 

   .

Parents
  • Hi

    Actually in nrf5340 there is a parameter UART_BUF_SIZE which is defined by default equal to 256. I couldn't find any explicit

    definition for rx buffer size for nrf5340. I think this parameter is for both rx and tx buffer sizes each one equal to 128 which in

    total makes 256.

    Any how by doubling this number to 512 my problem was solved and the chip could receive more than 200 bytes in one turn

    and there is no data corruption any more.

    B.R. 

Reply
  • Hi

    Actually in nrf5340 there is a parameter UART_BUF_SIZE which is defined by default equal to 256. I couldn't find any explicit

    definition for rx buffer size for nrf5340. I think this parameter is for both rx and tx buffer sizes each one equal to 128 which in

    total makes 256.

    Any how by doubling this number to 512 my problem was solved and the chip could receive more than 200 bytes in one turn

    and there is no data corruption any more.

    B.R. 

Children
No Data
Related