Home
last modified time | relevance | path

Searched refs:osrTemp (Results 1 – 2 of 2) sorted by relevance

/hal_nxp-3.5.0/mcux/mcux-sdk/drivers/lpsci/
Dfsl_lpsci.c222 uint32_t osrTemp; in LPSCI_Init() local
232 for (osrTemp = 4; osrTemp <= 32; osrTemp++) in LPSCI_Init()
235 sbrTemp = (srcClock_Hz / (config->baudRate_Bps * osrTemp)); in LPSCI_Init()
242 calculatedBaud = (srcClock_Hz / (osrTemp * sbrTemp)); in LPSCI_Init()
247 if (tempDiff > (config->baudRate_Bps - (srcClock_Hz / (osrTemp * (sbrTemp + 1))))) in LPSCI_Init()
249 tempDiff = config->baudRate_Bps - (srcClock_Hz / (osrTemp * (sbrTemp + 1))); in LPSCI_Init()
256 osr = osrTemp; /* update and store the best OSR value calculated*/ in LPSCI_Init()
356 uint8_t osrTemp; in LPSCI_SetBaudRate() local
365 for (osrTemp = 4; osrTemp <= 32; osrTemp++) in LPSCI_SetBaudRate()
368 sbrTemp = (srcClock_Hz / (baudRate_Bps * osrTemp)); in LPSCI_SetBaudRate()
[all …]
/hal_nxp-3.5.0/mcux/mcux-sdk/drivers/lpuart/
Dfsl_lpuart.c312 uint8_t osr, osrTemp; in LPUART_Init() local
324 for (osrTemp = 4U; osrTemp <= 32U; osrTemp++) in LPUART_Init()
327 … sbrTemp = (uint16_t)((srcClock_Hz * 10U / (config->baudRate_Bps * (uint32_t)osrTemp) + 5U) / 10U); in LPUART_Init()
342 calculatedBaud = (srcClock_Hz / ((uint32_t)osrTemp * (uint32_t)sbrTemp)); in LPUART_Init()
349 osr = osrTemp; /* update and store the best OSR value calculated */ in LPUART_Init()
640 uint8_t osr, osrTemp; in LPUART_SetBaudRate() local
652 for (osrTemp = 4U; osrTemp <= 32U; osrTemp++) in LPUART_SetBaudRate()
655 sbrTemp = (uint16_t)((srcClock_Hz * 10U / (baudRate_Bps * (uint32_t)osrTemp) + 5U) / 10U); in LPUART_SetBaudRate()
670 calculatedBaud = srcClock_Hz / ((uint32_t)osrTemp * (uint32_t)sbrTemp); in LPUART_SetBaudRate()
677 osr = osrTemp; /* update and store the best OSR value calculated */ in LPUART_SetBaudRate()