When I feed the fish, I hit Feed A and the sump fills up past the point of my high level switch. What programming code can I use so that it doesn't send the alarm to my phone and sound the alarm on the system?
Sent from my iPhone using Tapatalk
When I feed the fish, I hit Feed A and the sump fills up past the point of my high level switch. What programming code can I use so that it doesn't send the alarm to my phone and sound the alarm on the system?
Sent from my iPhone using Tapatalk
In your alarm / email code you could simply add
If FeedA then OFF
but note that will cut off all alarms / emails during that feeding period.
Put the high level alarm code in a VO with the if feed a then off code and reference the VO in your alarm and it will only affect that particular alarm not all of them.
Based on the info IBroughtPopcorn has given, I see no reason to use a VO; in this case, a VO just adds complexity without any tangible benefit. This situation can be handled simply by using a suitable order for the statements in the email output.
Let's look at a typical basic email alarm program, which also has a statement to trigger an alert if a float switch or optical sensor indicates CLOSED due to the sump level is higher than normal.
[Email_Alrm]
Set OFF
If Temp < 77.5 Then ON
If Temp > 79.5 Then ON
If pH < 7.90 Then ON
If pH > 8.30 Then ON
If SumpHi CLOSED Then ON
Now let's add the If FeedA statement at the end:
[Email_Alrm]
Set OFF
If Temp < 77.5 Then ON
If Temp > 79.5 Then ON
If pH < 7.90 Then ON
If pH > 8.30 Then ON
If SumpHi CLOSED Then ON
If FeedA 001 Then OFF
With the above code, all alarms will be suppressed while If FeedA is active, which might or might not be desirable.
But I don't want to suppress any alarms for all conditions; I only want to suppress an alarm for high sump level during feeding. So all I need to do is change the order of the statements, moving the If SumpHi and If FeedA lines up to the top (just below the Set OFF):
[Email_Alrm]
Set OFF
If SumpHi CLOSED Then ON
If FeedA 001 Then OFF
If Temp < 77.5 Then ON
If Temp > 79.5 Then ON
If pH < 7.90 Then ON
If pH > 8.30 Then ON
Now, only the SumpHi condition is suppressed while FeedA is active - abnormal Temp or pH conditions can still trigger the alarm.
Please do not send me PMs with technical questions or requesting assistance - use the forums for Apex help. PM me ONLY if the matter is of a private or personal nature. Thanks.
[Email_Alrm]
Set OFF
If SumpHi CLOSED Then ON
If FeedA 001 Then OFF
If Temp < 77.5 Then ON
If Temp > 79.5 Then ON
If pH < 7.90 Then ON
If pH > 8.30 Then ON
Now, only the SumpHi condition is suppressed while FeedA is active - abnormal Temp or pH conditions can still trigger the alarm.[/QUOTE]
Thank you. I think I need to defer the alarm by a minute after the feedA is complete to allow the water level to return to normal. Does it matter what order the defer statement is implemented?
Sent from my iPhone using Tapatalk
You do not need or want to use a Defer. Instead, add more time as necessary to the If FeedA statement. I already added an extra minute. If that's not long enough to allow time for the water level to normalize, increase that value.
Please do not send me PMs with technical questions or requesting assistance - use the forums for Apex help. PM me ONLY if the matter is of a private or personal nature. Thanks.
That's why we pay him the big bucks! Thanks RussM
Bookmarks