yeah i remind this one... but i'm not sure if it wasn't only for EXTERNAL eeprom.. playing with page write, voltage and temperature seems to be external dedicated tricks to me... but yeah i may have missed the one about PIC!
http://www.picbasic.co.uk/forum/showthread.php?t=1670
Steve
It's not a bug, it's a random feature.
There's no problem, only learning opportunities.
Yep, got me again, that's the one I was talking about. For some reason, I thought it was for internal eeprom/flash. I have yet to totally wipe out a flash PIC or on chip EEPROM on a PIC yet. I've worn out a small chunk of one, like the first 64 bytes of an older 18F4620, but not completely...yet...today...or even this year... I can sure try![]()
Some statements from 24LC32 datasheet.
"
• Endurance:
- 10,000,000 Erase/Write cycles
guaranteed for High Endurance Block
- 1,000,000 E/W cycles guaranteed for
Standard Endurance Block
"
In the same datasheet, there is also this;
"...the first 4K, starting at address 000,
is rated at 10,000,000 E/W cycles guaranteed. The
remainder of the array, 28K bits, is rated at 100,000 E/W cycles guaranteed."
Do I get it wrong, or the datasheet contradicts itself?
----------------
"If the Earth were a single state, Istanbul would be its capital." Napoleon Bonaparte
What this is saying is that the first 4k locations are 'high endurance' (and probably physically larger). The remaining 28k bytes are 'standard endurance'.
Just make sure your code always starts to store data from address 0 so the low adfdresses get most writes and the highest see less writes.
HTH
Brian
Hi everyone!
I'm using PIC16f877a and I program it this way:
'PIC DEFINES
'--------------------
@ DEVICE pic16f877a, XT_OSC
@ DEVICE pic16f877a, WDT_ON
@ DEVICE pic16f877a, PWRT_ON
@ DEVICE pic16f877a, BOD_ON
@ DEVICE pic16f877a, LVP_OFF
@ DEVICE pic16f877a, CPD_OFF
@ DEVICE pic16f877a, PROTECT_OFF
@ DEVICE pic16f877a, WRT_OFF
'LCD DISPLAY
'--------------------
DEFINE LCD_DREG PORTA
DEFINE LCD_DBIT 0
DEFINE LCD_RSREG PORTA
DEFINE LCD_RSBIT 4
DEFINE LCD_EREG PORTE
DEFINE LCD_EBIT 2
DEFINE LCD_BITS 4
DEFINE LCD_LINES 2
'DEFINE LCD_COMMANDUS 2000
'DEFINE LCD_DATAUS 50
ADCON1=7
prnt var byte[2]
TRISB=%00000000
TRISC=%00000000
TRISD=%00000001
CMCON=%00000111
'CVRCON=%0000000
OPTION_REG.7=0
EEPROM 0,[1]
EEPROM 1,[8]
lcdout $fe,1,"Reading eeprom"
read 0,prnt[0]
read 1,prnt[1]
lcdout $fe,1,"Reading=",#prnt[0],#prnt[1]
end
When I load the hex file I can see the values 1 and 8 stored in eeprom address 0 and 1 respectively.My problem is that it can't read those values. the lcd will just display "Reading=00".Please help me
Bookmarks