LinuxMCE Forums
May 20, 2013, 04:37:24 pm GMT-1 *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
News: Rule #1 - Be Patient - Rule #2 - Don't ask when, if you don't contribute - Rule #3 - You have coding skills - LinuxMCE's small brother is available: http://www.agocontrol.com
 
   Home   Help Search Chat Login Register  
Pages: [1]
  Print  
Author Topic: Responding to z-wave sensor events  (Read 1080 times)
caiman
Veteran
***
Posts: 119



View Profile
« on: May 13, 2008, 11:11:20 pm »

I have added two z-wave PIR sensors and defined the event handler as follows:

- Respond to events
- An sensor is tripped
- What device = "sensor hall"
- What time of day <> "DAYTIME"
- Event parameter "triggered" = 255
- action: switch on a light nearby

When I trigger the sensor I get this in the ZWave logs:
Code:
05      05/14/08 0:01:16.866            alarmPIRHandler : node: 18 report: 255 <0xb68f9b90>
05      05/14/08 0:01:16.867            SendSensorTrippedEvents: wrong node ID: 18, 19 <0xb68f9b90>
05      05/14/08 0:01:16.867            SendSensorTrippedEvents: wrong node ID: 18, 2 <0xb68f9b90>
05      05/14/08 0:01:16.867            SendSensorTrippedEvents: wrong node ID: 18, 3 <0xb68f9b90>
05      05/14/08 0:01:16.867            SendSensorTrippedEvents: wrong node ID: 18, 4 <0xb68f9b90>
05      05/14/08 0:01:16.867            SendSensorTrippedEvents: wrong node ID: 18, 5 <0xb68f9b90>
05      05/14/08 0:01:16.867            SendSensorTrippedEvents: wrong node ID: 18, 6 <0xb68f9b90>
05      05/14/08 0:01:16.867            SendSensorTrippedEvents: wrong node ID: 18, 8 <0xb68f9b90>
05      05/14/08 0:01:16.867            SendSensorTrippedEvents: wrong node ID: 18, 11 <0xb68f9b90>
05      05/14/08 0:01:16.867            SendSensorTrippedEvents: wrong node ID: 18, 12 <0xb68f9b90>
05      05/14/08 0:01:16.867            SendSensorTrippedEvents: wrong node ID: 18, 13 <0xb68f9b90>
05      05/14/08 0:01:16.867            SendSensorTrippedEvents: wrong node ID: 18, 14 <0xb68f9b90>
05      05/14/08 0:01:16.867            SendSensorTrippedEvents: wrong node ID: 18, 15 <0xb68f9b90>
05      05/14/08 0:01:16.867            SendSensorTrippedEvents: wrong node ID: 18, 16 <0xb68f9b90>
05      05/14/08 0:01:16.867            SendSensorTrippedEvents: wrong node ID: 18, 21 <0xb68f9b90>
05      05/14/08 0:01:16.867            SendSensorTrippedEvents: wrong node ID: 18, 1 <0xb68f9b90>

Two questions:
- is the config correct ?
- what does the wrong node ID message mean ?

thanks in advance...
Logged
caiman
Veteran
***
Posts: 119



View Profile
« Reply #1 on: May 15, 2008, 08:30:07 pm »

So the correct value for an event "sensor tripped ON" is 1 and not 255 as I had configured, which gives:
- Respond to events
- An sensor is tripped
- What device = "sensor hall"
- What time of day <> "DAYTIME"
- Event parameter "triggered" = 1
- action: switch on a light nearby

I have also added a handler for sensor tripped OFF (0) which turns off the line after a small timer. Neat.

The error
Code:
SendSensorTrippedEvents: wrong node ID:
remains, but it doesn't harm...

happy Smiley
Logged
caiman
Veteran
***
Posts: 119



View Profile
« Reply #2 on: May 19, 2008, 04:43:40 pm »

I'm successfully using the sensors to turn on the lamps now, but the "time of day" criteria does not work for me. First there was a mistake: "DAYTIME" does not exist so the condition was always true. The right one seems to be "Daytime". However, it seems that "time of day" is always set to "Daytime" which means the event is never triggered.

Any idea where that variable is supposed to be updated ?
Logged
chrisbirkinshaw
Guru
****
Posts: 431


View Profile
« Reply #3 on: May 19, 2008, 07:05:45 pm »

How did you set up the timers? I wanted to have a 2 min timer which starts counting down when the light is turned on but then is reset when more movement is detected. However I couldn't see any way to restart the timer.


Logged
caiman
Veteran
***
Posts: 119



View Profile
« Reply #4 on: May 20, 2008, 08:31:51 am »

I used to send a Delay command to DCErouter but now I am just catching the "sensor triggered == 0" which is sent by the sensor when no movement is detected. On my zwave PIR sensors, it conveniently does it a few minutes after it's triggered. I didn't test whether the timer in the sensor itself was reset when more movement is detected.
Logged
chrisbirkinshaw
Guru
****
Posts: 431


View Profile
« Reply #5 on: May 21, 2008, 02:10:17 pm »

The problem I can see here is that you enter a room, the light comes on, then after 2 mins it turns off and then back on again. Even if you are still moving the timer for turning the light off does not get cancelled or extended.


Logged
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines Valid XHTML 1.0! Valid CSS!