From eb820b68ba088e2cdb0f31c35133fdfed171dfab Mon Sep 17 00:00:00 2001 From: Arjan <44190435+vingerha@users.noreply.github.com> Date: Sat, 5 Oct 2024 07:23:08 +0200 Subject: [PATCH] Remove dummy sensors Removed as this was used for an attempt to get it working for Apexharts, which failed --- app/gazpar2mqtt.py | 17 +---------------- 1 file changed, 1 insertion(+), 16 deletions(-) diff --git a/app/gazpar2mqtt.py b/app/gazpar2mqtt.py index 8223423..b22acd3 100644 --- a/app/gazpar2mqtt.py +++ b/app/gazpar2mqtt.py @@ -650,22 +650,7 @@ def run(myParams): ## Other logging.debug("Creation of other entities") - myEntity = hass.Entity(myDevice,hass.BINARY,'connectivity','connectivity',hass.CONNECTIVITY_TYPE,None,None).setValue('ON') - - if myParams.hassLts: - logging.debug("Creation of dummy LTS sensors") - myEntity = hass.Entity(myDevice, hass.SENSOR, 'consumption_stat', 'consumption stat', hass.GAS_TYPE, None, - 'm³').setValue('0') - myEntity = hass.Entity(myDevice, hass.SENSOR, 'consumption_kwh_stat', 'consumption kwh stat', hass.ENERGY_TYPE, None, - 'kWh').setValue('0') - myEntity = hass.Entity(myDevice, hass.SENSOR, 'consumption_pub_stat', 'consumption pub stat', hass.GAS_TYPE, None, - 'm³').setValue('0') - myEntity = hass.Entity(myDevice, hass.SENSOR, 'consumption_kwh_pub_stat', 'consumption kwh pub stat', hass.ENERGY_TYPE, None, - 'kWh').setValue('0') - myEntity = hass.Entity(myDevice, hass.SENSOR, 'consumption_cost_stat', 'consumption cost stat', hass.COST_TYPE, None, - 'EUR').setValue('0') - myEntity = hass.Entity(myDevice, hass.SENSOR, 'consumption_cost_pub_stat', 'consumption cost pub stat', hass.COST_TYPE, None, - 'EUR').setValue('0') + myEntity = hass.Entity(myDevice,hass.BINARY,'connectivity','connectivity',hass.CONNECTIVITY_TYPE,None,None).setValue('ON') # Publish config, state (when value not none), attributes (when not none) logging.info("Publishing devices...")