Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Fork of mbed-src by
Diff: targets/hal/TARGET_NXP/TARGET_LPC176X/serial_api.c
- Revision:
- 20:4263a77256ae
- Parent:
- 13:0645d8841f51
--- a/targets/hal/TARGET_NXP/TARGET_LPC176X/serial_api.c Mon Aug 19 18:17:02 2013 +0300 +++ b/targets/hal/TARGET_NXP/TARGET_LPC176X/serial_api.c Tue Sep 10 15:14:19 2013 +0300 @@ -283,11 +283,6 @@ void serial_putc(serial_t *obj, int c) { while (!serial_writable(obj)); obj->uart->THR = c; - - uint32_t lsr = obj->uart->LSR; - lsr = lsr; - uint32_t thr = obj->uart->THR; - thr = thr; } int serial_readable(serial_t *obj) { @@ -299,7 +294,8 @@ } 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 }