SERIOUS Problem with clock configuration STM32L051K6U6TR
Hi community,
I have a serious problem with this microcontroller STM32L051K6U6TR.
I have created a code using STM32CubeIDE and based on STM32CubMX wizard creator, however, the clock is set up to match the microcontroller & its peripherals (USART, I2C, ..) clock requirements as shown this photo :
The generated code is compiled and flashed to the microcontroller without any error. I just tried this code :
thr problem is that the microcontroller gets crached. After debugging the code, I released that this issue is coming from HAL_Delay, because if I try the code without it, the proble is gone. Finally, I released that any call of a function or setting that uses the Clock of the CPU, the craching of the code occurs. I played a lot with the clock configuration in CubeMX to solve it but the same problem is still there, because I'm still thinking that maybe the clock setting generated by the CuBeMX is not supported physically by the microcontroller.
Did anyone face a simular issue ? Any suggestion might be a great help.
