So I’ve got it setup, really nice card. Just wondering is there a way to tell it to ignore when the solar panel sensors are unavailable (which they are when no power is generated). Because the card gets flooded with error messages.
Thanks, I have been trying that. But I’m not doing that properly apparently, because this still results in wrong values. The unavailable is gone, but it still dives to 0, when the omnik is unavailable. So my idea to take the previous value of the fixed template sensor does not work
Oh I see your energy sensor is not available. Then I agree you can’t substitute zero for that. In my case the power sensor disappears so zero is the correct substitute. I use an integration sensor in HA to calculate the energy rather than reading it from the solar system.
Guess I’ll have to build in some “sensor memory” And read from that directly on startup and/or unavailability.
But I’m totally unsure what will be the racing conditions between:
Have an automation triggered by platform: home assistant, event: start and assign value to template sensor. Will the template sensor even be available this quickly?
Define the template sensor that sets the value of it based on conditions
The actual solar sensors becoming available
Are there some debugging tools to see what actually happens during startup of home assistant?
Or can I somehow delay the utility meter to do it’s thing after restart?
and an automation that set its value to the value of the sensor.myomnik_energy_total. Use a condition in the automation that the value is only set when the value of the sensor is not unknown.
@gurbyz - Firstly, I’m new to Home Assistant and thanks for the effort you’ve put in on this card.
I’d like to offer a few suggestions and I’d welcome your thoughts on them?
From reading this long Topic I can see many variations on color, and your latest addition in 0.1.1 to add active_arrow_color: as an option is appreciated. However to my way of thinking, the color of the arrows should match the icon of the icon they are coming from. This isn’t how it currently works, the arrows are either the color specified (or yellow by default) or gray if not used. As an example and within the limitations of the options in the card, I have my icons colored as GREEN if they are “Exporting” and RED if they are “Importing” - (Import and Export from the viewpoint of the house). Therefore, the sun icon is either GREEN or Gray , the House is always RED and the Grid icon alternates between GREEN and RED depending if I’m producing excess solar or not. I would expect the arrows coming from the sun to be green, however they are always red or gray. I’d also expect the arrows coming from the grid to alternate between either green, red and gray, however they are either red or gray. I don’t know if this is possible for you to integrate the extra color?
As an extension to the above, the color of the house is always red (assuming it’s always going to be using some electricity). To me, the house is the center of the information this card is displaying - the house is either costing us money when we “import” or we are saving money when we “export”. I would prefer to see the color of the house change from Red to Green just like the grid icon does now. I would also like to see the icons rotated one position anti-clockwise and inverted so the house is the “main” icon. This would match the following screenshot of a Flukso power monitoring device I currently use that displays power/solar in a very similar way to your card - the beauty of this method is that the house is GREEN if there is excess electricity (and I’m not paying for any) RED if it’s costing me money. The red and Green color is also easy to see across the room compared to the tiny icons on the card.
Hi @vk2him , thanks for writing down your suggestions.
About number 1:
I like the fresh idea of coloring the arrows using the same colors the icons have. But since it’s a different approach as the current approach of coloring the arrows (i.e. using an active and an inactive color), it would mean I’d have to support both approaches. That’s adding to the complexity of the card. So I have to think about it a bit more. Maybe you could add your suggestion as a feature request here in GitHub and your suggestion won’t be lost in the big topic on the forum.
About number 2:
The coloring of the home icon you suggest is as copying the color of the grid icon to the home icon. That would break the current consistent approach of coloring the icons, since a green home icon would mean the home is generating power/energy/money. I try to understand your idea of attributing an overall earning/costing thing to the home icon. To me that overall earning/costing thing could be represented better by e.g. coloring the background of the whole wheel instead of just the home icon. But then again: the background color of the wheel will then resemble the color of the grid icon always. I’m not sure that will add anything. Ah well, you will be noticing it better from across the room.
About attributing more attention/value to the home icon. I agree. I’m thinking about a different layout where the home icon is in the center of the wheel. That leaves room for the battery icon in the outer ring. There is a growing collection of nice layout suggestions in this feature request on GitHub.
I saw this card on the Home Assistant Reddit and really liked the look, thanks for this!
I just implemented it, but it seems I’m doing something wrong:
The values under the icons remain 0 (and they flash when the card itself updates). What do I need to add to have values here too? The number under the arrow is correct with the current consumption.
vm_solar_power = a Z-wave measurement device that measures the input of the solar panels (obviously 0 at this time of day)
vm_fase_power = a Z-wave measurement device that measures what we consume from the grid (when we produce more than we consume it goes to negative numbers)
sensor.huis_verbruik = a custom sensor that does a subtraction of the above 2.
I also have several DSMR values coming into HA but I haven’t checked those yet.
This is how I show it currently, that card is a lot nicer though and more clear.
Thanks @gurbyz - I’ve done as you suggest by updating github.
I love your idea of the background color following the earning/cost - perhaps that can be one optional view with the icons etc being black with values displayed? It would be a super simple basic “Am I selling or buying power” view.
Thanks
Ian
Hi Mathias,
Glad you like the card. You say you’re using 2 sensors, but actually you use 3 in your configuration. Please leave out the sensor.huis_verbruik because that one is calculated by the card also. And that’s the reason that you see some zeros.
Because you have a sensor.vm_fase_power that gives you a value for consuming as well as for producing, you can use grid_power_entity instead of the 2 input parameters you currently use for grid power. And because the polarity of the sensor is the inverse of what the card is expecting, you can use production_is_positive: false and you should be set.
The card is already really great, but should you be looking for features to add, here’s my wishlist:
Option to disable the power-view. As you can see in above screenshot, I have a power view next to daily and monthly energy views. For the daily and monthly views, I have added money views. But cycling through the power view is not necessary as that is already displayed next to it. So would be great if there’s an option to disable it
Support for ‘high’ and ‘low’ tariffs in money view, with automatic switching based on smart meter reporting ‘normal’ and ‘low’ tariffs
Is there a way to size the icons (using css & card-mod), I have no issue sizing the text, coloring the icons, but don’t manage to resize the icons. Thanks!
I’m getting more and more confused the more I look at my configuration for energy calculation and I could use some advice. I’m using template sensors for my grid production and consumption this doesn’t work properly for me since it’s resulting in a net calculation, rather than cumulative for each. I’m starting to think I need a couple of data stores to effectively tally the each time the data is refreshed depending on whether I’m importing or exporting at that point in time, in which case it’s not going to be 100% accurate.
I note the enlighten web ui does provide exactly what I need but I’m not sure how to get hassio to access that data
Here’s my sensor setup in configuration.yaml
exported_today:
friendly_name: "Today's Energy Exported"
value_template: "{{ [0, (states('sensor.envoy_today_s_energy_production') | int - states('sensor.envoy_today_s_energy_consumption') | int)] | max }}"
unit_of_measurement: 'Wh'
icon_template: 'mdi:flash'
imported_today:
friendly_name: "Today's Energy Imported"
value_template: "{{ [0, (states('sensor.envoy_today_s_energy_consumption') | int - states('sensor.envoy_today_s_energy_production') | int)] | max }}"
unit_of_measurement: 'Wh'
icon_template: 'mdi:flash'
I have enlighten as well, however I obtain my consumption and production figures using a pulse counting Power meter connected to a device called a Flukso - https://www.flukso.net/about
The Flukso has in in-built mqqt broker, so it’s easy to just connect a sensor to its mqqt output. I have 3 x pulse counting power meters connected to the Flukso, 1) Solar Production, 2) House Power Consumption and 3) Hot Water heater consumption.
I am able to display however all the information from Enlighten - but there is a catch if you want the per panel details - you need the password for the installer account on your Envoy. If you have that password, this url has a ton of information (substitute the IP of your envoy: http://192.168.1.84/installer/setup/home#overview
To get your password, you need to download an Android app and enter the serial number of your envoy - it will then give you the password. If you don’t have an android phone, the app can be run on an Nvidia Shield or even an android emulator. This is the link to the (detailed) article ob how the guy wrote the app, look for the download link for the app just above where the comments start. https://thecomputerperson.wordpress.com/2016/08/28/reverse-engineering-the-enphase-installer-toolkit/
Here is the relevant sections from my configuration.yaml for obtaining the sensors for the envoy, flukso, and the value template for the power wheel. I have a value template for the solar production that farces a zero value after the sun sets as it will display incorrectly that it’s generating a few watts after sunset otherwise.