Jump to content

Leak Sensor Timeout Program


Go to solution Solved by MrBill,

Recommended Posts

Posted (edited)

Hi All - I need some assistance programming the Timeout program for my Leak Detectors. As I learned from @MrBillcomments do nothing and I am not sure how to follow these instructions.

The programming I have followed - https://www.termpro.com/asp/pubs.asp?ID=443

What I know -

The 9 Leak Detectors all work and trip the electronic valve to shut down water supply to house.

New Energizer Lithium batteries in each. 

After testing each Detector, I pressed the re-set button to return to dry status

The programming I followed to measure the Detector's heartbeat has been sending updates within every 24 hours for the past week.

This is what the programming should look like:

timeout.jpg

 

This is what I have: ( I know this is not correct ) I have // Time is Last Run..........as a comment. When I click on Add And (...) I can not figure out how to add Time is Last Run Time for 'Guest Bath Sink - Heartbeat' + 25 hours without it being a comment. 

 

Guest Bath Sink-Timeout - [ID 001E][Parent 0012]

If
        $sGuestBathroomSink is not 3
        
        // Time is Last Run Time for 'Guest Bath Sink - Heartbeat' + 25 hours
 
 
Then
        $sGuestBathroomSink  = 2
 
Else
   - No Actions - (To add one, press 'Action')

 

What am I missing? Thanks in advance for anyone's help.

Gary

Edited by FloridaGary
  • Solution
Posted

Click on the IF statement, Click the schedule button, the last dropdown in the TIme line defaults to "Time", change it to last run and you should be able to figure out the rest.

Posted (edited)

image.thumb.png.ddccc92c52edb4fcbea4cb3ca1e070ec.png

Does that help!?  ?

 

FWIW ...

Here is my heartbeat routine, it works. I don't bother repeating the warning. It sends an initial email to confirm that it is active. If a heartbeat comes within 26 hrs, then it restarts and sends another email to show it is working. I don't monitor those emails, they get filtered to a folder for reference should I need it.

But, if there is no heartbeat within 26 hours, it sends a text message indicating that heartbeats have lapsed.

It is also important to monitor for switched ON + switched OFF.

* Orest

 

Heartbeat Kitchen - [ID 021B][Parent 0135]

If
        'kitchen / LEAK - Kitchen-Heartbeat' is switched On
     Or 'kitchen / LEAK - Kitchen-Heartbeat' is switched Off
 
Then
        Send Notification to 'xxxxxxxx - GMail' content '$my_alert'
        Wait  26 hours
        Send Notification to 'xxxxxx - Text' content 'LEAK Heartbeat MISSED'
        Run Program 'Heartbeat Kitchen' (If)
 
Else
   - No Actions - (To add one, press 'Action')
 

 

Edited by oskrypuch
  • Like 1
Posted

@oskrypuch

Without testing I don't think this is doing what you want it to:

Heartbeat Kitchen - [ID 021B][Parent 0135]

If
        'kitchen / LEAK - Kitchen-Heartbeat' is switched On
     Or 'kitchen / LEAK - Kitchen-Heartbeat' is switched Off
 
Then
        Send Notification to 'xxxxxxxx - GMail' content '$my_alert'
        Wait  26 hours
        Send Notification to 'xxxxxx - Text' content 'LEAK Heartbeat MISSED'
        Run Program 'Heartbeat Kitchen' (If) (then)
 
Else
   - No Actions - (To add one, press 'Action')

 

Specifically I'd make the change in RED.   When it run's If as you have it set, the if will be false.  "is switched" is looking for the signal to come in, that only happens for less than 1 second each day.  Therefor when you re-run (if) the If will be false and it will execute the empty else.  If you change as indicated above you will get a repeat nag in 26 hours if the heartbeat sill hasn't arrived.

Posted (edited)
43 minutes ago, MrBill said:

Click on the IF statement, Click the schedule button, the last dropdown in the TIme line defaults to "Time", change it to last run and you should be able to figure out the rest.

