Page 1 of 1

RevPi Core 3 - Keep the variable value after unexpected shutdown

Posted: 05 Mar 2019, 07:24
by max1796911
Hello Mr. and Mrs.

We are now evaluating a potential Revolution Pi application project.
The customer requires some configuration(variables) that its value can be kept after rebooting the system.
Similar to the Persistent variable which can be declared in CODESYS.

However, we are not sure how to approach this issue.
Could someone help us with this issue?

*We are now planning on programming the application either with Python or logiCAD3.
*This is the first time we utilize this kind of system and we understand there might be multiple approaches to tackle this.
We would appreciate a simple solution that we will be capable of the actual implementation.

Re: RevPi Core 3 - Keep the variable value after unexpected shutdown

Posted: 05 Mar 2019, 10:00
by dirk
Hello with Python there exists a module called Pickle which implements simple serialization:
https://wiki.python.org/moin/UsingPickle
You should have in mind to prevent exhaustive writing to the eMMC as this has limited writing capability.
The logi.cals forum is perfect in case you have questions on this topic as there are the experts.

Re: RevPi Core 3 - Keep the variable value after unexpected shutdown

Posted: 07 Mar 2019, 10:46
by max1796911
Thank you for your reply!
I think Pickle should work just fine for our application.
The logi.cal solution is much appreciated as well.