2014-07-11 02:28 AM
Hello,
I use STM32F103 uC and I want to load pattern file to memory at address 0x08010000 (FLASH area). I want to do it in simulation.
I converted my pattern bin file to hex format by using bin2hex fromhttp://www.ht-lab.com/freeutils/bin2hex/bin2hex.html
:bin2hex.exe pattern.bin output.hex -s 0801 -o 0000
When I use type the command: Load ''C:\\output.hex'' in Keil Command window I do not get answer. In the Memory window data do not change. I tried to load this pattern file to address 0x2000000 (RAM area) with no effect too.
Please help how to do this. #stm32-flash-load-file2014-07-11 04:04 AM
If you are using an ST-LINK, you could use the ST-LINK Utilities to download arbitrary binary or hex data to flash.
A J-Link has similar tools. You could use a USART with the System Loader, and the Flash Demonstrator Application. You could add a feature in your firmware to accept a download and flash it to memory, in a similar fashion to an IAP solution/example. I'd imagine there's a way to do it with the Keil LOAD command, but I'd have to review the documentation, and output from your hex converter to be sure you're doing it right.2014-07-11 04:07 AM
Hi
''I use STM32F103 uC and I want to load pattern file to memory at address 0x08010000 (FLASH area).'' If you are using the ST-Link to debug, then the Utility program 'ST Link Util' that comes with it should be able to load an Intel Hex file and program it into memory. ''I want to do it in simulation.'' Do not know what you mean by this statement.2014-07-11 04:38 AM
I loaded successfuly file using ST-LINK Utility. I tried it before and I got wrong format error because my pattern file has not .bin extension. Thanks