zephyrproject-rtos / zephyr

Primary Git Repository for the Zephyr Project. Zephyr is a new generation, scalable, optimized, secure RTOS for multiple hardware architectures.
https://docs.zephyrproject.org
Apache License 2.0
10.45k stars 6.4k forks source link

Older stm32 (nucleo) boards without 8MHz ST-LINK clock do not work #50440

Open thedjnK opened 1 year ago

thedjnK commented 1 year ago

Describe the bug Older STM32 nucleo board, C-01, do not work with the default zephyr boards files, this is due to the default using an 8MHz clock provided by the ST-LINK chip, which on the C-01 boards is not connected. A possible fix is to have board revisions whereby building for e.g. nucleo_f401re@C-01 will build using the internal 16MHz clock source.

To Reproduce Build for any C-01 nucleo board and flash

Expected behavior The board to work

Impact Annoyance

Environment (please complete the following information):

erwango commented 1 year ago

Moving this to "Feature Request" as it's coming down to supporting a new board revision.

FRASTM commented 1 year ago

On the MB1136 C01 board schematic, the reason is probably that MCO signal is open (SB16 and/or SB50 not present on the PCB neither the 8MHz crystal on X3). A possible hardware WA is to close solder bridge. "The board marking MB1136 C-01 corresponds to a board, configured as HSE not used." "The board marking MB1136 C-02 (or higher) corresponds to a board, configured to use ST-LINK MCO as the clock input"

FRASTM commented 1 year ago

The board_porting does not explicitely mention a format like "C01" --> to accept this, the ./cmake/modules/extensions.cmake has to be modified to accept a BOARD_REV_FORMAT == LETTER_AND_NUMBER

--> see https://github.com/FRASTM/zephyr/tree/board_rev

zephyrbot commented 6 months ago

Hi @erwango,

This issue, marked as an Feature Request, was opened a while ago and did not get any traction. Please confirm the issue is correctly assigned and re-assign it otherwise.

Please take a moment to review if the issue is still relevant to the project. If it is, please provide feedback and direction on how to move forward. If it is not, has already been addressed, is a duplicate, or is no longer relevant, please close it with a short comment explaining the reason.

@thedjnK you are also encouraged to help moving this issue forward by providing additional information and confirming this request/issue is still relevant to you.

Thanks!