i used the 628 for 2 projects, and writing to eeprom has never been reliable. that's why I don't use the 628 anymore... tino ************************************************************************ ****************************** >-----Original Message----- >From: Jinx [mailto:joecolquitt@CLEAR.NET.NZ] >Sent: Tuesday, June 15, 2004 3:27 PM >To: PICLIST@MITVMA.MIT.EDU >Subject: Re: [PIC]: 16f628 EEPROM woes > >> Jinx, I tried that write code segment and that didn't work also > >I'm certain the code is fine. This is what I'm using currently on the >18F452 and it works OK. It's the 18F equivalent of the 628 code > >save bsf eecon1,wren ;enable write > mov 0x55,eecon2 > mov 0xaa,eecon2 > bsf eecon1,wr ;initiate write cycle > >wrend btfsc eecon1,wr ;wait for WR bit to clear > bra wrend2 > bcf eecon1,wren > return > >> Also, I tried writing to it with the programmer and reading it back >> with the programmer but it came back as 00's > >Trying another 628 should tell you what's going on > >-- >http://www.piclist.com hint: PICList Posts must start with ONE topic: >[PIC]:,[SX]:,[AVR]: ->uP ONLY! [EE]:,[OT]: ->Other [BUY]:,[AD]: ->Ads -- http://www.piclist.com hint: PICList Posts must start with ONE topic: [PIC]:,[SX]:,[AVR]: ->uP ONLY! [EE]:,[OT]: ->Other [BUY]:,[AD]: ->Ads