Schedule script for heating management - python

In this subforum you can show projects you have made, or you are busy with. Please create your own topic.

Moderator: leecollings

Post Reply
jjouifi
Posts: 3
Joined: Thursday 29 November 2018 21:56
Target OS: Linux
Domoticz version:
Contact:

Schedule script for heating management - python

Post by jjouifi »

Now updated with a Docker image.



------------------------

Hello everyone,

I have been working on the following python script, to manage the heating in my home.

Basically, the purpose is to enable easy scheduling of Domoticz switches across several conditions. For example, I need the living room radiator to heat up in some circumstances (e.g. in the evening in a normal work day) but at other times during particular days (full day during home office or week end). But wait, sometimes Grandpa and Grandma also come in the afternoon, so they need heating only in the afternoon!

Domoticz does provide a way to handle these needs, but a fine configuration gets quickly very complicated using Timers and timer Plans.

With this script instead, the whole set of configurations sits in a single spreadsheet, that is very easy to manipulate, with LibreOffice for example. Every hour, the script parses the spreadsheet, thus extracting the scheduling information. Based on that information, it decides what should be the state of each device, and sets it in Domoticz.

Check out the Spreadsheet screen capture attached, it will make things clearer.

The code is here: https://gitlab.com/jjouifi/schedule-for-domoticz

Hope it will be useful to you, and thanks a million times for your feedback.
JJD.



Screen_capture.png
Screen_capture.png (156.36 KiB) Viewed 756 times
Last edited by jjouifi on Thursday 19 November 2020 13:09, edited 1 time in total.
MikeF
Posts: 350
Joined: Sunday 19 April 2015 0:36
Target OS: Raspberry Pi / ODroid
Domoticz version: V2022.2
Location: UK
Contact:

Re: Schedule script for heating management - python

Post by MikeF »

Clever!
evertide
Posts: 14
Joined: Wednesday 19 November 2014 11:02
Target OS: Raspberry Pi / ODroid
Domoticz version: Stable
Contact:

Re: Schedule script for heating management - python

Post by evertide »

Very nice
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest