Before logging an issue, please update to the latest release of Visual Micro from the Downloads Page.

When Logging a Support Issue in the Forum, please ensure you have also:-

  • Enabled vMicro > Compiler > Show Build Properties
  • Re-Compile your program with these settings enabled
 
Save the new Output to a Text File and....
  • Click the Reply button and attach as .txt file OR
  • Click here to Email us with the file attached, and a link to your post
Support requests without the output above may be impossible to answer, so please help us to help you
 
Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic Preserving EEprom values between builds (Read 6408 times)
drpeej
Junior Member
**
Offline


Posts: 27
Location: UK
Joined: Dec 22nd, 2013
Preserving EEprom values between builds
Dec 30th, 2013 at 5:59pm
Print Post  
I have discovered that AS/VM clears any data stored in the on board EEProm when I build/upload it.

Is there any way to preserve the data between builds?
  
Back to top
 
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12191
Location: United Kingdom
Joined: Apr 10th, 2010
Re: Preserving EEprom values between builds
Reply #1 - Dec 30th, 2013 at 6:10pm
Print Post  
I think its a switch defined in the arduinoide/hardware/avr/platform.txt. You could hack yours. 

If you change any arduino hardware defs then click "Tools>Visual Micro>Reload Tool chains" or re-start the ide.

Does this help?
  
Back to top
IP Logged
 
drpeej
Junior Member
**
Offline


Posts: 27
Location: UK
Joined: Dec 22nd, 2013
Re: Preserving EEprom values between builds
Reply #2 - Dec 31st, 2013 at 9:14am
Print Post  
I have found a simpler solution.

I set the EESAVE bit in the high fuse and it now doesnt clear the EEprom values   Smiley
  
Back to top
 
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12191
Location: United Kingdom
Joined: Apr 10th, 2010
Re: Preserving EEprom values between builds
Reply #3 - Dec 31st, 2013 at 1:16pm
Print Post  
Thanks!
  
Back to top
IP Logged
 
Gilles Plante
Full Member
***
Offline


Posts: 156
Location: Québec, Canada
Joined: Oct 31st, 2013
Re: Preserving EEprom values between builds
Reply #4 - Jan 3rd, 2014 at 5:33pm
Print Post  
Hi dpreej and Visual Micro,

for which IDE version did you have issues ?

I wonder because this morning I gave a try to the EEPROM library from Arduino, and didn't have that issue. I use Atmel Studio with the V 1.0.5 IDE.

I looked for platform.txt and found under the 1.5 IDE and under Visual Micro for energia and maple18.

Could it be that issue would occur only for specifics situations ?

Thanks

Gilles Plante
  
Back to top
 
IP Logged
 
drpeej
Junior Member
**
Offline


Posts: 27
Location: UK
Joined: Dec 22nd, 2013
Re: Preserving EEprom values between builds
Reply #5 - Jan 6th, 2014 at 12:48pm
Print Post  
Sorry about the delay in replying.   

It hasnt got anything to do with the EEPROM library.   

My problem is that if I have a sketch with saved EEPROM values and I upload another sketch using an AVRISP programmer, the stored values in the EEPROM are cleared each time you rebuild and upload.  I want them to stay intact between builds.  If you upload using serial/USB and bootloader the problem doesnt occur.

Incidentally,  you may find the EEPROMex library easier to use.
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint