diff --git a/fhem/CHANGED b/fhem/CHANGED index 9057e68bf..f96c5a52e 100644 --- a/fhem/CHANGED +++ b/fhem/CHANGED @@ -1,5 +1,6 @@ # Add changes at the top of the list. Keep it in ASCII, and 80-char wide. # Do not insert empty lines here, update check depends on it. + - bugfix: 98_weekprofile: detect channel of HM-CC-TC as correct thermostat - bugfix: 00_SIGNALduino: Version 3.2.0 Module & Firmware serval fixes and enhacements improved stability diff --git a/fhem/FHEM/98_weekprofile.pm b/fhem/FHEM/98_weekprofile.pm index bbb188c3a..520cec578 100644 --- a/fhem/FHEM/98_weekprofile.pm +++ b/fhem/FHEM/98_weekprofile.pm @@ -60,10 +60,19 @@ sub weekprofile_getDeviceType($;$) if ($devHash->{TYPE} =~ /CUL_HM/){ my $model = AttrVal($device,"model",""); - return undef if (!defined($devHash->{chanNo})); #no channel device + if (!defined($devHash->{chanNo})) { #no channel device + #Log 2, "weekprofile_getDeviceType: $devHash->{NAME}, $model, has no chanNo"; + return undef; + } - $type = "CUL_HM" if ( ($model =~ m/.*(HM-CC).*/) && ($devHash->{chanNo} == 4) ); - $type = "CUL_HM" if ( ($model =~ m/.*(HM-TC).*/) && ($devHash->{chanNo} == 2) ); + my $channel = $devHash->{chanNo} + 0; + #Log 2, "weekprofile_getDeviceType: $devHash->{NAME}, $model, $channel"; + + $type = "CUL_HM" if ( ($model =~ m/.*HM-CC-RT.*/) && ($channel == 4) ); + $type = "CUL_HM" if ( ($model =~ m/.*HM-TC.*/) && ($channel == 2) ); + $type = "CUL_HM" if ( ($model =~ m/.*HM-CC-TC.*/) && ($channel == 2) ); + + #Log 2, "weekprofile_getDeviceType: $devHash->{NAME}, $model, $channel unknown"; } #avoid max shutter contact elsif ( ($devHash->{TYPE} =~ /MAX/) && ($devHash->{type} =~ /.*Thermostat.*/) ){