MCPcopy Create free account
hub / github.com/CE-Programming/CEmu / uart_char_ticks

Function uart_char_ticks

core/uart.c:98–103  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

96}
97
98static 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
105static bool uart_timer_should_run(void) {
106 return uart.txActive || uart.rxTimeoutChars;

Callers 2

uart_set_timerFunction · 0.85
uart_eventFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected