Wrong zwave switch level displayed On, 255 %

For Z-Wave related questions in Domoticz

Moderator: leecollings

User avatar
warp
Posts: 33
Joined: Thursday 07 May 2015 12:51
Target OS: Raspberry Pi / ODroid
Domoticz version: Beta
Location: Fr
Contact:

Wrong zwave switch level displayed On, 255 %

Post by warp »

-Raspberry pi2B with Domoticz V2.3678
-RaZberry with OpenZWave V1.3-550-g4a2b2e5
-Qubino ZMNHBA2 Flush 2 Relays
Ok.PNG
Ok.PNG (6.17 KiB) Viewed 3767 times
I have several problems on my Qubino ZMNHBA2 :
The first :
1°) when i click on the 001C01,
  • State reports to "On" for 001C01 -> Good Behaviour
Step2.PNG
Step2.PNG (6.28 KiB) Viewed 3767 times
2°) when i click on the 001C02,
  • State reports to "On" for 001C02 -> Goog Behaviour
    State reports to "On,Level 255%" for 001C01 -> Why, Bad Behaviour ?
    State reports RF Signal Level to "-" -> Why ?
Step3.PNG
Step3.PNG (6.57 KiB) Viewed 3767 times
The second :
- when i click on the 001C02,
  • State reports to "On,Level 255%" for 001C01 -> But the relay of the switch 001C01 is not at "On" !
It seems that other people have the same problem, right?
viewtopic.php?f=6&t=5698
viewtopic.php?f=17&t=7043

help me @gizmocuz..
Raspberry 2B:RaZberry Z-Wave+:Edimax EW-7811UN:Huawei E220 3G
4xQubino ZMNHCA2
Everspring SE812 & ST812
Mcohome MH-S411 & MH-S412
2xAEON LABS ZW-100
2xFibaro FGSD-002:Fibaro FGFS-101:Fibaro FGS-221 & KLF-050
User avatar
Egregius
Posts: 2592
Joined: Thursday 09 April 2015 12:19
Target OS: Linux
Domoticz version: v2024.7
Location: Beitem, BE
Contact:

Re: Wrong zwave switch level displayed On, 255 %

Post by Egregius »

Remove the 'mapping = endpoints' line at the bottom of the Config XML.
Then you'll have 3 switches. 2 & 3 will work properly then.

This isn't a actual problem of Domoticz but from Openzwave.
User avatar
warp
Posts: 33
Joined: Thursday 07 May 2015 12:51
Target OS: Raspberry Pi / ODroid
Domoticz version: Beta
Location: Fr
Contact:

Re: Wrong zwave switch level displayed On, 255 %

Post by warp »

Egregius wrote:Remove the 'mapping = endpoints' line at the bottom of the Config XML.
Then you'll have 3 switches. 2 & 3 will work properly then.

This isn't a actual problem of Domoticz but from Openzwave.
I have 3 switches now ..
But I still have problems:
When I click on the switch 2, switch State reports to "On"
When I click on the switch 3, switch 2 & 3 State reports to "On", :?
Raspberry 2B:RaZberry Z-Wave+:Edimax EW-7811UN:Huawei E220 3G
4xQubino ZMNHCA2
Everspring SE812 & ST812
Mcohome MH-S411 & MH-S412
2xAEON LABS ZW-100
2xFibaro FGSD-002:Fibaro FGFS-101:Fibaro FGS-221 & KLF-050
User avatar
Egregius
Posts: 2592
Joined: Thursday 09 April 2015 12:19
Target OS: Linux
Domoticz version: v2024.7
Location: Beitem, BE
Contact:

Re: Wrong zwave switch level displayed On, 255 %

Post by Egregius »

And then use the script in viewtopic.php?f=17&t=7043&start=40#p54276
Works fine here :)
User avatar
warp
Posts: 33
Joined: Thursday 07 May 2015 12:51
Target OS: Raspberry Pi / ODroid
Domoticz version: Beta
Location: Fr
Contact:

Re: Wrong zwave switch level displayed On, 255 %

Post by warp »

Thank you you got to answer @Egregius

I have two questions:
  • 1) Or should we set this script ?
    2) Have you opened a ticker in OpenZwave for this problem ?
For information I have a switch "Mcohome MH-S412 Two-load" with the 'mapping =endpoints' line at the bottom of the XML Config, and it Works fine .
Mcohome MH-S412 .jpg
Mcohome MH-S412 .jpg (6.1 KiB) Viewed 3682 times
Raspberry 2B:RaZberry Z-Wave+:Edimax EW-7811UN:Huawei E220 3G
4xQubino ZMNHCA2
Everspring SE812 & ST812
Mcohome MH-S411 & MH-S412
2xAEON LABS ZW-100
2xFibaro FGSD-002:Fibaro FGFS-101:Fibaro FGS-221 & KLF-050
User avatar
Egregius
Posts: 2592
Joined: Thursday 09 April 2015 12:19
Target OS: Linux
Domoticz version: v2024.7
Location: Beitem, BE
Contact:

