cc2538: uart: Make it possible to use several UARTs simultaneously
This avoids the limitation of having a single UART available at runtime, without duplicating code. Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
This commit is contained in:
parent
db754a57d7
commit
d93d129da6
12 changed files with 353 additions and 146 deletions
|
@ -81,16 +81,8 @@ void usb_isr(void);
|
|||
|
||||
/* Likewise for the UART[01] ISRs */
|
||||
#if UART_CONF_ENABLE
|
||||
void uart_isr(void);
|
||||
|
||||
#if UART_BASE==UART_1_BASE
|
||||
#define uart0_isr default_handler
|
||||
#define uart1_isr uart_isr
|
||||
#else
|
||||
#define uart0_isr uart_isr
|
||||
#define uart1_isr default_handler
|
||||
#endif
|
||||
|
||||
void uart0_isr(void);
|
||||
void uart1_isr(void);
|
||||
#else /* UART_CONF_ENABLE */
|
||||
#define uart0_isr default_handler
|
||||
#define uart1_isr default_handler
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue