mirror of
https://github.com/apache/nuttx.git
synced 2026-09-27 18:58:27 +08:00
Fix initiali interrupt issue
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@947 42af7a65-404d-4744-a932-0658087f49c3
This commit is contained in:
@@ -61,8 +61,6 @@
|
|||||||
* Definitions
|
* Definitions
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
|
|
||||||
#define BASE_BAUD 38400
|
|
||||||
|
|
||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* Private Types
|
* Private Types
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
@@ -356,6 +354,15 @@ static int up_setup(struct uart_dev_s *dev)
|
|||||||
up_serialout(priv, LPC214X_UART_FCR_OFFSET,
|
up_serialout(priv, LPC214X_UART_FCR_OFFSET,
|
||||||
(LPC214X_FCR_FIFO_TRIG8|LPC214X_FCR_TX_FIFO_RESET|\
|
(LPC214X_FCR_FIFO_TRIG8|LPC214X_FCR_TX_FIFO_RESET|\
|
||||||
LPC214X_FCR_RX_FIFO_RESET|LPC214X_FCR_FIFO_ENABLE));
|
LPC214X_FCR_RX_FIFO_RESET|LPC214X_FCR_FIFO_ENABLE));
|
||||||
|
|
||||||
|
/* The NuttX serial driver waits for the first THRE interrrupt before
|
||||||
|
* sending serial data... However, it appears that the lpc214x hardware
|
||||||
|
* does not generate that interrupt until a transition from not-empty
|
||||||
|
* to empty. So, the current kludge here is to send one NULL at
|
||||||
|
* startup to kick things off.
|
||||||
|
*/
|
||||||
|
|
||||||
|
up_serialout(priv, LPC214X_UART_THR_OFFSET, '\0');
|
||||||
#endif
|
#endif
|
||||||
return OK;
|
return OK;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user