mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-01-31 06:39:11 +00:00
gnuplot is now drawing FHT-Data without actuator or desired-temp too
git-svn-id: https://svn.fhem.de/fhem/trunk@88 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
f4ce915022
commit
fff185c682
@ -120,3 +120,6 @@ Changelog
|
|||||||
-- bugfix: HMS100WD is now aligned with other HMS-Devices
|
-- bugfix: HMS100WD is now aligned with other HMS-Devices
|
||||||
-- feature: Now there is a warning if there are not sufficient data to draw a gnuplot graph
|
-- feature: Now there is a warning if there are not sufficient data to draw a gnuplot graph
|
||||||
-- feature: more information about new HMS-Devices
|
-- feature: more information about new HMS-Devices
|
||||||
|
|
||||||
|
2007-09-05 (cvs)
|
||||||
|
-- feature: gnuplot pictures of FHT without all data (actuator, desired-temp) are shown with only measured temp
|
||||||
|
@ -22,3 +22,8 @@
|
|||||||
|
|
||||||
- Martin 2007-09-04
|
- Martin 2007-09-04
|
||||||
- Small changes in gnuplot.php, config.php, index.php, hms100.php
|
- Small changes in gnuplot.php, config.php, index.php, hms100.php
|
||||||
|
|
||||||
|
- Martin 2007-09-05
|
||||||
|
- Change in gnuplot.php: FHT: if there are not sufficient data (e.g. actuator) only measured-temp will be drawn
|
||||||
|
|
||||||
|
|
||||||
|
@ -78,6 +78,10 @@ EOD;
|
|||||||
set y2label 'Actuator (%)'
|
set y2label 'Actuator (%)'
|
||||||
set y2range [$FHTy2range]
|
set y2range [$FHTy2range]
|
||||||
";
|
";
|
||||||
|
$gplotmain2="
|
||||||
|
set ylabel 'Temperature (Celsius)'
|
||||||
|
set grid ytics
|
||||||
|
";
|
||||||
$gplotmaintmp = <<<EOD
|
$gplotmaintmp = <<<EOD
|
||||||
|
|
||||||
plot "< awk '/measured/{print $1, $4}' $logfile"\
|
plot "< awk '/measured/{print $1, $4}' $logfile"\
|
||||||
@ -86,8 +90,15 @@ using 1:2 axes x1y1 title 'Measured temperature' with lines lw 3,\
|
|||||||
using 1:2 axes x1y2 title 'Actuator (%)' with steps lw 1,\
|
using 1:2 axes x1y2 title 'Actuator (%)' with steps lw 1,\
|
||||||
"< awk '/desired/{print $1, $4}' $logfile"\
|
"< awk '/desired/{print $1, $4}' $logfile"\
|
||||||
using 1:2 axes x1y1 title 'Desired temperature' with steps
|
using 1:2 axes x1y1 title 'Desired temperature' with steps
|
||||||
|
EOD;
|
||||||
|
|
||||||
|
$gplotmainonlymeasured = <<<EOD
|
||||||
|
|
||||||
|
plot "< awk '/measured/{print $1, $4}' $logfile"\
|
||||||
|
using 1:2 axes x1y1 title 'Measured temperature' with lines lw 3
|
||||||
EOD;
|
EOD;
|
||||||
$gplotmain=$gplotmain.$gplotmaintmp;
|
$gplotmain=$gplotmain.$gplotmaintmp;
|
||||||
|
$gplotmain2=$gplotmain2.$gplotmainonlymeasured;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
Case HMS100T: ############################################
|
Case HMS100T: ############################################
|
||||||
@ -122,7 +133,20 @@ fclose($f2);
|
|||||||
exec("$gnuplot tmp/gnu2",$output);
|
exec("$gnuplot tmp/gnu2",$output);
|
||||||
$FOUT='tmp/'.$gnudraw1.'.'.$pictype;
|
$FOUT='tmp/'.$gnudraw1.'.'.$pictype;
|
||||||
$FS=filesize($FOUT);
|
$FS=filesize($FOUT);
|
||||||
if ($FS == '0')echo "Warning, there are not all required data in the logfile of $gnudraw to create a graph (e.g. actuator, desired-temp...).";
|
if ($FS == '0')
|
||||||
|
{
|
||||||
|
$message=$OUT1.$gplothdr.$gplotmain2;
|
||||||
|
$f1=fopen("tmp/gnu1","w");
|
||||||
|
fputs($f1,$message);
|
||||||
|
fclose($f1);
|
||||||
|
exec("$gnuplot tmp/gnu1",$output);
|
||||||
|
$message=$OUT2.$gplothdr.$xrange.$gplotmain2;
|
||||||
|
$f2=fopen("tmp/gnu2","w");
|
||||||
|
fputs($f2,$message);
|
||||||
|
fclose($f2);
|
||||||
|
exec("$gnuplot tmp/gnu2",$output);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
};
|
};
|
||||||
|
Loading…
Reference in New Issue
Block a user