generated from homebridge/homebridge-plugin-template
-
-
Notifications
You must be signed in to change notification settings - Fork 2
/
cts700Data.ts
173 lines (163 loc) · 4.53 KB
/
cts700Data.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
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
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
export enum Register {
// Pause is ID of register holding the pause flag
// 0 (Disabled)
// 1 (Pause ventilation)
// 2 (Pause DHW)
// 3 (Pause all)
Pause = 4727,
// FanSpeed is ID of register holding desired FanSpeed value
FanSpeed = 4747,
// DesiredRoomTemperature is ID of register holding desired room temperature in C times 10.
// Example: 23.5 C is stored as 235.
RoomTemperatureSetPoint = 4746,
// MasterSensorTemperature is ID of register holding the temperature that
// is used for regulation.
MasterSensorTemperature = 5088,
// Temperature at the CTS700 panel
PanelTemperature = 4713,
// OutdoorTemperature is ID of register outdoor temperature
OutdoorTemperature = 5152,
// ActualHumidity is ID of register holding actual humidity value
ActualHumidity = 4716,
// DHWTopTankTemperature is ID of register holding T11 top DHW tank temperature
DHWTopTankTemperature = 5162,
// DHWBottomTankTemperature is ID of register holding T12 bottom DHW tank temperature
DHWBottomTankTemperature = 5163,
// DHWSetPoint is ID of register holding desired DHW temperature
DHWTemperatureSetPoint = 5548,
// Forced operation mode.
// 0 (Auto)
// 1 (Cooling)
// 2 (Heating)
VentilationMode = 2402,
// Current regulation mode
// 0 Mode isn't defined.
// 1 Cooling mode.
// 2 Heating mode.
// 3 Ventilation mode.
// 4 Hot water mode.
OperationMode = 5432,
// Current Date-Time value.
CurrentTime = 4722,
// First 14 program records of Week Program.
FistWeekProgram = 573,
// Second 14 program records of Week Program.
SecondWeekProgram = 643,
// The MAC address for main board device.
// Reg1 Hi-byte: MAC 1-st byte
// Reg1 Lo-byte: MAC 2-nd byte
// Reg2 Hi-byte: MAC 3-rd byte
// Reg2 Lo-byte: MAC 4-th byte
// Reg3 Hi-byte: MAC 5-th byte
// Reg3 Lo-byte: MAC 6-th byte
// The rest: Reserved
MacAddress = 1330,
// Software version.
// Registers quantity : 2
// Reg1 Hi-byte: Major version number
// Reg1 Lo-byte:Hi Middle version number
// Reg2 Hi-byte: Lo Middle version number
// Reg2 Lo-byte:Minor version number
SoftwareVersion = 5065
}
export enum PauseOption {
// Disabled represents no pause option being set
Disabled = 0,
// Ventilation represents just ventilation being paused
Ventilation,
// DHW represents just hot water production being paused
DHW,
// All represents all operations being paused
All,
}
export enum VentilationMode {
// Auto represents automatic heading or cooling operation
Auto = 0,
// Cooling represents forced cooling mode
Cooling,
// Heating represents forced heating mode
Heating
}
export enum OperationMode {
// Mode isn't defined.
Undefined = 0,
// Cooling mode.
Cooling,
// Heating mode.
Heating,
// Ventilation mode.
Ventilation,
// Hot water mode.
DHW
}
// Device metadata for the Nilan system
export interface Metadata {
// The Serial number of control board.
macAddress: string;
// Software version.
softwareVersion: string;
}
// Settings of Nilan system
export interface Settings {
// Paused tells if operation is currently paused
paused: PauseOption;
// Fan speed of ventilation (20-100)
fanSpeed: number;
// Desired room temperature in C (5-40) times 10
roomTemperatureSetPoint: number;
// Desired DHW temperature in C (10-60) times 10
dhwTemperatureSetPoint: number;
// Ventilation mode indicates automatic or forced aur conditioning operation
ventilationMode: VentilationMode;
// The current operation mode of the unit.
operationMode: OperationMode;
}
// Readings from Nilan sensors
export interface Readings {
// Room temperature in C times 10
roomTemperature: number;
// Outdoor temperature in C times 10
outdoorTemperature: number;
// Panel temperature in C times 10
panelTemperature: number;
// Actual humidity of air (0-100%)
actualHumidity: number;
// DHW tank top temperature in C times 10
dhwTankTopTemperature: number;
// Current device time.
currentDateTime: DateTime;
}
// Nilan date / time entry
export interface DateTime {
// Seconds (0 ÷ 59)
second: number;
// Minutes (0 ÷ 59)
minute: number;
// Hours (0 ÷ 23)
hour: number;
// Day (1 ÷ 31)
day: number;
// Day of week (1 ÷ 7)
weekDay: number;
// Month (1 ÷ 12)
month: number;
// Year (0 ÷ 38)
year: number;
}
// Nilan date / time entry
export interface WeekScheduleRecord {
// Day of week (1 ÷ 7)
weekDay: number;
// Hours (0 ÷ 23)
hour: number;
// Minutes (0 ÷ 59)
minute: number;
// 50 ÷ 500 (5ºC ÷ 50ºC)
temperature: number;
// 100 ÷ 600 (10ºC ÷ 60ºC)
dhwTemperature: number;
// Flag bitmask
flags: number;
// 0 ÷ 100 (%)
fanSpeed: number;
}