AnsweredAssumed Answered

Can not flash in STM32F429i_Disco

Question asked by li.linda.001 on Mar 8, 2015
Latest reply on Mar 10, 2015 by li.linda.001
I need to read the flash, add 1 then flash back to same address, so that I can keep track how many time the user use the device, I use:
~~~~~~~~
 FLASH_Unlock();
  FLASH_ClearFlag(FLASH_FLAG_EOP | FLASH_FLAG_OPERR | FLASH_FLAG_WRPERR |
                  FLASH_FLAG_PGAERR | FLASH_FLAG_PGPERR|FLASH_FLAG_PGSERR); 
TimeUse= *(__IO uint32_t*)(0x04FFF3325)+1;
            if (FLASH_ProgramWord(0x04FFF3325,TimeUse) == FLASH_COMPLETE)
                {
                uwAddress = uwAddress + 4;
                }
~~~~~~~~~
It seems the program can not write anything. Then I try:

TimeUse= *(vu uint32_t*)(0x04FFF3325)+1;
still the same problem.


Why the program can write it?
Thanks


Outcomes