From 0e45f594799076e18a7347d795909f0ee422da46 Mon Sep 17 00:00:00 2001 From: Risiko <> Date: Mon, 18 Nov 2019 19:13:02 +0000 Subject: [PATCH] 98_weekprofile: fix time calculation for HM git-svn-id: https://svn.fhem.de/fhem/trunk@20535 2b470e98-0d58-463d-a4d8-8e2adae1ed80 --- fhem/CHANGED | 1 + fhem/FHEM/98_weekprofile.pm | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/fhem/CHANGED b/fhem/CHANGED index 725b9e5dd..677f631ac 100644 --- a/fhem/CHANGED +++ b/fhem/CHANGED @@ -1,5 +1,6 @@ # Add changes at the top of the list. Keep it in ASCII, and 80-char wide. # Do not insert empty lines here, update check depends on it. + - bugfix: 98_weekprofile: time calculation for HM - bugfix: 49_SSCam: FHEM crash when sending data by telegramBot Forum:#105486 - bugfix: 98_WeekTimer: fixed deletion of delayed timers (#104272) - bugfix: 73_AutoShuttersControl: fix brightness morning drive in with diff --git a/fhem/FHEM/98_weekprofile.pm b/fhem/FHEM/98_weekprofile.pm index f336869d0..33485c229 100644 --- a/fhem/FHEM/98_weekprofile.pm +++ b/fhem/FHEM/98_weekprofile.pm @@ -74,8 +74,8 @@ sub weekprofile_minutesToTime($) { my ($minutes) = @_; - my $hours = $minutes / 60.0; - $minutes = $minutes - $hours * 60.0; + my $hours =($minutes - $minutes % 60)/60; + $minutes = $minutes - $hours * 60; if (length($hours) eq 1){ $hours = "0$hours";