Created
June 20, 2020 21:58
-
-
Save mattheweshleman/589f4e3243b29499b4df6e3b55884fbd to your computer and use it in GitHub Desktop.
loopingForStatus
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//https://github.com/STMicroelectronics/STM32CubeF7/blob/master/Drivers/STM32F7xx_HAL_Driver/Src/stm32f7xx_hal_uart.c | |
HAL_StatusTypeDef UART_WaitOnFlagUntilTimeout(UART_HandleTypeDef *huart, uint32_t Flag, FlagStatus Status, | |
uint32_t Tickstart, uint32_t Timeout) | |
{ | |
/* Wait until flag is set */ | |
while ((__HAL_UART_GET_FLAG(huart, Flag) ? SET : RESET) == Status) | |
{ | |
/* Check for the Timeout */ | |
//removed for this example | |
} | |
return HAL_OK; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment