FHEM Forum

FHEM => Frontends => SVG / Plots / logProxy => Thema gestartet von: frankyaye am 26 August 2013, 18:01:58

Titel: SVG-Plot min max aktuell erst nach Anklicken sichtbar?
Beitrag von: frankyaye am 26 August 2013, 18:01:58
Hallo,

der SVG Plot läuft prima, auch longpollSVG 1.
Aber wie kann ich es bewerkstelligen, das die Anzeige des Min Max und Aktuellen wertes beim Aufruf sofort sichtbar ist?
Franky
Titel: Aw: SVG-Plot min max aktuell erst nach Anklicken sichtbar?
Beitrag von: justme1968 am 26 August 2013, 18:05:03
in dem du ein label in der folgenden art setzt:attr <device label "Temperatur Min: $data{min1}, Max: $data{max1}, Aktuell: $data{currval1}"

gruss
  andre
Titel: Aw: SVG-Plot min max aktuell erst nach Anklicken sichtbar?
Beitrag von: frankyaye am 26 August 2013, 18:18:06
Hallo,
Label sind ja jetzt im gplot
da scheint die Schreibweise nicht zu gehen.

def:
define SVG_FileLog_CUL_HM_HM_WDS30_T_O_1D7D56_1 SVG FileLog_CUL_HM_HM_WDS30_T_O_1D7D56:SVG_FileLog_CUL_HM_HM_WDS30_T_O_1D7D56_1:CURRENT
attr SVG_FileLog_CUL_HM_HM_WDS30_T_O_1D7D56_1 label "Aussensensor Min $data{min1}, Max $data{max1}, Last $data{currval1}"

geht für label nicht

SVG_FileLog_CUL_HM_HM_WDS30_T_O_1D7D56_1.gplot
inhalt
# Created by FHEM/98_SVG.pm, 2013-08-26 17:31:37
set terminal png transparent size <SIZE> crop
set output '<OUT>.png'
set xdata time
set timefmt "%Y-%m-%d_%H:%M:%S"
set xlabel " "
set title Aussensensor
set ytics
set y2tics
set grid ytics
set ylabel "Temperatur"
set y2label ""

#FileLog 4:CUL_HM_HM_WDS30_T_O_1D7D56.*::

plot "<IN>" using 1:2 axes x1y1 title 'Temperatur' ls l0 lw 1.5 with lines
Titel: Aw: SVG-Plot min max aktuell erst nach Anklicken sichtbar?
Beitrag von: rudolfkoenig am 27 August 2013, 11:02:51
http://fhem.de/commandref.html#label (//fhem.de/commandref.html#label)
Double-Colon separated list of values. The values will be used to replace <L#> type of strings in the .gplot file, with # beginning at 1 (<L1>, <L2>, etc.). Each value will be evaluated as a perl expression, so you have access e.g. to the Value functions.
...
Title with maximum and current values of the 1st curve (FileLog)
Fhem config:
  attr wl_1 label "Max $data{max1}, Current $data{currval1}"
.gplot file entry:
  set title <L1>
Titel: Aw: SVG-Plot min max aktuell erst nach Anklicken sichtbar?
Beitrag von: frankyaye am 27 August 2013, 18:28:10
solved gelöst

in .gplot

set title <L1>

many thanks
vielen Dank
Titel: Antw:SVG-Plot min max aktuell erst nach Anklicken sichtbar?
Beitrag von: MBPower am 14 April 2014, 15:55:05
Ich habe ein ähnliches Problem, aber die Lösung habe ich nicht so ganz verstenden.
Nach dem umbenennen des SVG wurde leider nur noch <L1> im Titel angezeigt.
Was genau muss ich machen, damit im Titel wieder die Max-, Min- und Last-Temperatur angezeigt wird.
Titel: Antw:SVG-Plot min max aktuell erst nach Anklicken sichtbar?
Beitrag von: MBPower am 03 Mai 2014, 22:15:26
Niemand hier, der das Problem schon einmal lösen konnte?
Titel: Antw:SVG-Plot min max aktuell erst nach Anklicken sichtbar?
Beitrag von: __benny__ am 05 August 2017, 08:09:14
Ich habe es hinbekommen.

In der fhem.cfg musst du das Attribute "label" hinzufügen:

attr SVG_FileLog_OG1_WC_Thermo_3 label "OG1 - WC - Ventil / Fenster - [Min: $data{min1} - Max: $data{max1} - Last: $data{curval1}]"

Hier für meine .gplot-Datei mit Bezeichnung "SVG_Filelog_OG1_WC_Thermo_3"

Im Plot-Editor musst du dann als "Plot Title"

<L1>
[\code]
eingeben. Dann zeigt er bei mit die Min-Max-Werte an. In meinem Fall die Ventilstellung.

Gruß
Benny