Script virtmeter.php [GUIDA]

Discussioni relative al software di monitoraggio energetico METERN
megamarco83
Messaggi: 184
Iscritto il: 22/08/2016, 14:13

Re: Script virtmeter.php [GUIDA]

Messaggioda megamarco83 » 21/12/2018, 11:30

Garluk ha scritto:
megamarco83 ha scritto:
Garluk ha scritto:Marco per cortesia crei momentaneamente un nuovo meter e usi in command virtmeter sia in

Immaginavo.
eflow non gestiva il passover mentre virtmet si.

Tutto è bene ciò che finisce bene.

ciao Garluk, sto monitorando virtmet, ma ho dei "buchi" nel csv, che con eflow invece non avevo

come mai secondo te?

grazie

con virtmet:

Codice: Seleziona tutto

Time,Consumi(Wh),Produzione(Wh),Prelievi(Wh),Immissioni(Wh),Autoconsumo(Wh),temperatura(°C),Umidità(%),PrelieviF1(Wh),PrelieviF23(Wh),10(euro),Temperatura Boiler(°C),Boiler(Wh),Mandata Riscaldamento(°C),Mandata Caldaia(°C),volt(V),Temp Corridoio(°C),Umid Corridoio(%),Temp Mansarda(°C),Umid Mansarda(%),gas(m3),Prelievi_Virt(Wh)
00:00,32954841,25665822,82668332,59076926,13904,-0.8,99.9,2916,25184,,54.25,,26.12,17.31,231.10,20.4,34.8,21.2,41.9,1209.98,
00:05,32954903,25665822,82668394,59076926,13904,-0.9,99.9,2916,25248,,54.25,,26.06,17.31,230.30,20.4,34.8,21.2,42,1209.98,
00:10,32954955,25665822,,,,-0.9,99.9,,,,54.12,,26.00,17.31,231.10,20.4,34.6,21.2,41.6,1209.98,
00:15,32955001,25665822,82668440,59076926,13904,-0.9,99.9,2916,25294,,54.00,,25.88,17.25,230.50,20.3,34.3,21.1,41.9,1209.98,
00:20,32955049,25665822,,,,-1.2,99.9,,,,53.88,,25.69,17.25,230.60,20.3,34.2,21.1,41.8,1209.98,
00:25,32955095,25665822,,,,-1.2,99.9,,,,53.69,,25.44,17.19,230.30,20.3,34,21.2,41.9,1209.98,
00:30,32955139,25665822,82668484,59076926,13904,-1.2,99.9,2916,25340,,53.44,,25.31,17.12,230.50,20.3,34,21.1,41.2,1209.98,
00:35,32955185,25665822,82668530,59076926,13904,-1.2,99.9,2916,25388,,53.31,,25.00,17.12,231.20,20.3,34.3,21.1,41,1209.98,
00:40,32955229,25665822,,,,-1.2,99.9,,,,53.06,,24.81,17.06,230.00,20.2,34,21.1,40.9,1209.98,
00:45,32955281,25665822,82668582,59076926,13904,-1.2,99.9,2916,25440,,52.88,,24.56,17.06,229.90,20.2,33.7,21.1,40.9,1209.98,
00:50,32955335,25665822,82668636,59076926,13904,-1.3,99.9,2916,25494,,52.69,,24.31,17.06,231.20,20.2,33.6,21.1,40.8,1209.98,
00:55,32955375,25665822,,,,-1.3,99.9,,,,52.38,,24.06,17.00,228.20,20.2,33.6,21.1,40.9,1209.98,
01:00,32955421,25665822,,,,-1.3,99.9,,,,52.19,,23.88,17.00,227.70,20.2,33.5,21.1,40.9,1209.98,
01:05,32955473,25665822,82668688,59076926,13904,-1.3,99.9,2916,25546,,52.00,,23.56,16.94,227.90,20.2,33.5,21.1,40.7,1209.98,
01:10,32955521,25665822,82668736,59076926,13904,-1.3,99.9,2916,25594,,51.81,,23.44,16.94,228.80,20.2,33.4,21.1,40.6,1209.98,
01:15,32955565,25665822,,,,-1.3,99.9,,,,51.75,,23.19,16.88,228.90,20.1,33.2,21.1,40.6,1209.98,
01:20,32955603,25665822,,,,-1.3,99.9,,,,51.75,,22.94,16.88,229.30,20.1,33.2,21.1,40.5,1209.98,
01:25,32955639,25665822,82668772,59076926,13904,-1.3,99.9,2916,25632,,51.69,,22.69,16.88,229.30,20.1,33.1,21.1,40.5,1209.98,
01:30,32955683,25665822,,,,-1.3,99.9,,,,51.62,,22.56,16.81,228.80,20,33.7,21,40.5,1209.98,
01:35,32955723,25665822,82668812,59076926,13904,-1.3,99.9,2916,25674,,51.56,,22.38,16.81,226.50,20,33.4,21.1,40.3,1209.98,
01:40,32955767,25665822,82668856,59076926,13904,-1.3,99.9,2916,25718,,51.50,,22.12,16.75,227.60,20,33.1,21,40.3,1209.98,
01:45,32955807,25665822,82668896,59076926,13904,-1.3,99.9,2916,25758,,51.44,,21.94,16.75,226.40,20,33,21,40.3,1209.98,
01:50,32955845,25665822,,,,-1.7,99.9,,,,51.38,,21.75,16.69,227.40,20,33.1,21,40.3,1209.98,
01:55,32955879,25665822,82668930,59076926,13904,-1.7,99.9,2916,25792,,51.38,,21.62,16.69,224.10,20,33,21,40.3,1209.98,
02:00,32955917,25665822,,,,-1.7,99.9,,,,51.31,,21.38,16.62,225.30,19.9,32.9,21,40.3,1209.98,
02:05,32955951,25665822,82668964,59076926,13904,-1.7,99.9,2916,25828,,51.25,,21.25,16.62,224.50,19.9,32.9,21,40.1,1209.98,
02:10,32955997,25665822,82669012,59076926,13904,-1.7,99.9,2916,25876,,51.19,,21.06,16.62,224.10,19.9,32.8,21,40,1209.98,
02:15,32956047,25665822,,,,-1.7,99.9,,,,51.19,,20.88,16.56,225.00,19.9,32.9,21,39.9,1209.98,
02:20,32956093,25665822,82669058,59076926,13904,-1.6,99.9,2916,25924,,51.12,,20.69,16.50,223.70,19.9,32.7,21,40,1209.98,
02:25,32956137,25665822,82669102,59076926,13904,-1.6,99.9,2916,25968,,51.12,,20.56,16.50,226.40,19.9,32.7,21,39.9,1209.98,
02:30,32956173,25665822,,,,-1.6,99.9,,,,51.06,,20.44,16.44,225.90,19.8,32.6,21,40,1209.98,
02:35,32956213,25665822,82669142,59076926,13904,-1.9,99.9,2916,26008,,51.00,,20.31,16.38,225.30,19.9,32.6,21,39.9,1209.98,
02:40,32956255,25665822,82669184,59076926,13904,-1.9,99.9,2916,26050,,50.94,,20.12,16.44,224.60,19.8,32.5,20.9,40,1209.98,
02:45,32956293,25665822,82669222,59076926,13904,-1.9,99.9,2916,26090,,50.88,,20.00,16.38,228.60,19.8,32.5,20.9,39.9,1209.98,
02:50,32956331,25665822,82669260,59076926,13904,-2.0,99.9,2916,26128,,50.88,,19.88,16.31,227.50,19.8,32.5,20.9,39.8,1209.98,
02:55,32956373,25665822,82669302,59076926,13904,-2.0,99.9,2916,26170,,50.81,,19.75,16.31,228.30,19.8,32.5,20.9,39.9,1209.98,
03:00,32956413,25665822,,,,-2.0,99.9,,,,50.75,,19.62,16.25,227.90,19.8,32.4,20.9,39.8,1209.98,



