2024-03-13 11:29 AM
The target MCU on the NUCLEO-F446RE board receives its clock input directly from the on-board STLink-V2.1 probe (see clock signal MCO in figure below):
That's because the crystal X3 is not soldered on the board by default. So, when I launch a new project in CubeMX for this particular board, I would expect to see this reflected in the clock settings:
However, I see the following:
That's weird. The default selection is 'Crystal/Ceramic Resonator' while in fact, no high-speed crystal is soldered on the board.
Is this an error in CubeMX? If so, then the following .ioc file must be fixed:
C:/Program Files/STMicroelectronics/STM32Cube/STM32CubeMX/db/plugins/boardmanager/boards/A42_Nucleo_NUCLEO-F446RE_STM32F446RE_Board_AllConfig.ioc
Solved! Go to Solution.
2024-03-18 05:13 AM
If you want to have the HSE and LSE disabled on default generated code, Select No on the option "Initialize all peripherals with their default mode?":
But If you check Yes, LSE and HSE will be set to Crystal/Ceramic Resonator so you can start directly configuring and using them on your codes:
Best Regards.
STTwo-32
To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.
2024-03-13 12:01 PM
Hello @Kristof Mulier
I will escalate your request to the concerned team for review.
Best Regards.
STTwo-32
To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.
2024-03-14 06:02 AM - edited 2024-03-14 06:03 AM
Thank you very much @STTwo-32
I also noticed that having HSE set to "Crystal/Ceramic Resonator" in CubeMX results in a functional project (the LED blinks on my Nucleo board) - despite the fact that no crystal is soldered. So could it be that choosing either "BYPASS Clock Source" or "Crystal/Ceramic Resonator" doesn't matter after all?
Or maybe the board works, but the wrong setting causes the MCU to wear out quickly. I've heard stories that wrong crystal settings can result in a "functional" MCU that dies after one year instead of 10.
Kind regards,
Kristof
2024-03-15 01:14 AM - edited 2024-03-15 01:15 AM
Hello @Kristof Mulier
After checking, The default initialization of the HSE is Crystal/Ceramic Resonator but the clock source is configured to PLL_HSI. So, the HSE mode doesn't have any effect on the function.
Best Regards.
STTwo-32
To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.
2024-03-18 04:59 AM
Thank you @STTwo-32
However, it's still confusing that the default initialization of the HSE doesn't correspond to the clock source setting. Shouldn't STMicro change the default settings then, such that we're no longer confused?
2024-03-18 05:13 AM
If you want to have the HSE and LSE disabled on default generated code, Select No on the option "Initialize all peripherals with their default mode?":
But If you check Yes, LSE and HSE will be set to Crystal/Ceramic Resonator so you can start directly configuring and using them on your codes:
Best Regards.
STTwo-32
To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.