Re: Wrong zwave switch level displayed On, 255 %

Post by Egregius »

User avatar
warp
Posts: 33
Joined: Thursday 07 May 2015 12:51
Target OS: Raspberry Pi / ODroid
Domoticz version: Beta
Location: Fr
Contact:

Re: Wrong zwave switch level displayed On, 255 %

Post by warp »

Where should we set this script php ?
Raspberry 2B:RaZberry Z-Wave+:Edimax EW-7811UN:Huawei E220 3G
4xQubino ZMNHCA2
Everspring SE812 & ST812
Mcohome MH-S411 & MH-S412
2xAEON LABS ZW-100
2xFibaro FGSD-002:Fibaro FGFS-101:Fibaro FGS-221 & KLF-050
User avatar
Egregius
Posts: 2592
Joined: Thursday 09 April 2015 12:19
Target OS: Linux
Domoticz version: v2024.7
Location: Beitem, BE
Contact:

Re: Wrong zwave switch level displayed On, 255 %

Post by Egregius »

Doesn't mather.
If you put it in the scripts folder you can call it by script://nameoffile.php
If it's somewhere else you'll need to specify the full path script:///path/nameoffile.php
User avatar
warp
Posts: 33
Joined: Thursday 07 May 2015 12:51
Target OS: Raspberry Pi / ODroid
Domoticz version: Beta
Location: Fr
Contact:

Re: Wrong zwave switch level displayed On, 255 %

Post by warp »

Egregius wrote:Doesn't mather.
If you put it in the scripts folder you can call it by script://nameoffile.php
If it's somewhere else you'll need to specify the full path script:///path/nameoffile.php
Sorry but my question was, or should I interfaced the php script ?
- in cron?
- in the actions on-off of the switch?
- or other ?
Raspberry 2B:RaZberry Z-Wave+:Edimax EW-7811UN:Huawei E220 3G
4xQubino ZMNHCA2
Everspring SE812 & ST812
Mcohome MH-S411 & MH-S412
2xAEON LABS ZW-100
2xFibaro FGSD-002:Fibaro FGFS-101:Fibaro FGS-221 & KLF-050
User avatar
Egregius
Posts: 2592
Joined: Thursday 09 April 2015 12:19
Target OS: Linux
Domoticz version: v2024.7
Location: Beitem, BE
Contact:

Re: Wrong zwave switch level displayed On, 255 %

Post by Egregius »

I have a refreshzwave in my script that runs after every switch update (thru domoticz_main)
If one of those switches is changed in the last 5 seconds I call the refreshzwave function for it.

Code: Select all

//Refresh Zwave node
	if($STTV>$time-5) RefreshZwave(10);
	if($STLichtTerrasGarage>$time-5) RefreshZwave(16);
	if($STLichtHallZolder>$time-5) RefreshZwave(20);
	if($STLichtInkomVoordeur>$time-5) RefreshZwave(23);
	if($STBureel_Tobi>$time-5) RefreshZwave(24);
	if($STSubwoofer>$time-5) RefreshZwave(51);
	if($STLamp_Bureel>$time-5) RefreshZwave(52);
	if($STPluto>$time-5) RefreshZwave(53);
	if($STKeukenZolder>$time-5) RefreshZwave(56);
	
I also have another that just runs by cron every 30 minutes. I like to call it custom polling ;)

Code: Select all

<?php 
file_get_contents('http://127.0.0.1:8080/json.htm?type=openzwavenodes&idx=5'); //Change IDX to IDX of your zwave controller
function RefreshZwave($node) {
	$zwaveurl='http://127.0.0.1:8080/ozwcp/refreshpost.html';
	$zwavedata=array('fun'=>'racp','node'=>$node);
	$zwaveoptions = array('http'=>array('header'=>'Content-Type: application/x-www-form-urlencoded\r\n','method'=>'POST','content'=>http_build_query($zwavedata),),);
	$zwavecontext=stream_context_create($zwaveoptions);
	for ($k=1;$k<=5;$k++){sleep(2);$result=file_get_contents($zwaveurl,false,$zwavecontext);if($result=='OK') break;}
}
RefreshZwave(10);
RefreshZwave(16);
RefreshZwave(20);
RefreshZwave(23);
RefreshZwave(24);
RefreshZwave(51);
RefreshZwave(52);
RefreshZwave(53);
RefreshZwave(56);
RefreshZwave(60);
RefreshZwave(61);
RefreshZwave(62);
RefreshZwave(63);
User avatar
warp
Posts: 33
Joined: Thursday 07 May 2015 12:51
Target OS: Raspberry Pi / ODroid
Domoticz version: Beta
Location: Fr
Contact:

Re: Wrong zwave switch level displayed On, 255 %

Post by warp »

