nmeyer
Joined: 09 Jul 2004 Posts: 70
|
Lock up during EEprom write |
Posted: Thu Jul 10, 2008 11:08 am |
|
|
I am developing a program that will load the eeprom of the chip on the first power up after the program has been loaded. I am using a PIC18F8722 and the internal_eeprom.c program in the ccs folders to accomplish this. This was working fine until i reach a location in the eeprom over ~200. Since the eeprom is 1024 bytes, i should have 1024 locations to write to, so i am not sure what the issue is. If i have the program loading up the first 200+ locations it just hangs up during the write process. My program is way to large to post here, but i was hoping someone else might have used the internal_eeprom.c and might have some clues. I did change the INT_EEPROM_ADDRESS to a int 16 from an INT8. Could i be trying to write too much to the eeprom at one time or do i need delays between the writes?
Compiler V4.062
Sample
Code: |
pacres_A=0;
write_float_eeprom(181,pacres_A);
pacres_B=0;
write_float_eeprom(185,pacres_B);
pacres_C=0;
write_float_eeprom(189,pacres_C);
pacres_D=0;
write_float_eeprom(193,pacres_D);
pacres_E=0;
write_float_eeprom(197,pacres_E);
pacres_F=0;
write_float_eeprom(201,pacres_F);
|
|
|