Thank you @MrBill. This helped, but how did the programs author add the (+ 25 hours )?

Edited by FloridaGary
Posted
37 minutes ago, oskrypuch said:

image.thumb.png.ddccc92c52edb4fcbea4cb3ca1e070ec.png

Does that help!?  ?

 

FWIW ...

Here is my heartbeat routine, it works. I don't bother repeating the warning. It sends an initial email to confirm that it is active. If a heartbeat comes within 26 hrs, then it restarts and sends another email to show it is working. I don't monitor those emails, they can filtered to a folder for reference should I need it.

But, if there is no heartbeat within 26 hours, it sends a text message indicating that heartbeats have lapsed.

It is also important to monitor for switched ON + switched OFF.

* Orest

 

Heartbeat Kitchen - [ID 021B][Parent 0135]

If
        'kitchen / LEAK - Kitchen-Heartbeat' is switched On
     Or 'kitchen / LEAK - Kitchen-Heartbeat' is switched Off
 
Then
        Send Notification to 'xxxxxxxx - GMail' content '$my_alert'
        Wait  26 hours
        Send Notification to 'xxxxxx - Text' content 'LEAK Heartbeat MISSED'
        Run Program 'Heartbeat Kitchen' (If)
 
Else
   - No Actions - (To add one, press 'Action')
 

 

Thank you. I still had a question which I posted in response to Mr.Bill. You show the "wait time" in the Then section, but the author of the program I am following shows it in the "If" statement. Trying to figure out how he did that.

Posted (edited)
44 minutes ago, MrBill said:

@oskrypuch

.... Therefor when you re-run (if) the If will be false and it will execute the empty else.  If you change as indicated above you will get a repeat nag in 26 hours if the heartbeat sill hasn't arrived.

Thanks, but no, actually, I only want to receive ONE nag text, preceded by the $alert email when a beat is actually sent, so that is why I send it back to IF to reset the routine. I actually won't lose track of that single text. The email alert I use more for archive.

Of course if it remains without a heartbeat, there will be no further activity.

* Orest

Edited by oskrypuch
Posted
2 hours ago, oskrypuch said:

Thanks, but no, actually, I only want to receive ONE nag text, preceded by the $alert email when a beat is actually sent, so that is why I send it back to IF to reset the routine. I actually won't lose track of that single text. The email alert I use more for archive.

Of course if it remains without a heartbeat, there will be no further activity.

* Orest

In that case you can simply delete that line from the program.

3 hours ago, MrBill said:

Run Program 'Heartbeat Kitchen' (If) (then)

It doesn't do anything.

  • Like 1
Posted (edited)
4 minutes ago, MrBill said:

In that case you can simply delete that line from the program.

It doesn't do anything.

Thanks, you are quite right.

Looking at it again, that line must be a bit of old code that never got deleted, when I was reworking the routine at some time in the past.

* Orest

Edited by oskrypuch
Posted
4 minutes ago, oskrypuch said:

Thanks, you are quite right.

Looking at it again, that line must be a bit of old code that never got deleted, when I was reworking the routine at some time in the past.

* Orest

Probably copied from one of my examples.  I like to restart the Then, so that if i don't deal with it today I'll get reminded tomorrow if the issue still exists.  If it doesn't still exist (i.e. new heartbeat received) that resets the clock again and kills the nag.  Some of my 2421's are horrible about dropping heartbeats.

Posted (edited)

Likely, here is where it came from ...

Quote

Heartbeat TEST - [ID 021F][Parent 0135][Not Enabled]

If
   - No Conditions - (To add one, press 'Schedule' or 'Condition')
 
Then
        Wait  1 minute
        Send Notification to 'xxxxxxx - Text' content 'LEAK Heartbeat MISSED'
        Run Program 'Heartbeat TEST' (If)
 
Else
   - No Actions - (To add one, press 'Action')
 

 

This was a bit of sandbox code testing out the text message text, before I rolled it into the actual routines.

* Orest

Edited by oskrypuch
Guest
This topic is now closed to further replies.

×
×
  • Create New...