I would like to display the energy consumption per day in Grafana. My problem is that the last date is double and the first date has wrong values (should be around 12kW per day).
(See screenshot markings)
Hello @Guido_Berger,
Thanks for your question.
Your query looks fine. This seems like it might be a grafana problem.
Have you tried querying via the api or influxDB UI to check to see if you get the same results?
Thank you
Yes it is the same in the influxDB UI. I now installed the latest 2.3 Version to use the timezone feature. May be it is timeszone issue. So after update the old buckets were lost.
So I have to wait some days to collect new data. I will try to set the timezone in the query and come back to you in a few days
I have the same meter and also using MBMD, so familiar issues
You have a couple of things going on:
First you can get the actual Kwh meter count from the SDM630 by using the “import” field. You can then use the difference between the registrations at the end of all days. That is more accurate then trying to integrate the instant Power over time.
Secondly, you have an issue with timezones. As you can see it now aggregates using 00:00 UTC while you seem to be at UTC+2.
Third, you query now uses a different time range, depending when you execute this, so beware to pick the good time range manually (which you can not do if you would execute this as a task).
I ran also into the timezone and range issues, especially trying to automate this using a Task, see also the discussion here
This is how I solved this in my task, that produces the usage and the end-meter value and runs every day: