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

Moved register 3 from sensor to number #77

Merged
merged 3 commits into from
Jan 12, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [Unreleased]

### Changed

- Register 3 has been changed from type `sensor` to `number` to make them configurable

## [5.1.0] - 2025-01-12

### Added
Expand Down
34 changes: 22 additions & 12 deletions heatpump.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -346,18 +346,7 @@ sensor:
return x;
# Register: 1 -> Is present in this config as a 'select'
# Register: 2 -> Is present in this config as a 'number'
# Register: 3
- platform: modbus_controller
modbus_controller_id: "${devicename}"
name: "Air Temperature Ts"
id: "${devicename}_air_temperature_ts"
icon: mdi:temperature-celsius
register_type: holding
address: 0x3
value_type: U_WORD
unit_of_measurement: "°C"
filters:
- multiply: 0.5
# Register: 3 -> Is present in this config as a 'number'
# Register: 4 -> Is present in this config as a 'number'
# Register: 5 -> Config is present as select, but now we need get value from heatpump and save it as global var
- platform: modbus_controller
Expand Down Expand Up @@ -3154,6 +3143,27 @@ number:
id(unmasked_value_water_temperature_t1s) = value;
return {};

# Register: 3
- platform: modbus_controller
modbus_controller_id: "${devicename}"
name: "Air Temperature Ts"
id: "${devicename}_air_temperature_ts"
icon: mdi:temperature-celsius
register_type: holding
address: 0x3
value_type: U_WORD
unit_of_measurement: "°C"
entity_category: config
device_class: temperature
min_value: 17
max_value: 30
step: 0.5
mode: slider
lambda: |-
return x * 0.5;
write_lambda: |-
return x * 2.0;

# Register: 4
- platform: modbus_controller
modbus_controller_id: "${devicename}"
Expand Down
Loading