Draft: lab 5 failed
This commit is contained in:
@@ -76,11 +76,13 @@ void uart_init(void)
|
||||
uart_readbuf = make_ringbuffer(UART_BUFLEN);
|
||||
uart_writebuf = make_ringbuffer(UART_BUFLEN);
|
||||
|
||||
_uart_enable_receive_interrupt(true);
|
||||
//uint64_t ier = *AUX_MU_IER;
|
||||
// _uart_enable_receive_interrupt(true);
|
||||
_uart_enable_receive_interrupt(false);
|
||||
_uart_enable_transmit_interrupt(false);
|
||||
// uint64_t ier = *AUX_MU_IER;
|
||||
|
||||
uart_getb = uart_getb_async;
|
||||
uart_putb = uart_putb_async;
|
||||
// uart_getb = uart_getb_async;
|
||||
// uart_putb = uart_putb_async;
|
||||
|
||||
is_uart_inited = true;
|
||||
}
|
||||
@@ -203,7 +205,7 @@ void uart_puts(const char *s)
|
||||
size_t len = strlen(s);
|
||||
size_t ret = uart_putb((const uint8_t *)s, len);
|
||||
if (ret != len)
|
||||
exit(ERR_IO_FAILED);
|
||||
panic(ERR_IO_FAILED);
|
||||
}
|
||||
|
||||
void uart_hex(uint64_t d)
|
||||
|
||||
Reference in New Issue
Block a user