Can't figure out issue with raise alarm condition

This section covers the Meteobridge PRO, PRO2, NANO SD, Raspberry Pi and VM platforms exclusively

Moderator: Mattk

Post Reply
paravis
Junior Boarder
Junior Boarder
Posts: 28
Joined: Thu Dec 08, 2016 10:32 pm

Can't figure out issue with raise alarm condition

Post by paravis »

Here's my raise alarm condition:

(([wind0wind-avg10=mph]>=8||[wind0wind-max10=mph]>=15)&&(([wind0dir-act]>=0&&[wind0dir-act]<=60)||([wind0dir-act]>=300&&[wind0dir-act]<=360)))

Can anyone tell me what I'm doing wrong here? I'm getting errors under the "Triggered Alarms" for this one.

Thanks!
paravis
Junior Boarder
Junior Boarder
Posts: 28
Joined: Thu Dec 08, 2016 10:32 pm

Re: Can't figure out issue with raise alarm condition

Post by paravis »

Actually ... Very odd ...

So the alarm condition was triggered, sent a text message. (Yes, I don't want strong winds blowing from the north -- our newly planted trees were pushed and were not straight up last time it was this windy.)

But now it is working for some reason ... Anyway, I guess it is ok now ...
User avatar
admin
Platinum Boarder
Platinum Boarder
Posts: 7854
Joined: Mon Oct 01, 2007 10:51 pm

Re: Can't figure out issue with raise alarm condition

Post by admin »

you might add default values, when a sensor data is not there.
Otherwise evaluation will fail, when no sensor data.
paravis
Junior Boarder
Junior Boarder
Posts: 28
Joined: Thu Dec 08, 2016 10:32 pm

Re: Can't figure out issue with raise alarm condition

Post by paravis »

You are a genius ... !!

And by the way, we do have a few little devices similar to yours. Mainly for monitoring the solar power generators, as well as energy utilization (both of those using ZigBee SE). Your device is ABOVE AND BEYOND the most appropriate, capable, and legitimate gateway that we have.

Such an excellent little (and powerful) device. Thanks again.
User avatar
Ian.
Junior Boarder
Junior Boarder
Posts: 36
Joined: Tue Dec 20, 2016 12:01 am
Location: Chatteris, Cambridgeshire, UK
Contact:

Re: Can't figure out issue with raise alarm condition

Post by Ian. »

Hi paravis,

I'm a novice to Meteobridge Pro, would you mind posting your finished rule so I can work up my own from it please.

Cheers
CWOP - DW3371
PWS - ICAMBRID16
https://www.chatteris.biz
Image
paravis
Junior Boarder
Junior Boarder
Posts: 28
Joined: Thu Dec 08, 2016 10:32 pm

Re: Can't figure out issue with raise alarm condition

Post by paravis »

Hey there Ian --

Here's what I finished with. It's formatted a little better so you can actually see the separate parts in the logic. This particular raise/clear alarm is specifically to tell me when wind is blowing too hard from the north, where it might start to cause issues with my trees.

Also, to keep the system happy, I simply made the default values (when, for whatever reason, the sensor was not being read properly) to make the clear alarm statement true.

Raise Alarm:

(
([wind0wind-avg10=mph:0]>=8||[wind0wind-max10=mph:0]>=15)
&&
(
([wind0dir-act:180]>=0&&[wind0dir-act:180]<=60)
||
([wind0dir-act:180]>=300&&[wind0dir-act:180]<=360)
)
)

Clear Alarm:

(
([wind0wind-avg10=mph:0]<=1&&[wind0wind-max10=mph:0]<=6)
||
([wind0dir-act:180]>90&&[wind0dir-act:180]<270&&[wind0wind-max10=mph:0]<=6)
)

Hope that helps!
User avatar
Ian.
Junior Boarder
Junior Boarder
Posts: 36
Joined: Tue Dec 20, 2016 12:01 am
Location: Chatteris, Cambridgeshire, UK
Contact:

Re: Can't figure out issue with raise alarm condition

Post by Ian. »

Paravis,

Many thanks for posting this, it is really helpful.

The software the Meteobridge Pro is replacing had predefined alerts that I want to replicate, so looking at how you have done this is very useful.

All the best to you and yours

Ian
CWOP - DW3371
PWS - ICAMBRID16
https://www.chatteris.biz
Image
paravis
Junior Boarder
Junior Boarder
Posts: 28
Joined: Thu Dec 08, 2016 10:32 pm

Re: Can't figure out issue with raise alarm condition

Post by paravis »

Hey, no worries! Happy to help!
~Laz
Post Reply