waterfurnace_aurora 1.4.11 → 1.5.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 53077daf9bf7047148ddb43fff7058c3a2e93d52673293fadc9b0a51bcd5bf06
4
- data.tar.gz: 789a953ebc457a4d607a6e67916703ecf9fd48b8394953026544c95b85ad3ce6
3
+ metadata.gz: 4aa5d7eb7e44c106d01755ecdfce849f23503d3d6c10da86bfa4c9d4376669e3
4
+ data.tar.gz: '026036095b6c3f5a7fd98825970612dd0399908f255ddc6a98520535edb2922d'
5
5
  SHA512:
6
- metadata.gz: aae7893a9da0786214b045fc5e8182590abac939461cc1df6c717bd4bbdf4391bf020a37a1d5e291f541f4d8f23d2a091d351d18f840edb4d091a210b6f33628
7
- data.tar.gz: 5166996c59c556c961100347217afe9b2b29a38a27b3e109cf9b9f9399128a0c83c680a53e39e363861a93a0c0cf311c227af6a23ee814c7fdc84b310f6e1a22
6
+ metadata.gz: b9904a9e4941a113c3c2a41819ba3dd279155262394011fa4b089062571079981c741a086e21c34c67276cd5b1f35ba2358ec71a5794022d01c7837aa635911b
7
+ data.tar.gz: 683a618118d05978ba623e0df2a6adaac9ff2d436b70baaad6374d4760e980c34bad29124a16929d5a4edd062df3a537b7a26baf96fa7dc69419c01e111658eb
@@ -151,7 +151,7 @@ class MQTTBridge
151
151
  :enum,
152
152
  @abc.current_mode,
153
153
  format: allowed_modes,
154
- hass: { sensor: { state_class: :measurement } })
154
+ hass: :sensor)
155
155
  node.property("emergency-shutdown",
156
156
  "Emergency Shutdown Requested",
157
157
  :boolean,
@@ -584,8 +584,7 @@ class MQTTBridge
584
584
  node.property("enabled",
585
585
  "Enabled",
586
586
  :boolean,
587
- @abc.dhw.enabled,
588
- hass: { switch: { icon: "mdi:water-boiler" } }) do |value|
587
+ @abc.dhw.enabled) do |value|
589
588
  @mutex.synchronize { @abc.dhw.enabled = value }
590
589
  end
591
590
  node.property("running",
@@ -598,27 +597,46 @@ class MQTTBridge
598
597
  :float,
599
598
  @abc.dhw.set_point,
600
599
  format: 100..140,
601
- unit: "°F",
602
- hass: { number: { step: 5 } }) do |value|
600
+ unit: "°F") do |value|
603
601
  @mutex.synchronize { @abc.dhw.set_point = value }
604
602
  end
605
603
  node.property("water-temperature",
606
604
  "Water Temperature",
607
605
  :float,
608
606
  @abc.dhw.water_temperature,
609
- unit: "°F",
610
- hass: { sensor: { device_class: :temperature,
611
- state_class: :measurement } })
607
+ unit: "°F")
608
+ @homie.mqtt.unpublish_hass_switch("dhw_enabled", node_id: @homie.id)
609
+ @homie.mqtt.unpublish_hass_number("dhw_set-point", node_id: @homie.id)
610
+ @homie.mqtt.unpublish_hass_sensor("dhw_water-temperature", node_id: @homie.id)
611
+ node.hass_water_heater(current_temperature_property: "water-temperature",
612
+ mode_property: "enabled",
613
+ modes: %i[off heat_pump],
614
+ mode_command_template: <<~JINJA,
615
+ {% if value == 'off' %}
616
+ false
617
+ {% else %}
618
+ true
619
+ {% endif %}
620
+ JINJA
621
+ mode_state_template: <<~JINJA,
622
+ {% if value == 'true' %}
623
+ heat_pump
624
+ {% elif value == 'false' %}
625
+ off
626
+ {% endif %}
627
+ JINJA
628
+ temperature_property: "set-point",
629
+ icon: "mdi:water-boiler")
612
630
  end
613
631
  end
614
632
 
615
633
  if @abc.humidistat
616
634
  @humidistat = @homie.node("humidistat", "Humidistat", "Humidistat") do |node|
617
635
  if @abc.humidistat.humidifier?
618
- node.property("humidifier-running",
619
- "Humidifier Running",
620
- :boolean,
621
- @abc.humidistat.humidifier_running?)
636
+ running = node.property("humidifier-running",
637
+ "Humidifier Running",
638
+ :boolean,
639
+ @abc.humidistat.humidifier_running?)
622
640
  if @abc.awl_communicating?
623
641
  node.property("humidifier-mode",
624
642
  "Humidifier Mode",
@@ -636,21 +654,22 @@ class MQTTBridge
636
654
  @mutex.synchronize { @abc.humidistat.humidification_target = value }
637
655
  end
638
656
  node.hass_humidifier("humidifier-running",
639
- target_property: "humidification-target",
657
+ target_humidity_property: "humidification-target",
640
658
  mode_property: "humidifier-mode",
641
- id: "humidifier",
659
+ object_id: "humidifier",
642
660
  name: "Humidifier",
643
- device_class: :humidifier)
661
+ device_class: :humidifier,
662
+ command_topic: "#{running.topic}/set")
644
663
  end
645
664
  end
646
665
 
647
666
  # VSDrive can perform active dehumidification, even without a dedicated dehumidifier
648
667
  if @abc.humidistat.dehumidifier? ||
649
668
  @abc.compressor.is_a?(Aurora::Compressor::VSDrive)
650
- node.property("dehumidifier-running",
651
- "Dehumidifier Running",
652
- :boolean,
653
- @abc.humidistat.dehumidifier_running?)
669
+ running = node.property("dehumidifier-running",
670
+ "Dehumidifier Running",
671
+ :boolean,
672
+ @abc.humidistat.dehumidifier_running?)
654
673
  if @abc.awl_communicating?
655
674
  node.property("dehumidifier-mode",
656
675
  "Dehumidifier Mode",
@@ -668,11 +687,12 @@ class MQTTBridge
668
687
  @mutex.synchronize { @abc.humidistat.dehumidification_target = value }
669
688
  end
670
689
  node.hass_humidifier("dehumidifier-running",
671
- target_property: "dehumidification-target",
690
+ target_humidity_property: "dehumidification-target",
672
691
  mode_property: "dehumidifier-mode",
673
- id: "dehumidifier",
692
+ object_id: "dehumidifier",
674
693
  name: "Dehumidifier",
675
- device_class: :dehumidifier)
694
+ device_class: :dehumidifier,
695
+ command_topic: "#{running.topic}/set")
676
696
  end
677
697
  end
678
698
  next unless @abc.awl_communicating?
@@ -819,17 +839,16 @@ class MQTTBridge
819
839
  mode_property: "target-mode",
820
840
  temperature_high_property: "cooling-target-temperature",
821
841
  temperature_low_property: "heating-target-temperature",
822
- templates: {
823
- action_template: <<~JINJA
824
- {% if value.startswith('h') %}
825
- heating
826
- {% elif value.startswith('c') %}
827
- cooling
828
- {% elif value == 'standby' %}
829
- idle
830
- {% endif %}
831
- JINJA
832
- })
842
+ action_template: <<~JINJA
843
+ {% if value.startswith('h') %}
844
+ heating
845
+ {% elif value.startswith('c') %}
846
+ cooling
847
+ {% elif value == 'standby' %}
848
+ idle
849
+ {% endif %}
850
+ JINJA
851
+ )
833
852
  end
834
853
  end
835
854
 
@@ -236,7 +236,7 @@ module Aurora
236
236
  end
237
237
  @outdoor_temperature = registers[31_003]
238
238
  @air_coil_temperature = registers[20]
239
- @locked_out = !(registers[25] & 0x8000).zero?
239
+ @locked_out = registers[25].anybits?(0x8000)
240
240
  @current_fault = registers[25] & 0x7fff
241
241
  @derated = (41..46).cover?(@current_fault)
242
242
  @safe_mode = [47, 48, 49, 72, 74].include?(@current_fault)
@@ -479,7 +479,7 @@ module Aurora
479
479
  def zone_configuration3(value)
480
480
  size = (value >> 3) & 0x3
481
481
  result = {
482
- zone_priority: ((value & 0x20) == 0x20) ? :economy : :comfort,
482
+ zone_priority: value.allbits?(0x20) ? :economy : :comfort,
483
483
  zone_size: ZONE_SIZES[size],
484
484
  normalized_size: value >> 8
485
485
  }
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Aurora
4
- VERSION = "1.4.11"
4
+ VERSION = "1.5.0"
5
5
  end
@@ -43,7 +43,7 @@ module Aurora
43
43
  end
44
44
 
45
45
  get "/request.cgi" do
46
- params = parse_query_string(request.query_string)
46
+ params = URI.decode_www_form(request.query_string).to_h
47
47
  result = params.slice("cmd", "id", "set", "addr")
48
48
  result["err"] = nil
49
49
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: waterfurnace_aurora
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.4.11
4
+ version: 1.5.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Cody Cutrer
8
- autorequire:
8
+ autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2024-10-07 00:00:00.000000000 Z
11
+ date: 2025-01-02 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: ccutrer-serialport
@@ -25,25 +25,19 @@ dependencies:
25
25
  - !ruby/object:Gem::Version
26
26
  version: '1.0'
27
27
  - !ruby/object:Gem::Dependency
28
- name: mqtt-homeassistant
28
+ name: mqtt-homie-homeassistant
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
31
  - - "~>"
32
32
  - !ruby/object:Gem::Version
33
- version: '0.1'
34
- - - ">="
35
- - !ruby/object:Gem::Version
36
- version: 0.1.5
33
+ version: '1.0'
37
34
  type: :runtime
38
35
  prerelease: false
39
36
  version_requirements: !ruby/object:Gem::Requirement
40
37
  requirements:
41
38
  - - "~>"
42
39
  - !ruby/object:Gem::Version
43
- version: '0.1'
44
- - - ">="
45
- - !ruby/object:Gem::Version
46
- version: 0.1.5
40
+ version: '1.0'
47
41
  - !ruby/object:Gem::Dependency
48
42
  name: net-telnet-rfc2217
49
43
  requirement: !ruby/object:Gem::Requirement
@@ -132,7 +126,7 @@ dependencies:
132
126
  - - "<"
133
127
  - !ruby/object:Gem::Version
134
128
  version: 5.0.a
135
- description:
129
+ description:
136
130
  email: cody@cutrer.us'
137
131
  executables:
138
132
  - aurora_fetch
@@ -173,7 +167,7 @@ licenses:
173
167
  - MIT
174
168
  metadata:
175
169
  rubygems_mfa_required: 'true'
176
- post_install_message:
170
+ post_install_message:
177
171
  rdoc_options: []
178
172
  require_paths:
179
173
  - lib
@@ -189,7 +183,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
189
183
  version: '0'
190
184
  requirements: []
191
185
  rubygems_version: 3.5.11
192
- signing_key:
186
+ signing_key:
193
187
  specification_version: 4
194
188
  summary: Library for communication with WaterFurnace Aurora control systems
195
189
  test_files: []