T3000 non volatile memory

Greeting ,can we write on controller non volatile memory ? to save the data incase of power down

Yes of course. all variables are stored every few minutes and will resume from where they left off once power resumes.

Maurice Duteau

Gents ,
Kindly advise , this is generally or for some variables, as scenario I have after power is down , program is reset . And variables are forced to intial values , we may store them in permanent memory , after power is back we can restore them , is that possible

This very good, but the issue i faced related to Interval command , that after power restored , the interval start from beginning and program overwrite old variables, is there possible solution .

Perhaps I can help out if we see your program. The time-on and off statements store their data in non volatile memory which is indeed lost during a power cycle. How about storing the time-on and off in a variable, explicitly.

10 VAR1 = TIME-ON( OUT1 )

Var1 will hold the time-on of the output on power up, it will quickly get overwritten though depending on your startup conditions. With some creative use of the power-on statement you might be able to get around that. It could get messy though.

Another option would be to just get a low cost backup power supply, they are not expensive.

Great Idea , i would try , suppose i am using interval command , is there a way to assign regular interval time to a variable ?

Interval is useful for the timing applications as you’re working on. Here’s one which increments a variable every one second.

IF INTERVAL( 0:0:01 ) THEN VAR1 = VAR1 + 1

The IF+ statement is also useful, this statement will trigger once when the timer hits a certain value, 10 minutes in this case.

IF+ VAR1 = 00:10:00 THEN VAR2 = NOT VAR2