mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-03-04 11:26:55 +00:00
10_CUL_HM: code cleanup
git-svn-id: https://svn.fhem.de/fhem/trunk@9103 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
39a3586597
commit
e5cebbe7c6
@ -737,6 +737,7 @@ sub HMLAN_Parse($$) {##########################################################
|
|||||||
Dispatch($hash, $dmsg, \%addvals) if($mFld[5] !~ m/99.112999999000000/);#ignore overload test
|
Dispatch($hash, $dmsg, \%addvals) if($mFld[5] !~ m/99.112999999000000/);#ignore overload test
|
||||||
}
|
}
|
||||||
elsif($mFld[0] =~ m /HHM-(LAN|USB)-IF/){#HMLAN version info
|
elsif($mFld[0] =~ m /HHM-(LAN|USB)-IF/){#HMLAN version info
|
||||||
|
$hash->{IFmodel} = $1;
|
||||||
$hash->{uptime} = HMLAN_uptime($mFld[5],$hash);
|
$hash->{uptime} = HMLAN_uptime($mFld[5],$hash);
|
||||||
|
|
||||||
$hash->{helper}{assIdRep} = hex($mFld[6]);
|
$hash->{helper}{assIdRep} = hex($mFld[6]);
|
||||||
|
@ -1149,7 +1149,7 @@ sub CUL_HM_Parse($$) {#########################################################
|
|||||||
."\n original cmd: $origcmd";
|
."\n original cmd: $origcmd";
|
||||||
|
|
||||||
if ($cmd eq $origcmd) {
|
if ($cmd eq $origcmd) {
|
||||||
Log3 $mh{devH},4,"CUL_HM $mh{dstN} signature: good, authbytes: $mh{authbytes}";
|
Log3 $mh{devH},4,"CUL_HM $mh{dstN} signature: good, authbytes: ${authbytes}";
|
||||||
$mh{devH}->{helper}{aesAuthBytes} = $authbytes;
|
$mh{devH}->{helper}{aesAuthBytes} = $authbytes;
|
||||||
$mh{devH}->{helper}{aesCommRq}{msgStat} = "AESCom-ok";
|
$mh{devH}->{helper}{aesCommRq}{msgStat} = "AESCom-ok";
|
||||||
}
|
}
|
||||||
@ -1206,7 +1206,7 @@ sub CUL_HM_Parse($$) {#########################################################
|
|||||||
$mh{devH}->{helper}{aesCommRq}{challenge} = $challenge;
|
$mh{devH}->{helper}{aesCommRq}{challenge} = $challenge;
|
||||||
$mh{devH}->{helper}{aesCommRq}{kNo} = $kNo;
|
$mh{devH}->{helper}{aesCommRq}{kNo} = $kNo;
|
||||||
|
|
||||||
my $cmd = "$mh{mNo}A002$mh{dst}$mh{src}04$mh{challenge}".sprintf("%02X", $kNo*2);
|
my $cmd = "$mh{mNo}A002$mh{dst}$mh{src}04${challenge}".sprintf("%02X", $kNo*2);
|
||||||
$cmd = sprintf("As%02X%s", length($cmd)/2, $cmd);
|
$cmd = sprintf("As%02X%s", length($cmd)/2, $cmd);
|
||||||
IOWrite($mh{devH}, "", $cmd);
|
IOWrite($mh{devH}, "", $cmd);
|
||||||
$mh{msgStat}="AESpending";
|
$mh{msgStat}="AESpending";
|
||||||
|
Loading…
x
Reference in New Issue
Block a user