AnsweredAssumed Answered

STM32L151 MD: duplicate byte on EEPROM write

Question asked by Omar on Jan 14, 2015
I a facing a problem writing to eeprom using DATA_EEPROM_ProgramByte
what I noticed is that my byte gets duplicated and I end up with n+1 bytes written where it is supposed to write only n bytes
 
I am using  the lib stm32l1xx_flash.c V1.2.0
My code looks like:
DATA_EEPROM_Unlock();
DATA_EEPROM_FixedTimeProgramCmd( ENABLE );
    
for( ; size > 0; size-- )
{
        DATA_EEPROM_ProgramByte( ( u32_t )pt, *p );
        pt++;
        p++;
}
DATA_EEPROM_FixedTimeProgramCmd( DISABLE );
DATA_EEPROM_Lock();

please advice
thanks in advance

Outcomes