Notification depending on condition and time

Discussions about RaZberry - Z-Wave board for Raspberry computer
Post Reply
hwittler
Posts: 5
Joined: 20 Dec 2015 11:18

Notification depending on condition and time

Post by hwittler »

Hi,

i am quite new to home automation and I have a problem.

I want to send a message at 22:00 if i forgot to close some windows.

From my point of view I need a shedule which then checks at the apointed time if a window is open and if yes sends out the mail.

Sending out the mail with the Mail via Mail Notification works.
Doing a schedule shouldn't be hard either. What I don't get to work is the condition.
If I use the 'if - then' app or the logical condition I can check on the window sensor but not on the time of day.

Would this be an application for the js device? If so could somebody post a sample please?

Thanks in advance.
pz1
Posts: 2053
Joined: 08 Apr 2012 13:44

Re: Notification depending on condition and time

Post by pz1 »

This logical rule works for me for heating. It activates a scene that switches a couple of thermostatic radiator valves. The time settings do not trigger themselves, but rather determine in which time frame the temperature level may be evaluated. Click on image to get the full picture.
Capture.PNG
Capture.PNG (16.16 KiB) Viewed 11264 times
bogr
Posts: 190
Joined: 16 Nov 2015 22:46

Re: Notification depending on condition and time

Post by bogr »

PZ1's solution seem neat and simple enough, although I don't quite understand the config ;).

If that does not work for you an alternative is to create a virtual switch (Dummy Device) that is set to "ON" when it's 22.00 (on Schedule). Then in your logical rule, you also incorporate a check for this switch and then send a mail, as well as resetting the switch to OFF.
pz1
Posts: 2053
Joined: 08 Apr 2012 13:44

Re: Notification depending on condition and time

Post by pz1 »

bogr wrote: although I don't quite understand the config.
Where is the difficulty? I am happy to further explain if necessary. I did present the JSON viewer representation, because it is more compact than a screen shot. It does show all the settings in proper order though.
bogr
Posts: 190
Joined: 16 Nov 2015 22:46

Re: Notification depending on condition and time

Post by bogr »

I didn't say (or imply) it's _difficult_, just that _I_ didn't understand how you configured it in the logical rule, because I haven't seen any abilities to configure the time aspect in the logical rule app. I checked the app again and actually just saw the time entry in the "Type of condition"-drop down, so I was probably struck by temporary blindness :o - it's all crystal clear now.
pz1
Posts: 2053
Joined: 08 Apr 2012 13:44

Re: Notification depending on condition and time

Post by pz1 »

I did choose the word difficult, because I found it a bit rude to ask 'what is your problem' ;)
hwittler
Posts: 5
Joined: 20 Dec 2015 11:18

Re: Notification depending on condition and time

Post by hwittler »

pz1 wrote:This logical rule works for me for heating. It activates a scene that switches a couple of thermostatic radiator valves. The time settings do not trigger themselves, but rather determine in which time frame the temperature level may be evaluated. Click on image to get the full picture.
Capture.PNG

let me see if i get this right:

Your rule triggers whenever one of the devices triggers. This means whenever Object [2] changes you check if it is between 19:30 and 22:00 and testValue <= 9. If so you run LightScene_49.

I think that won't work for me because I want to check on the status of some devices not a change of one.

At the moment I trigger my rule when i close my shutters (which is basically the right time) and then check on the window sensors sending the notification if one is open. I am not completely happy with that solution but hope that it works that way.
If not I will try to play around with a dummy device. :)

Thanks for the tips though. I spend quite a lot of time trying to find out how something that should be simple is actually working. (usually by beeing simple but not by beeing the way i first thought it would work. :) )
pz1
Posts: 2053
Joined: 08 Apr 2012 13:44

Re: Notification depending on condition and time

Post by pz1 »

hwittler wrote:At the moment I trigger my rule when i close my shutters (which is basically the right time)
Is this meant to prevent shutters damaging open windows? If so you may have a look in the latest shutter and dows modules by Maros. Looks like is doing something about it.

(For my understanding: Do you close your shutters via a scene, and do you include that scene in the Trigger list for the Rule?
Seems a good solution. May well consider to use that instead, because it is simpler than mine.)
hwittler
Posts: 5
Joined: 20 Dec 2015 11:18

Re: Notification depending on condition and time

Post by hwittler »

pz1 wrote:
hwittler wrote:At the moment I trigger my rule when i close my shutters (which is basically the right time)
Is this meant to prevent shutters damaging open windows? If so you may have a look in the latest shutter and dows modules by Maros. Looks like is doing something about it.

(For my understanding: Do you close your shutters via a scene, and do you include that scene in the Trigger list for the Rule?
Seems a good solution. May well consider to use that instead, because it is simpler than mine.)
This is meant as a reminder that I haven't closed all the windows because I am to lazy to walk through all the rooms every day. :)

I close the shutters with a timed event by the astronomy module of Maros. (sunset + 3600 seconds). That works very well.

Right now the trigger list for the logical rule consists only of the scene that closes the shutters. Since it is called around the time i want to send out the note if any windows are still not closed for the night it sort of works.

Anyway, I am still in the process of learning the z-wave.me interface and its a lot try-and-error at the moment :)
kandalf
Posts: 54
Joined: 13 May 2016 11:10

Re: Notification depending on condition and time

Post by kandalf »

Hello,

can you explain me, what and with which apps you have configured to control the shutter and the astronomy module?
Are the shutter closing at the evening and opening in the morning fully automatically?
Raspberry PI with Z-Wave.me Board
2 x Fibaro Double Relay-Switch FGS 222
2 x Fibaro Shutter FGR 222
Fibaro Multi Sensor
Z-Wave.me RemoteControl
Post Reply