I have just managed to set up a Switch to control an external relay. The relay is not supported by Domoticz, so I use a switch or a scene to call a script, which turns the relay on and off.
So far so good.
But now want to start and stop it at specific times. I created user variables start time and stop time to be able to activate the scene with Blockly. That works nicely, but I would like to be able to modify the start time and stop time easily.
Now I have to go into setup - more options - user variables to get to the start and stop times.
I would like to have them on my dashboard, so I can modify them from there, or ideally have a start time and duration on my dashboard, so that if i change start time or duration, the stop time is modified along with it.
Easily change a user variable
Moderator: leecollings
-
- Posts: 350
- Joined: Sunday 19 April 2015 0:36
- Target OS: Raspberry Pi / ODroid
- Domoticz version: V2022.2
- Location: UK
- Contact:
Re: Easily change a user variable
Why not just set a timer? Click on the Timers button for that device in the Switches tab, and you can change the start and stop times there.Mainow wrote: ↑Sunday 07 June 2020 1:28 I have just managed to set up a Switch to control an external relay. The relay is not supported by Domoticz, so I use a switch or a scene to call a script, which turns the relay on and off.
So far so good.
But now want to start and stop it at specific times. I created user variables start time and stop time to be able to activate the scene with Blockly. That works nicely, but I would like to be able to modify the start time and stop time easily.
Now I have to go into setup - more options - user variables to get to the start and stop times.
I would like to have them on my dashboard, so I can modify them from there, or ideally have a start time and duration on my dashboard, so that if i change start time or duration, the stop time is modified along with it.
-
- Posts: 3
- Joined: Sunday 01 September 2019 9:53
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Easily change a user variable
Hi MikeF
Yes, that could work, but I want to be able to make my timer conditional on a dummy switch.
The plan is this: I have a garden sprinkler which I want to sprinkle the grass once a day. I'm not entirely sure about the time and duration yet.
But of course it would be silly to have it go off if it's rainy weather and the grass will be wet anyways.
So I set up a dummy switch which controls whether the sprinkler will go today. I set it up in Blockly, and that works, but it's rather time consuming to have to go into the user variables menu to change the start and stop time.
Ideally, I'd like to have a start time and a duration, so that I can start at time x and stop at time x+y, but I haven't managed to get Blockly to do that either.
Yes, that could work, but I want to be able to make my timer conditional on a dummy switch.
The plan is this: I have a garden sprinkler which I want to sprinkle the grass once a day. I'm not entirely sure about the time and duration yet.
But of course it would be silly to have it go off if it's rainy weather and the grass will be wet anyways.
So I set up a dummy switch which controls whether the sprinkler will go today. I set it up in Blockly, and that works, but it's rather time consuming to have to go into the user variables menu to change the start and stop time.
Ideally, I'd like to have a start time and a duration, so that I can start at time x and stop at time x+y, but I haven't managed to get Blockly to do that either.
Re: Easily change a user variable
Could not you use a selector switch with a few presets?
-
- Posts: 3
- Joined: Sunday 01 September 2019 9:53
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Easily change a user variable
I suppose that could work.
You mean like a radio button with multiple options? Is that possible?
All I found so far is a dummy on/off switch.
You mean like a radio button with multiple options? Is that possible?
All I found so far is a dummy on/off switch.
Who is online
Users browsing this forum: Google [Bot] and 1 guest