That is a good point Mike, The eeprom_write() and eeprom_read() are functions built into the compiler and are not of my own making. However I will note that if this was not being handled properly then would not the read directly after the write have caused a problem? In hindsight probably not since the EEdata register would not have changed. I'll check how the data function is implemented for the WR bit. Thanks, John > > > Does your eeprom_write implementation wait for the WR bit to be clear at the > start or the end of the function? If it waits for it at the start, you may > be corrupting the EEPROM by attempting to read before a write operation has > completed. > > Regards > > Mike > > -- > http://www.piclist.com hint: The list server can filter out subtopics > (like ads or off topics) for you. See http://www.piclist.com/#topics > > > -- http://www.piclist.com hint: The list server can filter out subtopics (like ads or off topics) for you. See http://www.piclist.com/#topics