con eflow zero buchi:

Codice: Seleziona tutto

20:55,32975311,25680740,82675354,59079446,23880,-0.9,99.9,4814,29594,,45.12,,23.81,20.62,214.50,19.8,34,21.1,41.2,1210.52
21:00,32975363,25680740,82675406,59079446,23880,-0.9,99.9,4814,29646,,44.88,,23.56,20.25,212.80,19.9,34.1,21.1,41,1210.52
21:05,32975415,25680740,82675458,59079446,23880,-0.9,99.9,4814,29698,,44.62,,23.25,19.88,215.00,19.8,34.1,21.1,41.1,1210.52
21:10,32975459,25680740,82675502,59079446,23880,-0.9,99.9,4814,29742,,44.50,,23.00,19.56,216.40,19.8,34,21.1,41.1,1210.52
21:15,32975511,25680740,82675554,59079446,23880,-0.9,99.9,4814,29794,,44.44,,22.69,19.19,218.70,19.8,34,21.1,41.1,1210.52
21:20,32975565,25680740,82675608,59079446,23880,-1.2,99.9,4814,29848,,44.31,,22.38,18.94,220.70,19.8,33.5,21.1,41,1210.52
21:25,32975615,25680740,82675658,59079446,23880,-1.2,99.9,4814,29898,,44.19,,22.19,18.69,217.80,19.7,33.2,21.1,40.9,1210.52
21:30,32975663,25680740,82675706,59079446,23880,-1.2,99.9,4814,29946,,44.12,,21.88,18.44,221.10,19.7,33.5,21.1,40.8,1210.52
21:35,32975723,25680740,82675766,59079446,23880,-1.2,99.9,4814,30006,,43.81,,30.31,46.50,221.40,19.7,34.1,21.1,41.1,1210.61
21:40,32975783,25680740,82675826,59079446,23880,-1.2,99.9,4814,30066,,43.50,,34.50,47.31,222.80,19.8,34.7,21,40.8,1210.71
21:45,32975843,25680740,82675886,59079446,23880,-1.2,99.9,4814,30126,,43.38,,34.31,46.88,224.00,19.8,33.5,21,40.8,1210.79
21:50,32975905,25680740,82675948,59079446,23880,-1.1,99.9,4814,30188,,43.50,,34.00,48.00,225.30,19.8,33.9,21,40.8,1210.85
21:55,32975969,25680740,82676012,59079446,23880,-1.1,99.9,,,,43.81,,33.19,47.06,222.20,19.9,33.2,21,41,1210.92
22:00,32976035,25680740,82676078,59079446,23880,-1.1,99.9,4814,30254,,44.19,,35.56,47.50,222.30,19.9,33.4,21,41.2,1210.98
22:05,32976113,25680740,82676156,59079446,23880,-1.1,99.9,4814,30332,,44.50,,33.12,48.12,221.90,20,33.3,21,41,1211.03
22:10,32976219,25680740,82676262,59079446,23880,-1.1,99.9,4814,30438,,44.69,,38.31,47.44,220.80,20,33.3,21,41.2,1211.09
22:15,32976295,25680740,82676338,59079446,23880,-1.1,99.9,4814,30514,,45.19,,37.81,47.69,220.70,20.1,33.2,21,41.5,1211.13
22:20,32976379,25680740,82676422,59079446,23880,-1.1,99.9,4814,30598,,45.69,,32.12,46.94,221.10,20.2,33.2,21,41.4,1211.2
22:25,32976459,25680740,82676502,59079446,23880,-1.1,99.9,4814,30678,,46.94,,27.88,36.38,223.00,20,33.3,21,41.3,1211.22
22:30,32976531,25680740,82676574,59079446,23880,-1.1,99.9,4814,30750,,56.25,,26.62,34.19,226.30,20.1,33.2,21,41.5,1211.22
22:35,32976607,25680740,82676650,59079446,23880,-1.3,99.9,4814,30826,,60.81,,26.12,32.38,227.10,20.2,32.9,21,41.4,1211.22
22:40,32976675,25680740,82676718,59079446,23880,-1.3,99.9,4814,30894,,62.06,,25.88,30.81,225.90,20.2,33.1,21,40.9,1211.22
22:45,32976743,25680740,82676786,59079446,23880,-1.3,99.9,4814,30962,,62.50,,25.69,29.44,228.40,20.2,33,21,40.9,1211.22
22:50,32976813,25680740,82676856,59079446,23880,-1.2,99.9,4814,31032,,63.19,,25.56,28.19,228.10,20.2,33,21,41,1211.22
22:55,32976881,25680740,82676924,59079446,23880,-1.2,99.9,4814,31100,,64.44,,25.50,27.06,228.90,20.2,32.8,21.1,40.8,1211.22
23:00,32976949,25680740,82676992,59079446,23880,-1.2,99.9,4814,31168,,65.69,,25.44,26.06,228.40,20.2,32.8,21.1,40.5,1211.22
23:05,32977021,25680740,82677064,59079446,23880,-1.9,99.9,4814,31240,,66.69,,25.44,25.19,229.10,20.2,32.6,21.1,40.5,1211.22
23:10,32977093,25680740,82677136,59079446,23880,-1.9,99.9,4814,31312,,67.44,,25.44,24.44,229.90,20.2,32.8,21.1,40.6,1211.22
23:15,32977181,25680740,82677224,59079446,23880,-1.9,99.9,4814,31400,,67.88,,25.44,23.69,230.60,20.2,32.7,21.1,40.3,1211.22
23:20,32977263,25680740,82677306,59079446,23880,-1.9,99.9,4814,31482,,68.31,,25.44,23.06,230.50,20.2,32.6,21.1,40.5,1211.22
23:25,32977339,25680740,82677382,59079446,23880,-1.9,99.9,4814,31558,,68.81,,25.50,22.50,230.10,20.2,32.6,21.1,40.4,1211.22
23:30,32977403,25680740,82677446,59079446,23880,-1.9,99.9,4814,31622,,69.31,,25.50,22.00,229.80,20.2,32.5,21.2,41.1,1211.22
23:35,32977469,25680740,82677512,59079446,23880,-1.6,99.9,4814,31688,,69.75,,25.50,21.50,230.00,20.2,32.5,21.2,40.4,1211.22
23:40,32977533,25680740,82677576,59079446,23880,-1.6,99.9,4814,31752,,69.94,,25.56,21.19,230.70,20.2,32.5,21.2,40.2,1211.22
23:45,32977599,25680740,82677642,59079446,23880,-1.6,99.9,4814,31818,,70.00,,25.62,20.75,230.10,20.1,32.4,21.2,40.6,1211.22
23:50,32977665,25680740,82677708,59079446,23880,-1.8,99.9,4814,31884,,70.06,,25.62,20.44,231.10,20.2,32.3,21.2,40.1,1211.22
23:55,32977729,25680740,82677772,59079446,23880,-1.8,99.9,4814,31948,,70.00,,25.62,20.19,229.40,20.2,32.2,21.2,40.3,1211.22
00:00,32977793,25680740,82677836,59079446,23880,-1.8,99.9,4814,32012,,69.94,,25.69,19.88,231.10,20.1,32.1,21.2,39.7,1211.22


