AnsweredAssumed Answered

How to program the application flash file (hex file) in chosen flash area by using ST-LINK for STM32F0

Question asked by thieu.toan on Oct 6, 2012
Latest reply on Oct 8, 2012 by thieu.toan
Dear Friends.
I'm using STM32F0 for my project but there is something I don't understand how to program the application flash file into flash memory of STM32F0. I explain my working and my understanding about the flash. 
In my project, i using eeprom emulation with 2 pages.
#define EEPROM_START_ADDRESS  ((uint32_t)0x08002000) // 8K after sector 2
#define PAGE_SIZE             ((uint32_t)0x0400)  /* Page size = 1KByte */

I want to ask all friends that

1) Must i program my application hex file from 0x08002800? 
I understand if I program at address 0x08000000. That means the data I stored in eeprom emulation will be erased every time I program new hex file. Is it right?

2) Address in ST-Link GUI is always 0x08000000, if I want to program at address, i must correct to 0x08002800 before I program. Is it right?

3) Do I need to modify anything in library or start up file STM32F0 to pointer to address 0x08002800? So that every time, application code execute, it will execute from address 0x08002800. Is that right?

4) I'm using Keil. Do i need to modify any thing in Keil to program address at 0x08002800?

I'm really confused how to program the flash area of STM32. All friends understand how to do that. Could you please give me a help? I'm appreciated.


Outcomes