Page 1 of 1

Fake Gasmeter

Posted: Saturday 02 February 2019 17:49
by Derik
Dear..

Is there perhaps someone that is using a dummy gasmeter to see the usage of Kwh
I hope someone have this working so i can upload Kwh [ from my heatpump ] to www.mindergas.nl
What i am searching for is a dummy gasmeter, that is for real a kwh meter and this dummy have to count the actual and the total usage of the kwh meter.
When i have this working, i can upload this dummy gasmeter to www.mindergas.nl every day.

Re: Fake Gasmeter

Posted: Monday 04 February 2019 20:06
by SweetPants
Can you elaborate on a gas meter that usage Kwh?

Re: Fake Gasmeter

Posted: Monday 04 February 2019 20:12
by Derik
SweetPants wrote: Monday 04 February 2019 20:06 Can you elaborate on a gas meter that usage Kwh?
I use a script to divide the Heatpump Kwh meter to 2Kwh to 1M3 gas.
And this Kwh meter is set to a dummy gas.:

DZ vents script Khw to Gas:

Code: Select all

return {
on = { timer = { "every 1 minutes"}}, --at 21:52 every minute

execute = function(dz)

local WarmtepompKWH = dz.devices('Z: WP Tot').counterToday 
dz.log(WarmtepompKWH)
local WP_gas = dz.devices('D.M.: WP naar Gas')
local usage = WarmtepompKWH * 500
dz.log(usage)
WP_gas.updateGas(usage)
dz.openURL('http://192.168.5.70:8080/json.htm?type=command&param=udevice&idx=12268&nvalue=0&svalue='..usage)
end
}
So i get a dummy filled with "gas":
ScreenShot211.jpg
ScreenShot211.jpg (15.59 KiB) Viewed 575 times
Only i mis the total counter.. this counter that is in this meter is only a day total counter.

And this total counter [ a Always total counter not for 1 day ] is needed for a good upload tot mindergas
www.mindergas.nl

Re: Fake Gasmeter

Posted: Monday 04 February 2019 20:25
by SweetPants
If i remember correct, there was a total counter in the passed, but it is removed. Total counters (per year) are now in the reports section. I'am afraid you have to calculate this yourself.

Re: Fake Gasmeter

Posted: Monday 04 February 2019 20:30
by Derik
SweetPants wrote: Monday 04 February 2019 20:25 If i remember correct, there was a total counter in the passed, but it is removed. Total counters (per year) are now in the reports section. I'am afraid you have to calculate this yourself.
So i must make a feature request?


And do know what type of counter in the dummy section looks a gasmeter? so that have a total counter like the gasmeter?
Perhaps i can upload that on to mindergas..

Re: Fake Gasmeter

Posted: Monday 04 February 2019 22:00
by waaren
Derik wrote: Monday 04 February 2019 20:30 So i must make a feature request?
No.
domoticz gas meter devices (real or virtual are the same internally) only store the total value in table deviceStatus. The daily usage is the result of a calculation (subtract max value from meter_calendar from current value)
So if you want to update the gas meter you should do something like

Code: Select all

gas = domoticz.devices("your gas meter) 
wpWHTotal=dz.devices('Z: WP Tot').WhTotal
gas.updateGas(wpWHTotal * 500)