Jump to content

Welcome to Smart Home Forum by FIBARO

Dear Guest,

 

as you can notice parts of Smart Home Forum by FIBARO is not available for you. You have to register in order to view all content and post in our community. Don't worry! Registration is a simple free process that requires minimal information for you to sign up. Become a part of of Smart Home Forum by FIBARO by creating an account.

 

As a member you can:

  •     Start new topics and reply to others
  •     Follow topics and users to get email updates
  •     Get your own profile page and make new friends
  •     Send personal messages
  •     ... and learn a lot about our system!

 

Regards,

Smart Home Forum by FIBARO Team


  • 0

Multiple thermostats in one room


FlorianH

Question

Hi,

I have in my home 11 danfoss thermostats and a boiler on/off switch from horstmann.

Currently I use the fibaro heating schedule to create a schedule for multiple zones at the same time and use a scene to check if I have to turn my boiler on and off. The scene I found here:

Please login or register to see this link.

Adapted it looks like this:

Please login or register to see this code.

I am very pleased with how it works. Turns on and off when there is some thermostat that still requires the boiler...

Now I was hoping someone could help me expand my functionality? Or point me to resources I haven't found yet.

Basically I would like to do the following, which was already asked here:

Please login or register to see this link.

I want a scene where I constantly check if one of X thermostats has changed and propagate this change to the other X thermostats.

I think the basis of the code is this:

187 - is danfoss thermostat.

189 - another danfoss thermostat.

if(fibaro:getValue(189, 'value') != fibaro:getValue(187, 'value')){

fibaro:call(187, "setTargetLevel", fibaro:getValue(189, 'value'));

fibaro:call(187, "setTime", tonumber(os.time(t)) + 60*60);

}

My problem is that I don't know which one changed first, if i would add 3 or 4 in the same scene, I am completely lost. I also don't know how I would propagate the time. However I wouldn't mind if they would all change to 1 hour for example...

I could of course check all values and use the one that's unique. But that still leaves me helpless with zones that have 2 thermostats...

Thanks for any help...

Florian

Link to comment
Share on other sites

1 answer to this question

Recommended Posts

  • 0

You can create a scene which is triggered by changing value on any of your thermostats. So if thermostat x or thermostat y is changed the scene will run.

Then you use the fibaro:getSourceTrigger function to get the thermostat which have been changed and extract the value from that thermostat. This value is saved to a local variable and then the scene just sets all the thermostats to the value in the local

Please login or register to see this code.

Then you just need to replace the "XX value" in the properties section with a line for each of your thermostats.

This one scene will:

- trigger at any thermostat change

- retrieve the id of the thermostat you changed

- find the room that thermostat is located in

- retrieve the setpoint of the thermostat

- loop through all your devices on the HC2 and find thermostats with the same room ID

- update their setpoint to match the thermostat you changed

- kill itself

You only need ONE scene, not one for each room. Only thing you need to ensure, is that the thermostats are configured to be in the same rooms in the HC2 and then as mentioned, that you include a line for EACH of your thermostats in the %%properties section.

I haven't tested it - just made it off the top of my head, but it should work (spelling mistakes are for free

Please login or register to see this image.

/emoticons/default_icon_mrgreen.gif" alt=":mrgreen:" /> )

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...