From df5684a5756ab053fb4e7e3914780bb1860ea4fa Mon Sep 17 00:00:00 2001 From: rudolfkoenig <> Date: Sat, 16 Apr 2022 10:39:48 +0000 Subject: [PATCH] 00_KM271.pm: fix datetime day setting (Forum #56681) git-svn-id: https://svn.fhem.de/fhem/trunk@25972 2b470e98-0d58-463d-a4d8-8e2adae1ed80 --- fhem/FHEM/00_KM271.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fhem/FHEM/00_KM271.pm b/fhem/FHEM/00_KM271.pm index 8820bb625..79de6a768 100755 --- a/fhem/FHEM/00_KM271.pm +++ b/fhem/FHEM/00_KM271.pm @@ -636,7 +636,7 @@ KM271_Set($@) $val = sprintf("%02x%02x%02x%02x%02x%02x", $lt[0], $lt[1], $lt[2], # Ignoring DST and Radio-Clock $lt[3], - ($lt[4]+1) + (($lt[6] ? $lt[6] : 7) << 4), + ($lt[4]+1) + ((($lt[6]+6) % 7)<<4), # WDay: 0/Mon..6/Sun $lt[5]); } push @{$hash->{SENDBUFFER}}, sprintf($cmd, $val, $val);