Page 11 of 15

Re: Energy Dashboard (Build in)

Posted: Tuesday 20 August 2024 8:29
by gizmocuz
I think that an offline approach and calculating this internally would be great if that was possible:

I found some information about this.

https://www.nowtricity.com/country/netherlands/

https://h2iq.org/calculate-co2-your-ele ... generates/

https://www.cencepower.com/calculators/ ... calculator

https://greencleanguide.com/calculate-y ... footprint/

Re: Energy Dashboard (Build in)

Posted: Tuesday 20 August 2024 19:45
by FireWizard
Hello @gizmocuz.

I had a quick look to the links you provided.

No 1 (Nowtricity)

This site gives more or less the same data as "Electricity Maps" but some essential data is missing.
I think the site is somewhat easier to read. I don't see anything about "Open Source".
Both have an API and the API of Nowtricity gives you more history (monthly/yearly)
The percentage of fossil-free or renewable energy is missing, so that cannot be calculated from their site.
The history can easily be managed by Domoticz, but the missing percentage is worse.

I think this makes that site less useful.

No 2 (H2 IQ)

This site has a nice online calculation tool , but I don't see anything that looks like an API.
So interfacing with Home Automation systems will be more difficult.

No 3 (Cencepower)

This site will give you the formula's to be able to calculate the emission.
In fact, there is very few information and also an API is missing.
You have to fill in a web formulae and it will give you the emission.

No 4 (Green Clean Guide)

I think this site has its origin in India. I gives you some information about ISO 14064.
But their approach is different from my goal

I want to know what the current footprint is, if I consume electricity from the grid.

They summarize all energy (electricity, diesel, petrol, LPG) and calculate your personal carbon footprint.
This data is from the past, so it is historical data.
The question is also, how to collect this data in your Home Automation system?
I think that an offline approach and calculating this internally would be great if that was possible
Of course , that would be nice, but I don't think that that is possible. You have to collect the percentage or the break down of the various source, like solar, wind , nuclear, hydro, etc to be able to calculate it.

No 1 (Nowtricity) does not provide that data, while the other 3 have no API.
I don't know another method to get the data into Domoticz.

Regards

Re: Energy Dashboard (Build in)

Posted: Wednesday 21 August 2024 8:08
by gizmocuz
You don't need an API when you can calculate this directly in the Domoticz code...
These 'countries emission factors' are fixed right? So this has to be entered once (or with a 'get' button that calls an API to get those for your country)
Then it is a matter of using the right calculation as demonstrated above and it's done...

Re: Energy Dashboard (Build in)

Posted: Wednesday 21 August 2024 18:49
by FireWizard
Hello @gizmocuz,

You wrote:
You don't need an API when you can calculate this directly in the Domoticz code...
These 'countries emission factors' are fixed right? So this has to be entered once (or with a 'get' button that calls an API to get those for your country)
Unfortunately the countries (areas) emission factors are not fixed. It are variables, which are updated every hour.

To give you an impression of the variations, see the log file of the sensor below.

Screenshot_Carbon_footprint_log.png
Screenshot_Carbon_footprint_log.png (177.09 KiB) Viewed 2021 times

During the night hours the value is higher than during the day, as in the night the big solar farms are not contributing to the total energy production.

On the Nowtricity site I cannot find a statement about the resolution, but you can see it, if you look to the returned data of their API.

Electricity Maps is clear as it states:
Resolution

All endpoints return data with a resolution of 1 hour.
So this has to be entered once (or with a 'get' button that calls an API to get those for your country)
No, at least once an hour you have to call an API and if that API gives you also the factor of fossil-free consumption or renewable consumption, then there is no need to calculate this value yourself.
As Electricity Maps does exactly this, there was no need for me to look further.

Regards

Re: Energy Dashboard (Build in)

Posted: Wednesday 28 August 2024 7:30
by gizmocuz
Hmmmm that indeed makes things complicated....

Seems HASS is using another API

https://community.home-assistant.io/t/h ... d/335072/3

Maybe a dzVents plugin could do this like yours.

You can use one of the 3 widget positions on the right to show the value? If yes, I could create a 'leaf' icon to choose

Re: Energy Dashboard (Build in)

Posted: Wednesday 28 August 2024 15:03
by FireWizard
Hi, @gizmocuz,

You wrote:
Seems HASS is using another API
This could very well be the case, as CO2 Signal is now integrated in Electricity Maps.

See: https://www.co2signal.com/

For the time being, the API of CO2 Signal is still functioning, but how long will it take before they switch to the Electricity Maps API?
That´s why, I took Electricity Maps.
Maybe a dzVents plugin could do this like yours.
I think, every programming language or script could do that.

1. Grab the fossilFreePercentage from the specific endpoint for your lat/lon co-ordinates.
2. Multiply it with the consumed power from the grid at that time.
3. Calculate the consumed Energy
4. Push the value to the right sensor.

As I'm more familiar with Node-RED, I did it with NR.
See: https://www.domoticz.com/forum/viewtopic.php?t=42587
You can use one of the 3 widget positions on the right to show the value? If yes, I could create a 'leaf' icon to choose
Yes, that would be a possibility. Creating a "green leaf" icon is not a problem either as that can easily done as a Custom icon.
However, the widgets at the right are connected to the "House" and represent data consumed from the "House" (either the public grid or your own solar panels or even a windmill) The fossil-free Energy gives data on the other side. I tells me how much fossil-free Energy I consume from the grid.
In my opinion the HA way of positioning the widget is better. Connect that to the grid.

Regards

Re: Energy Dashboard (Build in)

