Storing a Nib whilst power is off?
Morrolan
Posts: 98
Hi guys,
I've found myself in a position where I need to save the value of a Nib between power-ups. I've read up on Scratch Pad RAM and that doesn't seem to be an option, and neither does the EEPROM command as it seems that it can only be written to at compile time.
So is it possible to save a variable to the Stamps EEPROM whilst the power is turned off, or do I need a second EEPROM chip?
Many Thanks in advance,
Morrolan
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Flying is simple. You just throw yourself at the ground and miss.
"I think computer viruses should count as life. I think it says something about human nature that the only form of life we have created so far is purely destructive. We've created life in our own image."
Stephen Hawking
I've found myself in a position where I need to save the value of a Nib between power-ups. I've read up on Scratch Pad RAM and that doesn't seem to be an option, and neither does the EEPROM command as it seems that it can only be written to at compile time.
So is it possible to save a variable to the Stamps EEPROM whilst the power is turned off, or do I need a second EEPROM chip?
Many Thanks in advance,
Morrolan
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Flying is simple. You just throw yourself at the ground and miss.
"I think computer viruses should count as life. I think it says something about human nature that the only form of life we have created so far is purely destructive. We've created life in our own image."
Stephen Hawking
Comments
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
www.madlabs.info - Home of the Hydrogen Fuel Cell Robot
What PJ means is that you have to have power to actually save a variable to an EEPROM, but that only takes a few milliseconds.
Once the variable is saved, the power can be turned off and the saved value will be retained. Once the power is restored, the
value can be read from the EEPROM and restored to the variable.
Eck.
Post Edit -- LOL, or something like it.
My wording probably wasn't perfectly accurate, but I have a small circuit driving a servo, and sometimes I want to vary the speed of the servo (using PULSOUT within a FOR - NEXT and changing the size of the STEP value). All I want to do is remember the current speed setting when the circuit is powered down, so the number of write commands to the EEPROM won't be an issue, as I doubt I'll be writing to it very often.
Many Thanks,
Morrolan
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Flying is simple. You just throw yourself at the ground and miss.
"I think computer viruses should count as life. I think it says something about human nature that the only form of life we have created so far is purely destructive. We've created life in our own image."
Stephen Hawking