KartoffelToby / better_thermostat

This custom component for Home Assistant will add crucial features to your climate-controlling TRV (Thermostatic Radiator Valves) to save you the work of creating automations to make it smart. It combines a room-temperature sensor, window/door sensors, weather forecasts, or an ambient temperature probe to decide when it should call for heat and automatically calibrate your TRVs to fix the imprecise measurements taken in the radiator's vicinity.
https://better-thermostat.org
GNU Affero General Public License v3.0
744 stars 123 forks source link

Recorded BT heating intervals do not match actual TRV heating #1147

Open pomeloy opened 9 months ago

pomeloy commented 9 months ago

Prerequisites

hvac_modes: heat, off
min_temp: 5
max_temp: 30
target_temp_step: 0.5
current_temperature: 21.4
temperature: 20
hvac_action: off
window_open: false
call_for_heat: true
last_change: ***
saved_temperature: null
humidity: 65.2
main_mode: heat
tolerance: 0.5
heating_power: 0.0192
errors: []
batteries: {"binary_sensor.***_contact": {"battery": "off", "battery_id": "binary_sensor.***_battery_low"}, "climate.***_thermostat_1": {"battery": "24", "battery_id": "sensor.***_thermostat_1_battery"}, "climate.***_thermostat_2": {"battery": "32", "battery_id": "sensor.***_thermostat_2_battery"}}
friendly_name: ***
supported_features: 1

{
  "home_assistant": {
    "installation_type": "Home Assistant Container",
    "version": "2023.11.2",
    "dev": false,
    "hassio": false,
    "virtualenv": false,
    "python_version": "3.11.6",
    "docker": true,
    "arch": "x86_64",
    "timezone": "Europe/Berlin",
    "os_name": "Linux",
    "os_version": "5.10.0-26-amd64",
    "run_as_root": true
  },
  "custom_components": {
    "better_thermostat": {
      "version": "1.4.0",
      "requirements": []
    },
    ***
    "hacs": {
      "version": "1.33.0",
      "requirements": [
        "aiogithubapi>=22.10.1"
      ]
    }
  },
  "integration_manifest": {
    "domain": "better_thermostat",
    "name": "Better Thermostat",
    "after_dependencies": [
      "climate"
    ],
    "codeowners": [
      "@kartoffeltoby"
    ],
    "config_flow": true,
    "dependencies": [
      "climate",
      "recorder"
    ],
    "documentation": "https://github.com/KartoffelToby/better_thermostat",
    "iot_class": "local_push",
    "issue_tracker": "https://github.com/KartoffelToby/better_thermostat/issues",
    "requirements": [],
    "version": "1.4.0",
    "is_built_in": false
  },
  "data": {
    "info": {
      "name": "***",
      "temperature_sensor": "sensor.***_temperature",
      "off_temperature": 20,
      "tolerance": 0.5,
      "humidity_sensor": "sensor.***_humidity",
      "outdoor_sensor": "sensor.***_temperature",
      "weather": "weather.***",
      "window_sensors": "binary_sensor.***_contact",
      "window_off_delay": 45,
      "model": "BTH-RA/BTH-RA",
      "window_off_delay_after": 60
    },
    "thermostat": {
      "climate.***_thermostat_1": {
        "name": "*** thermostat 1",
        "state": "heat",
        "attributes": {
          "hvac_modes": [
            "off",
            "heat",
            "auto"
          ],
          "min_temp": 5.0,
          "max_temp": 30.0,
          "target_temp_step": 0.5,
          "current_temperature": 20.5,
          "temperature": 20.0,
          "hvac_action": "off",
          "friendly_name": "*** thermostat 1",
          "supported_features": 1
        },
        "bt_config": {
          "calibration": "local_calibration_based",
          "calibration_mode": "heating_power_calibration",
          "protect_overheating": false,
          "no_off_system_mode": false,
          "heat_auto_swapped": false,
          "child_lock": false,
          "homaticip": false
        },
        "bt_adapter": "mqtt",
        "bt_integration": "mqtt",
        "model": "BTH-RA"
      },
      "climate.***_thermostat_2": {
        "name": "*** thermostat 2",
        "state": "heat",
        "attributes": {
          "hvac_modes": [
            "off",
            "heat",
            "auto"
          ],
          "min_temp": 5.0,
          "max_temp": 30.0,
          "target_temp_step": 0.5,
          "current_temperature": 20.7,
          "temperature": 20.0,
          "hvac_action": "off",
          "friendly_name": "*** thermostat 2",
          "supported_features": 1
        },
        "bt_config": {
          "calibration": "local_calibration_based",
          "calibration_mode": "heating_power_calibration",
          "protect_overheating": false,
          "no_off_system_mode": false,
          "heat_auto_swapped": false,
          "child_lock": false,
          "homaticip": false
        },
        "bt_adapter": "mqtt",
        "bt_integration": "mqtt",
        "model": "BTH-RA"
      }
    },
    "external_temperature_sensor": {
      "entity_id": "sensor.***_temperature",
      "state": "21.34",
      "attributes": {
        "state_class": "measurement",
        "unit_of_measurement": "\u00b0C",
        "icon": "mdi:thermometer",
        "friendly_name": "***",
        "device_class": "temperature"
      },
      "last_changed": "***",
      "last_updated": "***",
      "context": {
        "id": "***",
        "parent_id": null,
        "user_id": null
      }
    },
    "window_sensor": {
      "entity_id": "binary_sensor.***_contact",
      "state": "off",
      "attributes": {
        "device_class": "window",
        "friendly_name": "***"
      },
      "last_changed": "***",
      "last_updated": "***",
      "context": {
        "id": "***",
        "parent_id": null,
        "user_id": null
      }
    }
  }
}

Description

The recorded heating intervals for the BT entities do not match the heating intervals recorded for the actual TRV devices.

Steps to Reproduce

  1. Create BT TRV
  2. Set temperature

Expected behavior:

The history graph for the BT entity should show the same heating intervals as the one for the actual TRV device.

Actual behavior:

The history graph for the BT entity shows no heating over a large period of time when, in fact, the actual valve is at least partly open so heating does occur.

Versions

HA 2023.11.2 BT 1.4.0

Additional Information

Better Thermostat: bt Actual devices: devices Actual heating demand: heatingdemand

auanasgheps commented 9 months ago

I just opened an issue about the exact same problem!

1161

Waiting for mods to decide if mine should be closed, I think it's the same problem.