From 74f5960ecc06e1849babeb005a080912c91e0215 Mon Sep 17 00:00:00 2001 From: losinshi Date: Tue, 22 Aug 2006 12:40:09 +0000 Subject: [PATCH] Some improvements in the average value calculation git-svn-id: file:///home/jan/tmp/wetterstation/trunk@33 dd492736-c11a-0410-ad51-8c26713eaf7f --- webstuff/frontend/php_inc/modules/hum.inc.php | 2 +- webstuff/frontend/php_inc/modules/press.inc.php | 2 +- webstuff/frontend/php_inc/modules/temp.inc.php | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/webstuff/frontend/php_inc/modules/hum.inc.php b/webstuff/frontend/php_inc/modules/hum.inc.php index 64883ec..3550581 100644 --- a/webstuff/frontend/php_inc/modules/hum.inc.php +++ b/webstuff/frontend/php_inc/modules/hum.inc.php @@ -61,7 +61,7 @@ class Hum{ $avData = array('average'=>0, 'count'=>0); /* Array initialisieren */ $i = 3; /* Laufvariable */ while($avData['count']<5){ /* Schleife prüft, in welchem Interval 5 Werte zusammenkommen */ - $avData = $this->_getAverage($sensId, $table, &$connection, ($i*10)." minutes"); /* Holt Werte mit gegebenem Interval */ + $avData = $this->_getAverage($sensId, $table, &$connection, ($i*15)." minutes"); /* Holt Werte mit gegebenem Interval */ $i++; /* Laufvariable erhöhen */ } diff --git a/webstuff/frontend/php_inc/modules/press.inc.php b/webstuff/frontend/php_inc/modules/press.inc.php index bc53804..5c1e91d 100644 --- a/webstuff/frontend/php_inc/modules/press.inc.php +++ b/webstuff/frontend/php_inc/modules/press.inc.php @@ -60,7 +60,7 @@ class Press{ $avData = array('average'=>0, 'count'=>0); /* Array initialisieren */ $i = 3; /* Laufvariable */ while($avData['count']<5){ /* Schleife prüft, in welchem Interval 5 Werte zusammenkommen */ - $avData = $this->_getAverage($sensId, $table, &$connection, ($i*10)." minutes"); /* Holt Werte mit gegebenem Interval */ + $avData = $this->_getAverage($sensId, $table, &$connection, ($i*15)." minutes"); /* Holt Werte mit gegebenem Interval */ $i++; /* Laufvariable erhöhen */ } diff --git a/webstuff/frontend/php_inc/modules/temp.inc.php b/webstuff/frontend/php_inc/modules/temp.inc.php index 8848134..187a26f 100644 --- a/webstuff/frontend/php_inc/modules/temp.inc.php +++ b/webstuff/frontend/php_inc/modules/temp.inc.php @@ -60,7 +60,7 @@ class Temp{ $avData = array('average'=>0, 'count'=>0); /* Array initialisieren */ $i = 3; /* Laufvariable */ while($avData['count']<5){ /* Schleife prüft, in welchem Interval 5 Werte zusammenkommen */ - $avData = $this->_getAverage($sensId, $table, &$connection, ($i*10)." minutes"); /* Holt Werte mit gegebenem Interval */ + $avData = $this->_getAverage($sensId, $table, &$connection, ($i*15)." minutes"); /* Holt Werte mit gegebenem Interval */ $i++; /* Laufvariable erhöhen */ }