}
return(HW_REG(uart_base[uartno]+UARTFR_OFFSET)&_BV(UART_RXFE))?0:1;
}
+
+
+void uart_flush(uint8_t uartno){
+ if(uartno>UART_MAX){
+ return;
+ }
+ while(circularbytebuffer_cnt(&(uart_tx_buffer[uartno])))
+ ;
+ while((HW_REG(uart_base[uartno]+UARTCTL_OFFSET)&_BV(UART_EOT)) == 0)
+ ;
+}