HandyHat / ha-hildebrandglow-dcc

Home Assistant integration for UK SMETS (Smart) meters pulling data from the DCC via the Hildebrand Glow API
MIT License
233 stars 35 forks source link

HA 2022.11 - gas consumption data can't be added to the energy dashboard #266

Closed HandyHat closed 1 year ago

HandyHat commented 1 year ago

See #264 for more information

dklemm commented 1 year ago

I think the issue is with HA https://github.com/home-assistant/frontend/issues/14292

Thorburn commented 1 year ago

The Gas sensors need their State to be "Gas" not "Energy".

Using the following works for me to get the Gas Today readings in to the Energy tab.

homeassistant: customize: sensor.gas_consumption_today: device_class: gas

dklemm commented 1 year ago

The Gas sensors need their State to be "Gas" not "Energy".

Using the following works for me to get the Gas Today readings in to the Energy tab.

homeassistant: customize: sensor.gas_consumption_today: device_class: gas

It might work to get the sensor added but its not the correct class. device_class: gas is only valid for volume based measurements (m3 ft3), energy is the correct class for kwh etc.

purcell-lab commented 1 year ago

This issue appears to be fixed in the 2022.12 beta release.

STUKguy commented 1 year ago

Not sure if mine is related but for some reason when i go to set up "Gas Consumption" under gas usage nothing shows up, but when i go to set up "Electricity grid" the gas option shows up on the consumed energy drop down

HandyHat commented 1 year ago

This should be fixed as of Home Assistant 2022.12 - if anyone if still having issues, please say!

fhwi93ne commented 1 year ago

Hi, I just updated to 2023.1.4 and have the same issue with my gas meter. state_class: total_increasing unit_of_measurement: m³ device_class: gas icon: mdi:gauge friendly_name: Value So I gueds the issue still exists.

HandyHat commented 1 year ago

Hey @fhwi93ne, are you running v1.0.2? I'm a bit confused because the device_class should be energy and this integration has never set it to gas

fhwi93ne commented 1 year ago

Hi @HandyHat, v1.0.2 of what? My gas meter is based on an AI-on-the-edge-device. The sensors seem to look ok for me, but they do not show up in the energy dashboard. I cannot pick them as gas source. This is what MQTT-Discovery makes out of it: { "device_class": null, "disabled_by": null, "disabled": false, "entity_category": null, "entity_id": "sensor.esp32_gaszaehler_value", "icon": null, "original_device_class": "gas", "original_icon": "mdi:gauge", "state": { "entity_id": "sensor.esp32_gaszaehler_value", "state": "23771.628", "attributes": { "state_class": "total_increasing", "unit_of_measurement": "m\u00b3", "device_class": "gas", "icon": "mdi:gauge", "friendly_name": "Value" }, "last_changed": "2023-01-14T20:43:47.643966+00:00", "last_updated": "2023-01-14T20:43:47.643966+00:00" }, "unit_of_measurement": "m\u00b3" },

It looks basically the same as my Shelly based energy meters, just for gas.

fhwi93ne commented 1 year ago

@HandyHat, my fault. I posted in the wrong repo. This belongs to homeassistant itself. Sorry for that!

HandyHat commented 1 year ago

Ah, no worries!