Lines Matching refs:clkdiv
318 uint32_t clkdiv; in USART_BaudrateAsyncSet() local
402 clkdiv = 4 * refFreq + (oversample * baudrate) / 2; in USART_BaudrateAsyncSet()
403 clkdiv /= oversample * baudrate; in USART_BaudrateAsyncSet()
404 clkdiv -= 4; in USART_BaudrateAsyncSet()
405 clkdiv *= 64; in USART_BaudrateAsyncSet()
408 clkdiv = 32 * refFreq + (oversample * baudrate) / 2; in USART_BaudrateAsyncSet()
409 clkdiv /= oversample * baudrate; in USART_BaudrateAsyncSet()
410 clkdiv -= 32; in USART_BaudrateAsyncSet()
411 clkdiv *= 8; in USART_BaudrateAsyncSet()
415 EFM_ASSERT(clkdiv <= CLKDIV_MASK); in USART_BaudrateAsyncSet()
418 clkdiv &= CLKDIV_MASK; in USART_BaudrateAsyncSet()
422 usart->CLKDIV = clkdiv; in USART_BaudrateAsyncSet()
454 uint32_t clkdiv, in USART_BaudrateCalc() argument
466 EFM_ASSERT(clkdiv <= CLKDIV_MASK); in USART_BaudrateCalc()
469 clkdiv &= CLKDIV_MASK; in USART_BaudrateCalc()
550 divisor = oversample * (256 + clkdiv); in USART_BaudrateCalc()
643 uint32_t clkdiv; in USART_BaudrateSyncSet() local
671 clkdiv = (refFreq - 1) / (2 * baudrate); in USART_BaudrateSyncSet()
672 clkdiv = clkdiv << 8; in USART_BaudrateSyncSet()
675 EFM_ASSERT(!(clkdiv & ~CLKDIV_MASK)); in USART_BaudrateSyncSet()
677 usart->CLKDIV = clkdiv; in USART_BaudrateSyncSet()