[LPC1768] Fix serial_clear

serial_clear() erroneously disabled the UART FIFOs.
Reported by Adam Green.
pull/61/merge
Bogdan Marinescu 2013-09-09 12:28:11 +03:00
parent e03e337af6
commit fded46b459
1 changed files with 2 additions and 1 deletions

View File

@ -299,7 +299,8 @@ int serial_writable(serial_t *obj) {
}
void serial_clear(serial_t *obj) {
obj->uart->FCR = 1 << 1 // rx FIFO reset
obj->uart->FCR = 1 << 0 // FIFO Enable - 0 = Disables, 1 = Enabled
| 1 << 1 // rx FIFO reset
| 1 << 2 // tx FIFO reset
| 0 << 6; // interrupt depth
}