cosimo61
Messaggi: 36
Iscritto il: 20/11/2017, 14:32

Re: Script virtmeter.php [GUIDA]

Messaggioda cosimo61 » 21/12/2018, 12:04

megamarco83 ha scritto:
Garluk ha scritto:Marco per cortesia crei momentaneamente un nuovo meter e usi in command virtmeter sia in command che in live e mi dici cosa succede?

Ciao
G.

Ciao Garluk e grazie
ho risolto...c'era un passover a 100000 sul meter 1 per i consumi...
li avrò controlalti 50mila volte ma si vede che l'occhio li non voleva guardare...
scusami..ora funziona tutto, ho messo il passover a 0 per i consumi e tutto va...
grazie!!!


Ragazzi, grazie a questa discussione ho risolto il mio problema dell'incremento anomalo di 100000 Wh ad ogni scrittura nel csv dei meter F1 e F23.
Uso virtmeter per il monitoraggio dei consumi in F1 e F23 e anch'io, a seconda della fascia oraria, avevo la stessa situazione di megamarco83.
Inoltre questo accadeva ogni qual volta riavviavo il raspy per prove o aggiornamenti del sistema.
Ho sempre creduto, erroneamente, che si trattasse di un bug di virtmeter ma dopo le rassicurazioni di flane ed altri utenti del forum mi ero convinto che qualche cosa non andasse nella mia installazione e quindi avevo momentaneamente disabilitato i due meter in attesa di trovare una soluzione.
Ed ecco arrivata la soluzione! Avevo solo il meter Consumi (anche io al n. 1) con passover a 100000, probabilmente impostato di default.
Grazie! e ancora grazie prima a Garluk per il suo script (adesso ne apprezzo le qualità) e poi a megamarco83 per aver sollevato il problema nei giusti termini e determinato la soluzione.

