mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-05-01 20:20:10 +00:00
10_EQ3BT: fix wrong date and time on thermostats
git-svn-id: https://svn.fhem.de/fhem/trunk@18384 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
5cb76c7525
commit
cd27965060
@ -8,6 +8,9 @@
|
||||
#
|
||||
#############################################################
|
||||
#
|
||||
# v2.0.6 - 20190122
|
||||
# - BUGFIX: fix wrong time on thermostats
|
||||
#
|
||||
# v2.0.5 - 20181007
|
||||
# - BUGFIX: ssh bugfixes by CoolTux
|
||||
#
|
||||
@ -535,6 +538,11 @@ sub EQ3BT_execGatttool($) {
|
||||
}
|
||||
}
|
||||
|
||||
if($value eq "03") {
|
||||
my ($sec, $min, $hour, $mday, $mon, $year, $wday, $yday, $isdst) = localtime(time);
|
||||
my $currentDate = sprintf("%02X%02X%02X%02X%02X", $year+1900-2000, $mon+1, $mday, $hour, $min);
|
||||
$value .= $currentDate;
|
||||
}
|
||||
|
||||
$cmd .= "ssh $sshHost '" if($sshHost ne 'none');
|
||||
$cmd .= "timeout " . AttrVal($name, "timeout", 15) . " " if($listen);
|
||||
@ -544,16 +552,6 @@ sub EQ3BT_execGatttool($) {
|
||||
$cmd .= " 2>&1 /dev/null";
|
||||
$cmd .= "'" if($sshHost ne 'none');
|
||||
|
||||
|
||||
|
||||
|
||||
if($value eq "03") {
|
||||
my ($sec, $min, $hour, $mday, $mon, $year, $wday, $yday, $isdst) = localtime(time);
|
||||
my $currentDate = sprintf("%02X%02X%02X%02X%02X", $year+1900-2000, $mon+1, $mday, $hour, $min);
|
||||
$value .= $currentDate;
|
||||
}
|
||||
|
||||
|
||||
#my $cmd = "gatttool -b $mac -i $hciDevice --char-write-req --handle=$handle --value=$value";
|
||||
# if( $sshHost ne 'none' ) {
|
||||
# $cmd = "ssh $sshHost 'gatttool -b $mac -i $hciDevice --char-write-req --handle=$handle --value=$value";
|
||||
|
Loading…
x
Reference in New Issue
Block a user