Announcement

Collapse
No announcement yet.

Any 2 sensors triggered in a group of 6

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • w.vuyk
    replied
    Creative solution! Might use similar events in the future

    Leave a comment:


  • logman
    replied
    Yes, sorry... I was a bit sloppy in my typing when I posted that and left out some colons and parentheses. Glad you got it figured out and that it worked for you.

    --Barry

    Leave a comment:


  • nickgosling
    replied
    This has done the trick. I changed the code a little as some of the brackets etc didn't seem to be in the right place for me. I also ended up making the number 300 as my Xiaomi devices report 100 instead of 255. However I'm using a mix of fibaro's (255) and xiaomi's (100) so 300 seemed a decent compromise. Here is the code that I used. Note that I needed to add another set of colons at the end of the device ref as the help file seems to suggest that they are needed.

    Thanks so much for the reply its a perfect solution and I wouldn't have been able to do it otherwise.

    I cant seem to write this code without it populating with smiley faces and I have tried editing it about 10 times. The smiley faces are a colon and a bracket. AKA a smiley face if I was sending a text.

    ""(($$DVR:1057+($$DVR:498+($$DVR:166+($$DVR:1657+($$DVR:1675+($$DVR:1344>300""

    Again: Sorry for posting this in the Jowi hue forum. I don't know how to move it.

    Click image for larger version  Name:	2 triggers.png Views:	0 Size:	71.9 KB ID:	1524181

    Leave a comment:


  • nickgosling
    replied
    That's a great solution. I'll give it a go. I would never have thought of that expression.

    Thank you. I will report back once I've tested.

    Leave a comment:


  • logman
    replied
    I ran into this in our garage where we keep several small cats in the winter. If you have EasyTrigger, then what you want to do is possible by creating a MotionGroup containing your 6 sensors. You would then set up an event like this:

    Code:
    IF [LEFT][SIZE=16px][COLOR=#212529][FONT=Roboto]Any device in group [/FONT][/COLOR][/SIZE][COLOR=#000080][FONT=Roboto][SIZE=16px]GarageMotion [/SIZE][/FONT][/COLOR][SIZE=16px][COLOR=#212529][FONT=Roboto]had its value set and this expression [/FONT][/COLOR][/SIZE][COLOR=#000080][FONT=Roboto][SIZE=16px]$$DVR:001)+$$DVR:002)+$$DVR:003)+($$DVR:004)+($$DVR:005)+$$DVR:006)>509 [/SIZE][/FONT][/COLOR][SIZE=16px][COLOR=#212529][FONT=Roboto]is true;[/FONT][/COLOR][/SIZE]
    
    THEN
    Set Device:
    1st Floor Garage Garage Occupancy to Occupied[/LEFT]
    The above assumes your motion sensors report motion as value 255 and no motion as 0. You will need to replace the 001, 002, etc with your actual device reference numbers. So if any 2 or more motion sensors are reporting motion at the same time (value total =510+), then the expression becomes true and it will toggle your virtual device. This should cut down on your falsies yet still be fairly reliable if you have your motion sensors placed pretty well.

    Click image for larger version  Name:	example2.png Views:	0 Size:	45.9 KB ID:	1524173

    --Barry

    Leave a comment:


  • nickgosling
    started a topic Any 2 sensors triggered in a group of 6

    Any 2 sensors triggered in a group of 6

    Sorry. Wrong sub forum. Can't seem to delete this post......

    I'm not sure this is possible. All I want to achieve is to have a virtual device that triggers if 2 sensors in my group of 6 sensors are triggered within a certain time of each other. We have pets and I keep getting false alerts. So I figured if we are getting burgled if 2 sensors are triggered within say 30 seconds then that's probably an intruder.

    This is what I have done so far but it doesn't seem to be prefect.

    P.s. the "at least" always seems to default to exactly but it still seems to work as an "at least" statement.

    Click image for larger version  Name:	Screenshot_20220125-093539_Chrome.jpg Views:	0 Size:	62.1 KB ID:	1523092
    ​​​​​​​
    Last edited by nickgosling; January 25, 2022, 04:39 AM. Reason: Wrong sub forum
Working...
X