miki8989
Messaggi: 297
Iscritto il: 22/01/2016, 6:39

Re: Script virtmeter.php [GUIDA]

Messaggioda miki8989 » 21/12/2018, 21:49

ciao Garluk

purtroppo non và...
il log non si crea e lo script non viene lanciato..

ho lanciato il pooler ( ./pooler485.sh ) e funziona..
dò un ctrl+c e si blocca la scrittura del log e lancio dello script

una domanda.
ma con virtmeter il pooler485 viene usato???

grazie

Garluk
Messaggi: 80
Iscritto il: 01/10/2017, 22:00

Re: Script virtmeter.php [GUIDA]

Messaggioda Garluk » 22/12/2018, 0:49

miki da quello che scrivi forse dipende da come viene lanciato lo script....

Mi dai questo comando e mi posti il risultato?
ls -al /bin | grep sh

Oppure fammi collegare che gli dò un occhiata.
Se il log con il codice che ti ho dato non viene scritto vuol dire che il contatore non viene incrementato.

Riguardo alla tua domanda: virtmet non usa pooler485.sh: sono due cose diverse.
pooler485.sh viene usato per il ciclo che effettua le letture dei contatori e sensori vari. I dati prelevati dai dispositivi hardware vengono memorizzati in memoria (tipicamente /dev/shm).
virmet.php è uno script usato da meterN per valorizzare un meter. I dati vengono prelevati da /dev/shm e opportunamente elaborati passati a meterN che li memorizza e fa le sue elaborazioni.

