Hi All,
I have multiple z-wave door contacts.
I use LUA to check on some of them how long they are open, and take action on that.
First I look at the status of the contact, and if it is Open then do something.
In general that works fine, but for two contacts the status queried by LUA gives me the battery level instead of the OPn/Close status.
The affected sensors are from Fibaro, the type is FIBARO System FGK101 Door Opening Sensor.
So for the Fibaro "StatusPoortSensor = otherdevices['Poort Sensor']" gives me the BatteryLevel.
And for the Vision Security Unknown: type=2001, id=0103 "StatusGarageSensor = otherdevices['Garage Sensor 01 Door Contact']" gives me the Open/Close status.
While writing and testing this I noticed for a Philio Technology Corp PST02-C Door/Window 3 in 1 sensor+ it reports also the battery level.
Hope someone can shed a light on this.
With Regards
Peer
Status Door Contact
Moderator: leecollings
-
- Posts: 70
- Joined: Monday 14 December 2015 22:16
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Location: Mierlo
- Contact:
-
- Posts: 70
- Joined: Monday 14 December 2015 22:16
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Location: Mierlo
- Contact:
Re: Status Door Contact
So after some trouble shooting, and converting LUA to python I see it is not a LUA problem.
In my python script I load the json data into a variabele and select the 'Poort Sensor' data.
It returns the same value as the LUA script (the battery percentage), while in my debug windows it shows clear the 'Closed' status.

So what you see is not what you get...…

In the browser when i query the api is see the same values as i see in the python debug.

So the story continues, will trouble shoot more but if someone can set me on the right track that would be much appreciated.
gr. Peer
In my python script I load the json data into a variabele and select the 'Poort Sensor' data.
It returns the same value as the LUA script (the battery percentage), while in my debug windows it shows clear the 'Closed' status.

So what you see is not what you get...…

In the browser when i query the api is see the same values as i see in the python debug.

So the story continues, will trouble shoot more but if someone can set me on the right track that would be much appreciated.
gr. Peer
-
- Posts: 70
- Joined: Monday 14 December 2015 22:16
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Location: Mierlo
- Contact:
Re: Status Door Contact
Ok a little more info,
When I query domoicz json straight to the idx of the sensor, the data is correct ??

So I am going to use this in my python scritpt, but I don't understand why this gives me the correct values.
Regards
Peer
When I query domoicz json straight to the idx of the sensor, the data is correct ??

So I am going to use this in my python scritpt, but I don't understand why this gives me the correct values.
Regards
Peer
Who is online
Users browsing this forum: No registered users and 1 guest