handling of X10 ms14a sensor corrected

git-svn-id: https://fhem.svn.sourceforge.net/svnroot/fhem/trunk/fhem@1411 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
wherzig
2012-04-04 18:43:07 +00:00
parent 795dc55253
commit 2ee200910f

View File

@@ -189,13 +189,20 @@ TRX_LIGHT_Define($$)
$type = uc($type); $type = uc($type);
my $device_name = "TRX".$DOT.$type.$DOT.$deviceid;
if ($type ne "X10" && $type ne "ARC" && $type ne "MS14A" && $type ne "AB400D" && $type ne "WAVEMAN" && $type ne "EMW200" && $type ne "IMPULS") { if ($type ne "X10" && $type ne "ARC" && $type ne "MS14A" && $type ne "AB400D" && $type ne "WAVEMAN" && $type ne "EMW200" && $type ne "IMPULS") {
Log 1,"RFX10SEC define: wrong type: $type"; Log 1,"TRX_LIGHT define: wrong type: $type";
return "RFX10SEC: wrong type: $type"; return "TRX_LIGHT: wrong type: $type";
} }
my $my_type;
if ($type eq "MS14A") {
$my_type = "X10"; # device will be received as X10
} else {
$my_type = $type;
}
my $device_name = "TRX".$DOT.$my_type.$DOT.$deviceid;
$hash->{TRX_LIGHT_deviceid} = $deviceid; $hash->{TRX_LIGHT_deviceid} = $deviceid;
$hash->{TRX_LIGHT_devicelog} = $devicelog; $hash->{TRX_LIGHT_devicelog} = $devicelog;
$hash->{TRX_LIGHT_type} = $type; $hash->{TRX_LIGHT_type} = $type;