治標(biāo)治本,徹底解決AVR單片機(jī)EEPROM數(shù)據(jù)丟失問(wèn)題
page ++;
}
if (page == 3) //三個(gè)備份都被破壞了
{
return INVALID; //數(shù)據(jù)完全無(wú)效了
}
while ((page--) > 0) //數(shù)據(jù)恢復(fù)
{
for (i = 0; i < EepromPageSize; i ++)
{
temp = EepromReadByte((uint8_t *) (validpage + i));
評(píng)論