Motion Sensors trip immediately when set to Armed - but nothing is in the room!?

I just got a bunch of Schlage motion sensor… and for the most part they have been working perfectly.

One exception…

I have Automation setup to change them to/from Armed & Bypass as needed. This does work but when set to Armed, I get an immediate tripped state on one or more of them… even when there is no movement (no people, fans, etc) in the room. This happens day and night so light conditions don’t seem to matter.

This is VERY annoying when setting the home right before going to sleep at night.

Anyone seen this, or have any ideas?

Ghosts? :slight_smile:

Sorry, couldn’t resist.

I wonder if setting the Tripped variable on the sensor to 0 before arming it would fix this?

… You might be on to something here. I think the sensors that are going off are ones that are in Bypass but Tripped. So when they go to Armed, they must still be in Tripped state.

What LUUP code could I use in the Automation Scene to set Tripped = 0?

Since you have multiple sensors that you need to reset, try this:

[code]local SECURITY_SENSOR_SERVICE =“urn:micasaverde-com:serviceId:SecuritySensor1”

luup.variable_set (SECURITY_SENSOR_SERVICE, “Tripped”, 0, device)[/code]

device = the device ID of one of the motion sensors you want to reset.

If you have multiple sensors you want to reset, you can just keep adding additional [tt]luup.variable_set[/tt] lines or add this to the top of the luup code for the controlling scene:

function resetSensor (device) local SECURITY_SENSOR_SERVICE ="urn:micasaverde-com:serviceId:SecuritySensor1" luup.variable_set (SECURITY_SENSOR_SERVICE, "Tripped", 0, device) end

Then use:

resetSensor(<device>) 

as many time as you need to reset all the sensors before arming them.

If you want to clear then arm the sensor try this:

function resetSensor (device) local SECURITY_SENSOR_SERVICE ="urn:micasaverde-com:serviceId:SecuritySensor1" luup.variable_set (SECURITY_SENSOR_SERVICE, "Tripped", 0, device) luup.call_action(SECURITY_SENSOR_SERVICE,"SetArmed",{ newArmedValue="1" }, device) end

I’m assuming that this should work to clear the Tripped state of the sensor, but I have not tested it.

There is also a SetTripped handler for the SecuritySensor device. You can call it if you want to it to handle setting the Tripped variable. This only makes sense if you set Tripped to 1, since it also updates the LastTrip time.

thx, I’ll try it ans let you know how it works

SOlivas
Tried the code by itself in a Vera Automation scene - which works fine. Then I put it in my ‘Sleep’ scene and the motion sensors went off.

But, during some daytime testing it seems to work. I’ll do more real-world testing and let me know what happens.

thx for helping!

I tried the code but couldn’t get it to reset. Then again I have no idea what I’m doing. I finally looked at the manual for my ecolink motion sensor. I’m able to put it in “test” mode and it will reset after 5 second. I’m not sure how much this will effect battery life but it’s the only way I can keep it from tripping the siren when we switch to away mode when leaving the house.

homeuser

I use TEST mode on all my motion sensors… battery life still last over a year (I’ve yet to replace any battery in 6+ devices).
When I launch a scene (PLEG or Vera native) that involves arming a motion sensor, I run the below scene first, with a 1 second delay starting all other Actions. This allows all the motions sensors to remove the tripped state… as long as you are not currently tripping them. The alternative is to delay all your Actions by 5 seconds.

I created a native Vera Automation scene with the LUUP code like this…

[code]function resetSensor (device)
local SECURITY_SENSOR_SERVICE =“urn:micasaverde-com:serviceId:SecuritySensor1”
luup.variable_set (SECURITY_SENSOR_SERVICE, “Tripped”, 0, device)
end

resetSensor(147)
resetSensor(209)
resetSensor(163)
resetSensor(148)
resetSensor(164)
resetSensor(146)
resetSensor(151)
resetSensor(149)
resetSensor(155)
resetSensor(150)
resetSensor(145)
resetSensor(210)[/code]

This looks like it is exactly what I need, but where do I enter this loop code? I want this to execute every time I go to dashboard and click on away, so it resets my indoor motion sensor to not tripped before it is armed. If Igo to my modes, there is no way to enter luup code.

When trying to execute this inside a Scene I get an error. Can this code not be used there?

An easier solution is to use the modes since you are on UI7 and want to use away mode. Go into the modes dashboard, you set to away, arm on your sensors, but set the delay to away longer than the longest trip time of your sensors. This will allow your sensors to untrip before they are Armed.