cancel
Showing results for 
Search instead for 
Did you mean: 

HAL_UART_Receive_IT is not working

KaushikSTM32
Visitor

Originally a reply in this thread - split as a separate question.


Hello 

My blocking mode is working with "HAL_UART_Receive(&huart4, temp, 1, 100);"

Nonblocking mode is not working

Can you suggest anything to check?

I have defined as said

 

/* USER CODE BEGIN 2 */

HAL_UART_Receive_IT(&huart4, temp, 1);

/* USER CODE END 2 */

 

and

 

/* USER CODE BEGIN 4 */

void HAL_UART_RxCpltCallback(UART_HandleTypeDef *huart)
{
  HAL_UART_Receive_IT(&huart4, temp, 1);
  HAL_UART_Transmit(&huart4, temp, 1, 100);
}

/* USER CODE END 4 */

 

10 REPLIES 10

Thank you so much sir,

I had signed off for today. I will confirm whether the above logic is working or not, tomorrow.