Heatpump rules - not working

Moderator: leecollings

Post Reply
ksga
Posts: 12
Joined: Tuesday 02 February 2016 11:08
Target OS: Raspberry Pi / ODroid
Domoticz version: Stable
Location: Denmark
Contact:

Heatpump rules - not working

Post by ksga »

Hi. I'm trying to get my first Blockly working - and so far mixed success...
I'm trying to setup something that will keep my apartment in a reasonable heated/cooled state when I'm away for a couple of days/weeks.

I started out with a simple "if lower than 26C, then turn on inverter on heat setting" sort of thing. Worked fine..

But when I added the "else if" statement, it stopped working.

What I'm trying to accomplish with the script below is:
1. If its colder than 26C (temperatures will be adjusted before I leave it to do its thing...) turn on the AC/heatpump in "Heat" mode - 20% level on my multi selector switch.
2. If its warmer than 30C turn on the AC/heatpump in "Cool" mode - 30% level.
3. If its somewhere between 27C and 29C turn off the AC/heatpump - but only if it is not already turned off (the thing makes an annoying beep sound every time it receives a command - also if its the same as the last one)
heatpump.PNG
heatpump.PNG (33.67 KiB) Viewed 2100 times
Nothing is happening, nothing in the log - so what am I missing??? (apart from any clue what I'm doing obviously :) )
tnegun
Posts: 11
Joined: Tuesday 27 December 2016 16:19
Target OS: Raspberry Pi / ODroid
Domoticz version: 3.6328
Location: Ireland
Contact:

Re: Heatpump rules - not working

Post by tnegun »

Did you ever find a solution? I'm having the same issue with IF/ElseIF statements IF/Do work ok though
User avatar
Egregius
Posts: 2589
Joined: Thursday 09 April 2015 12:19
Target OS: Linux
Domoticz version: v2024.7
Location: Beitem, BE
Contact:

Re: Heatpump rules - not working

Post by Egregius »

Use a script and you can do whatever you want. Seems pretty basic stuff above :P
tnegun
Posts: 11
Joined: Tuesday 27 December 2016 16:19
Target OS: Raspberry Pi / ODroid
Domoticz version: 3.6328
Location: Ireland
Contact:

Re: Heatpump rules - not working

Post by tnegun »

I'm lazy :) is it a bug or expected that selector switches don't work with If Else blocklys?
Nautilus
Posts: 722
Joined: Friday 02 October 2015 12:12
Target OS: Raspberry Pi / ODroid
Domoticz version: beta
Location: Finland
Contact:

Re: Heatpump rules - not working

Post by Nautilus »

tnegun wrote:I'm lazy :) is it a bug or expected that selector switches don't work with If Else blocklys?
Should work. Couple of notes though.
1. Maybe it is supposed to be so but from 26 to 27 and 29 to 30 the scripts does nothing.
2. When checking a selector switch state you are not checking the level but the actual value of the state. So if Level 0 name is .e.g. "Off" you need to compare against that in the last "else if"

Trust you've made sure the event is marked active and type device? Maybe add some logging to try to see what is happening..
tnegun
Posts: 11
Joined: Tuesday 27 December 2016 16:19
Target OS: Raspberry Pi / ODroid
Domoticz version: 3.6328
Location: Ireland
Contact:

Re: Heatpump rules - not working

Post by tnegun »

Just updated to 3.6328

I just realized I'm not doing the same as the OP. I'm acting ont the selector state not setting it.

e.g. This works properly
Image

but this doesn't
Image
Nautilus
Posts: 722
Joined: Friday 02 October 2015 12:12
Target OS: Raspberry Pi / ODroid
Domoticz version: beta
Location: Finland
Contact:

Re: Heatpump rules - not working

Post by Nautilus »

tnegun wrote:Just updated to 3.6328

I just realized I'm not doing the same as the OP. I'm acting ont the selector state not setting it.

e.g. This works properly
Image

but this doesn't
Image
Sorry, missed the fact you were not the OP :) There the problem is the If-block type, the one with the blue icon on top left corner requires an "else if" as well. Plain "if -> do" works only with the version without this icon.
Last edited by Nautilus on Wednesday 11 January 2017 8:17, edited 1 time in total.
tnegun
Posts: 11
Joined: Tuesday 27 December 2016 16:19
Target OS: Raspberry Pi / ODroid
Domoticz version: 3.6328
Location: Ireland
Contact:

Re: Heatpump rules - not working

Post by tnegun »

And thats working.... I was testing by building in stages and got stuck here!!

Thanks for your help :)
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest