Skip to content

Commit

Permalink
Merge pull request #31 from Mosibi/register_0_bit_1_2_and_3_to_switch
Browse files Browse the repository at this point in the history
Bit 0, 1 and 3 changed from `binary sensor` to `switch` to make them configurable
  • Loading branch information
Mosibi authored Jun 30, 2024
2 parents de361b3 + c4fd2c1 commit ef4b8f5
Show file tree
Hide file tree
Showing 2 changed files with 36 additions and 24 deletions.
9 changes: 9 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,15 @@ 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).

## [3.1.0] - 2024-06-30

### Changed

- Register 0: Bit 0, 1 and 3 changed from `binary sensor` to `switch` to make them configurable
- Bit 0: Power Air Conditioner Zone 1
- Bit 1: Power Floor Heating Zone 1
- Bit 3: Power Air Conditioner Zone 2

## [3.0.1] - 2024-06-23

### Fixed
Expand Down
51 changes: 27 additions & 24 deletions heatpump.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -987,31 +987,10 @@ sensor:

binary_sensor:
# Register: 0
# Bit: 0
- platform: modbus_controller
modbus_controller_id: "${devicename}"
name: "${entity_prefix} Power Air Conditioner Zone 1"
id: "${devicename}_power_air_conditioner_zone_1"
register_type: holding
address: 0x0
bitmask: 0x1
# Bit: 1
- platform: modbus_controller
modbus_controller_id: "${devicename}"
name: "${entity_prefix} Power Floor Heating Zone 1"
id: "${devicename}_power_floor_heating_zone_1"
register_type: holding
address: 0x0
bitmask: 0x2
# Bit: 0 -> Is present in this config as a 'switch'
# Bit: 1 -> Is present in this config as a 'switch'
# Bit: 2 -> Is present in this config as a 'switch'
# Bit: 3
- platform: modbus_controller
modbus_controller_id: "${devicename}"
name: "${entity_prefix} Power Air Conditioner Zone 2"
id: "${devicename}_power_air_conditioner_zone_2"
register_type: holding
address: 0x0
bitmask: 0x8
# Bit: 3 -> Is present in this config as a 'switch'
# Bit: 4
- platform: modbus_controller
modbus_controller_id: "${devicename}"
Expand Down Expand Up @@ -1898,6 +1877,22 @@ binary_sensor:
switch:
- platform: factory_reset
name: Restart with Factory Default Settings
# Register: 0 -> Bit 0
- platform: modbus_controller
modbus_controller_id: "${devicename}"
name: "${entity_prefix} Power Air Conditioner Zone 1"
id: "${devicename}_power_air_conditioner_zone_1"
register_type: holding
address: 0x0
bitmask: 0x1
# Register: 0 -> Bit 1
- platform: modbus_controller
modbus_controller_id: "${devicename}"
name: "${entity_prefix} Power Floor Heating Zone 1"
id: "${devicename}_power_floor_heating_zone_1"
register_type: holding
address: 0x0
bitmask: 0x2
# Register: 0 -> Bit 2
- platform: modbus_controller
modbus_controller_id: "${devicename}"
Expand All @@ -1907,6 +1902,14 @@ switch:
entity_category: config
address: 0x0
bitmask: 0x4
# Register: 0 -> Bit 3
- platform: modbus_controller
modbus_controller_id: "${devicename}"
name: "${entity_prefix} Power Air Conditioner Zone 2"
id: "${devicename}_power_air_conditioner_zone_2"
register_type: holding
address: 0x0
bitmask: 0x8
# Register: 5 -> Bit 12
- platform: modbus_controller
modbus_controller_id: "${devicename}"
Expand Down

0 comments on commit ef4b8f5

Please sign in to comment.