PDA

View Full Version : On-Chip eeprom problem DATA READ command



xapmanis
- 14th April 2013, 09:20
AM i going nuts ?! srly until yesterday EVEYTHING was good. Im doing a project with some Led dot matrix and i need to store some fonts. I used on-chip eeprom of my 18F26K22. I dont know if i did something wrong i can't recall but i can't write on the eeprom. I used an other 18F26K22 but still same results. Is there any specific number of times that you can write on Eeprom ?? I remember that you can write many many many times until it gets destroyed...

SO i tried to write 2 bytes on the eeprom and recall them to 1 Hserout to check where the problem is. BUT still !!! all data i got back was $FF ....
Doesn't $FF mean eeprom is empty ??

Here are the registers i set.


'----REGISTERS---------
TRISA= %00000000
TRISB= %00000010
TRISC= %11000000
'CMCON= 7 'Comparator module OFF
INTCON.6= 1 'Set Pheripheral Interrupts
PIE1.5= 1
ANSELA=0
ANSELB=0
ANSELC=0

clear
pause 250

Here is an image from the simply data-read command i tried with an Hserout indicator.

6967
6966

If you see anything i miss please let me know !! Im heading out to get some fresh air, can't stand this any more !!

xapmanis
- 14th April 2013, 09:28
I found it !! it was stupid as ALL misstakes with programming PICs :P :P
My mistake was this
6968 and after6969 !!!!