EEPROM write question.

Status
Not open for further replies.

birdman0_o

Active Member
Hey guys,

This should probably be on the actual Microchip forum as it is a very technical question. Google and the 16F manual came up with no answers so I turn to the best!

My question: Why is it that when writing to an EEPROM you must write 0X55 then 0XAA to the EECON2 register?

Does this apply to all EEPROMS (serial and parallel)?

Thanks
 
It is just to stop accidental writes to the EEPROM. The chances of that exact sequence of instruction appearing in the rom somewhere is very remote and so, if the chip glitches and executes random code, it is extremely unlikely to corrupt the EEPROM.

Mike.
 

Pommie has already answered this, but I thought it was clearly explained in the datasheet anyway?.
 
And another hidden secret why the hell use only those two values 0X55 & 0XAA!

Because the two values are inverse of each other full filling all 8bits in the internal register in two steps.

What a method
 
Status
Not open for further replies.
Cookies are required to use this site. You must accept them to continue using the site. Learn more…