2025-05-28 8:42 AM - last edited on 2025-05-28 12:36 PM by Pavel A.
Hello,
I followed https://community.st.com/t5/stm32-mcus/how-to-create-a-project-for-stm32h7-with-ethernet-and-lwip-stack/ta-p/49308 tutorial from the scratch to the end, including the Hello UDP part, and adding the "ETH CODE" code.
However, I can't ping my board.
After some debug, I found that I am locked in HAL_MspInit.
I tried this on 2 eval boards, with same results. I do not have further ideas to try.
Please find attached my projects.
Also, I wanted to know if FreeRTOS is mandatory for a project using Ethernet ?
If somebody have a "plug and play" project for STM32H757, I would be happy to try it out.
Thank you very much,
Matteo
Solved! Go to Solution.
2025-06-05 5:54 AM - edited 2025-06-05 5:55 AM
Hello,
0x1ff0a754 is at the bootloader range.
Check the SW1 switch position on the board:
Put it at the position 0
And with cube programmer check the Boot address in options bytes:
Mainly for BOOT=0 for CM7.
2025-06-05 7:39 AM
@mƎALLEm ,
Thank you very much, switching Sw1 worked.
Do you know why ? I thought it was irrelevant for this issue, since it was only changing the boot option ?
(Sorry for when I told I checked the jumper, I mainly checked JP5 and JP10 since I only saw these 2 as relevant for ethernet or board issue).
2025-06-05 7:44 AM - edited 2025-06-05 7:50 AM
@Matteo-uC wrote:
@mƎALLEm ,
Thank you very much, switching Sw1 worked.
Do you know why ?
SW1 is to select the boot mode:
If Boot0 = 0, the MCU boots from the user flash.
If Boot0 = 1, the MCU boots from the bootloader.
So in your case, your MCU didn't execute your application but the bootloader.
2025-06-05 7:52 AM
Thanks.
The bootloader isn't supposed to, after booting, linking to the application ?
2025-06-05 8:10 AM - edited 2025-06-05 8:26 AM
The bootloader is intended to be executed if a condition is met one of them BOOT0 = 1 and the address in the option byte is set to an address starting from something 0x1FFxxxx. It doesn't give the hand to the application. You need to set Boot0 = 0 and reset the MCU to jump to the application.
And in your case the debugger is resetting the MCU. As Boot0 = 1, that state will be latched by MCU to proceed to the bootloader and still in that state until the next reset reading the BOOT0 pin to decide it it should jump to the application or to the bootloader.