Contact Door DIO 54781
Posted: 15 Aug 2017, 14:13
Hello,
I have a detection problem with the DIO sensor. Indeed, the closure contact is well deduced, however the opening contact rarely.
I am in version R46 for RFLink and in V3.8292 for domoticz on Raspi 3.
After analysis it appears that the door openings (CMD = ON of the DIO) are sometimes decoded like a dimmer with CMD = SET_LEVEL = 2 (or 4 or other) and not as CMD = ON.
I was able to solve this problem of detection of openings only by using a recompiled old version (R33) and by modifying the source of the plugin 4 corresponding to the protocol NewKaku (see the two lines commented after the if (i> 140) and the following one replacing them):
int command = (bitstream >> 4) & 0x03;
if (command > 1) command ++;
if (i>140) { // Command and Dim part
// sprintf(pbuffer, "SET_LEVEL=%d;", dim );
// Serial.print( pbuffer );
Serial.print(F("ON;"));
} else {
if ( command == 0 ) Serial.print(F("OFF;"));
if ( command == 1 ) Serial.print(F("ON;"));
if ( command == 3 ) Serial.print(F("ALLOFF;"));
if ( command == 4 ) Serial.print(F("ALLON;"));
}
Serial.println();
The disadvantage is that my milight bulbs and others rflink devices are no longer working.
Does anyone have the same problem?
Is there a way to fix this in the R46 version?
Is it possible to download the sources of the R46?
Thanks.
I have a detection problem with the DIO sensor. Indeed, the closure contact is well deduced, however the opening contact rarely.
I am in version R46 for RFLink and in V3.8292 for domoticz on Raspi 3.
After analysis it appears that the door openings (CMD = ON of the DIO) are sometimes decoded like a dimmer with CMD = SET_LEVEL = 2 (or 4 or other) and not as CMD = ON.
I was able to solve this problem of detection of openings only by using a recompiled old version (R33) and by modifying the source of the plugin 4 corresponding to the protocol NewKaku (see the two lines commented after the if (i> 140) and the following one replacing them):
int command = (bitstream >> 4) & 0x03;
if (command > 1) command ++;
if (i>140) { // Command and Dim part
// sprintf(pbuffer, "SET_LEVEL=%d;", dim );
// Serial.print( pbuffer );
Serial.print(F("ON;"));
} else {
if ( command == 0 ) Serial.print(F("OFF;"));
if ( command == 1 ) Serial.print(F("ON;"));
if ( command == 3 ) Serial.print(F("ALLOFF;"));
if ( command == 4 ) Serial.print(F("ALLON;"));
}
Serial.println();
The disadvantage is that my milight bulbs and others rflink devices are no longer working.
Does anyone have the same problem?
Is there a way to fix this in the R46 version?
Is it possible to download the sources of the R46?
Thanks.