mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-04-21 14:04:15 +00:00
CUL_HM: bugfix float calculation
git-svn-id: https://svn.fhem.de/fhem/trunk@12396 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
d420ea9bd8
commit
50703cc3f2
@ -834,6 +834,14 @@ sub CUL_HM_Attr(@) {#################################
|
||||
return "$attrName only usable for ActionDetector" if(CUL_HM_hash2Id($hash) ne "000000");#only for device
|
||||
}
|
||||
}
|
||||
elsif($attrName eq "tempListTmpl" ){
|
||||
if ($cmd eq "set"){
|
||||
CUL_HM_UpdtReadSingle($hash,"tempTmplSet",$attrVal,0)
|
||||
}
|
||||
else{
|
||||
delete $hash->{READINGS}{"tempTmplSet"};
|
||||
}
|
||||
}
|
||||
elsif($attrName =~ m /^hmKey/){
|
||||
my $retVal= "";
|
||||
return "use $attrName only for vccu device"
|
||||
@ -7734,11 +7742,12 @@ sub CUL_HM_convTemp($) {########################
|
||||
return sprintf("%02X", $val*2);
|
||||
}
|
||||
sub CUL_HM_decodeTime16($) {####################
|
||||
my $v = hex(shift);
|
||||
my $x = shift;
|
||||
my $v = hex($x);
|
||||
my $m = int($v>>5);
|
||||
my $e = $v & 0x1f;
|
||||
my $mul = 0.1;
|
||||
return 2^$e*$m*0.1;
|
||||
return (2**$e)*$m*0.1;
|
||||
}
|
||||
sub CUL_HM_secSince2000() {#####################
|
||||
# Calculate the local time in seconds from 2000.
|
||||
|
Loading…
x
Reference in New Issue
Block a user