Page 1 of 1

After event returning to last value

Posted: Sunday 22 May 2016 20:48
by OCB73
Hello!

I am using a Danfoss LC-13 Heatingvalve in combination with a Fibaro Door/Window-Sensor.
When window is open, the heatingvalve is falling back to 15 degrees, after closing the window
my heatingvalve go up to 22 degrees. All is working fine!

But i am also using a scheduled switching with my heatingvalves. So if it´s after 9:00am, valve
is going down to 18 degrees and raises up to 22 after 15:00pm. If the window get´s opened and
closed in this range of time, valve is going to 22 degrees, but should be at 18.

Any ideas what i can do?

Greetings
OCB

Re: After event returning to last value

Posted: Sunday 22 May 2016 21:06
by jvdz
I am using a similar logic for the heating with presence detection.
The way I've solved it is to save the Thermostat value in a uservariable.
When we leave the house, the uservariable is set to the current Thermostat level and the Thermostat is set to a lower temperature.
At the preset times to change the Temperature, the uservariable is always updated to the new set temperature and the Thermostat is only changed in case we are home.
In case we return home the Thermostat is always set to the value in the User variable.

Hope that makes sense, else just ask.
Jos

Re: After event returning to last value

Posted: Monday 23 May 2016 20:29
by OCB73
Many thanks for your answer!

I will try it after reading a little bit more about LUA and uservariables. ;)

Re: After event returning to last value

Posted: Wednesday 01 June 2016 20:21
by OCB73
Hi again! ;)

I am a little bit confused about all the scripts and what is possible with LUA.

I think i need help again or maybe i understood something wrong. If i set up a user variable,
is it possible that when thermostat changes the temp., that the user variable get´s updated
to the new value of the thermostat? Or do i have to set up more user varibles for each daytime
and query the time in a script to pick the daytime-temp. for my thermostat?

Thanks
Oliver

Re: After event returning to last value

Posted: Wednesday 01 June 2016 20:41
by jvdz
I am not updating the uservariable until an event happens that requires to save the current temperature and change the actual temperature to something else. Let me explain a little more:

I have one TIME script running for setting the Thermostat at predefined times configurable per day of the week. This script will always set the UserVariable to the newly wanted Temperature, but will only set the actual thermostat temp in case we are home at that moment.

Also have a presence script that will perform the following actions for the thermostat:
When Leaving: Save the current Thermostat Temp to the UserVariable and set the Thermostat to 17 C.
When Returning: Set the Thermostat Temp to the value of the User variable.

Is that making it clearer for you?
Ask in case it is still foggy. :)
Jos

Re: After event returning to last value

Posted: Saturday 04 June 2016 18:34
by OCB73
Finally i got it...THX for your help! :-)

Next step is to make a timescript like you instead of using
the device-timer, suits better for me i think.

After that, i like to use my Netatmo to reduce the temp. of
my heating-valves if outside temp. rises above 20 degrees
and go back to uservariable if under 20 degrees outside.

Greetings
Oliver

Re: After event returning to last value

Posted: Saturday 04 June 2016 20:52
by OCB73
One question...

If i want to change the heating-valve-value 3 times a day,
can i use it in only 1 script or have i to make 3 scripts?

Oliver

Re: After event returning to last value

Posted: Sunday 05 June 2016 0:04
by jvdz
One script should work fine, just a matter of having the correct logic in it. :)

Jos