Solved
How the System clock is set in the files? I see uint32_t SystemCoreClock = 4000000U in system_stm32l4xx.c however I had set 120MHz in CubeMX for SysClock...
..
..
It is a placeholder. The part doesn't start at 120 MHz.
Once you actually call code to configure the clock sources and PLL, it back computes the RCC/PLL settings and HSI, MSI and HSE, and writes a value to the variable.
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.