Industry Automation and Control Forum
This forum is addressing industrial automation design & engineering, operations, asset performance, cyber security and digital transformation for Plants & Machines.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2022-08-26 09:00 PM
Hi I want ask question about PLC TM172PBG28R, I use Ecostructure Machine Expert - HVAC to program this PLC. I already made Running Machine with hours and minute accuracy, but I have a problem saving run hours and run minutes in EEPROM. When a flicker occurs, the EEPROM hours storage section is reset to 0. Is there any other solution how to save EEPROM which is better?
Here I attach a screenshot of the PLC program that I have made
Best Regards
Caroko Tri (Electrical Engineer in PT. Infion Pharma Indonesia)
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2022-08-29 01:01 AM
You did not have the possiblity to do anything if the power get cut off.
But you can notice a power on, but not a power off.
The problem is that you write directly on the EEPROM. And the EEPROM is specified "only" for 100.000 writes. If you increse these number of writes the memory could be destroyed. The value will always stored in EEPROM. If you store everything on the SD card this will so far I know not solve this issue.
If you write on the EEPROM if a Anlog Value changes you will destroy the memory of the controler.
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2022-08-29 12:10 AM
Please consider that you prevent to reach more then 100.000 writes on eeprom values. Otherwise you would destroy the memory. I could not see with which frequency you use "sysWritePar****".
Regarding to this the use of a hour counter with minute resolution is not recommend.
Generell the writing to eeprom seems to be correct so far ud_Run_hours and ud_Run_Minutes representing the EEPROM values.
I would suggest maybe a missing initalistation of the values of ud_operating_Minutes and ud_Operating are the problem.
Did you mean with flicker a restart of the machine? (Power On/Off)
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2022-08-29 12:47 AM
Thank you for your answer @Bastian_Schmitz . I Use SD Card on my PLC, so *.PAR file will save in my SD Card, does it still affect EEPROM?
Did you mean frequency is Task Configuration? If yes, I use 100 ms
Yes flicker means Power On/Off. At my factory often occurs flicker. So I need non-volatile storage to save running hours. I want to make the program work like this, when flicker occurs (PLC OFF) my Operating Hours (format hours and minutes) save to EEPROM (ud_Hours & ud_Minutes) and when PLC is ON, value EEPROM transfer to volatile memory (ud_Operating_minutes & ud_Operating), so calculation of operating hours (format hours and minutes) can be continued.
I use DPT (Differential Pressure Transmitter) feedback to indicate my machine flicker. See my program (Rst_Running_Hours), on 'AI_DPT'. So when DPT is low value EEPROM transfer to volatile memory (ud_Operating_minutes & ud_Operating).
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Posted: 2022-08-29 01:01 AM
You did not have the possiblity to do anything if the power get cut off.
But you can notice a power on, but not a power off.
The problem is that you write directly on the EEPROM. And the EEPROM is specified "only" for 100.000 writes. If you increse these number of writes the memory could be destroyed. The value will always stored in EEPROM. If you store everything on the SD card this will so far I know not solve this issue.
If you write on the EEPROM if a Anlog Value changes you will destroy the memory of the controler.
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Link copied. Please paste this link to share this article on your social media post.
Create your free account or log in to subscribe to the board - and gain access to more than 10,000+ support articles along with insights from experts and peers.