lost wrote: ↑Wednesday 12 June 2024 7:16
For this kind of usage, you can also have several timer plans.
Thanks for your tip. I saw this option later (or the functionality only came after I had already set it up). It is still on my list to look at although I have a good working and flexible situation now. Because it still has everything to do with obtaining and setting timers, I will consider it on-topic and will elaborate a bit on it. Maybe it will give someone another idea.
My experience with fixed timers was that when I went to bed later, I was suddenly sitting in the dark.

I now have the following 'layered' approach to achieve a more 'dynamic' setup. This is especially good in my case, because I have a number of timer settings that may or may not be active under certain conditions. Some issues can be resolved in more than one way and are a matter of preference.
1. The basis lies in the time of day and whether someone is home.
A. A personal switch is made with an 'online checker' for my wife and a geofence for myself.
Changing these switches triggers a script. This sets the user variable 'someone's home' to 0 or 1. This can be used anywhere to check.
B. A DayEveningNight script is triggered by Domoticz system start, or time, or device.
-'between 8:00 and 16 minutes before sunset' I call it day.
-'between 15 minutes before sunset and 23:59' I call it evening
- When a specific light switches off and time 'at 10:00 PM-02:30 AM' (I go to bed) I call it night.
uservariable 'DayEveningNightStand' is set to 1, 2 or 3.
2. Actions based on this take place in TV-Switch-byTimeAndPresence.
Triggered on variable change, or time (for a few specific conditional switches)
It is divided into three parts if dayeveningnight = 1 or 2 or 3.
In each part is divided into 4 parts: always switch off, always switch on, actions when someone at home = 0, actions when someone at home = 1
Advantatage is that you can set conditions and also have everything with dependencies together in one place.
A couple of devices that have a fixed timer that are set on the device itself.
3. Next to this I have a my Vacationtimer.
This is a dummy switch which has its own timer, that is set by a bash script. This script gets iCal information from my Synology Calendar, parses out the vacation start and end datetimes from it and sets this timer. On/Off switching on its turn triggers my vacation script, where depending the on the on or off status, this script switches On/Off some devices, some scene schedules, my EvoHome and my repeater.
Finally I just added to switch on/off some dzVents scripts during my vacation.