mirror of
https://github.com/Atmosphere-NX/Atmosphere.git
synced 2024-12-22 02:12:06 +00:00
thermosphere: uart fixes/ still not working
This commit is contained in:
parent
f6e1cff5f8
commit
e6adccce6e
2 changed files with 12 additions and 12 deletions
|
@ -68,10 +68,10 @@ static inline uint32_t get_clk_source_val(CarDevice dev) {
|
|||
|
||||
static inline uint32_t get_clk_source_div(CarDevice dev) {
|
||||
switch (dev) {
|
||||
case CARDEVICE_UARTA: return 1 << 24; // enable bit
|
||||
case CARDEVICE_UARTB: return 1 << 24; // enable bit
|
||||
case CARDEVICE_UARTC: return 1 << 24; // enable bit
|
||||
case CARDEVICE_UARTD: return 1 << 24; // enable bit
|
||||
case CARDEVICE_UARTA: return 0;
|
||||
case CARDEVICE_UARTB: return 0;
|
||||
case CARDEVICE_UARTC: return 0;
|
||||
case CARDEVICE_UARTD: return 0;
|
||||
case CARDEVICE_I2C1: return 0;
|
||||
case CARDEVICE_I2C5: return 0;
|
||||
case CARDEVICE_TZRAM: return 0;
|
||||
|
|
|
@ -26,26 +26,26 @@ void uart_config(UartDevice dev) {
|
|||
|
||||
switch (dev) {
|
||||
case UART_A:
|
||||
pinmux->uart1_rx = 0;
|
||||
pinmux->uart1_tx = (PINMUX_INPUT | PINMUX_PULL_UP);
|
||||
pinmux->uart1_tx = 0;
|
||||
pinmux->uart1_rx = (PINMUX_INPUT | PINMUX_PULL_UP);
|
||||
pinmux->uart1_rts = 0;
|
||||
pinmux->uart1_cts = (PINMUX_INPUT | PINMUX_PULL_DOWN);
|
||||
break;
|
||||
case UART_B:
|
||||
pinmux->uart2_rx = 0;
|
||||
pinmux->uart2_tx = (PINMUX_INPUT | PINMUX_PULL_UP);
|
||||
pinmux->uart2_tx = 0;
|
||||
pinmux->uart2_rx = (PINMUX_INPUT | PINMUX_PULL_UP);
|
||||
pinmux->uart2_rts = 0;
|
||||
pinmux->uart2_cts = (PINMUX_INPUT | PINMUX_PULL_DOWN);
|
||||
break;
|
||||
case UART_C:
|
||||
pinmux->uart3_rx = 0;
|
||||
pinmux->uart3_tx = (PINMUX_INPUT | PINMUX_PULL_UP);
|
||||
pinmux->uart3_tx = 0;
|
||||
pinmux->uart3_rx = (PINMUX_INPUT | PINMUX_PULL_UP);
|
||||
pinmux->uart3_rts = 0;
|
||||
pinmux->uart3_cts = (PINMUX_INPUT | PINMUX_PULL_DOWN);
|
||||
break;
|
||||
case UART_D:
|
||||
pinmux->uart4_rx = 0;
|
||||
pinmux->uart4_tx = (PINMUX_INPUT | PINMUX_PULL_UP);
|
||||
pinmux->uart4_tx = 0;
|
||||
pinmux->uart4_rx = (PINMUX_INPUT | PINMUX_PULL_UP);
|
||||
pinmux->uart4_rts = 0;
|
||||
pinmux->uart4_cts = (PINMUX_INPUT | PINMUX_PULL_DOWN);
|
||||
break;
|
||||
|
|
Loading…
Reference in a new issue