Power Distribution card

Hi,

Love your work! I use it now for my energy overview.

But… I don’t use is for live values, but to get a view of what I produce/use per day.

image

So for live view the extension of “kW” is correct, but when you use it to monitor historical values it should be “kWh”.

Hope to hear from you soon.

Kind regards

Is there a way to change this?

There’s already a built in card for that.

type: energy-distribution
title: Energy Distribution 
1 Like

Yes I know, but as stated in my post the calculation is not correct for me.

What calculation?

It is not designed to show energy, only power.

If you want energy, use the core card, like I said.

Thanx for fast reply, but that doesn’t give correct numbers.

It does work with this card, only kW instead of kWh. But if that can’t be changed it’s ok, was just a question.

Did the change myself, just edited the js file :slight_smile:

image

So again, thanx for replying.

Yes, the core card does give correct results for energy. If you are seeing something odd then there is probably an issue with the way you have set up the Energy Dashboard.

Apparently there is a naming conflict with an existing card in HACS. If anyone has any suggestions for an alternative name I’m all ears.

Also, the next feature on the horizon is support for both W and kW unit input and configurable display of those as well.

Power dashboard as opposed to Energy dashboard?

Hi Eltjo,

Wanted to edit the .js file as well, however my changes are not reflected in the UI. Am I missing something?

1 Like

Hi, what I did was pretty easy. I opened the file with File editor and find+replace the “kW” with “kWh”. I believe there are six “kW” in the file.

BUT… you have to clear your cache! So in Chrome or browser and on mobile via the settings of your phone (Apps → Clear cache)

That was it for me!

Maybe give option for kWh also :wink:

This is not good advice and the reason your values don’t add up. It’s similar to saying something is 10km away and now you replace km with km/h. You can’t do this — not if you want it to be correct. That was what Tom was trying to point out to you.

4 Likes

My calculated values are correct, 100% certain since I have an alternative monitoring system.

For me there is no harm in changing this value since it is a representation of the calculated values. In my case the used and produced energy for a day.

At midnight the values are reset and during the day the values go up.

Again, for my purpose this is perfect. If you don’t know how to calculate energy yes then you can get maybe some strange results.

Just for clarity sake. I don’t have any intention of supporting or adding an option for kWh. If the builtin cards don’t work right or the integration being used doesn’t work right then issues should probably be opened there. That said, if anyone wants to hack on the “compiled” javascript or fork the source, that’s totally fine by me, enjoy yourselves :slight_smile: But obviously I can’t support that.

2 Likes

Must have been the cache then. Meanwhile updated to the last version using HACS. Works like a charm now. Thanks!

@ulic This is exactly what i was looking for. The instant power production/consumption :slight_smile:

But i can not make it work… i install the repository via HACS latest version, i see it has created the power-flow-card directory and files in www/community , the resource is added to the Dashboards, but i can not find the actual card to add it to the dashboard.

little help pls? :innocent:

@Momo Thanks! I’m glad you like it. The card currently only supports manual configuration. Meaning there is no GUI editor. So you could select the “Manual” card and then fill out the configuration from there.

In the next release I’ll make it so that you can pick it from the list of cards, but it will still be a manual configuration. At some point I may get around to a GUI configuration, but no telling when that might happen.

aha good:) got it !

now i have

where power_house is total house consumption, power_to_grid is what i am sending to grid, and power_solar is total solar production.

But the numbers are not correct: in reality power_to_grid is 0; power_solar is 0.5 kW BUT the power_house is 3.4 kW.

I’m sure i put those sensors wrong…

Never mind :slight_smile: I sorted it !

Documentation says:
consumption: sensor.grid_out
production: sensor.grid_in

And i was confused as my consumption is power_from_grid and production is power_to_grid in this case.

All good now !! Thank you !!

1 Like