Posted: Thu Apr 07, 2016 4:45 pm Post subject: KamPROG programmer and eeprom
Does anybody know if the KamPROG software erases the eeprom memory when you program the chip if the reset chip option is set?
I have been using a variable in the eeprom like this...
Code:
$regfile="M8def.dat"'This tells the compiler which chip we are using $crystal=1000000'16mhz for MR-8 $swstack=16 $hwstack=40
Dim eiFred AsEramInteger dim iNewVal asinteger
iNewVal=5
eiFred = iNewVal
When I run the software, I can see the value in the memory if I download the content of the eeprom.
However, if I re-program the chip again, the byte value reverts back to 255.
I would like to hold a chip ID in the eeprom, so I don't want to lose the value each time the chip is reprogrammed.
If I switch off the resetting of the chip, I get a verification error.
Also, how does the software map the variable to the memory space. Is it just the sequence of the DIM statements that sets the position?
It seems you should set fusebit "J" (it is not related to Kamprog, this is chip setting).
Check "Lock and Fuse bits" tab in KamProg - fusebit high - J
I have no experience with Kamprog but help usualy helps: http://avrhelp.mcselec.com/ , search "Kamprog", second picture
p.s. if you are using eeprom it is good idea to use BOD to prevent eeprom coruption - fusebits GFE. Another good idea is not to use first eeprom address ("dim dummy as eram byte" at top of your variables)
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You cannot attach files in this forum You cannot download files in this forum