2023-11-06 06:37 PM - edited 2023-11-07 05:49 PM
Hi Madam/Sir,
We recently developed a custom board using STM32H747. The designs and schematic were based on Portenta H7 and the disco board. We received the board from PCBWay and confirmed that hardware-wise, it's okay and was proven electrically correct. However, upon loading even a simple LED toggle program on M7, the board suddenly was inaccessible, so I had to power cycle it by pulling the Boot0 to VDD. I was able to do that and erase the chip's program.
However, the next time I try to load it again, it becomes corrupted again I found out that the Loading on M7 alone is ok but gets weird on M4 core. I scoured the tutorials regarding proper debugging and also tried to uncheck/check the HALT of all Cores on debugging but to no avail. I attached the screenshots of relevant info that may help me fish out where I went wrong.
Please help me, I desperately need this board to work. Im willing to share my schematic design on this.
Thanks,
Ian
[Updates], I debugged by step my program, M7 only, disabling the M4, and found out that the SMPS that I selected on .oic was wrong, corrected it then the program works now. However, integrating the M4 program still gives an issue "SIGTRAP" as shown on the attached image. I hope someone can help me with this. Thanks
Solved! Go to Solution.
2023-11-09 02:57 AM
Hi @ICMosquera ,
In fact when using SMPS you can't exceed 400Mhz in D1 domain @VOS1 and D2 is the half clock of D1 domain (200Mhz).
2023-11-07 10:50 PM - edited 2023-11-09 06:51 AM
@SofLit May be you have an idea ?
thank you .
2023-11-08 01:07 AM
Hello @ICMosquera ,
First of all you need to tell us, what is the system frequency you are using? Your voltage scale is set to VOS1 so you can't exceed 400MHz.
Second, You've configured the power supply in EXTERNAL_SOURCE_SUPPLY. Are you sure?
Check your HW and see what is the power supply config your board is mounted to (refer to the Figure 22 in RM0399):
According to your power config in CubeMX it's the 6th config (Bypass config).
2023-11-08 05:32 PM
Hi @SofLit ,
Thank you for the reply.
1. Im using 400Mhz before, now that you mentioned it, ill try to lower it to 200MHz. Currently, my voltage scale is VOS1. This might solve my issue on M4. Ill test this later and get back if this works.
2. Yes power supply, my bad, I changed it now, my SMPS is like that of Figure 4. I found out this works now.
2023-11-09 02:57 AM
Hi @ICMosquera ,
In fact when using SMPS you can't exceed 400Mhz in D1 domain @VOS1 and D2 is the half clock of D1 domain (200Mhz).
2023-11-09 05:55 PM
Hi, @SofLit ,
Thanks so much for the info. I managed to test my M7 working with the modified power Supply config, matching my hardware. May I ask what reference manual I can refer to when deciding what clock to use with the SMPS configuration?
Moving forward, my next goal is to get the M4 core to work with the correct power configuration. However, I get an error right after the HAL_Delay inside the while loop. This breaks the loop. May I ask what caused this error, see image.
Thanks,
Ian
2023-11-13 03:41 AM
Hi @ICMosquera ,
Please refer to RM0399 (reference manual) for STM32H747 product.
Now regarding M4, I suggest you to write a very simple code on CM4 side without any low power mode or hardware semaphore.
Move your system clock config from M4 side (for example blinking a LED) and disable M7 from option bytes using CubeProgrammer (BE SURE YOU DON'T ALSO DISABLE CM4 CORE)
M4 should run.
Regarding the debug in dual core is a bit tricky but you can refer to this video.
Also see the this application note (STM32H7x5/x7 dual-core microcontroller debugging).
2023-11-14 06:10 PM
I did what you suggested, moved my simple toggle code to the M4 core, disabled hardware semaphore and other unnecessary lines leaving only the GPIO initialization and other stuff generated by the IDE, and then rebuilt it.
However, my problem is that when I unchecked the BCM7, and applied it on my board using the cubeprogrammer, the chip broke. Now I cannot even connect with my cubeprogrammer. I tried to pull up to boot0 to VDD, but it says it cannot reset the chip. then I pulled up the RST too, but still, I could not connect.
How sad I cannot verify this on my other board coz that too I bricked it. :( Is there any other way to revive the chip?
Thanks,
Ian
2023-11-14 10:39 PM
You need to connect with Access port 3 in CubeProgrammer (as shown below) as CM7 has been disabled (Access Port 0)