Page 1 of 1

STM32_PPRE1/STM32_PPRE2 settings

Posted: Fri Feb 28, 2014 2:26 pm
by Tabulous
Hi can someone explain these to me please

STM32F417 is my MCU

#define STM32_HPRE STM32_HPRE_DIV1
#define STM32_PPRE1 STM32_PPRE1_DIV4
#define STM32_PPRE2 STM32_PPRE2_DIV2

I believe they are the APB1/2 clock pre-scalers ?

What im trying to achieve is the following

UART1 = 4800 Baud
UART6 = 115200 Baud
UART2 = 115200 Baud
UART3 = 1200 Baud

Now UART2/3 are on APB1 and UART1/6 are on APB2

What pre-scalers would achieve this ?

Re: STM32_PPRE1/STM32_PPRE2 settings

Posted: Fri Feb 28, 2014 2:49 pm
by Giovanni
PPRE1 and PPRE2, those names are the ones used on the RM in the RCC CFGR register description.

Giovanni