2
0
mirror of https://github.com/fhem/fhem-mirror.git synced 2025-04-22 02:10:32 +00:00

31_HUEDevice.pm: preliminary event timestamp fix

git-svn-id: https://svn.fhem.de/fhem/trunk@25527 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
justme-1968 2022-01-20 21:27:30 +00:00
parent 309a410569
commit 409e0f8767

View File

@ -1801,15 +1801,17 @@ HUEDevice_Parse($$)
$hash->{lastupdated} = ReadingsVal( $name, '.lastupdated', '' ) if( !$hash->{lastupdated} );
$hash->{lastupdated_local} = ReadingsVal( $name, '.lastupdated_local', '' ) if( !$hash->{lastupdated_local} );
substr($hash->{lastupdated},10, 1, '_' );
substr($lastupdated,10, 1, '_' );
my $hlu = SVG_time_to_sec( $hash->{lastupdated} );
my $lu = SVG_time_to_sec( $lastupdated );
return undef if( $hash->{lastupdated}
&& $hlu <= $lu
#&& !defined($result->{v2_service})
&& !defined($result->{v2_service})
#&& $hash->{lastupdated} eq $lastupdated
&& (!$readings{state} || $readings{state} eq ReadingsVal( $name, 'state', '' )) );
&& (!$readings{state} || $readings{state} eq ReadingsVal( $name, 'state', '' ))
);
Log3 $name, 4, "$name: lastupdated: $lastupdated, hash->{lastupdated}: $hash->{lastupdated}, lastupdated_local: $lastupdated_local, offsetUTC: $offset";
#Log3 $name, 5, "$name: ". Dumper $result if($HUEDevice_hasDataDumper);