mbed library sources
Dependents: frdm_kl05z_gpio_test
Fork of mbed-src by
Diff: targets/hal/TARGET_NXP/TARGET_LPC43XX/serial_api.c
- Revision:
- 283:bf0f62a62bf4
- Parent:
- 256:76fd9a263045
- Child:
- 285:31249416b6f9
diff -r 4abd2456cfa5 -r bf0f62a62bf4 targets/hal/TARGET_NXP/TARGET_LPC43XX/serial_api.c --- a/targets/hal/TARGET_NXP/TARGET_LPC43XX/serial_api.c Tue Aug 12 10:30:08 2014 +0100 +++ b/targets/hal/TARGET_NXP/TARGET_LPC43XX/serial_api.c Wed Aug 13 09:00:06 2014 +0100 @@ -31,45 +31,49 @@ ******************************************************************************/ #define UART_NUM 4 +// SCU mode for UART pins +#define SCU_PINIO_UART_TX SCU_MODE_PULLDOWN +#define SCU_PINIO_UART_RX SCU_PINIO_PULLNONE + static const PinMap PinMap_UART_TX[] = { - {P1_13, UART_1, (SCU_MODE_PULLDOWN | 1)}, - {P1_15, UART_2, (SCU_MODE_PULLDOWN | 1)}, - {P2_0, UART_0, (SCU_MODE_PULLDOWN | 1)}, - {P2_3, UART_3, (SCU_MODE_PULLDOWN | 2)}, - {P2_10, UART_2, (SCU_MODE_PULLDOWN | 2)}, - {P3_4, UART_1, (SCU_MODE_PULLDOWN | 4)}, - {P4_1, UART_3, (SCU_MODE_PULLDOWN | 6)}, - {P5_6, UART_1, (SCU_MODE_PULLDOWN | 4)}, - {P6_4, UART_0, (SCU_MODE_PULLDOWN | 2)}, - {P7_1, UART_2, (SCU_MODE_PULLDOWN | 6)}, - {P9_3, UART_3, (SCU_MODE_PULLDOWN | 7)}, - {P9_5, UART_0, (SCU_MODE_PULLDOWN | 7)}, - {PA_1, UART_2, (SCU_MODE_PULLDOWN | 3)}, - {PC_13, UART_1, (SCU_MODE_PULLDOWN | 2)}, - {PE_11, UART_1, (SCU_MODE_PULLDOWN | 2)}, - {PF_2, UART_3, (SCU_MODE_PULLDOWN | 1)}, - {PF_10, UART_0, (SCU_MODE_PULLDOWN | 1)}, + {P1_13, UART_1, (SCU_PINIO_UART_TX | 1)}, + {P1_15, UART_2, (SCU_PINIO_UART_TX | 1)}, + {P2_0, UART_0, (SCU_PINIO_UART_TX | 1)}, + {P2_3, UART_3, (SCU_PINIO_UART_TX | 2)}, + {P2_10, UART_2, (SCU_PINIO_UART_TX | 2)}, + {P3_4, UART_1, (SCU_PINIO_UART_TX | 4)}, + {P4_1, UART_3, (SCU_PINIO_UART_TX | 6)}, + {P5_6, UART_1, (SCU_PINIO_UART_TX | 4)}, + {P6_4, UART_0, (SCU_PINIO_UART_TX | 2)}, + {P7_1, UART_2, (SCU_PINIO_UART_TX | 6)}, + {P9_3, UART_3, (SCU_PINIO_UART_TX | 7)}, + {P9_5, UART_0, (SCU_PINIO_UART_TX | 7)}, + {PA_1, UART_2, (SCU_PINIO_UART_TX | 3)}, + {PC_13, UART_1, (SCU_PINIO_UART_TX | 2)}, + {PE_11, UART_1, (SCU_PINIO_UART_TX | 2)}, + {PF_2, UART_3, (SCU_PINIO_UART_TX | 1)}, + {PF_10, UART_0, (SCU_PINIO_UART_TX | 1)}, {NC, NC, 0} }; static const PinMap PinMap_UART_RX[] = { - {P1_14, UART_1, (SCU_PINIO_PULLNONE | 1)}, - {P1_16, UART_2, (SCU_PINIO_PULLNONE | 1)}, - {P2_1, UART_0, (SCU_PINIO_PULLNONE | 1)}, - {P2_4, UART_3, (SCU_PINIO_PULLNONE | 2)}, - {P2_11, UART_2, (SCU_PINIO_PULLNONE | 2)}, - {P3_5, UART_1, (SCU_PINIO_PULLNONE | 4)}, - {P4_2, UART_3, (SCU_PINIO_PULLNONE | 6)}, - {P5_7, UART_1, (SCU_PINIO_PULLNONE | 4)}, - {P6_5, UART_0, (SCU_PINIO_PULLNONE | 2)}, - {P7_2, UART_2, (SCU_PINIO_PULLNONE | 6)}, - {P9_4, UART_3, (SCU_PINIO_PULLNONE | 7)}, - {P9_6, UART_0, (SCU_PINIO_PULLNONE | 7)}, - {PA_2, UART_2, (SCU_PINIO_PULLNONE | 3)}, - {PC_14, UART_1, (SCU_PINIO_PULLNONE | 2)}, - {PE_12, UART_1, (SCU_PINIO_PULLNONE | 2)}, - {PF_3, UART_3, (SCU_PINIO_PULLNONE | 1)}, - {PF_11, UART_0, (SCU_PINIO_PULLNONE | 1)}, + {P1_14, UART_1, (SCU_PINIO_UART_RX | 1)}, + {P1_16, UART_2, (SCU_PINIO_UART_RX | 1)}, + {P2_1, UART_0, (SCU_PINIO_UART_RX | 1)}, + {P2_4, UART_3, (SCU_PINIO_UART_RX | 2)}, + {P2_11, UART_2, (SCU_PINIO_UART_RX | 2)}, + {P3_5, UART_1, (SCU_PINIO_UART_RX | 4)}, + {P4_2, UART_3, (SCU_PINIO_UART_RX | 6)}, + {P5_7, UART_1, (SCU_PINIO_UART_RX | 4)}, + {P6_5, UART_0, (SCU_PINIO_UART_RX | 2)}, + {P7_2, UART_2, (SCU_PINIO_UART_RX | 6)}, + {P9_4, UART_3, (SCU_PINIO_UART_RX | 7)}, + {P9_6, UART_0, (SCU_PINIO_UART_RX | 7)}, + {PA_2, UART_2, (SCU_PINIO_UART_RX | 3)}, + {PC_14, UART_1, (SCU_PINIO_UART_RX | 2)}, + {PE_12, UART_1, (SCU_PINIO_UART_RX | 2)}, + {PF_3, UART_3, (SCU_PINIO_UART_RX | 1)}, + {PF_11, UART_0, (SCU_PINIO_UART_RX | 1)}, {NC, NC, 0} };