Searching \ for ' PIC16F627 EEPROM' in subject line. ()
Make payments with PayPal - it's fast, free and secure! Help us get a faster server
FAQ page: www.piclist.com/techref/microchip/memory.htm?key=eeprom
Search entire site for: 'PIC16F627 EEPROM'.

No exact or substring matches. trying for part
PICList Thread
'[PICLIST] PIC16F627 EEPROM'
2001\01\14@173146 by Harold M Hallikainen

picon face
       I'm making my first attempt at using EEPROM in the PIC16F627. Here are
the problems I'm having:

       1. In the sample code on page 93 of the datasheet, they write to eeadr
in bank 0, yet the datasheet indicates eeadr is in bank 1. They are using
bank 0 in example 13-1. In example 13-3, they write to eedata in bank 0,
yet, again, the datasheet indicates it's in bank 1. In my code I've gone
with the datasheet and used bank 1 for all eeprom access.
       2. The MPLAB simulator properly indicates in a watch window that I've
put the expected values in eeadr and eedata.  Using the example code in
example 13-2, the written data never shows up in the eeprom data window.
Further, eecon1,wr never seems to clear, which hardware is supposed to do
on completion of the eeprom write. The stopwatch indicates I've been
waiting over 2 seconds for the write to complete. The datasheet does not
indicate the eeprom write time, but I'd expect it to be in the 5 to 50 ms
area.
       3. Running on an actual chip, I'm trying to write some constants into
eeprom locations 0 and 1 during initialization. It appears that it is
happening since the code DOES get beyond that point (it doesn't get stuck
waiting for eecon1,wr to go low). However, when I later read data from
these eeprom locations, I get what appears to be random data (I don't
have an emulator for this chip, so I'm just deducing stuff from the
observable I/O).

       So, Brain Trust, Any ideas?

Thanks!!!

Harold



FCC Rules Online at http://hallikainen.com/FccRules
Lighting control for theatre and television at http://www.dovesystems.com

________________________________________________________________
GET INTERNET ACCESS FROM JUNO!
Juno offers FREE or PREMIUM Internet access for less!
Join Juno today!  For your FREE software, visit:
dl.http://www.juno.com/get/tagj.

--
http://www.piclist.com hint: The PICList is archived three different
ways.  See http://www.piclist.com/#archives for details.


2001\01\14@211132 by dpharris

picon face
Hi-
I informed Microchip that their example code was in error.  They included a
generic example.  The datasheet is right in regards to where the control registers
are.  The eeprom works ok.
David

Harold M Hallikainen wrote:

{Quote hidden}

--
http://www.piclist.com hint: The PICList is archived three different
ways.  See http://www.piclist.com/#archives for details.


'[PIC:}Re: PIC16F627 EEPROM'
2001\01\15@132500 by Harold M Hallikainen

picon face
       Thanks! I found that I had forgotten to set WREN (even though that's in
their sample code! I got so hung up as to which bank I was in, I forgot
about that). Under simulation, stuff now works properly. I THINK the
write is now working properly. I can read reasonable values back out of
the EEPROM with the PRO MATE. However, my reads still don't seem right.
If I put a movlw constant right after the eeprom read so w holds the
value that I indeed SHOULD have read, my code seems to work ok. If I
instead just read the supposedly same value from the eeprom, it LOOKS
like I'm getting somewhat random numbers.
       I'll continue to play with it, but thanks for the confirmation on banks!

Harold



On Sun, 14 Jan 2001 17:31:26 -0800 David Harris <spam_OUTdpharrisTakeThisOuTspamTELUS.NET>
writes:
{Quote hidden}

FCC Rules Online at http://hallikainen.com/FccRules
Lighting control for theatre and television at http://www.dovesystems.com

________________________________________________________________
GET INTERNET ACCESS FROM JUNO!
Juno offers FREE or PREMIUM Internet access for less!
Join Juno today!  For your FREE software, visit:
dl.http://www.juno.com/get/tagj.

--
http://www.piclist.com#nomail Going offline? Don't AutoReply us!
email .....listservKILLspamspam@spam@mitvma.mit.edu with SET PICList DIGEST in the body


More... (looser matching)
- Last day of these posts
- In 2001 , 2002 only
- Today
- New search...