TM STM32F4xx Libraries  v1.0.0
Libraries for STM32F4xx devices from Tilen Majerle
TM_RCC_Functions

Library Functions. More...

Functions

void TM_RCC_SetPLL (TM_RCC_PLL_t *PLL_Settings)
 Sets the main PLL settings for STM32F4xx device. More...
 
void TM_RCC_GetPLL (TM_RCC_PLL_t *PLL_Settings)
 Gets current PLL settings from RCC registers. More...
 
uint8_t TM_RCC_IsPLLReady (void)
 Checks if main PLL is ready. More...
 

Detailed Description

Library Functions.

Function Documentation

void TM_RCC_GetPLL ( TM_RCC_PLL_t PLL_Settings)

Gets current PLL settings from RCC registers.

Note
You can use this function to read current PLL settings before applying new settings
Parameters
*PLL_SettingsPointer to TM_RCC_PLL_t structure where PLL settings will be stored
Return values
None
uint8_t TM_RCC_IsPLLReady ( void  )

Checks if main PLL is ready.

Parameters
None
Return values
PLLready status:
  • 0: PLL is not ready
  • > 0: PLL is ready
void TM_RCC_SetPLL ( TM_RCC_PLL_t PLL_Settings)

Sets the main PLL settings for STM32F4xx device.

Note
PLL can only be configured when PLL is not used as system clock. For that purpose, this function does the following things:
  • Enables HSI as system core clock
  • Disables PLL
  • Sets PLL parameters passed as parameters in function
  • Enables PLL
  • Waits will PLL is ready and locked
  • Enables PLL as system core clock
  • Updates system core clock variable
Parameters
*PLL_SettingsPointer to TM_RCC_PLL_t structure with PLL settings. Use 0 for setting you don't want to change
Return values
None