AnsweredAssumed Answered

How to receive UART fixed length datas in sequence

Question asked by paker earth on Jan 24, 2017
Latest reply on Jan 24, 2017 by Clive One

Hi all

 

I'd like to use UART to receive soe fixed length datas, ex."1234567890".

uint8_t buff[10]; 

hal_uart_receive_it(&huart, buff, 10); or hal_uart_receive_dma(&huart, buff, 10);

 

How should I do and then make sure the buff contain "1234567890" every time, not "5678901234" or other situation.

Thank you in advance. 

Outcomes