Ciao
G.

miki8989
Messaggi: 297
Iscritto il: 22/01/2016, 6:39

Re: Script virtmeter.php [GUIDA]

Messaggioda miki8989 » 22/12/2018, 10:29

grazie gentilissimo..

eccolo

Codice: Seleziona tutto

pi@raspberrypi:~ $ ls -al /bin | grep sh
-rwxr-xr-x  1 root root 912712 mag 15  2017 bash
-rwxr-xr-x  1 root root  91764 gen 24  2017 dash
lrwxrwxrwx  1 root root      4 mag 15  2017 rbash -> bash
lrwxrwxrwx  1 root root      4 gen 24  2017 sh -> dash
lrwxrwxrwx  1 root root      4 gen 24  2017 sh.distrib -> dash


in privato ti lascio le credenziali

grazie

megamarco83
Messaggi: 184
Iscritto il: 22/08/2016, 14:13

Re: Script virtmeter.php [GUIDA]

Messaggioda megamarco83 » 20/07/2019, 11:55

ciao, ma anche a voi con l'ultima versione di metern 1.2 non funziona più virtmet?
io ottengo questo errore:

Codice: Seleziona tutto

Command : virtmeter 5 0 0 selfcpower 0

Abording: Too late mN live values is not valid, the correct format is 5(1234.5*W)


oppure nel live

Codice: Seleziona tutto

PHP Notice: Undefined variable: LIVEPOOL2 in /var/www/comapps/virtmeter.php on line 499PHP Notice: Undefined variable: LIVEPOOL1 in /var/www/comapps/virtmeter.php on line 5045(0*W) is not valid, the correct format is 5(1234.5*W
)

Avatar utente
Flane
Messaggi: 2084
Iscritto il: 16/01/2016, 15:02

Re: Script virtmeter.php [GUIDA]

Messaggioda Flane » 20/07/2019, 15:43

Virtmeter utilizza per le letture i valori che si trovano nei file creati da metern in /dev/shm.
Mi sembra di ricordare che in qualche aggiornamnto JM ha fatto delle modifiche in uno di questi file, aggiungendo qualche dato prima non presente.

Potrebbe essere questa la causa del problema.

io sono ancora a MeterN 0.9.4 e virtmeter funziona bene.

megamarco83
Messaggi: 184
Iscritto il: 22/08/2016, 14:13

Re: Script virtmeter.php [GUIDA]

Messaggioda megamarco83 » 20/07/2019, 16:14

ciao, JM ha eliminato LIVEPOOL ora è diventato LIVECOMMAND
credo da metern 1.1 in poi
mi ha srpiegato come modificare virtmet, lo ho fatto e funziona, lo allego qui se servisse a qualcuno.
spero che non me ne voglia garluk che è l'autore di virtmeter
Allegati
virtmeter.zip
(5.41 KiB) Scaricato 47 volte

Ivan70
Messaggi: 28
Iscritto il: 14/08/2018, 11:08

Re: Script virtmeter.php [GUIDA]

Messaggioda Ivan70 » 24/08/2019, 17:46

Ciao Flane,
io ho appena aggiornato alla 1.2.1 e non mi funzionano più i valori virtmeter live.
Da quanto leggo credo che il file che posti possa risolvere. Qualcuno ora riderà.. Ma qual'è il metodo più semplice per caricare il file sul Raspberry, da ambiente windows 10?

Grazie per la pazienza.. ;)



Torna a “MeterN”

Chi c’è in linea

Visitano il forum: Nessuno e 1 ospite