You may be onto something there ... since posting the email, I've been trying to find a sequence of steps to reproduce the problem and noticed that it will write the EEPROM once, but not after that. Also, I'm writing hours to EEPROM and then minutes to EEPROM, and noticed that if I swap the order of these, I get different results. This could explain the symptoms I'm seeing. I'll be back... Thanks, -Neil. -----Original Message----- From: pic microcontroller discussion list [mailto:PICLIST@MITVMA.MIT.EDU]On Behalf Of Jinx Sent: Friday, June 07, 2002 12:29 AM To: PICLIST@MITVMA.MIT.EDU Subject: Re: [PIC]: EEPROM write woes > > WaitEEWriteComplete: > btfss PIR2,EEIF > goto WaitEEWriteComplete You should add bcf PIR2,EEIF to clear EEIF. See if that makes a difference - there may be something in your program that's reacting to EEIF being set outside of the EEPROM routine. The rest of the code looks alright > return -- 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