2023-04-28 10:00 AM
The default clock settings in CubeMX are:
High Speed Clock (HSE): BYPASS clock source
Low Speed Clock (LSE): Crystal/Ceramic oscillator
This causes the MCU to go into Error_Handler() after going into SystemClock_Config()
How to fix:
Change High Speed Clock (HSE) to Crystal/Ceramic oscillator
Low Speed Clock I think should be disabled.
2023-05-02 09:07 AM - edited 2023-11-20 06:50 AM
Hello @Community member
First let me thank you for posting.
I tried to reproduce the issue mentioned above but everything is working just fine .
Please check the screenshot :
Using CubeMX 6.8.1
After generating the code and debugging it , there is no Error_Handler()
I will be waiting for your feedback .
Thx
Ghofrane
2023-05-02 10:52 AM
Most of the DISCO / NUCLEO are BYPASS for HSE because the clock source is being feed via an 8 MHz feed from the ST-LINK/V2-1 or V3 (8.33 MHz) MCO pins.
Very free have the HSE *crystal* populated, and only those which do need OSC_OUT driven.
2024-06-27 12:39 PM
You are fully right ab.31 !.
STM CUBEMX 6.11 + Board STM32F411E-DISCO gives WRONG clock Setting by default.
and CORRECT SETTING is:
High Speed Clock (HSE) must be Crystal/Ceramic oscillator
Low Speed Clock disabled.