improve peercheck in HMInfo
git-svn-id: https://svn.fhem.de/fhem/trunk@4647 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
@@ -164,6 +164,7 @@ sub HMinfo_peerCheck(@) { #####################################################
|
|||||||
my @entities = @_;
|
my @entities = @_;
|
||||||
my @peerIDsFail;
|
my @peerIDsFail;
|
||||||
my @peerIDsEmpty;
|
my @peerIDsEmpty;
|
||||||
|
my @peerIDnotDef;
|
||||||
my @peerIDsNoPeer;
|
my @peerIDsNoPeer;
|
||||||
foreach my $eName (@entities){
|
foreach my $eName (@entities){
|
||||||
next if (!$defs{$eName}{helper}{role}{chn});#device has no channels
|
next if (!$defs{$eName}{helper}{role}{chn});#device has no channels
|
||||||
@@ -190,16 +191,24 @@ sub HMinfo_peerCheck(@) { #####################################################
|
|||||||
$_ =~ s/04$/05/; # have to compare with clima_team, not clima
|
$_ =~ s/04$/05/; # have to compare with clima_team, not clima
|
||||||
$cId =~ s/05$/04/;# will find 04 in peerlist, not 05
|
$cId =~ s/05$/04/;# will find 04 in peerlist, not 05
|
||||||
}
|
}
|
||||||
|
my $pDiD = substr($_,0,6) if (substr($_,6,2) eq "01");
|
||||||
|
if (!$modules{CUL_HM}{defptr}{$_} &&
|
||||||
|
($pDiD && !$modules{CUL_HM}{defptr}{$pDiD})){
|
||||||
|
push @peerIDnotDef,$eName." id:".$_;
|
||||||
|
}
|
||||||
|
else{
|
||||||
my $pName = CUL_HM_id2Name($_);
|
my $pName = CUL_HM_id2Name($_);
|
||||||
$pName =~s/_chn:01//; #channel 01 could be covered by device
|
$pName =~s/_chn:01//; #channel 01 could be covered by device
|
||||||
my $pPlist = AttrVal($pName,"peerIDs","");
|
my $pPlist = AttrVal($pName,"peerIDs","");
|
||||||
push @peerIDsNoPeer,$eName." p:".$pName if ($pPlist !~ m/$cId/);
|
push @peerIDsNoPeer,$eName." p:".$pName if (!$pPlist || $pPlist !~ m/$cId/);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
my $ret = "";
|
my $ret = "";
|
||||||
$ret .="\n\n peer list not read" ."\n ".(join "\n ",sort @peerIDsEmpty) if(@peerIDsEmpty);
|
$ret .="\n\n peer list not read" ."\n ".(join "\n ",sort @peerIDsEmpty) if(@peerIDsEmpty);
|
||||||
$ret .="\n\n peer list incomplete"."\n ".(join "\n ",sort @peerIDsFail) if(@peerIDsEmpty);
|
$ret .="\n\n peer list incomplete"."\n ".(join "\n ",sort @peerIDsFail) if(@peerIDsEmpty);
|
||||||
|
$ret .="\n\n peer not defined" ."\n ".(join "\n ",sort @peerIDnotDef) if(@peerIDnotDef);
|
||||||
$ret .="\n\n peer not verified" ."\n ".(join "\n ",sort @peerIDsNoPeer)if(@peerIDsEmpty);
|
$ret .="\n\n peer not verified" ."\n ".(join "\n ",sort @peerIDsNoPeer)if(@peerIDsEmpty);
|
||||||
return $ret;
|
return $ret;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1412,15 +1412,25 @@ $culHmChanSets{"ROTO_ZEL-STG-RM-FWT02"} = $culHmChanSets{"HM-CC-TC02"};
|
|||||||
"11;p02=8100" => { txt => "LEDall" , params => {
|
"11;p02=8100" => { txt => "LEDall" , params => {
|
||||||
Led1To16 => '04,8,$val= join(":",sprintf("%b",hex($val))=~ /(.{2})/g)',
|
Led1To16 => '04,8,$val= join(":",sprintf("%b",hex($val))=~ /(.{2})/g)',
|
||||||
} },
|
} },
|
||||||
"11;p01=81" => { txt => "LEVEL" , params => {
|
"11;p01=81" => { txt => "LEVEL" , params => {#ALARM_COUNT/HANDLE_LOCK/LEVEL_SET/MANU_MODE_SET/SET_ALL_CHANNELS
|
||||||
CHANNEL => "02,2",
|
CHANNEL => "02,2",
|
||||||
TIME => '04,2,$val=hex($val)',
|
TIME => '04,2,$val=hex($val)',
|
||||||
SPEED => '06,2,$val=hex($val)',
|
SPEED => '06,2,$val=hex($val)',
|
||||||
} },
|
} },
|
||||||
"11;p01=82" => { txt => "Sleepmode" , params => {#only LED16?
|
"11;p01=82" => { txt => "Sleepmode" , params => {#SET_WINTER_MODE/SET_LED_SLEEP_MODE/SERVICE_COUNT/PARTY_MODE_SET
|
||||||
CHANNEL => "02,2",
|
CHANNEL => "02,2",
|
||||||
MODE => '04,2,$val=hex($val)',
|
MODE => '04,2,$val=hex($val)',
|
||||||
} },
|
} },
|
||||||
|
"11;p01=83" => { txt => "EnterBootLoader" },#BOOST_MODE_SET/SET_HANDLE_LED_MODE
|
||||||
|
# "11;p01=84" => { txt => "" },#SET_SHEV_POS/COMFORT_MODE_SET
|
||||||
|
# "11;p01=85" => { txt => "" },#LOWERING_MODE_SET/SET_RELEASE_TURN
|
||||||
|
"11;p01=86" => { txt => "SetTemp" , params => {
|
||||||
|
B1 => "02,2",
|
||||||
|
B2 => '04,2',
|
||||||
|
} },
|
||||||
|
"11;p01=87" => { txt => "AdaptionDriveSet" },
|
||||||
|
"11;p01=CA" => { txt => "EnterBootLoader" },#download? at the end?
|
||||||
|
|
||||||
"12" => { txt => "HAVE_DATA"},
|
"12" => { txt => "HAVE_DATA"},
|
||||||
"3E" => { txt => "SWITCH" , params => {
|
"3E" => { txt => "SWITCH" , params => {
|
||||||
DST => "00,6",
|
DST => "00,6",
|
||||||
|
|||||||
Reference in New Issue
Block a user