ich arbeite mich gerade in Codesys ein, und komme bei folgender Aufgabe nicht weiter:
Ich brauche persistente Variablen. Diese müssen eigentlich nur bei Änderung neu gespeichert werden, um dann bei Neustart der Steuerung wieder verwendet werden zu können (Änderung der Variablen ca alle 10 Betriebsstunden)
Ich habe nun in einen Beitrag hier im Forum gelesen, dass sich dies mit den Persistence-Manager lösen lassen würde.
Ich komme aber nun nicht weiter wie man diesen zur Application / bzw zu den Modulen hinzufügt. In der Hilfe von Codesys finde ich hier auch nichts konkretes.
Kann mir hierzu jemand einen Tipp geben ?
Vielen Dank im Voraus
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi,
attached the example project for using the persistence manager,
anyway an ups would even in this case help to prevent the sd card damage (in case you switch off powersupply while writing the
persistence manager files)
I am using VAR PERSISTENT RETAIN to rescue data on my raspberry pi.
Runtimesystem will save this data in to file in case of stop runtime and restore it automaticly during startup runtime, right? in case of loss power data can not be restored because of controlled runtimestop is not possible.
So now is it possible to save for example once per hour thisVAR PERSISTENT RETAIN file" by plc code?
in my opinion the most simple way to rescue in case of powerloss.
please answer, thanks dumpfbacke
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
sorry, dass ich dieses alte Thema wieder aufgreife.
Ich habe mir das Projekt angesehen, funktioniert auch so weit, bzw. auch klar.
Leider schaffe ich es nicht, den Persitence Manager in mein eigenes Projekt zu integrieren.
Ich habe mit dem Application Composer leider keinerlei Erfahrung.
Allem Anschein nach sind hier viele POU´s, Tasks,.. automatisch generiert worden.
Ist irgendwo ein Manual vorhanden, wie der Applcation Composer zu bedienen ist?
Schönes neues Jahr.
lg
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Keep in mind even here a 100% soultion is to have a UPS running on Raspberry Pi.
If you remove the power while writing the files... it may happen that the SD card would be damaged...
BR
Edwin
I downloaded the file "How to Setup the PersistenceManager from Scratch.pdf" and cannot complete step 5. I'm using version 3.5.15.0 and the screenshot is a little different.
I can't seem to add the Module or the Application.
How do I solve this issue?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Writing files to SD card could lead to corrupt SD card while switching it off.
Therefore I told already told - for Retains in file and as alternative retains with persistence manager
having a UPS is mandatory to have it reliable.
However, I needed to add this function to my existing application where before I could add/configure the persistent functionality, I had to go menu "Composer - Add Module Library to Project", select AC_PRESIST and add to my project.
From then on, it was quite simple.
Thanks for your help.
👍
1
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
So I've successfully implemented the persistence manager, but this seems to have caused another issue.
I now have unstable communications with one of my Modbus RTU Slave devices. I'm using Codesys V3.5.15.0.
The modbus RTU salve, I've tried using V3.5.10.30 and V3.5.15.0 and both drop out shortly after a download. V3.5.10.30 seems to last a little longer, but drops out after a few minutes.
If I remove the persistence manager, the modbus RTU slave works fine. Also, this slave has been working for around 18 months so I'm fairly certain it's not a wiring issue.
How do I make this RTU slave have stable communications?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Check the taskdeployment where your modbus io's are updated and varify the
priorities of your tasks according this.
If needed call the modbus stuff in the High Task of the application composer / persistence manager
BR
Edwin
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hallo,
ich habe mich bereits eine Weile mit dem Persistence Manager beschäftigt, jedoch stehe ich nach wie vor vor dem Problem, dass die Variabeln nicht gespeichert werden.
Ich habe alles in der Simulation ausprobiert.
Bei einem erneuten Download werden die Daten wieder überschrieben.
Beim ausführen des Musterprojekts werden folgende Fehler angezeigt: License file invalid. Chanel1periodicandChange: Config file not found!
*Chanel2onChange: Config file not found!
Es wird auch eine Datei vom Typ ~U-Datei erzeugt in der folgende Daten zu fenden sind:
if you write 'simulation' you mean you are using Control Win on the same machine where CODESYS is up and running or is it real simulation in CODESYS?
Simulation is not doing these files acesses... so please login to the plc which is on your CODESYS machine.
(use the german section if you need answers in german) 😉
👍
1
Last edit: eschwellinger 2020-11-16
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hallo
ich arbeite mich gerade in Codesys ein, und komme bei folgender Aufgabe nicht weiter:
Ich brauche persistente Variablen. Diese müssen eigentlich nur bei Änderung neu gespeichert werden, um dann bei Neustart der Steuerung wieder verwendet werden zu können (Änderung der Variablen ca alle 10 Betriebsstunden)
Ich habe nun in einen Beitrag hier im Forum gelesen, dass sich dies mit den Persistence-Manager lösen lassen würde.
Ich komme aber nun nicht weiter wie man diesen zur Application / bzw zu den Modulen hinzufügt. In der Hilfe von Codesys finde ich hier auch nichts konkretes.
Kann mir hierzu jemand einen Tipp geben ?
Vielen Dank im Voraus
more posts ...
Hi,
attached the example project for using the persistence manager,
anyway an ups would even in this case help to prevent the sd card damage (in case you switch off powersupply while writing the
persistence manager files)
BR
Edwin
Persistenz_mini_SP11.project [95.92 KiB]
Sorry for asking again.
I am using VAR PERSISTENT RETAIN to rescue data on my raspberry pi.
Runtimesystem will save this data in to file in case of stop runtime and restore it automaticly during startup runtime, right? in case of loss power data can not be restored because of controlled runtimestop is not possible.
So now is it possible to save for example once per hour thisVAR PERSISTENT RETAIN file" by plc code?
in my opinion the most simple way to rescue in case of powerloss.
please answer, thanks dumpfbacke
Hallo,
sorry, dass ich dieses alte Thema wieder aufgreife.
Ich habe mir das Projekt angesehen, funktioniert auch so weit, bzw. auch klar.
Leider schaffe ich es nicht, den Persitence Manager in mein eigenes Projekt zu integrieren.
Ich habe mit dem Application Composer leider keinerlei Erfahrung.
Allem Anschein nach sind hier viele POU´s, Tasks,.. automatisch generiert worden.
Ist irgendwo ein Manual vorhanden, wie der Applcation Composer zu bedienen ist?
Schönes neues Jahr.
lg
Hi,
would start here:
https://help.codesys.com/webapp/ac_pm_o ... n=3.5.14.0
Keep in mind even here a 100% soultion is to have a UPS running on Raspberry Pi.
If you remove the power while writing the files... it may happen that the SD card would be damaged...
BR
Edwin
How to Setup the PersistenceManager from Scratch.pdf [734.34 KiB]
I downloaded the file "How to Setup the PersistenceManager from Scratch.pdf" and cannot complete step 5. I'm using version 3.5.15.0 and the screenshot is a little different.
I can't seem to add the Module or the Application.
How do I solve this issue?
Hi,
maybe the example project helps in this case.
Writing files to SD card could lead to corrupt SD card while switching it off.
Therefore I told already told - for Retains in file and as alternative retains with persistence manager
having a UPS is mandatory to have it reliable.
BR
Edwin
Persistenz_mini_PI_SP15.project [277.13 KiB]
Thanks for the example which worked fine.
However, I needed to add this function to my existing application where before I could add/configure the persistent functionality, I had to go menu "Composer - Add Module Library to Project", select AC_PRESIST and add to my project.
From then on, it was quite simple.
Thanks for your help.
Thanks for the info. I also had problems with step 5. "Composer - Add Module Library to Project" step is missing in the pdf.
Thank you
So I've successfully implemented the persistence manager, but this seems to have caused another issue.
I now have unstable communications with one of my Modbus RTU Slave devices. I'm using Codesys V3.5.15.0.
The modbus RTU salve, I've tried using V3.5.10.30 and V3.5.15.0 and both drop out shortly after a download. V3.5.10.30 seems to last a little longer, but drops out after a few minutes.
If I remove the persistence manager, the modbus RTU slave works fine. Also, this slave has been working for around 18 months so I'm fairly certain it's not a wiring issue.
How do I make this RTU slave have stable communications?
Hi,
not sure, some ideas:
priorities of your tasks according this.
If needed call the modbus stuff in the High Task of the application composer / persistence manager
BR
Edwin
Hallo,
ich habe mich bereits eine Weile mit dem Persistence Manager beschäftigt, jedoch stehe ich nach wie vor vor dem Problem, dass die Variabeln nicht gespeichert werden.
Ich habe alles in der Simulation ausprobiert.
Bei einem erneuten Download werden die Daten wieder überschrieben.
Beim ausführen des Musterprojekts werden folgende Fehler angezeigt:
License file invalid.
Chanel1periodicandChange: Config file not found!
*Chanel2onChange: Config file not found!
Es wird auch eine Datei vom Typ ~U-Datei erzeugt in der folgende Daten zu fenden sind:
Name
DESKTOP-QJPPC0T
5548
637411299644040318
Dies entspricht nicht dem Format in wie es in der Beschreibung zu finden ist:
https://help.codesys.com/webapp/ac_pm_storage_format;product=core_Application_Composer;version=3.5.16.0
Kann mir hierzu jemand weiterhelfen?
Vielen Dank im Voraus
if you write 'simulation' you mean you are using Control Win on the same machine where CODESYS is up and running or is it real simulation in CODESYS?
Simulation is not doing these files acesses... so please login to the plc which is on your CODESYS machine.
(use the german section if you need answers in german) 😉
Last edit: eschwellinger 2020-11-16
Das Problem wurde gelöst. Es lag an dem Simulations-Modus.