Skip to content

SystemCoreClock variable is updated in two ways only #96

@CanastraRF

Description

@CanastraRF

Dear Developer
in Drivers/CMSIS/Device/ST/Source/Templates/system_stm32l4xx.c
stands:

The SystemCoreClock variable is updated in three ways:
1) by calling CMSIS function SystemCoreClockUpdate()
2) by calling HAL API function HAL_RCC_GetHCLKFreq()
3) each time HAL_RCC_ClockConfig() is called to configure the system clock frequency

But HAL_RCC_GetHCLKFreq() does not update SystemCoreClock

Either fix the doc or the code

BTW:
HAL_RCC_GetSysClockFreq() and SystemCoreClockUpdate() are very similar
Can they merged together?

In HAL_RCC_GetSysClockFreq() are RCC_xxx_Pos used. In SystemCoreClockUpdate() are numerical Values used.
Please use in both case RCC_xxx_Pos.

Metadata

Metadata

Assignees

Labels

bugSomething isn't workinghalHAL-LL driver-related issue or pull-request.internal bug trackerIssue confirmed and logged into the internal bug tracking systemrccReset and Clock Controller

Type

Projects

Status

In progress

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions