Sure: Virtual power sensor (manual) — Powercalc documentation.
Than select “fixed” Fixed — Powercalc documentation
I can’t add integration Powercalc, I’m getting error message: : “Invalid handler specified”. My HA version is 2024.3.3 - is this HA version supported?
Debug message:
Source: config_entries.py:2444
Error occurred loading flow for integration powercalc: cannot import name ‘ConfigFlowResult’ from ‘homeassistant.config_entries’ (/home/orangepi/.local/share/pipx/venvs/homeassistant/lib/python3.11/site-packages/homeassistant/config_entries.py)
Is my Python version too old, or some Python lib is missing? Currently, I have no easy way to upgrade Python on my device, because I will need to use Debian Experimental repos, which I don’t really want to do.
Latest Python version available in Debian is 3.11.8 and 3.12.1 is experimental.
Yes it’s a known issue. Also see versione 1.11.8 doenst work · Issue #2222 · bramstroker/homeassistant-powercalc · GitHub
I didn’t have time to look into making compatible with both 2024.3 and 2024.4+
In one of last Powercalc versions compatibility with 2024.3.x and lower broke.
I suggest you to upgrade to HA 2024.4 which should solve your issue.
Unfortunately, new HA requires higher Python version. As I wrote, I either need to use experimental builds or keep waiting for new stable Python build for Debian Linux.
Cutrently, I am not able to update HA without a risk to break other stuff. But thanks for clarification.
Is there any older version suitable for my HA version? The only functionality I need is to calculate power consumption based on constant value, without any advanced alghoritms.
Do you think any older version could meet my needs? As I can see in bug report you linked, 1.11.7 should work?
Yes correct, you can just downgrade to that version of Powercalc, and upgrade later when you are ready.
There are not much huge features or important bug fixes lately you’ll miss.
Except that profiles are downloaded from the internet starting from v1.12 onwards, but the integration will still work fine with the 1.11.7 version.
1.11.7 works just fine I it seems it meets my requirements. BTW isn’t there any way to hide incompatible versions from HACS list? It’s a bit confusing when I am able to download version that is not suitable for my HA version.
Hello,
I have Avatto (Tuya) thermostats and when I want to set state_power, even with running_state:idle it still adds values. What’s wrong with my settings?
{
"backlight_mode": "medium",
"child_lock": "UNLOCK",
"current_heating_setpoint": 15,
"faultalarm": 0,
"frost_protection": "ON",
"linkquality": 88,
"local_temperature": 19.8,
"max_temperature_limit": 35,
"preset": "manual",
"running_state": "idle",
"sensor": "both",
"system_mode": "heat",
"working_day": "disabled",
"deadzone_temperature": null,
"factory_reset": null,
"local_temperature_calibration": null,
"schedule_holiday": null,
"schedule_weekday": null
}
it grows by 1/6 every 5 (10) minutes, then nothing for 5 (10) minutes and grows by 1/6 again
Your configuration looks fine by me. You are sure the entity state did not go from idle to heat again at 19.00?
Have look at the power sensor history first to see if that one is correct.
Also I suggest to enable debug logging for powercalc, that should log all the state changes of your climate entity and resulting W value from powercalc.
No, the thermostat really is off. I turned on logging for powercalc, see below, but there is nothing about what you describe. Am I turning on the wrong log?
{
"home_assistant": {
"installation_type": "Home Assistant OS",
"version": "2024.5.4",
"dev": false,
"hassio": true,
"virtualenv": false,
"python_version": "3.12.2",
"docker": true,
"arch": "aarch64",
"timezone": "Europe/Prague",
"os_name": "Linux",
"os_version": "6.6.29-haos",
"supervisor": "2024.05.1",
"host_os": "Home Assistant OS 12.3",
"docker_version": "25.0.5",
"chassis": "embedded",
"run_as_root": true
},
"custom_components": {
"openhab": {
"documentation": "https://github.com/kubawolanin/ha-openhab",
"version": "0.0.1",
"requirements": [
"zeroconf",
"python-openhab==2.16.2"
]
},
"mydolphin_plus": {
"documentation": "https://github.com/sh00t2kill/dolphin-robot",
"version": "1.0.13",
"requirements": [
"awsiotsdk"
]
},
"hacs": {
"documentation": "https://hacs.xyz/docs/configuration/start",
"version": "1.34.0",
"requirements": [
"aiogithubapi>=22.10.1"
]
},
"sonoff": {
"documentation": "https://github.com/AlexxIT/SonoffLAN",
"version": "3.7.3",
"requirements": [
"pycryptodome>=3.6.6"
]
},
"ariston": {
"documentation": "https://github.com/fustom/ariston-remotethermo-home-assistant-v3",
"version": "0.19.1",
"requirements": [
"ariston==0.19.3"
]
},
"hikvision_next": {
"documentation": "https://github.com/maciej-or/hikvision_next",
"version": "1.0.15",
"requirements": [
"xmltodict==0.13.0",
"hikvisionapi==0.3.2",
"requests-toolbelt==1.0.0"
]
},
"mobile_alerts": {
"documentation": "https://github.com/cestlagalere/mobilealerts",
"version": "1.1.1",
"requirements": []
},
"ecowitt": {
"documentation": "https://www.home-assistant.io/integrations/ecowitt",
"version": "0.7",
"requirements": [
"pyecowitt==0.14"
]
},
"scheduler": {
"documentation": "https://github.com/nielsfaber/scheduler-component",
"version": "v0.0.0",
"requirements": []
},
"powercalc": {
"documentation": "https://github.com/bramstroker/homeassistant-powercalc",
"version": "v1.12.3",
"requirements": [
"numpy>=1.21.1"
]
}
},
"integration_manifest": {
"after_dependencies": [
"integration",
"utility_meter"
],
"codeowners": [
"@bramstroker"
],
"config_flow": true,
"dependencies": [
"light",
"group",
"template",
"select",
"utility_meter"
],
"documentation": "https://github.com/bramstroker/homeassistant-powercalc",
"domain": "powercalc",
"iot_class": "local_polling",
"issue_tracker": "https://github.com/bramstroker/homeassistant-powercalc/issues",
"name": "Powercalc",
"requirements": [
"numpy>=1.21.1"
],
"version": "v1.12.3",
"is_built_in": false
},
"data": {
"entry": {
"entry_id": "de935ac6fb3216ce5ba7025b457976b9",
"version": 3,
"minor_version": 1,
"domain": "powercalc",
"title": "Bojler",
"data": {
"mode": "fixed",
"create_energy_sensor": true,
"create_utility_meters": true,
"entity_id": "switch.bojler_bojler_switch",
"name": "Bojler",
"unique_id": "bojler_spotreba",
"standby_power": 0.0,
"fixed": {
"power": 2400.0
},
"energy_integration_method": "left",
"sensor_type": "virtual_power",
"_power_entity": "sensor.bojler_power",
"_energy_entity": "sensor.bojler_energy"
},
"options": {},
"pref_disable_new_entities": false,
"pref_disable_polling": false,
"source": "user",
"unique_id": "bojler_spotreba",
"disabled_by": null
}
}
}[wrap="justify"]
[wrap="justify"]
Text
[/wrap]
[/wrap]
I’m sorry, in debug log is this:
2024-05-21 20:44:06.754 DEBUG (MainThread) [custom_components.powercalc.sensors.power] climate.termostat_dilna: State changed to "heat". Power:1000.00
2024-05-21 20:44:51.628 DEBUG (MainThread) [custom_components.powercalc.sensors.power] climate.termostat_dilna: State changed to "heat". Power:1000.00
2024-05-21 20:45:06.585 DEBUG (MainThread) [custom_components.powercalc.sensors.power] climate.termostat_dilna: State changed to "heat". Power:1000.00
2024-05-21 20:45:36.512 DEBUG (MainThread) [custom_components.powercalc.sensors.power] climate.termostat_dilna: State changed to "heat". Power:1000.00
But in the history of the thermostat switching, there is no thermostat turning on. makes no sense to me. Isn’t it possible that it would fault another state, for example the “system_mode” entity?
This appeared in the log when I manually increased the temperature and heated the thermostat
2024-05-21 21:04:25.445 DEBUG (MainThread) [custom_components.powercalc.sensors.power] climate.termostat_dilna: State changed to "heat". Power:1000.00
2024-05-21 21:04:33.885 DEBUG (MainThread) [custom_components.powercalc.sensors.power] climate.termostat_dilna: State changed to "heat". Power:1000.00
2024-05-21 21:05:53.133 DEBUG (MainThread) [custom_components.powercalc.sensors.power] climate.termostat_dilna: State changed to "heat". Power:1000.00
2024-05-21 21:06:03.667 DEBUG (MainThread) [custom_components.powercalc.sensors.power] climate.termostat_dilna: State changed to "heat". Power:1000.00
Then I turned off the thermostat, but nothing else appeared in the log.
I add the log from MQTT, there is the state “running_state:heat” and then “running_state:idle”
2024-05-21 21:12:47.650 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{"backlight_mode":"medium","child_lock":"UNLOCK","current_heating_setpoint":15,"deadzone_temperature":null,"factory_reset":null,"faultalarm":0,"frost_protection":"ON","linkquality":140,"local_temperature":19.4,"local_temperature_calibration":null,"max_temperature_limit":35,"preset":"manual","running_state":"idle","schedule_holiday":null,"schedule_weekday":null,"sensor":"both","system_mode":"heat","working_day":"disabled"}' with variables {'entity_id': 'text.termostat_dilna_schedule_holiday', 'name': 'Schedule holiday', 'this': <template TemplateStateFromEntityId(text.termostat_dilna_schedule_holiday)>} and Template<template=({{ value_json.schedule_holiday }}) renders=606>
2024-05-21 21:12:55.663 DEBUG (MainThread) [custom_components.powercalc.sensors.power] climate.termostat_dilna: State changed to "heat". Power:1000.00
2024-05-21 21:13:02.748 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{"backlight_mode":"medium","child_lock":"UNLOCK","current_heating_setpoint":23,"deadzone_temperature":null,"factory_reset":null,"faultalarm":0,"frost_protection":"ON","linkquality":144,"local_temperature":19.4,"local_temperature_calibration":null,"max_temperature_limit":35,"preset":"manual","running_state":"heat","schedule_holiday":null,"schedule_weekday":null,"sensor":"both","system_mode":"heat","working_day":"disabled"}' with variables {'entity_id': 'lock.termostat_dilna_child_lock', 'name': 'Child lock', 'this': <template TemplateStateFromEntityId(lock.termostat_dilna_child_lock)>} and Template<template=({{ value_json.child_lock }}) renders=611>
2024-05-21 21:13:02.759 DEBUG (MainThread) [custom_components.powercalc.sensors.power] climate.termostat_dilna: State changed to "heat". Power:1000.00
2024-05-21 21:13:17.694 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{"backlight_mode":"medium","child_lock":"UNLOCK","current_heating_setpoint":15,"deadzone_temperature":null,"factory_reset":null,"faultalarm":0,"frost_protection":"ON","linkquality":140,"local_temperature":19.4,"local_temperature_calibration":null,"max_temperature_limit":35,"preset":"manual","running_state":"idle","schedule_holiday":null,"schedule_weekday":null,"sensor":"both","system_mode":"heat","working_day":"disabled"}' with variables {'entity_id': 'text.termostat_dilna_schedule_holiday', 'name': 'Schedule holiday', 'this': <template TemplateStateFromEntityId(text.termostat_dilna_schedule_holiday)>} and Template<template=({{ value_json.schedule_holiday }}) renders=616>
2024-05-21 21:13:17.696 DEBUG (MainThread) [custom_components.powercalc.sensors.power] climate.termostat_dilna: State changed to "heat". Power:1000.00
That’s very strange, because state change to off
should also be logged.
What is the state history of the climate.termostat_dilna
entity. You can find that in logbook. Click this icon in entity dialog, and than show more.
Edit nevermind, your state attributes are changing (running_state) so that causes powercalc to recalculate. But the climate entity stays on state heat
and that is what powercalc logs.
A bit strange why the state of the climate entity stays heat
and does not become idle
. I would say this is a problem on it’s own and should be “fixed” first.
These are the set temperatures. I think you can watch the actual state from logbook, not the charts.
You’ll to click Show more on logbook
It is not so. You can see in the log that the running_state is first idle, then heat and then idle again. I only extracted a few lines, but in the log the state remains running_state=idle and still powercalc calculates.
Another log, I deleted the unnecessary stuff. it can be seen that even if running_state is: idle, powercalc takes the state change to heat from somewhere.
2024-05-22 08:10:17.316 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'switch.termostat_dilna_factory_reset', 'name': 'Factory reset', 'this': <template TemplateStateFromEntityId(switch.termostat_dilna_factory_reset)>} and Template<template=({{ value_json.factory_reset }}) renders=5174>
2024-05-22 08:10:17.317 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'switch.termostat_dilna_frost_protection', 'name': 'Frost protection', 'this': <template TemplateStateFromEntityId(switch.termostat_dilna_frost_protection)>} and Template<template=({{ value_json.frost_protection }}) renders=5174>
2024-05-22 08:10:17.317 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'select.termostat_dilna_sensor', 'name': 'Sensor', 'this': <template TemplateStateFromEntityId(select.termostat_dilna_sensor)>} and Template<template=({{ value_json.sensor }}) renders=5174>
2024-05-22 08:10:17.318 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'select.termostat_dilna_backlight_mode', 'name': 'Backlight mode', 'this': <template TemplateStateFromEntityId(select.termostat_dilna_backlight_mode)>} and Template<template=({{ value_json.backlight_mode }}) renders=5174>
2024-05-22 08:10:17.319 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'select.termostat_dilna_working_day', 'name': 'Working day', 'this': <template TemplateStateFromEntityId(select.termostat_dilna_working_day)>} and Template<template=({{ value_json.working_day }}) renders=5174>
2024-05-22 08:10:17.319 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'lock.termostat_dilna_child_lock', 'name': 'Child lock', 'this': <template TemplateStateFromEntityId(lock.termostat_dilna_child_lock)>} and Template<template=({{ value_json.child_lock }}) renders=5174>
2024-05-22 08:10:17.320 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'number.termostat_dilna_local_temperature_calibration', 'name': 'Teplota', 'this': <template TemplateStateFromEntityId(number.termostat_dilna_local_temperature_calibration)>} and Template<template=({{ value_json.local_temperature_calibration }}) renders=5174>
2024-05-22 08:10:17.320 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'number.termostat_dilna_max_temperature_limit', 'name': 'Max temperature limit', 'this': <template TemplateStateFromEntityId(number.termostat_dilna_max_temperature_limit)>} and Template<template=({{ value_json.max_temperature_limit }}) renders=5174>
2024-05-22 08:10:17.321 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'number.termostat_dilna_deadzone_temperature', 'name': 'Deadzone temperature', 'this': <template TemplateStateFromEntityId(number.termostat_dilna_deadzone_temperature)>} and Template<template=({{ value_json.deadzone_temperature }}) renders=5174>
2024-05-22 08:10:17.322 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'climate.termostat_dilna', 'name': None, 'this': <template TemplateStateFromEntityId(climate.termostat_dilna)>} and Template<template=({% set values = {None:None,'idle':'idle','heat':'heating','cool':'cooling','fan_only':'fan'} %}{{ values[value_json.running_state] }}) renders=5174>
2024-05-22 08:10:17.333 DEBUG (MainThread) [custom_components.powercalc.sensors.power] climate.termostat_dilna: State changed to "heat". Power:1000.00
2024-05-22 08:10:30.120 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'switch.termostat_dilna_factory_reset', 'name': 'Factory reset', 'this': <template TemplateStateFromEntityId(switch.termostat_dilna_factory_reset)>} and Template<template=({{ value_json.factory_reset }}) renders=5175>
2024-05-22 08:10:32.065 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'switch.termostat_dilna_frost_protection', 'name': 'Frost protection', 'this': <template TemplateStateFromEntityId(switch.termostat_dilna_frost_protection)>} and Template<template=({{ value_json.frost_protection }}) renders=5175>
2024-05-22 08:10:32.066 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'select.termostat_dilna_sensor', 'name': 'Sensor', 'this': <template TemplateStateFromEntityId(select.termostat_dilna_sensor)>} and Template<template=({{ value_json.sensor }}) renders=5175>
2024-05-22 08:10:32.067 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'select.termostat_dilna_backlight_mode', 'name': 'Backlight mode', 'this': <template TemplateStateFromEntityId(select.termostat_dilna_backlight_mode)>} and Template<template=({{ value_json.backlight_mode }}) renders=5175>
2024-05-22 08:10:32.067 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'select.termostat_dilna_working_day', 'name': 'Working day', 'this': <template TemplateStateFromEntityId(select.termostat_dilna_working_day)>} and Template<template=({{ value_json.working_day }}) renders=5175>
2024-05-22 08:10:32.068 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'lock.termostat_dilna_child_lock', 'name': 'Child lock', 'this': <template TemplateStateFromEntityId(lock.termostat_dilna_child_lock)>} and Template<template=({{ value_json.child_lock }}) renders=5175>
2024-05-22 08:10:32.069 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'number.termostat_dilna_local_temperature_calibration', 'name': 'Teplota', 'this': <template TemplateStateFromEntityId(number.termostat_dilna_local_temperature_calibration)>} and Template<template=({{ value_json.local_temperature_calibration }}) renders=5175>
2024-05-22 08:10:32.069 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'number.termostat_dilna_max_temperature_limit', 'name': 'Max temperature limit', 'this': <template TemplateStateFromEntityId(number.termostat_dilna_max_temperature_limit)>} and Template<template=({{ value_json.max_temperature_limit }}) renders=5175>
2024-05-22 08:10:32.070 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'number.termostat_dilna_deadzone_temperature', 'name': 'Deadzone temperature', 'this': <template TemplateStateFromEntityId(number.termostat_dilna_deadzone_temperature)>} and Template<template=({{ value_json.deadzone_temperature }}) renders=5175>
2024-05-22 08:10:32.071 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'climate.termostat_dilna', 'name': None, 'this': <template TemplateStateFromEntityId(climate.termostat_dilna)>} and Template<template=({% set values = {None:None,'idle':'idle','heat':'heating','cool':'cooling','fan_only':'fan'} %}{{ values[value_json.running_state] }}) renders=5175>
2
2024-05-22 08:10:32.081 DEBUG (MainThread) [custom_components.powercalc.sensors.power] climate.termostat_dilna: State changed to "heat". Power:1000.00
2024-05-22 08:10:47.019 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'switch.termostat_dilna_factory_reset', 'name': 'Factory reset', 'this': <template TemplateStateFromEntityId(switch.termostat_dilna_factory_reset)>} and Template<template=({{ value_json.factory_reset }}) renders=5176>
2024-05-22 08:10:47.020 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'switch.termostat_dilna_frost_protection', 'name': 'Frost protection', 'this': <template TemplateStateFromEntityId(switch.termostat_dilna_frost_protection)>} and Template<template=({{ value_json.frost_protection }}) renders=5176>
2024-05-22 08:10:47.020 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'select.termostat_dilna_sensor', 'name': 'Sensor', 'this': <template TemplateStateFromEntityId(select.termostat_dilna_sensor)>} and Template<template=({{ value_json.sensor }}) renders=5176>
2024-05-22 08:10:47.021 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'select.termostat_dilna_backlight_mode', 'name': 'Backlight mode', 'this': <template TemplateStateFromEntityId(select.termostat_dilna_backlight_mode)>} and Template<template=({{ value_json.backlight_mode }}) renders=5176>
2024-05-22 08:10:47.021 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'select.termostat_dilna_working_day', 'name': 'Working day', 'this': <template TemplateStateFromEntityId(select.termostat_dilna_working_day)>} and Template<template=({{ value_json.working_day }}) renders=5176>
2024-05-22 08:10:47.022 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'lock.termostat_dilna_child_lock', 'name': 'Child lock', 'this': <template TemplateStateFromEntityId(lock.termostat_dilna_child_lock)>} and Template<template=({{ value_json.child_lock }}) renders=5176>
2024-05-22 08:10:47.022 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'number.termostat_dilna_local_temperature_calibration', 'name': 'Teplota', 'this': <template TemplateStateFromEntityId(number.termostat_dilna_local_temperature_calibration)>} and Template<template=({{ value_json.local_temperature_calibration }}) renders=5176>
2024-05-22 08:10:47.023 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'number.termostat_dilna_max_temperature_limit', 'name': 'Max temperature limit', 'this': <template TemplateStateFromEntityId(number.termostat_dilna_max_temperature_limit)>} and Template<template=({{ value_json.max_temperature_limit }}) renders=5176>
2024-05-22 08:10:47.024 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'number.termostat_dilna_deadzone_temperature', 'name': 'Deadzone temperature', 'this': <template TemplateStateFromEntityId(number.termostat_dilna_deadzone_temperature)>} and Template<template=({{ value_json.deadzone_temperature }}) renders=5176>
2024-05-22 08:10:47.025 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'climate.termostat_dilna', 'name': None, 'this': <template TemplateStateFromEntityId(climate.termostat_dilna)>} and Template<template=({% set values = {None:None,'idle':'idle','heat':'heating','cool':'cooling','fan_only':'fan'} %}{{ values[value_json.running_state] }}) renders=5176>
2024-05-22 08:10:47.026 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'climate.termostat_dilna', 'name': None, 'this': <template TemplateStateFromEntityId(climate.termostat_dilna)>} and Template<template=({{ value_json.system_mode }}) renders=5176>
2024-05-22 08:10:47.028 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'climate.termostat_dilna', 'name': None, 'this': <template TemplateStateFromEntityId(climate.termostat_dilna)>} and Template<template=({{ value_json.preset }}) renders=5176>
2024-05-22 08:10:47.029 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'climate.termostat_dilna', 'name': None, 'this': <template TemplateStateFromEntityId(climate.termostat_dilna)>} and Template<template=({{ value_json.local_temperature }}) renders=5176>
2024-05-22 08:11:16.966 DEBUG (MainThread) [custom_components.powercalc.sensors.power] climate.termostat_dilna: State changed to "heat". Power:1000.00
2024-05-22 08:11:18.648 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'text.termostat_dilna_schedule_weekday', 'name': 'Schedule weekday', 'this': <template TemplateStateFromEntityId(text.termostat_dilna_schedule_weekday)>} and Template<template=({{ value_json.schedule_weekday }}) renders=5184>
2024-05-22 08:11:18.650 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'text.termostat_dilna_schedule_holiday', 'name': 'Schedule holiday', 'this': <template TemplateStateFromEntityId(text.termostat_dilna_schedule_holiday)>} and Template<template=({{ value_json.schedule_holiday }}) renders=5184>
2024-05-22 08:11:31.924 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'select.termostat_dilna_working_day', 'name': 'Working day', 'this': <template TemplateStateFromEntityId(select.termostat_dilna_working_day)>} and Template<template=({{ value_json.working_day }}) renders=5185>
2024-05-22 08:11:31.926 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'lock.termostat_dilna_child_lock', 'name': 'Child lock', 'this': <template TemplateStateFromEntityId(lock.termostat_dilna_child_lock)>} and Template<template=({{ value_json.child_lock }}) renders=5185>
2024-05-22 08:11:31.928 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'number.termostat_dilna_local_temperature_calibration', 'name': 'Teplota', 'this': <template TemplateStateFromEntityId(number.termostat_dilna_local_temperature_calibration)>} and Template<template=({{ value_json.local_temperature_calibration }}) renders=5185>
2024-05-22 08:11:31.929 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'number.termostat_dilna_max_temperature_limit', 'name': 'Max temperature limit', 'this': <template TemplateStateFromEntityId(number.termostat_dilna_max_temperature_limit)>} and Template<template=({{ value_json.max_temperature_limit }}) renders=5185>
2024-05-22 08:11:31.930 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'number.termostat_dilna_deadzone_temperature', 'name': 'Deadzone temperature', 'this': <template TemplateStateFromEntityId(number.termostat_dilna_deadzone_temperature)>} and Template<template=({{ value_json.deadzone_temperature }}) renders=5185>
2024-05-22 08:11:31.931 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'climate.termostat_dilna', 'name': None, 'this': <template TemplateStateFromEntityId(climate.termostat_dilna)>} and Template<template=({% set values = {None:None,'idle':'idle','heat':'heating','cool':'cooling','fan_only':'fan'} %}{{ values[value_json.running_state] }}) renders=5185>
2024-05-22 08:11:31.934 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'climate.termostat_dilna', 'name': None, 'this': <template TemplateStateFromEntityId(climate.termostat_dilna)>} and Template<template=({{ value_json.system_mode }}) renders=5185>
2024-05-22 08:11:31.937 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'climate.termostat_dilna', 'name': None, 'this': <template TemplateStateFromEntityId(climate.termostat_dilna)>} and Template<template=({{ value_json.preset }}) renders=5185>
2024-05-22 08:11:31.938 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'climate.termostat_dilna', 'name': None, 'this': <template TemplateStateFromEntityId(climate.termostat_dilna)>} and Template<template=({{ value_json.local_temperature }}) renders=5185>
2024-05-22 08:11:31.940 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'climate.termostat_dilna', 'name': None, 'this': <template TemplateStateFromEntityId(climate.termostat_dilna)>} and Template<template=({{ value_json.current_heating_setpoint }}) renders=5185>
2024-05-22 08:11:31.941 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'text.termostat_dilna_schedule_weekday', 'name': 'Schedule weekday', 'this': <template TemplateStateFromEntityId(text.termostat_dilna_schedule_weekday)>} and Template<template=({{ value_json.schedule_weekday }}) renders=5185>
2024-05-22 08:11:31.942 DEBUG (MainThread) [homeassistant.components.mqtt.models] Rendering incoming payload '{ "running_state":"idle" ' with variables {'entity_id': 'text.termostat_dilna_schedule_holiday', 'name': 'Schedule holiday', 'this': <template TemplateStateFromEntityId(text.termostat_dilna_schedule_holiday)>} and Template<template=({{ value_json.schedule_holiday }}) renders=5185>
2024-05-22 08:11:31.944 DEBUG (MainThread) [custom_components.powercalc.sensors.power] climate.termostat_dilna: State changed to "heat". Power:1000.00
Ich running_state really in your sensor entity attributes?
Can you show the dev tools state of your source sensor?
Ok, maby will be problem there… I’ll try change to hvac_action…
Edit: Looks like that was it. Problem was use wrong entities. Thank you.
Edti 2: Right is:
hvac_action|heat: 500
hvac_action|idle: 0
ah, glad you got it resolved.
Hello,
I try use powercalc forthermostat with climate.
climate.thermostat_bureau
But after next the box dialog say me
What mistake am I making?
Is it possible to change unit_of_measurement
to A instead of just W or kW ??