[?]: groups of variables in WinCC 6.2 SP3

ProTool, WinCC flexible, WinCC, PP/OP/TP/TD/MP
ofadragas
Posts: 4
Joined: Tue Dec 07, 2010 1:51 pm

[?]: groups of variables in WinCC 6.2 SP3

Post by ofadragas »

Hello ,I have a following trouble ,I have some groups of variables in wincc that I need remember the last value that was read before the proyect close ,for example for a energy cut off ,restart a server or something like this.

the default value for this variables that the proyect restart is 0 and i need the default value was the last value before the proyect close.

Can somebody help me with that trouble? (clap)
Lepes9
Posts: 17
Joined: Fri Sep 24, 2010 10:03 pm

Re: [?]: groups of variables in WinCC 6.2 SP3

Post by Lepes9 »

Hi,


you could save these variables every x second in a CSV file with a VB or C script. Something like the function archiving variables but you could overwrite this file every time - you need only the latest values.
On the next start you have to read these values them from the file and assign them to the variables.

I did it in one of my projects, however in WinCC flexible. But it should work in WinCC too.


Good luck!
L9
ofadragas
Posts: 4
Joined: Tue Dec 07, 2010 1:51 pm

Re: [?]: groups of variables in WinCC 6.2 SP3

Post by ofadragas »

Thanks for your help, I have been working at the solution someting like you sugest to me ,the diference I store the values in the table of user archives,every x times whith the script in C ,latter when the proyect shut down at restart another script in C write the last values into the variables.

But I afraid the code in C use too many recurses of the operative System and maybe the System Halt.
Lepes9
Posts: 17
Joined: Fri Sep 24, 2010 10:03 pm

Re: [?]: groups of variables in WinCC 6.2 SP3

Post by Lepes9 »

It depends on...
- how many variables do you want to save
- how often

But if you NEED this function then you have to accept that it costs performance.