Return if UART not initialized
This commit is contained in:
@@ -91,6 +91,8 @@ int _write(int file, char *ptr, int len)
|
|||||||
|
|
||||||
void uart_debug_print(const char *fmt, ...)
|
void uart_debug_print(const char *fmt, ...)
|
||||||
{
|
{
|
||||||
|
if (huart1.gState == HAL_UART_STATE_RESET) return;
|
||||||
|
|
||||||
char buf[128];
|
char buf[128];
|
||||||
va_list args;
|
va_list args;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user