| 96 | } |
| 97 | |
| 98 | static uint32_t uart_char_ticks(void) { |
| 99 | uint32_t divisor = (uint16_t)(uart.divisor - 1) + 1; |
| 100 | /* Start + Character + Parity + Stop */ |
| 101 | uint32_t bits = 1 + 5 + (uart.lcr >> 0 & 3) + (uart.lcr >> 3 & 1) + 1 + (uart.lcr >> 2 & 1); |
| 102 | return divisor * bits; |
| 103 | } |
| 104 | |
| 105 | static bool uart_timer_should_run(void) { |
| 106 | return uart.txActive || uart.rxTimeoutChars; |
no outgoing calls
no test coverage detected