Posted: Wednesday 04 September 2024 11:28
by FireWizard
Hi @gizmocuz,

You wrote:
You can use one of the 3 widget positions on the right to show the value? If yes, I could create a 'leaf' icon to choose
I created that and the picture below shows the "Fossil-free Energy" in both a "Text" widget as an "Electricity" widget.
Sorry it is not possible to add a picture. While trying to add it gives a "HTTP error"

This one is connected to the "House", but I still think that the HASS way is better and that the "Electricity" widget should be connected to the grid.

A new flow you may find at https://www.domoticz.com/forum/viewtopi ... 81&t=42587

Regards

Re: Energy Dashboard (Build in)

Posted: Sunday 08 September 2024 18:49
by andrehj
Very nice, this dashboard.

However, I'm running into a problem:
A P1 Smart Meter device is not available as Solar device in Energy Dashboard Setup.
I have the power, production and consumption data of my PV system in a counter of type "P1 Smart Meter" (which I'm filling with a script running every minute, which uses data from an ABB kWh-meter), since that P1 Smart Meter was the only type that can can record both "usage" and "return" of a device.
However, this device cannot be selected in the drop-down menu of the Solar devices. Is something wrong? Or is this intended? Is this still on the to-do list?

Re: Energy Dashboard (Build in)

Posted: Sunday 08 September 2024 23:21
by waltervl
It is not common to have a P1 device as a solar panel monitoring device. You should have used a common Electricity Energy + Power device.

Re: Energy Dashboard (Build in)

Posted: Wednesday 11 September 2024 19:57
by andrehj
Thanks @waltervl. Too bad no-one thought of this.
However, just created an extra dummy device to fix the display of the solar system in the Energy Dashboard, and immediately ran into another problem:
The Energy Dashboard converts consumption to production! At night my solar system consumes energy (around 2 W) for its Wifi etc, however the Energy Dashboard shows this as production. I would like to see the dotted lines flow the correct way.
Can this bug be fixed?

Re: Energy Dashboard (Build in)

Posted: Wednesday 11 September 2024 20:34
by waltervl
I already discussed this with another user in this topic that it should be possible to fix it. Please read back

Re: Energy Dashboard (Build in)

Posted: Wednesday 11 September 2024 20:57
by andrehj
Thanks. You probably mean this discussion: viewtopic.php?p=318834#p318834
I should be able to find it, however, it apparently only fixes the values, not the movement of the dotted lines. Also, any modifications I make to that code will be overwritten at every update of Domotics (just like my 1 minute interval mod gets removed at every update...).
So it's not really a solution.
How can I make a bug fix (or call it code change if you like) request?

Re: Energy Dashboard (Build in)

Posted: Thursday 12 September 2024 0:28
by waltervl
If you have found the solution you can make a Pull request on the GitHub repository so it can be implemented into the Domoticz source files.

Re: Energy Dashboard (Build in)

Posted: Sunday 15 September 2024 14:28
by mgerhard74
Thank you for the energy-dashboard. Looks great (for start). Costs are always "0,00€"... maybe a configuration failure....
I displayed grid smartmeter, PV-production, PV battery data.

Re: Energy Dashboard (Build in)

Posted: Sunday 15 September 2024 14:37
by FireWizard
You wrote:
Costs are always "0,00€"... maybe a configuration failure....
Probably the same as I made once.

See the first page in this thread and my post:
Post by FireWizard » 10 Jun 2024, 14:10.
Regards

Re: Energy Dashboard (Build in)

Posted: Saturday 21 September 2024 13:26
by Henry
I recently updated to release 2024.7 and saw this new board. It looks very nice but I noticed a problem for my situation. I have an Omnik inverter from with I get the current and daily energy total. I noticed that the solar daily total was a negative number and this seemed to be the total of the day before which was reset at midnight (see viewtopic.php?t=42697). I can’t select another device in the configuration. I’m not sure if this can be solved in the configuration of the dashboard, or if there is some other way to solve this.

Re: Energy Dashboard (Build in)

Posted: Saturday 21 September 2024 16:51
by BartSr
To be independent and free to choose which figures you need I would advice to include a seperate measuring device. e.g. Pzem 004t. But there are many other brands/types.

Re: Energy Dashboard (Build in)

Posted: Wednesday 13 November 2024 17:25
by Bluffpearce
winner61 wrote: Friday 16 August 2024 9:38 Thank you Waltervl. If you work with dynamic prices based on the feed I assume there is no need to specify prices. These are prices with tax included so seeking a way to substract about 0,148 cent. This is my setting:


dash.png

Thank you.

edit: propably I answered another post by Waltervl, sorry for that.
Where\how did you obtain the access token?

Re: Energy Dashboard (Build in)

Posted: Friday 15 November 2024 16:58
by Ctenberge
Hi, I have a few questions:
1, How to get a second convertor (there are 2 separated convertors) to feed from solar into my house? There is only one source available.
2, how to connect my watermeter from smartgateways, I can not choose it because I get at that line only “not connected”
Thanks in advance

Re: Energy Dashboard (Build in)

Posted: Friday 15 November 2024 17:13
by waltervl
Ctenberge wrote: Friday 15 November 2024 16:58 Hi, I have a few questions:
1, How to get a second convertor (there are 2 separated convertors) to feed from solar into my house? There is only one source available.
2, how to connect my watermeter from smartgateways, I can not choose it because I get at that line only “not connected”
Thanks in advance
1. Make a dummy device and combine the values into that dummy device. An example script is in this topic. Use the dummy device in the settings of the energy dashboard.
2. Do you already have a Domoticz device for the watermeter? If not, create a new forum topic about this as it is not related to the energy dashboard.