[HAL][KSDK] Fix first serial char not being sent

The K64F/K22F didn't send the first char. I don't know why exactly, but
any type of reading a status register seems to fix it. And this extra
line at least makes sense. Now it works correctly.
pull/677/head
Sissors 2014-11-09 19:40:29 +01:00
parent cc3456f254
commit 57a79c08a9
1 changed files with 1 additions and 0 deletions

View File

@ -75,6 +75,7 @@ void serial_init(serial_t *obj, PinName tx, PinName rx) {
stdio_uart_inited = 1; stdio_uart_inited = 1;
memcpy(&stdio_uart, obj, sizeof(serial_t)); memcpy(&stdio_uart, obj, sizeof(serial_t));
} }
while(!UART_HAL_IsTxDataRegEmpty(uart_addrs[obj->index]));
} }
void serial_free(serial_t *obj) { void serial_free(serial_t *obj) {