While learning PIC programming I suddenly encounter the problem that the programmed information from the .hex files gets corrupted after a while. After reprogramming everything works fine but after a while it looks as if the EEPROM of the PIC gets corrupted. What could be the cause. I have no clue where to look.
The power supply of the PIC is a lab supply at 5V DC. The power lines on the experimental print have 2 capacitors. 1 220uF over the power and one capacitor of 0.1 uF directly over the supply terminals of the PIC.
I am working on a four digit timer. the timer pics up the required preset information from the EEPROM before the counting starts and puts the information in 4 display registers. These registers are scanned by the interupt routine. The counting cycle works fine. But when I want to select a new preset value. The EEPROM returns a non existing value. Verification of the PIC in the programmer indicates that that the the programming is no longer identical to the information in the hex.
The error must be in writing to the EEPROM. Since the overwritten positions in the EEPROM are not always the same I suspect that I have to look for an error just prior to the actual writing cycle. So back to the debugging.