@Egregius
Can you give me the exact code of your domoticz_main ?
Raspberry 2B:RaZberry Z-Wave+:Edimax EW-7811UN:Huawei E220 3G
4xQubino ZMNHCA2
Everspring SE812 & ST812
Mcohome MH-S411 & MH-S412
2xAEON LABS ZW-100
2xFibaro FGSD-002:Fibaro FGFS-101:Fibaro FGS-221 & KLF-050
User avatar
Egregius
Posts: 2592
Joined: Thursday 09 April 2015 12:19
Target OS: Linux
Domoticz version: v2024.7
Location: Beitem, BE
Contact:

Re: Wrong zwave switch level displayed On, 255 %

Post by Egregius »

Sure ;)

Code: Select all

#!/bin/sh
curl 'http://127.0.0.1/secure/cron.php'
I use curl instead of /usr/bin/php because it allows use of xcache.
stolle
Posts: 1
Joined: Sunday 28 December 2014 4:40
Target OS: Raspberry Pi / ODroid
Domoticz version:
Location: Sweden
Contact:

Re: Wrong zwave switch level displayed On, 255 %

Post by stolle »

Hi,
I got the same problem and is wondering if I shall exclude/include the device after removing the mapping=endpoint line?
User avatar
warp
Posts: 33
Joined: Thursday 07 May 2015 12:51
Target OS: Raspberry Pi / ODroid
Domoticz version: Beta
Location: Fr
Contact:

Re: Wrong zwave switch level displayed On, 255 %

Post by warp »

@Egregius
Can you give me the exact code of your domoticz_main ?
Raspberry 2B:RaZberry Z-Wave+:Edimax EW-7811UN:Huawei E220 3G
4xQubino ZMNHCA2
Everspring SE812 & ST812
Mcohome MH-S411 & MH-S412
2xAEON LABS ZW-100
2xFibaro FGSD-002:Fibaro FGFS-101:Fibaro FGS-221 & KLF-050
User avatar
Egregius
Posts: 2592
Joined: Thursday 09 April 2015 12:19
Target OS: Linux
Domoticz version: v2024.7
Location: Beitem, BE
Contact:

Re: Wrong zwave switch level displayed On, 255 %

Post by Egregius »

User avatar
warp
Posts: 33
Joined: Thursday 07 May 2015 12:51
Target OS: Raspberry Pi / ODroid
Domoticz version: Beta
Location: Fr
Contact:

Re: Wrong zwave switch level displayed On, 255 %

Post by warp »

Code: Select all

#!/bin/sh
curl 'http://127.0.0.1/secure/cron.php'
@Egregius
Sorry but i could not find "cron.php"
Raspberry 2B:RaZberry Z-Wave+:Edimax EW-7811UN:Huawei E220 3G
4xQubino ZMNHCA2
Everspring SE812 & ST812
Mcohome MH-S411 & MH-S412
2xAEON LABS ZW-100
2xFibaro FGSD-002:Fibaro FGFS-101:Fibaro FGS-221 & KLF-050
User avatar
Egregius
Posts: 2592
Joined: Thursday 09 April 2015 12:19
Target OS: Linux
Domoticz version: v2024.7
Location: Beitem, BE
Contact:

Re: Wrong zwave switch level displayed On, 255 %

Post by Egregius »

It's on my github, see link in signature below.
User avatar
warp
Posts: 33
Joined: Thursday 07 May 2015 12:51
Target OS: Raspberry Pi / ODroid
Domoticz version: Beta
Location: Fr
Contact:

Re: Wrong zwave switch level displayed On, 255 %

Post by warp »

Egregius wrote:It's on my github, see link in signature below.
Thank you, but your "cron.php" script is too complicated for me, I will have wished to have only the part concerning the problem of QUBINO ZMNHBA2.
Raspberry 2B:RaZberry Z-Wave+:Edimax EW-7811UN:Huawei E220 3G
4xQubino ZMNHCA2
Everspring SE812 & ST812
Mcohome MH-S411 & MH-S412
2xAEON LABS ZW-100
2xFibaro FGSD-002:Fibaro FGFS-101:Fibaro FGS-221 & KLF-050
User avatar
Egregius
Posts: 2592
Joined: Thursday 09 April 2015 12:19
Target OS: Linux
Domoticz version: v2024.7
Location: Beitem, BE
Contact:

Re: Wrong zwave switch level displayed On, 255 %

Post by Egregius »

You only need the refreshzwave function.
There's a complete example in one of the other qubino topics.
User avatar
warp
Posts: 33
Joined: Thursday 07 May 2015 12:51
Target OS: Raspberry Pi / ODroid
Domoticz version: Beta
Location: Fr
Contact:

Re: Wrong zwave switch level displayed On, 255 %

Post by warp »

@Egregius
Thank, for the cron.php and the refreshzwave function.
But if i want refresh after every switch update , how to do ?
Raspberry 2B:RaZberry Z-Wave+:Edimax EW-7811UN:Huawei E220 3G
4xQubino ZMNHCA2
Everspring SE812 & ST812
Mcohome MH-S411 & MH-S412
2xAEON LABS ZW-100
2xFibaro FGSD-002:Fibaro FGFS-101:Fibaro FGS-221 & KLF-050
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest