stm32cortex-mtrace32lauterbach

Flashing image to STM3220g-EVAL board using Trace 32


I have an STM3220g-EVAL board. It doesn't seem to have a preloaded image in it now, as it was used for other purposes. When I power it on, the display is shown blank.

I dont have a STLINK/V2 hardware. I am using Trace32 and Lauterbach for flashing and debugging the code.

I created a simple C program, created an elf file by using arm-none-eabi-gcc toolchain, and was able to flash it into the STM3220g-EVAL board using a cmm script for stm32 provided in demo folder of Trace32.

What I require is to flash default image for STM3220g-eval using Trace32. Can someone provide me the link to get the boot image and cmm script to flash the same.

I tried the demonstration builder platform and demonstration firmware provided in the following link http://www.st.com/web/en/catalog/tools/FM116/SC959/SS1532/PF250374

As they are providing hex file, I used Trace 32 command data.load.asciihex to load the hex file. When I press go, am getting error( emulation poer fail).

Can somesome provide me the correct cmm script to flash the .hex file to the board.


Solution

  • If I understand you correctly you are trying to flash the "STM3220G-EVAL demonstration firmware" on your STM3220G-EVAL board. So the hex-file you are talking about is "STM322xG_EVAL_FW_V1.2.0.hex", right?

    This hex-file is in Intel HEX file format. (See https://en.wikipedia.org/wiki/Intel_HEX) To load a file in Intel HEX format, you should use Data.LOAD.IntelHex

    So this is how to flash the file in your CPU:

    1. Select your CPU with SYStem.CPU STM32F207IG
    2. Connect to your CPU with SYStem.Up
    3. Prepare flash-programming with DO ~~/demo/arm/flash/stm32f2xx.cmm PREPAREONLY
    4. Arm flash programming with FLASH.ReProgram ALL
    5. Load your Intel Hex file with Data.LOAD.IntelHex STM322xG_EVAL_FW_V1.2.0.hex
    6. Finalize flash programming with FLASH.ReProgram OFF (This will start the actual programming.)