.out_buff = {0},
.sending = 0,
.out_lock = 0,
- .rx_callback = 0,
+ .rx_callback = NULL,
.capabilities = (SERIAL_CAP_UART | SERIAL_CAP_RS485),
.current_mode = SERIAL_MODE_UART,
},
.out_buff = {0},
.sending = 0,
.out_lock = 0,
- .rx_callback = 0,
+ .rx_callback = NULL,
.capabilities = (SERIAL_CAP_UART | SERIAL_CAP_IRDA),
.current_mode = SERIAL_MODE_UART,
},
uart_clk_off(uart_num);
/* Turn Off power */
subsystem_power(uart->power_offset, 0);
+ uarts[uart_num].rx_callback = NULL;
}
#define LPC_UART_ENABLE_DLAB (0x01 << 7)
/* FIFO Control Register */
#define LPC_UART_FIFO_EN (0x01 << 0)
-#define LPC_UART_TX_CLR (0x01 << 1)
-#define LPC_UART_RX_CLR (0x01 << 2)
+#define LPC_UART_RX_CLR (0x01 << 1)
+#define LPC_UART_TX_CLR (0x01 << 2)
+#define LPC_UART_DMA_MODE_EN (0x01 << 3)
#define LPC_UART_FIFO_TRIG(x) ((x & 0x03) << 6) /* 1 / 4 / 8 / 14 chars */
/* Interrupt Enable Register */
#define LPC_UART_RX_INT_EN (0x01 << 0)