Evohome JSON Api
Moderator: leecollings
-
- Posts: 31
- Joined: Sunday 14 August 2016 9:20
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Evohome JSON Api
Hi all,
I've just installed EvoHome to my long running Domoticz install and I'm using the Web integration (rather than USB) for running this.
When I go to be my house alarm is set and I want to recreate what I had with nest. Which was when alarm == night set, set setpoint to X - but with EvoHome I want this to be more granular.
Reading the AP and testing it the modes on offer are: Auto,TemporaryOverride,PermanentOverride,FollowSchedule
But, they don't seem to work as they sound.
Auto = Auto, great!
Temporary Override = This needs an end date/time, which kills it's use for me
PermanentOverride = Works
Follow Schedule = Not sure how this differs from Auto. As setting a setpoint here does nothing.
I've been playing with this and have managed to get Domoticz to delete my test zone... so had to re-add it.
Any ideas on how to get this to work?
https://USER:[email protected]:1 ... &used=true == constant set
https://USER:[email protected]:1 ... &used=true == Follow schedule, but at previous temp (ignores X)
https://USER:[email protected]:1 ... &used=true == Normal
I've just installed EvoHome to my long running Domoticz install and I'm using the Web integration (rather than USB) for running this.
When I go to be my house alarm is set and I want to recreate what I had with nest. Which was when alarm == night set, set setpoint to X - but with EvoHome I want this to be more granular.
Reading the AP and testing it the modes on offer are: Auto,TemporaryOverride,PermanentOverride,FollowSchedule
But, they don't seem to work as they sound.
Auto = Auto, great!
Temporary Override = This needs an end date/time, which kills it's use for me
PermanentOverride = Works
Follow Schedule = Not sure how this differs from Auto. As setting a setpoint here does nothing.
I've been playing with this and have managed to get Domoticz to delete my test zone... so had to re-add it.
Any ideas on how to get this to work?
https://USER:[email protected]:1 ... &used=true == constant set
https://USER:[email protected]:1 ... &used=true == Follow schedule, but at previous temp (ignores X)
https://USER:[email protected]:1 ... &used=true == Normal
- waaren
- Posts: 6028
- Joined: Tuesday 03 January 2017 14:18
- Target OS: Linux
- Domoticz version: Beta
- Location: Netherlands
- Contact:
Re: Evohome JSON Api
I am not sure that I understand what you try to achieve.
Especial the more granular part. Can you please elaborate on what you want and what is not working ?
Especial the more granular part. Can you please elaborate on what you want and what is not working ?
Debian buster, bullseye on RPI-4, Intel NUC.
dz Beta, Z-Wave, RFLink, RFXtrx433e, P1, Youless, Hue, Yeelight, Xiaomi, MQTT
==>> dzVents wiki
dz Beta, Z-Wave, RFLink, RFXtrx433e, P1, Youless, Hue, Yeelight, Xiaomi, MQTT
==>> dzVents wiki
-
- Posts: 31
- Joined: Sunday 14 August 2016 9:20
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Evohome JSON Api
Hiya,
When I go to bed 'alarm = night set' this triggers a switch on Domoticz (I'm using a Fibaro universal sensor wired into my alarm).
I want an event to run that'll do the following:
Set kitchen setpoint = 16Deg
Set living room setpoint = 16Deg
Set play room setpoint = 16Deg
Set our bedroom setpoint = 17Deg
Set kids bedrooms setpoint = 18Deg
The evohome schedule is set to hit these setpoints at 11pm anyway (irrespective of what Domoticz says), but when we go to bed earlier I want it to have a temp setpoint made active, in effect pulling these setpoints forward.
Doing this via the JSON API is the easiest way to do this (sadly Domoticz doesnt allow EvoHome setpoints in Blockly).
But the problem is that I can't set a 'temp' setpoint on the devices, only permanent override seems to work.
Thx
When I go to bed 'alarm = night set' this triggers a switch on Domoticz (I'm using a Fibaro universal sensor wired into my alarm).
I want an event to run that'll do the following:
Set kitchen setpoint = 16Deg
Set living room setpoint = 16Deg
Set play room setpoint = 16Deg
Set our bedroom setpoint = 17Deg
Set kids bedrooms setpoint = 18Deg
The evohome schedule is set to hit these setpoints at 11pm anyway (irrespective of what Domoticz says), but when we go to bed earlier I want it to have a temp setpoint made active, in effect pulling these setpoints forward.
Doing this via the JSON API is the easiest way to do this (sadly Domoticz doesnt allow EvoHome setpoints in Blockly).
But the problem is that I can't set a 'temp' setpoint on the devices, only permanent override seems to work.
Thx
- waaren
- Posts: 6028
- Joined: Tuesday 03 January 2017 14:18
- Target OS: Linux
- Domoticz version: Beta
- Location: Netherlands
- Contact:
Re: Evohome JSON Api
OK understand now. Would it be an option for you to set a virtual switch or variable with the json and let dzVents (triggered by that switch or var) handle the updateSetpoint ?billytkid wrote: ↑Monday 05 March 2018 13:13 Hiya,
When I go to bed 'alarm = night set' this triggers a switch on Domoticz (I'm using a Fibaro universal sensor wired into my alarm).
I want an event to run that'll do the following:
Set kitchen setpoint = 16Deg
Set living room setpoint = 16Deg
Set play room setpoint = 16Deg
Set our bedroom setpoint = 17Deg
Set kids bedrooms setpoint = 18Deg
The evohome schedule is set to hit these setpoints at 11pm anyway (irrespective of what Domoticz says), but when we go to bed earlier I want it to have a temp setpoint made active, in effect pulling these setpoints forward.
Doing this via the JSON API is the easiest way to do this (sadly Domoticz doesnt allow EvoHome setpoints in Blockly).
But the problem is that I can't set a 'temp' setpoint on the devices, only permanent override seems to work.
Thx
Debian buster, bullseye on RPI-4, Intel NUC.
dz Beta, Z-Wave, RFLink, RFXtrx433e, P1, Youless, Hue, Yeelight, Xiaomi, MQTT
==>> dzVents wiki
dz Beta, Z-Wave, RFLink, RFXtrx433e, P1, Youless, Hue, Yeelight, Xiaomi, MQTT
==>> dzVents wiki
-
- Posts: 31
- Joined: Sunday 14 August 2016 9:20
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Evohome JSON Api
Ok thanks,
I havent used Dzvents yet, but could give it a go.
Will this make it easier to set the termporary setpoint (ie setpoint until next EvoHome setpoint)?
thanks
I havent used Dzvents yet, but could give it a go.
Will this make it easier to set the termporary setpoint (ie setpoint until next EvoHome setpoint)?
thanks
- waaren
- Posts: 6028
- Joined: Tuesday 03 January 2017 14:18
- Target OS: Linux
- Domoticz version: Beta
- Location: Netherlands
- Contact:
Re: Evohome JSON Api
I certainly think so but have not tested it in exactly the same way you want to use it.billytkid wrote:Ok thanks,
I havent used Dzvents yet, but could give it a go.
Will this make it easier to set the termporary setpoint (ie setpoint until next EvoHome setpoint)?
thanks
I will check later today and come back to you.
Debian buster, bullseye on RPI-4, Intel NUC.
dz Beta, Z-Wave, RFLink, RFXtrx433e, P1, Youless, Hue, Yeelight, Xiaomi, MQTT
==>> dzVents wiki
dz Beta, Z-Wave, RFLink, RFXtrx433e, P1, Youless, Hue, Yeelight, Xiaomi, MQTT
==>> dzVents wiki
-
- Posts: 31
- Joined: Sunday 14 August 2016 9:20
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Evohome JSON Api
Great, thanks!
- philchillbill
- Posts: 399
- Joined: Monday 12 September 2016 13:47
- Target OS: Linux
- Domoticz version: beta
- Location: Eindhoven. NL
- Contact:
Re: Evohome JSON Api
Why is specifying an endtime a no-no for you? It's just an ISO8601 date string like '2018-02-06T14:30:00+01:00'. I have a perl script that sets a temporary override for me for 15 minutes via Alexa on a named zone. The json call looks like this:
$url=$url{domo}.'/json.htm?type=setused&idx='.$idx.'&setpoint=22.5&mode=TemporaryOverride&until='.$endtime.'&used=true';
the $endtime is calculated in perl using the DateTime module which can add e.g. 15 minutes to an ISO date and will take care of things like after-midnight overflow or whatever. The code I use is (the hrs=1 is needed for CET offset):
$dt = DateTime->now();
$dt->add( hours => 1, minutes => 15 );
$endtime=$dt->ymd() . 'T' . $dt->hms;
$endtime=~s/:\d\d$//;
Voila!
$url=$url{domo}.'/json.htm?type=setused&idx='.$idx.'&setpoint=22.5&mode=TemporaryOverride&until='.$endtime.'&used=true';
the $endtime is calculated in perl using the DateTime module which can add e.g. 15 minutes to an ISO date and will take care of things like after-midnight overflow or whatever. The code I use is (the hrs=1 is needed for CET offset):
$dt = DateTime->now();
$dt->add( hours => 1, minutes => 15 );
$endtime=$dt->ymd() . 'T' . $dt->hms;
$endtime=~s/:\d\d$//;
Voila!
Alexa skills author: EvoControl, Statereport, MediaServer, LMS-lite
- waaren
- Posts: 6028
- Joined: Tuesday 03 January 2017 14:18
- Target OS: Linux
- Domoticz version: Beta
- Location: Netherlands
- Contact:
Re: Evohome JSON Api
And in dzVents.. (tested and working)
And change line 10 of domoticz/dzVents/runtime/evohome_device.lua
to
time calculation in LUA / dzVents:
Code: Select all
return {
on = { devices = {'TriggerDevice' } },
execute = function(domoticz,_)
local myZone = domoticz.devices('Slaapkamer')
myZone.updateSetPoint("15", "TemporaryOverride",'2018-03-05T22:00:00-01:00')
end
}
to
Code: Select all
local res = ((device.hardwareTypeValue == 39 or device.hardwareTypeValue == 75 ) and device.deviceSubType == 'Zone')
Code: Select all
local now=os.time()
print("-1900: " .. os.date("!%Y-%m-%dT%TZ",now-1900)) -- current time - 1900 seconds
Last edited by waaren on Tuesday 06 March 2018 1:26, edited 1 time in total.
Debian buster, bullseye on RPI-4, Intel NUC.
dz Beta, Z-Wave, RFLink, RFXtrx433e, P1, Youless, Hue, Yeelight, Xiaomi, MQTT
==>> dzVents wiki
dz Beta, Z-Wave, RFLink, RFXtrx433e, P1, Youless, Hue, Yeelight, Xiaomi, MQTT
==>> dzVents wiki
-
- Posts: 31
- Joined: Sunday 14 August 2016 9:20
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Evohome JSON Api
Hi all,
I don't want to use an end time as it needs to be both calculated (which is a pain, and can't be done in the blockly interface), and may interfere with events on EvoHome.
My view (probably wrong in some eyes) is that each system should be independent and own their own schedules(ie Hue for lighting, times/schedules. EvoHome for heating times/schedules). Domoticz then gathers this data to report, and also is the 'exception engine' which can then provide override or what/if scenarios.
This means I've got a system which doesn't totally rely on Domoticz (which only I can fix) so this raises the WAF, and it also means that each component's basic requirement (lighting/heating) just works.
So with this requirement for EvoHome I want that to run the schedule for heating on/off on all zones, with their own setpoints/times etc.
But what I want with Domoticz is to have temporary 'override until next EvoHome setpoint' setup, this means that I can set my alarm which'll then trigger earlier setpoints until EvoHome setpoints take over.
I hope that explains it a bit more!
I don't want to use an end time as it needs to be both calculated (which is a pain, and can't be done in the blockly interface), and may interfere with events on EvoHome.
My view (probably wrong in some eyes) is that each system should be independent and own their own schedules(ie Hue for lighting, times/schedules. EvoHome for heating times/schedules). Domoticz then gathers this data to report, and also is the 'exception engine' which can then provide override or what/if scenarios.
This means I've got a system which doesn't totally rely on Domoticz (which only I can fix) so this raises the WAF, and it also means that each component's basic requirement (lighting/heating) just works.
So with this requirement for EvoHome I want that to run the schedule for heating on/off on all zones, with their own setpoints/times etc.
But what I want with Domoticz is to have temporary 'override until next EvoHome setpoint' setup, this means that I can set my alarm which'll then trigger earlier setpoints until EvoHome setpoints take over.
I hope that explains it a bit more!
- philchillbill
- Posts: 399
- Joined: Monday 12 September 2016 13:47
- Target OS: Linux
- Domoticz version: beta
- Location: Eindhoven. NL
- Contact:
Re: Evohome JSON Api
Bring it on !gordonb3 wrote: ↑Tuesday 06 March 2018 20:11 It might interest you to know that I'm currently working on a companion app for Evohome in Domoticz to replace a stand-alone app I'm currently using to handle special events like "override for X minutes". I like this "schedule advance" idea you put out here and I'm thinking of automating that even more by letting Domoticz provide the next setpoint value, which is already available internally but simply not published to the outside.

Alexa skills author: EvoControl, Statereport, MediaServer, LMS-lite
- philchillbill
- Posts: 399
- Joined: Monday 12 September 2016 13:47
- Target OS: Linux
- Domoticz version: beta
- Location: Eindhoven. NL
- Contact:
Re: Evohome JSON Api
Well the non-WiFi (older) Evotouch had to 'talk' on the 868MHz phoneline to the RFG100 to get the schedule update after it was changed in the cloud (via the app). That means the HGI80 should at least see those packets when they are being transmitted.
Would be really great to have scheduling via the HGI80. My interface to Google Calendar for scheduling Evohome has to go 'external' via TCC to update the schedule JSON. I'd much prefer to do it all 'internally' via my HGI80.
Last edited by philchillbill on Wednesday 07 March 2018 16:55, edited 1 time in total.
Alexa skills author: EvoControl, Statereport, MediaServer, LMS-lite
-
- Posts: 31
- Joined: Sunday 14 August 2016 9:20
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Evohome JSON Api
Thanks, however I'm trying to use Blockly to script the changes, rather than using the web Gui.gordonb3 wrote: ↑Tuesday 06 March 2018 20:11 If you use Evohome via Web API you do not need to calculate the end time as this is already provided in the correct format (which is UTC as indicated by the 'Z' terminator). The only catch is that you must supply it when issuing the override.
It might interest you to know that I'm currently working on a companion app for Evohome in Domoticz to replace a stand-alone app I'm currently using to handle special events like "override for X minutes". I like this "schedule advance" idea you put out here and I'm thinking of automating that even more by letting Domoticz provide the next setpoint value, which is already available internally but simply not published to the outside.
Great news on the companion app.
Looking from the replies it looks like I've only really got one simple (ish) option to solve this.
1. At X, set permanently setpoint to X
2. At a specific time each night (2am), change all setpoints back to auto
This'll allow me to 'pull' the schedule forward. My only worry is that if Domoticz falls over the zones will be stuck in permanent override, failing WAF.
Who is online
Users browsing this forum: No registered users and 1 guest