waterfurnace_aurora 0.3.11 → 0.4.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/exe/aurora_fetch +4 -22
- data/exe/aurora_mock +16 -16
- data/exe/aurora_monitor +29 -19
- data/exe/aurora_mqtt_bridge +49 -22
- data/exe/web_aid_tool +10 -53
- data/lib/aurora/abc_client.rb +181 -20
- data/lib/aurora/mock_abc.rb +48 -0
- data/lib/aurora/registers.rb +378 -108
- data/lib/aurora/thermostat.rb +1 -1
- data/lib/aurora/version.rb +1 -1
- data/lib/aurora.rb +1 -0
- metadata +3 -2
@@ -0,0 +1,48 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module Aurora
|
4
|
+
class MockABC
|
5
|
+
attr_accessor :logger
|
6
|
+
|
7
|
+
def initialize(registers)
|
8
|
+
@registers = registers
|
9
|
+
end
|
10
|
+
|
11
|
+
def read_retry_timeout=(_); end
|
12
|
+
|
13
|
+
def read_retries=(_); end
|
14
|
+
|
15
|
+
def holding_registers
|
16
|
+
self
|
17
|
+
end
|
18
|
+
|
19
|
+
def [](*register)
|
20
|
+
if register.length == 1
|
21
|
+
case register.first
|
22
|
+
when Integer
|
23
|
+
@registers[register.first]
|
24
|
+
when Range
|
25
|
+
@registers.values_at(*register.first.to_a)
|
26
|
+
else
|
27
|
+
raise ArgumentError, "Not implemented yet #{register.inspect}"
|
28
|
+
end
|
29
|
+
else
|
30
|
+
read_multiple_holding_registers(*register)
|
31
|
+
end
|
32
|
+
end
|
33
|
+
|
34
|
+
def read_multiple_holding_registers(*queries)
|
35
|
+
result = {}
|
36
|
+
queries.each do |query|
|
37
|
+
Array(query).each do |i|
|
38
|
+
result[i] = @registers[i]
|
39
|
+
end
|
40
|
+
end
|
41
|
+
result
|
42
|
+
end
|
43
|
+
|
44
|
+
def write_holding_register(addr, value)
|
45
|
+
@registers[addr] = value
|
46
|
+
end
|
47
|
+
end
|
48
|
+
end
|
data/lib/aurora/registers.rb
CHANGED
@@ -59,69 +59,145 @@ module Aurora
|
|
59
59
|
result
|
60
60
|
end
|
61
61
|
|
62
|
+
def to_int32(registers, idx)
|
63
|
+
(registers[idx] << 16) + registers[idx + 1]
|
64
|
+
end
|
65
|
+
|
62
66
|
def to_string(registers, idx, length)
|
63
67
|
(idx...(idx + length)).map do |i|
|
68
|
+
raise ArgumentError, "Missing register #{i} for string starting at #{idx}" unless registers[i]
|
69
|
+
|
64
70
|
(registers[i] >> 8).chr + (registers[i] & 0xff).chr
|
65
71
|
end.join.sub(/[ \0]+$/, "")
|
66
72
|
end
|
67
73
|
|
68
74
|
FAULTS = {
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
|
75
|
-
|
75
|
+
# ABC/AXB Basic Faults
|
76
|
+
1 => "Input Error", # Tstat input error. Autoreset upon condition removal.
|
77
|
+
2 => "High Pressure", # HP switch has tripped (>600 psi)
|
78
|
+
3 => "Low Pressure", # Low Pressure Switch has tripped (<40 psi for 30 continous sec.)
|
79
|
+
4 => "Freeze Detect FP2", # Freeze protection sensor has tripped (<15 or 30 degF for 30 continuous sec.)
|
80
|
+
5 => "Freeze Detect FP1", # Freeze protection sensor has tripped (<15 or 30 degF for 30 continuous sec.)
|
81
|
+
7 => "Condensate Overflow", # Condensate switch has shown continuity for 30 continuous sec.
|
82
|
+
8 => "Over/Under Voltage", # Instantaneous Voltage is out of range. **Controls shut down until resolved.
|
76
83
|
9 => "AirF/RPM",
|
77
|
-
10 => "
|
78
|
-
11 => "FP1/2
|
79
|
-
12 => "RefPerfrm
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
|
100
|
-
|
101
|
-
|
102
|
-
|
103
|
-
|
104
|
-
|
105
|
-
|
106
|
-
|
107
|
-
|
108
|
-
|
109
|
-
|
110
|
-
|
111
|
-
|
112
|
-
|
113
|
-
|
114
|
-
|
115
|
-
|
116
|
-
|
117
|
-
|
118
|
-
|
84
|
+
10 => "Compressor Monitor", # Open Crkt, Run, Start or welded cont
|
85
|
+
11 => "FP1/2 Sensor Error",
|
86
|
+
12 => "RefPerfrm Error",
|
87
|
+
# Miscellaneous
|
88
|
+
13 => "Non-Critical AXB Sensor Error", # Any Other Sensor Error
|
89
|
+
14 => "Critical AXB Sensor Error", # Sensor Err for EEV or HW
|
90
|
+
15 => "Hot Water Limit", # HW over limit or logic lockout. HW pump deactivated.
|
91
|
+
16 => "VS Pump Error", # Alert is read from PWM feedback.
|
92
|
+
17 => "Communicating Thermostat Error",
|
93
|
+
18 => "Non-Critical Communications Error", # Any non-critical com error
|
94
|
+
19 => "Critical Communications Error", # Any critical com error. Auto reset upon condition removal
|
95
|
+
21 => "Low Loop Pressure", # Loop pressure is below 3 psi for more than 3 minutes
|
96
|
+
22 => "Communicating ECM Error",
|
97
|
+
23 => "HA Alarm 1", # Closed contact input is present on Dig 2 input - Text is configurable.
|
98
|
+
24 => "HA Alarm 2", # Closed contact input is present on Dig 3 input - Text is configurable.
|
99
|
+
25 => "AxbEev Error",
|
100
|
+
# VS Drive
|
101
|
+
41 => "High Drive Temp", # Drive Temp has reached critical High Temp (>239 ̊F/115 ̊C)
|
102
|
+
42 => "High Discharge Temp", # Discharge temperature has reached critical high temp (> 280 ̊F/138 ̊C)
|
103
|
+
43 => "Low Suction Pressure", # Suction Pressure is critically low (< 28 psig)
|
104
|
+
44 => "Low Condensing Pressure", # Condensing pressure is critically low (< 119 psig)
|
105
|
+
45 => "High Condensing Pressure", # Condensing pressure is critically high (> 654 psig)
|
106
|
+
46 => "Output Power Limit", # Supply Voltage is <208V or Max Pwr is reached due to high pressure
|
107
|
+
47 => "EEV ID Comm Error", # Com with EEV is interupted EEV has gone independent mode
|
108
|
+
48 => "EEV OD Comm Error", # Com with EEV is interupted EEV has gone independent mode
|
109
|
+
49 => "Cabinet Temperature Sensor", # Ambient Temperature (Tamb) is <-76 or > 212 F and out of range or invalid
|
110
|
+
51 => "Discharge Temp Sensor", # Discharge Sensor (Sd) is > 280 F or invalid (-76 to 392 F)
|
111
|
+
52 => "Suction Presure Sensor", # Suction Pressure (P0) is invalid (0 to 232 psi)
|
112
|
+
53 => "Condensing Pressure Sensor", # Low condensing pressure (PD) or invalid (0 to 870 psi) Retry 10x.
|
113
|
+
54 => "Low Supply Voltage", # Supply Voltage is <180 V (190V to reset) or powered off/on too quickly (<30 sec.).
|
114
|
+
55 => "Out of Envelope", # Comp Operating out of envelope (P0) more than 90 sec. Retry 10x.
|
115
|
+
56 => "Drive Over Currnet", # Over current tripped by phase loss, earth fault, short circuit, low water flow, low air flow, or major drive fault. # rubocop:disable Layout/LineLength
|
116
|
+
57 => "Drive Over/Under Voltage", # DC Link Voltage to compressor is >450vdc or at minimum voltage (<185vdc).
|
117
|
+
58 => "High Drive Temp", # Drive Temp has reached critical High Temp >239 F
|
118
|
+
59 => "Internal Drive Error", # The MOC has encountered an internal fault or an internal error. Probably fatal.
|
119
|
+
61 => "Multiple Safe Mode", # More than one SafeMode condition is present requiring lockout
|
120
|
+
# EEV2
|
121
|
+
71 => "Loss of Charge", # High superheat and high EEV opening % for a long time will trigger a loss of charge fault
|
122
|
+
72 => "Suction Temperature Sensor", # Suction Temperature Sensor is invalid (-76 to 392 F)
|
123
|
+
73 => "Leaving Air Temperature Sensor", # Leaving Air Temperature Sensor is invalid (-76 to 392 F)
|
124
|
+
74 => "Maximum Operating Pressure", # Suction pressure has exceeded that maximum operating level for 90 sec.
|
125
|
+
99 => "System Reset"
|
126
|
+
}.freeze
|
127
|
+
|
128
|
+
SMARTGRID_ACTION = {
|
129
|
+
0 => :none,
|
130
|
+
1 => :unoccupied_set_points,
|
131
|
+
2 => :load_shed,
|
132
|
+
3 => :capacity_limiting,
|
133
|
+
4 => :off_time
|
134
|
+
}.freeze
|
135
|
+
|
136
|
+
HA_ALARM = {
|
137
|
+
0 => :none,
|
138
|
+
1 => :general,
|
139
|
+
2 => :security,
|
140
|
+
3 => :sump,
|
141
|
+
4 => :carbon_monoxide,
|
142
|
+
5 => :dirty_filter
|
143
|
+
}.freeze
|
144
|
+
|
145
|
+
BRINE_TYPE = Hash.new("Water").merge!(
|
146
|
+
485 => "Antifreeze"
|
147
|
+
).freeze
|
148
|
+
|
149
|
+
FLOW_METER_TYPE = Hash.new("Other").merge!(
|
150
|
+
0 => "None",
|
151
|
+
1 => '3/4"',
|
152
|
+
2 => '1"'
|
153
|
+
).freeze
|
154
|
+
|
155
|
+
PUMP_TYPE = Hash.new("Other").merge!(
|
156
|
+
0 => "Open Loop",
|
157
|
+
1 => "FC1",
|
158
|
+
2 => "FC2",
|
159
|
+
3 => "VS Pump",
|
160
|
+
4 => "VS Pump + 26-99",
|
161
|
+
5 => "VS Pump + UPS26-99",
|
162
|
+
6 => "FC1_GLNP",
|
163
|
+
7 => "FC2_GLNP"
|
164
|
+
).freeze
|
165
|
+
|
166
|
+
PHASE_TYPE = Hash.new("Other").merge!(
|
167
|
+
0 => "Single",
|
168
|
+
1 => "Three"
|
169
|
+
).freeze
|
170
|
+
|
171
|
+
BLOWER_TYPE = Hash.new("Other").merge!(
|
172
|
+
0 => "PSC",
|
173
|
+
1 => "ECM 208/230",
|
174
|
+
2 => "ECM 265/277",
|
175
|
+
3 => "5 Speed ECM 460"
|
176
|
+
).freeze
|
177
|
+
|
178
|
+
ENERGY_MONITOR_TYPE = Hash.new("Other").merge!(
|
179
|
+
0 => "None",
|
180
|
+
1 => "Compressor Monitor",
|
181
|
+
2 => "Energy Monitor"
|
182
|
+
).freeze
|
183
|
+
|
184
|
+
VS_FAULTS = {
|
185
|
+
"Under-Voltage Warning" => (71..77),
|
186
|
+
"RPM Sensor Signal Fault" => (78..82),
|
187
|
+
"Under-Voltage Stop" => (83..87),
|
188
|
+
"Rotor Locked" => (88..92),
|
189
|
+
"Standby" => (93..)
|
119
190
|
}.freeze
|
120
191
|
|
192
|
+
def vs_fault(value)
|
193
|
+
name = VS_FAULTS.find { |(_, range)| range.include?(value) }&.first
|
194
|
+
name ? "#{value} #{name}" : value.to_s
|
195
|
+
end
|
196
|
+
|
121
197
|
AR_SETTINGS = {
|
122
198
|
0 => "Cycle with Compressor",
|
123
|
-
1 => "
|
124
|
-
2 => "
|
199
|
+
1 => "Slow Opening Water Valve",
|
200
|
+
2 => "Cycle with Thermostat Humidification Call",
|
125
201
|
3 => "Cycle with Blower"
|
126
202
|
}.freeze
|
127
203
|
|
@@ -132,13 +208,20 @@ module Aurora
|
|
132
208
|
fp1: value & 0x01 == 0x01 ? "30ºF" : "15ºF",
|
133
209
|
fp2: value & 0x02 == 0x02 ? "30ºF" : "15ºF",
|
134
210
|
rv: value & 0x04 == 0x04 ? "O" : "B",
|
135
|
-
ar: AR_SETTINGS[(value >> 3) &
|
211
|
+
ar: AR_SETTINGS[(value >> 3) & 0x3],
|
136
212
|
cc: value & 0x20 == 0x20 ? "Single Stage" : "Dual Stage",
|
137
213
|
lo: value & 0x40 == 0x40 ? "Continouous" : "Pulse",
|
138
|
-
dh_rh: value & 0x80 == 0x80 ? "
|
214
|
+
dh_rh: value & 0x80 == 0x80 ? "Dehumidifier On" : "Reheat On"
|
139
215
|
}
|
140
216
|
end
|
141
217
|
|
218
|
+
COMPONENT_STATUS = {
|
219
|
+
1 => :active,
|
220
|
+
2 => :added,
|
221
|
+
3 => :removed,
|
222
|
+
0xffff => :missing
|
223
|
+
}.freeze
|
224
|
+
|
142
225
|
SYSTEM_OUTPUTS = {
|
143
226
|
0x01 => :cc, # compressor stage 1
|
144
227
|
0x02 => :cc2, # compressor stage 2
|
@@ -151,15 +234,22 @@ module Aurora
|
|
151
234
|
0x800 => :alarm
|
152
235
|
}.freeze
|
153
236
|
|
237
|
+
# 5-speed ECM shows
|
238
|
+
# Aux if eh1 is on
|
239
|
+
# High if cc2 is on
|
240
|
+
# Med if cc1 is on
|
241
|
+
# Low if blower is on
|
242
|
+
# Off
|
243
|
+
|
154
244
|
SYSTEM_INPUTS = {
|
155
|
-
0x01 =>
|
156
|
-
0x02 =>
|
157
|
-
0x04 =>
|
158
|
-
0x08 =>
|
159
|
-
0x10 =>
|
160
|
-
0x20 =>
|
161
|
-
0x40 =>
|
162
|
-
0x200 =>
|
245
|
+
0x01 => :y1,
|
246
|
+
0x02 => :y2,
|
247
|
+
0x04 => :w,
|
248
|
+
0x08 => :o,
|
249
|
+
0x10 => :g,
|
250
|
+
0x20 => :dh_rh,
|
251
|
+
0x40 => :emergency_shutdown,
|
252
|
+
0x200 => :load_shed
|
163
253
|
}.freeze
|
164
254
|
|
165
255
|
def status(value)
|
@@ -167,9 +257,10 @@ module Aurora
|
|
167
257
|
lps: value & 0x80 == 0x80 ? :closed : :open,
|
168
258
|
hps: value & 0x100 == 0x100 ? :closed : :open
|
169
259
|
}
|
170
|
-
|
171
|
-
|
172
|
-
|
260
|
+
SYSTEM_INPUTS.each do |(i, name)|
|
261
|
+
result[name] = true if value & i == i
|
262
|
+
end
|
263
|
+
leftover = value & ~0x03ff
|
173
264
|
result[:unknown] = format("0x%04x", leftover) unless leftover.zero?
|
174
265
|
result
|
175
266
|
end
|
@@ -216,13 +307,36 @@ module Aurora
|
|
216
307
|
|
217
308
|
}.freeze
|
218
309
|
|
219
|
-
|
220
|
-
|
310
|
+
def axb_inputs(value)
|
311
|
+
result = {}
|
312
|
+
result["Smart Grid"] = value & 0x001 == 0x001
|
313
|
+
result["Home Automation 1"] = value & 0x002 == 0x002
|
314
|
+
result["Home Automation 2"] = value & 0x004 == 0x004
|
315
|
+
result["Pump Slave"] = value & 0x008 == 0x008
|
316
|
+
|
317
|
+
result[:mb_address] = value & 0x010 == 0x010 ? 3 : 4
|
318
|
+
result[:sw1_2] = value & 0x020 == 0x020 # future use # rubocop:disable Naming/VariableNumber
|
319
|
+
result[:sw1_3] = value & 0x040 == 0x040 # future use # rubocop:disable Naming/VariableNumber
|
320
|
+
result[:cycle_with] = if value & 0x080 == 0x080 && value & 0x100 == 0x100
|
321
|
+
"Blower"
|
322
|
+
elsif value & 0x100 == 0x100
|
323
|
+
"Low Capacity Compressor"
|
324
|
+
elsif value & 0x080 == 0x080
|
325
|
+
"High Capacity Compressor"
|
326
|
+
else
|
327
|
+
"Thermostat Dehumidifier"
|
328
|
+
end
|
329
|
+
leftover = value & ~0x1ff
|
330
|
+
result[:unknown] = format("0x%04x", leftover) unless leftover.zero?
|
331
|
+
result
|
332
|
+
end
|
221
333
|
|
222
334
|
AXB_OUTPUTS = {
|
223
|
-
|
224
|
-
0x02 =>
|
225
|
-
|
335
|
+
0x01 => :dhw,
|
336
|
+
0x02 => :loop_pump,
|
337
|
+
0x04 => :diverting_valve,
|
338
|
+
0x08 => :dehumidifer_reheat,
|
339
|
+
0x10 => :accessory2
|
226
340
|
}.freeze
|
227
341
|
|
228
342
|
HEATING_MODE = {
|
@@ -267,6 +381,33 @@ module Aurora
|
|
267
381
|
0x7 => :unknown7
|
268
382
|
}.freeze
|
269
383
|
|
384
|
+
def manual_operation(value)
|
385
|
+
return :off if value == 0x7fff
|
386
|
+
|
387
|
+
result = {
|
388
|
+
mode: value & 0x100 == 0x100 ? :cooling : :heating
|
389
|
+
}
|
390
|
+
result[:aux_heat] = true if value & 0x200 == 0x200
|
391
|
+
result[:compressor_speed] = value & 0xf
|
392
|
+
result[:blower_speed] = value & 0xf0
|
393
|
+
result[:blower_speed] = :with_compressor if value & 0xf0 == 0xf0
|
394
|
+
leftover = value & ~0x03ff
|
395
|
+
result[:unknown] = format("0x%04x", leftover) unless leftover.zero?
|
396
|
+
result
|
397
|
+
end
|
398
|
+
|
399
|
+
def vs_manual_control(value)
|
400
|
+
return :off if value == 0x7fff
|
401
|
+
|
402
|
+
value
|
403
|
+
end
|
404
|
+
|
405
|
+
def thermostat_override(value)
|
406
|
+
return [:off] if value == 0x7fff
|
407
|
+
|
408
|
+
from_bitmask(value, SYSTEM_INPUTS)
|
409
|
+
end
|
410
|
+
|
270
411
|
def iz2_demand(value)
|
271
412
|
{
|
272
413
|
fan_demand: value >> 8,
|
@@ -274,6 +415,18 @@ module Aurora
|
|
274
415
|
}
|
275
416
|
end
|
276
417
|
|
418
|
+
def iz2_fan_desired(value)
|
419
|
+
case value
|
420
|
+
when 1 then 25
|
421
|
+
when 2 then 40
|
422
|
+
when 3 then 55
|
423
|
+
when 4 then 70
|
424
|
+
when 5 then 85
|
425
|
+
when 6 then 100
|
426
|
+
else value
|
427
|
+
end
|
428
|
+
end
|
429
|
+
|
277
430
|
def zone_configuration1(value)
|
278
431
|
fan = if value & 0x80 == 0x80
|
279
432
|
:continuous
|
@@ -328,9 +481,11 @@ module Aurora
|
|
328
481
|
# intermittent off time allowed: 5, 10, 15, 20, 25, 30, 35, 40
|
329
482
|
|
330
483
|
REGISTER_CONVERTERS = {
|
331
|
-
TO_HUNDREDTHS => [2, 3, 807, 813, 816, 817, 819, 820, 825, 828],
|
484
|
+
TO_HUNDREDTHS => [2, 3, 417, 418, 801, 804, 807, 813, 816, 817, 819, 820, 825, 828],
|
332
485
|
method(:dipswitch_settings) => [4, 33],
|
333
|
-
TO_TENTHS => [19, 20, 401, 567, 740, 745, 746, 747, 900,
|
486
|
+
TO_TENTHS => [19, 20, 401, 419, 501, 502, 567, 740, 745, 746, 747, 900,
|
487
|
+
1105, 1106, 1107, 1108, 1109, 1110, 1111, 1112, 1113, 1114, 1115, 1116, 1117, 1119, 1124, 1125, 1134,
|
488
|
+
3322, 3323, 3325, 3326, 3327, 3330, 3522, 3903, 3905, 3906,
|
334
489
|
12_619, 12_620,
|
335
490
|
21_203, 21_204,
|
336
491
|
21_212, 21_213,
|
@@ -344,18 +499,35 @@ module Aurora
|
|
344
499
|
->(v) { from_bitmask(v, SYSTEM_OUTPUTS) } => [27, 30],
|
345
500
|
->(v) { from_bitmask(v, SYSTEM_INPUTS) } => [28],
|
346
501
|
method(:status) => [31],
|
502
|
+
method(:thermostat_override) => [32],
|
503
|
+
->(v) { !v.zero? } => [45, 362, 400],
|
347
504
|
->(registers, idx) { to_string(registers, idx, 4) } => [88],
|
348
505
|
->(registers, idx) { to_string(registers, idx, 12) } => [92],
|
349
506
|
->(registers, idx) { to_string(registers, idx, 5) } => [105],
|
350
|
-
->(v) { from_bitmask(v, VS_DRIVE_DERATE) } => [214],
|
351
|
-
->(v) { from_bitmask(v, VS_SAFE_MODE) } => [216],
|
352
|
-
->(v) { from_bitmask(v, VS_ALARM1) } => [217],
|
353
|
-
->(v) { from_bitmask(v, VS_ALARM2) } => [218],
|
354
|
-
->(v) { from_bitmask(v, VS_EEV2) } => [280],
|
507
|
+
->(v) { from_bitmask(v, VS_DRIVE_DERATE) } => [214, 3223],
|
508
|
+
->(v) { from_bitmask(v, VS_SAFE_MODE) } => [216, 3225],
|
509
|
+
->(v) { from_bitmask(v, VS_ALARM1) } => [217, 3226],
|
510
|
+
->(v) { from_bitmask(v, VS_ALARM2) } => [218, 3227],
|
511
|
+
->(v) { from_bitmask(v, VS_EEV2) } => [280, 3804],
|
512
|
+
method(:vs_manual_control) => [323],
|
355
513
|
NEGATABLE => [346, 1146],
|
356
|
-
->(v) {
|
514
|
+
->(v) { BRINE_TYPE[v] } => [402],
|
515
|
+
->(v) { FLOW_METER_TYPE[v] } => [403],
|
516
|
+
->(v) { BLOWER_TYPE[v] } => [404],
|
517
|
+
->(v) { v.zero? ? :closed : :open } => [405, 408, 410],
|
518
|
+
->(v) { SMARTGRID_ACTION[v] } => [406],
|
519
|
+
->(v) { HA_ALARM[v] } => [409, 411],
|
520
|
+
->(v) { ENERGY_MONITOR_TYPE[v] } => [412],
|
521
|
+
->(v) { PUMP_TYPE[v] } => [413],
|
522
|
+
->(v) { PHASE_TYPE[v] } => [416],
|
523
|
+
method(:iz2_fan_desired) => [565],
|
524
|
+
->(registers, idx) { to_string(registers, idx, 8) } => [710],
|
525
|
+
->(v) { COMPONENT_STATUS[v] } => [800, 803, 806, 812, 815, 818, 824, 827],
|
526
|
+
method(:axb_inputs) => [1103],
|
357
527
|
->(v) { from_bitmask(v, AXB_OUTPUTS) } => [1104],
|
358
|
-
->(v) { TO_TENTHS.call(NEGATABLE.call(v)) } => [1136],
|
528
|
+
->(v) { TO_TENTHS.call(NEGATABLE.call(v)) } => [1135, 1136],
|
529
|
+
method(:to_int32) => [1146, 1148, 1150, 1152, 1154, 1156, 1164, 3422, 3424],
|
530
|
+
method(:manual_operation) => [3002],
|
359
531
|
->(v) { HEATING_MODE[v] } => [12_606, 21_202, 21_211, 21_220, 21_229, 21_238, 21_247],
|
360
532
|
->(v) { FAN_MODE[v] } => [12_621, 21_205, 21_214, 21_223, 21_232, 21_241, 21_250],
|
361
533
|
->(v) { from_bitmask(v, HUMIDIFIER_SETTINGS) } => [31_109],
|
@@ -373,9 +545,11 @@ module Aurora
|
|
373
545
|
}.freeze
|
374
546
|
|
375
547
|
REGISTER_FORMATS = {
|
376
|
-
"%ds" => [1, 6, 9, 15, 84, 85],
|
377
|
-
"%dV" => [16, 112],
|
378
|
-
"%0.1fºF" => [19, 20, 401, 567, 740, 745, 746, 747, 900,
|
548
|
+
"%ds" => [1, 6, 9, 15, 84, 85, 110],
|
549
|
+
"%dV" => [16, 112, 3331, 3424, 3523],
|
550
|
+
"%0.1fºF" => [19, 20, 401, 501, 502, 567, 740, 745, 746, 747, 900,
|
551
|
+
1109, 1110, 1111, 1112, 1113, 1114, 1124, 1125, 1134, 1135, 1136,
|
552
|
+
3325, 3326, 3327, 3330, 3522, 3903, 3905, 3906,
|
379
553
|
12_619, 12_620,
|
380
554
|
21_203, 21_204,
|
381
555
|
21_212, 21_213,
|
@@ -386,14 +560,17 @@ module Aurora
|
|
386
560
|
31_003,
|
387
561
|
31_007, 31_010, 31_013, 31_016, 31_019, 31_022],
|
388
562
|
"E%d" => [25, 26],
|
389
|
-
"%d%%" => [282, 321, 322, 346, 565, 741],
|
563
|
+
"%d%%" => [282, 321, 322, 325, 346, 565, 741, 1126, 3332, 3524, 3808],
|
564
|
+
"%0.1f psi" => [419, 1115, 1116, 1119, 3322, 3323],
|
390
565
|
"%0.1fA" => [1105, 1106, 1107, 1108],
|
391
566
|
"%0.1fgpm" => [1117],
|
392
|
-
"%dW" => [
|
393
|
-
"%dBtuh" => [
|
567
|
+
"%dW" => [1146, 1148, 1150, 1152, 1164, 3422],
|
568
|
+
"%dBtuh" => [1154, 1156]
|
394
569
|
}.freeze
|
395
570
|
|
396
|
-
def ignore(range)
|
571
|
+
def ignore(*range)
|
572
|
+
range = range.first if range.length == 1
|
573
|
+
range = [range] if range.is_a?(Integer)
|
397
574
|
range.zip(Array.new(range.count)).to_h
|
398
575
|
end
|
399
576
|
|
@@ -513,25 +690,32 @@ module Aurora
|
|
513
690
|
].freeze
|
514
691
|
|
515
692
|
REGISTER_NAMES = {
|
693
|
+
0 => "Test Mode Flag", # 0x100 for enabled; this might have other flags
|
516
694
|
1 => "Random Start Delay",
|
517
695
|
2 => "ABC Program Version",
|
518
696
|
3 => "??? Version?",
|
519
697
|
4 => "DIP Switch Override",
|
520
698
|
6 => "Compressor Anti-Short Cycle Delay",
|
521
|
-
8 => "
|
699
|
+
8 => "ABC Program Revision",
|
522
700
|
9 => "Compressor Minimum Run Time",
|
523
701
|
15 => "Blower Off Delay",
|
524
702
|
16 => "Line Voltage",
|
525
|
-
|
703
|
+
17 => "Aux/E Heat Stage", # this has some complicated condition based on
|
704
|
+
# current inputs and outputs on if it should have a value (310 - v) or (130 - v), or be 0
|
705
|
+
19 => "FP1 (Cooling Liquid Line) Temperature",
|
526
706
|
20 => "FP2",
|
527
707
|
21 => "Condensate", # >= 270 normal, otherwise fault
|
528
|
-
25 => "Last Fault Number",
|
708
|
+
25 => "Last Fault Number", # high bit set if locked out
|
529
709
|
26 => "Last Lockout",
|
530
710
|
27 => "System Outputs (At Last Lockout)",
|
531
711
|
28 => "System Inputs (At Last Lockout)",
|
532
712
|
30 => "System Outputs",
|
533
713
|
31 => "Status",
|
714
|
+
32 => "Thermostat Input Override",
|
534
715
|
33 => "DIP Switch Status",
|
716
|
+
36 => "ABC Board Rev",
|
717
|
+
45 => "Test Mode (write)", # 1 to enable
|
718
|
+
47 => "Clear Fault History", # 0x5555 to clear
|
535
719
|
50 => "ECM Speed Low (== 5)",
|
536
720
|
51 => "ECM Speed Med (== 5)",
|
537
721
|
52 => "ECM Speed High (== 5)",
|
@@ -541,7 +725,8 @@ module Aurora
|
|
541
725
|
88 => "ABC Program",
|
542
726
|
92 => "Model Number",
|
543
727
|
105 => "Serial Number",
|
544
|
-
|
728
|
+
110 => "Reheat Delay",
|
729
|
+
112 => "Line Voltage Setting",
|
545
730
|
201 => "Discharge Pressure", # I can't figure out how this number is represented;
|
546
731
|
203 => "Suction Pressure",
|
547
732
|
205 => "Discharge Temperature",
|
@@ -562,6 +747,9 @@ module Aurora
|
|
562
747
|
284 => "Saturated Suction Temperature", ## ?? data format
|
563
748
|
321 => "VS Pump Min",
|
564
749
|
322 => "VS Pump Max",
|
750
|
+
323 => "VS Pump Speed Manual Control",
|
751
|
+
325 => "VS Pump Output",
|
752
|
+
326 => "VS Pump Fault",
|
565
753
|
340 => "Blower Only Speed",
|
566
754
|
341 => "Lo Compressor ECM Speed",
|
567
755
|
342 => "Hi Compressor ECM Speed",
|
@@ -569,25 +757,67 @@ module Aurora
|
|
569
757
|
346 => "Cooling Airflow Adjustment",
|
570
758
|
347 => "Aux Heat ECM Speed",
|
571
759
|
362 => "Active Dehumidify", # any value is true
|
760
|
+
400 => "DHW Enabled",
|
572
761
|
401 => "DHW Setpoint",
|
573
|
-
|
762
|
+
402 => "Brine Type",
|
763
|
+
403 => "Flow Meter Type",
|
764
|
+
404 => "Blower Type",
|
765
|
+
405 => "SmartGrid Trigger",
|
766
|
+
406 => "SmartGrid Action", # 0/1 for 1/2; see 414
|
767
|
+
407 => "Off Time Length",
|
768
|
+
408 => "HA Alarm 1 Trigger",
|
769
|
+
409 => "HA Alarm 1 Action",
|
770
|
+
410 => "HA Alarm 2 Trigger",
|
771
|
+
411 => "HA Alarm 2 Action",
|
772
|
+
412 => "Energy Monitor", # 0 none, 1 compressor monitor, 2 energy monitor
|
773
|
+
413 => "Pump Type",
|
774
|
+
414 => "On Peak/SmartGrid", # 0x0001 only
|
775
|
+
416 => "Energy Phase Type",
|
776
|
+
417 => "Power Adjustment Factor L",
|
777
|
+
418 => "Power Adjustment Factor H",
|
778
|
+
419 => "Loop Pressure Trip",
|
779
|
+
460 => "IZ2 Heartbeat?",
|
780
|
+
461 => "IZ2 Heartbeat?",
|
781
|
+
462 => "IZ2 Status", # 5 when online; 1 when in setup mode
|
574
782
|
483 => "Number of IZ2 Zones",
|
783
|
+
501 => "Set Point", # only read by AID tool? this is _not_ heating/cooling set point
|
784
|
+
502 => "Ambient Temperature",
|
575
785
|
564 => "IZ2 Compressor Speed Desired",
|
576
786
|
565 => "IZ2 Blower % Desired",
|
577
787
|
567 => "Entering Air",
|
788
|
+
710 => "Fault Description",
|
578
789
|
740 => "Entering Air",
|
579
790
|
741 => "Relative Humidity",
|
580
791
|
745 => "Heating Set Point",
|
581
792
|
746 => "Cooling Set Point",
|
582
|
-
747 => "Ambient Temperature",
|
793
|
+
747 => "Ambient Temperature", # from communicating thermostat? but set to 0 when mode is off?
|
794
|
+
800 => "Thermostat Installed",
|
795
|
+
801 => "Thermostat Version",
|
796
|
+
802 => "Thermostat Revision",
|
797
|
+
803 => "??? Installed",
|
798
|
+
804 => "??? Version",
|
799
|
+
805 => "??? Revision",
|
800
|
+
806 => "AXB Installed",
|
583
801
|
807 => "AXB Version",
|
802
|
+
808 => "AXB Revision",
|
803
|
+
809 => "AHB Installed",
|
804
|
+
810 => "AHB Version",
|
805
|
+
811 => "AHB Revision",
|
806
|
+
812 => "IZ2 Installed",
|
584
807
|
813 => "IZ2 Version",
|
585
|
-
|
586
|
-
|
587
|
-
|
588
|
-
|
808
|
+
814 => "IZ2 Revision",
|
809
|
+
815 => "AOC Installed",
|
810
|
+
816 => "AOC Version",
|
811
|
+
817 => "AOC Revision",
|
812
|
+
818 => "MOC Installed",
|
813
|
+
819 => "MOC Version",
|
814
|
+
820 => "MOC Revision",
|
815
|
+
824 => "EEV2 Installed",
|
589
816
|
825 => "EEV2 Version",
|
817
|
+
826 => "EEV2 Revision",
|
818
|
+
827 => "AWL Installed",
|
590
819
|
828 => "AWL Version",
|
820
|
+
829 => "AWL Revision",
|
591
821
|
900 => "Leaving Air",
|
592
822
|
1103 => "AXB Inputs",
|
593
823
|
1104 => "AXB Outputs",
|
@@ -595,27 +825,64 @@ module Aurora
|
|
595
825
|
1106 => "Aux Amps",
|
596
826
|
1107 => "Compressor 1 Amps",
|
597
827
|
1108 => "Compressor 2 Amps",
|
598
|
-
1109 => "Heating Liquid Line",
|
828
|
+
1109 => "Heating Liquid Line Temperature",
|
599
829
|
1110 => "Leaving Water",
|
600
830
|
1111 => "Entering Water",
|
601
|
-
|
831
|
+
1112 => "Leaving Air Temperature",
|
832
|
+
1113 => "Suction Temperature",
|
833
|
+
1114 => "DHW Temperature",
|
834
|
+
1115 => "Discharge Pressure",
|
835
|
+
1116 => "Suction Pressure",
|
602
836
|
1117 => "Waterflow",
|
603
|
-
|
604
|
-
|
605
|
-
|
606
|
-
|
607
|
-
|
608
|
-
|
609
|
-
|
610
|
-
|
837
|
+
1119 => "Loop Pressure", # only valid < 1000psi
|
838
|
+
1124 => "Saturated Evaporator Temperature",
|
839
|
+
1125 => "SuperHeat",
|
840
|
+
1126 => "Vaport Injector Open %",
|
841
|
+
1134 => "Saturated Condensor Discharge Temperature",
|
842
|
+
1135 => "SubCooling (Heating)",
|
843
|
+
1136 => "SubCooling (Cooling)",
|
844
|
+
1146 => "Compressor Watts",
|
845
|
+
1148 => "Blower Watts",
|
846
|
+
1150 => "Aux Watts",
|
847
|
+
1152 => "Total Watts",
|
848
|
+
1154 => "Heat of Extraction",
|
849
|
+
1156 => "Heat of Rejection",
|
850
|
+
1164 => "Pump Watts",
|
611
851
|
12_606 => "Heating Mode (write)",
|
612
852
|
12_619 => "Heating Setpoint (write)",
|
613
853
|
12_620 => "Cooling Setpoint (write)",
|
614
854
|
12_621 => "Fan Mode (write)",
|
615
|
-
3000 => "Compressor Speed
|
616
|
-
3001 => "Compressor Speed
|
855
|
+
3000 => "Compressor Speed Desired",
|
856
|
+
3001 => "Compressor Speed Actual",
|
857
|
+
3002 => "Manual Operation",
|
617
858
|
3027 => "Compressor Speed",
|
618
|
-
|
859
|
+
3220 => "VS Drive Details (General 1)",
|
860
|
+
3221 => "VS Drive Details (General 2)",
|
861
|
+
3222 => "VS Drive Details (Derate 1)",
|
862
|
+
3223 => "VS Drive Details (Derate 2)",
|
863
|
+
3224 => "VS Drive Details (Safemode 1)",
|
864
|
+
3225 => "VS Drive Details (Safemode 2)",
|
865
|
+
3226 => "VS Drive Details (Alarm 1)",
|
866
|
+
3227 => "VS Drive Details (Alarm 2)",
|
867
|
+
3327 => "VS Drive Temperature",
|
868
|
+
3322 => "VS Drive Discharge Pressure",
|
869
|
+
3323 => "VS Drive Suction Pressure",
|
870
|
+
3325 => "VS Drive Discharge Temperature",
|
871
|
+
3326 => "VS Drive Compressor Ambient Temperature",
|
872
|
+
3330 => "VS Drive Entering Water Temperature",
|
873
|
+
3331 => "VS Drive Line Voltage",
|
874
|
+
3332 => "VS Drive Thermo Power",
|
875
|
+
3422 => "VS Drive Compressor Power",
|
876
|
+
3424 => "VS Drive Supply Voltage",
|
877
|
+
3522 => "VS Drive Inverter Temperature",
|
878
|
+
3523 => "VS Drive UDC Voltage",
|
879
|
+
3524 => "VS Drive Fan Speed",
|
880
|
+
3804 => "VS Drive Details (EEV2 Ctl)",
|
881
|
+
3808 => "VS Drive SuperHeat Percent",
|
882
|
+
3903 => "VS Drive Suction Temperature",
|
883
|
+
3904 => "VS Drive Leaving Air Temperature?",
|
884
|
+
3905 => "VS Drive Saturated Evaporator Discharge Temperature",
|
885
|
+
3906 => "VS Drive SuperHeat Temperature",
|
619
886
|
31_003 => "Outdoor Temp",
|
620
887
|
31_005 => "IZ2 Demand",
|
621
888
|
31_109 => "Humidifier Mode", # write to 21114
|
@@ -630,7 +897,10 @@ module Aurora
|
|
630
897
|
.merge(ignore(93..104))
|
631
898
|
.merge(ignore(106..109))
|
632
899
|
.merge(faults(601..699))
|
900
|
+
.merge(ignore(711..717))
|
633
901
|
.merge(zone_registers)
|
902
|
+
.merge(ignore(1147, 1149, 1151, 1153, 1155, 1157, 1165))
|
903
|
+
.merge(ignore(3423, 3425))
|
634
904
|
.merge(ignore(31_401..31_412))
|
635
905
|
.merge(ignore(31_414..31_420))
|
636
906
|
.merge(ignore(31_422..31_433))
|