Hello everyone, in my automation program for an ammonia compressor I made an hour meter but every time the HMI is turned off it clears the working hours.
My question is if there is a way to keep the operating hours variables no matter the HMI is turned off?
working hours counter
-
- Posts: 3
- Joined: 14/10/2021, 22:42
working hours counter
You do not have the required permissions to view the files attached to this post.
-
- Moderatore
- Posts: 1699
- Joined: 29/10/2010, 10:09
- Contact:
Re: working hours counter
Hi,
you need simply use RETAIN variables with the FuntionBlock, in you case CON_SEC, CON_MIN and CON_HOUR.
In this way the times are stored also after a power off and the FunctionBlock continues to increase that values.
you need simply use RETAIN variables with the FuntionBlock, in you case CON_SEC, CON_MIN and CON_HOUR.
In this way the times are stored also after a power off and the FunctionBlock continues to increase that values.
-
- Posts: 3
- Joined: 14/10/2021, 22:42
Re: working hours counter
Pixsys tecnico 1 wrote:Hi,
you need simply use RETAIN variables with the FuntionBlock, in you case CON_SEC, CON_MIN and CON_HOUR.
In this way the times are stored also after a power off and the FunctionBlock continues to increase that values.
Hello Mr. Pixsys I did what you suggested but it still does not store the time value after a shutdown of the HMI pixsys 810.
Can you please send me an example?
You do not have the required permissions to view the files attached to this post.
-
- Moderatore
- Posts: 1699
- Joined: 29/10/2010, 10:09
- Contact:
Re: working hours counter
Keep in mind that the retain value is stored every 30 seconds, so the power on time must be at least that time.
To set the attribute "retain" to a variable:
To set the attribute "retain" to a variable:
You do not have the required permissions to view the files attached to this post.