Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Local temperatur calibration being completly wrong #1470

Open
1 task done
LarsK1 opened this issue Nov 15, 2024 · 3 comments
Open
1 task done

Local temperatur calibration being completly wrong #1470

LarsK1 opened this issue Nov 15, 2024 · 3 comments
Assignees
Labels
new bug incoming bug issue

Comments

@LarsK1
Copy link

LarsK1 commented Nov 15, 2024

Prerequisites

  • Model name of your Devices: Tuya TS0601

Unfortunately I can't generate diagnostic data (see #1469)

Description

Somehow the local temperature calibration is way of. See these images. The temperature sensor reads 22.2°C, the thermostat it self reports 21.5°C, which should result in an offset of 0.7°C, but it is set to 9°C?
image
image

Device config:
image
image

Versions

BT: 1.7.0-beta1
HA: 2024.11.1

@LarsK1 LarsK1 added the new bug incoming bug issue label Nov 15, 2024
@eflye
Copy link

eflye commented Nov 15, 2024

my 20 cents, i'm digging within the same kind of issue. I was able to identify that calibration is impacted by the following code change from the beta in calibration.py:

    # Base calibration adjustment considering tolerance
    if _cur_external_temp >= _cur_target_temp + self.tolerance:
        _new_trv_calibration += (
            _cur_external_temp - (_cur_target_temp + self.tolerance)
        ) * 2.0

if _cur_external_temp >= _cur_target_temp + self.tolerance:

@KartoffelToby may i ask you to explain why _new_trv_calibration is changed when _cur_external_temp > _cur_target_temp.
Example here:

Before quoted if statement, new_trv_calculation = 0 ( after respecting tolerance in all calibration modes, delaying heat is statement)

  • _cur_external_temp -> 17.7
  • _cur_target_temp -> 17.0
  • self.tolerance -> 0.0
  • Result -> _new_trv_calibration after base calibration adjustement considering tolrance -> 1.3999999999999986

It's impact Normal mode also.

I'm going to rollback to previous version and i will follow explanation.

Let me know if both case are not the same and if i have to create another issue.

@LarsK1
Copy link
Author

LarsK1 commented Nov 16, 2024

@eflye try changing this line (

_calibrated_setpoint = (_cur_target_temp - _cur_external_temp) + _cur_trv_temp_s
)
to this:
_new_trv_calibration = _cur_external_temp - (_cur_trv_temp_f - _current_trv_calibration)

@LarsK1
Copy link
Author

LarsK1 commented Nov 16, 2024

That's resolved the issue for me.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
new bug incoming bug issue
Projects
None yet
Development

No branches or pull requests

3 participants