@xyo-network/pentair-plugin 2.42.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (52) hide show
  1. package/LICENSE +165 -0
  2. package/README.md +81 -0
  3. package/dist/cjs/Plugin.d.ts +15 -0
  4. package/dist/cjs/Plugin.d.ts.map +1 -0
  5. package/dist/cjs/Plugin.js +16 -0
  6. package/dist/cjs/Plugin.js.map +1 -0
  7. package/dist/cjs/Witness.d.ts +24 -0
  8. package/dist/cjs/Witness.d.ts.map +1 -0
  9. package/dist/cjs/Witness.js +36 -0
  10. package/dist/cjs/Witness.js.map +1 -0
  11. package/dist/cjs/index.d.ts +5 -0
  12. package/dist/cjs/index.d.ts.map +1 -0
  13. package/dist/cjs/index.js +10 -0
  14. package/dist/cjs/index.js.map +1 -0
  15. package/dist/cjs/screenlogic/controller.d.ts +100 -0
  16. package/dist/cjs/screenlogic/controller.d.ts.map +1 -0
  17. package/dist/cjs/screenlogic/controller.js +326 -0
  18. package/dist/cjs/screenlogic/controller.js.map +1 -0
  19. package/dist/cjs/screenlogic/index.d.ts +2 -0
  20. package/dist/cjs/screenlogic/index.d.ts.map +1 -0
  21. package/dist/cjs/screenlogic/index.js +5 -0
  22. package/dist/cjs/screenlogic/index.js.map +1 -0
  23. package/dist/docs.json +4932 -0
  24. package/dist/esm/Plugin.d.ts +15 -0
  25. package/dist/esm/Plugin.d.ts.map +1 -0
  26. package/dist/esm/Plugin.js +11 -0
  27. package/dist/esm/Plugin.js.map +1 -0
  28. package/dist/esm/Witness.d.ts +24 -0
  29. package/dist/esm/Witness.d.ts.map +1 -0
  30. package/dist/esm/Witness.js +18 -0
  31. package/dist/esm/Witness.js.map +1 -0
  32. package/dist/esm/index.d.ts +5 -0
  33. package/dist/esm/index.d.ts.map +1 -0
  34. package/dist/esm/index.js +6 -0
  35. package/dist/esm/index.js.map +1 -0
  36. package/dist/esm/screenlogic/controller.d.ts +100 -0
  37. package/dist/esm/screenlogic/controller.d.ts.map +1 -0
  38. package/dist/esm/screenlogic/controller.js +332 -0
  39. package/dist/esm/screenlogic/controller.js.map +1 -0
  40. package/dist/esm/screenlogic/index.d.ts +2 -0
  41. package/dist/esm/screenlogic/index.d.ts.map +1 -0
  42. package/dist/esm/screenlogic/index.js +2 -0
  43. package/dist/esm/screenlogic/index.js.map +1 -0
  44. package/package.json +55 -0
  45. package/src/Plugin.spec.ts +21 -0
  46. package/src/Plugin.ts +17 -0
  47. package/src/Witness.spec.ts +13 -0
  48. package/src/Witness.ts +41 -0
  49. package/src/index.ts +8 -0
  50. package/src/screenlogic/controller.ts +377 -0
  51. package/src/screenlogic/index.ts +1 -0
  52. package/src/screenlogic/types/index.d.ts +135 -0
@@ -0,0 +1,21 @@
1
+ import { PayloadSetPluginResolver } from '@xyo-network/payloadset-plugin'
2
+ import { XyoPentairScreenlogicSchema } from '@xyo-network/pentair-payload-plugin'
3
+
4
+ import { XyoPentairScreenlogicPlugin } from './Plugin'
5
+ import { XyoPentairScreenlogicWitnessConfigSchema } from './Witness'
6
+
7
+ describe('XyoPentairScreenlogicPlugin', () => {
8
+ test('Add to Resolver', () => {
9
+ const plugin = XyoPentairScreenlogicPlugin()
10
+ const resolver = new PayloadSetPluginResolver().register(plugin, {
11
+ witness: {
12
+ config: {
13
+ schema: XyoPentairScreenlogicWitnessConfigSchema,
14
+ targetSchema: XyoPentairScreenlogicSchema,
15
+ },
16
+ },
17
+ })
18
+ expect(resolver.resolve(plugin.set)).toBeObject()
19
+ expect(resolver.witness(XyoPentairScreenlogicSchema)).toBeObject()
20
+ })
21
+ })
package/src/Plugin.ts ADDED
@@ -0,0 +1,17 @@
1
+ import { XyoModuleParams } from '@xyo-network/module'
2
+ import { PayloadSetSchema } from '@xyo-network/payload'
3
+ import { createPayloadSetPlugin, PayloadSetWitnessPlugin } from '@xyo-network/payloadset-plugin'
4
+ import { XyoPentairScreenlogicSchema } from '@xyo-network/pentair-payload-plugin'
5
+
6
+ import { XyoPentairScreenlogicWitness, XyoPentairScreenlogicWitnessConfig } from './Witness'
7
+
8
+ export const XyoPentairScreenlogicPlugin = () =>
9
+ createPayloadSetPlugin<PayloadSetWitnessPlugin<XyoModuleParams<XyoPentairScreenlogicWitnessConfig>>>(
10
+ { required: { [XyoPentairScreenlogicSchema]: 1 }, schema: PayloadSetSchema },
11
+ {
12
+ witness: async (params) => {
13
+ const result = await XyoPentairScreenlogicWitness.create(params)
14
+ return result
15
+ },
16
+ },
17
+ )
@@ -0,0 +1,13 @@
1
+ import { PayloadWrapper } from '@xyo-network/payload'
2
+
3
+ import { XyoPentairScreenlogicWitness } from './Witness'
4
+
5
+ const testIf = (condition: string | undefined) => (condition ? it : it.skip)
6
+
7
+ describe('XyoPentairScreenLogicWitness', () => {
8
+ testIf(process.env.TEST_PENTAIR)('Witnessing [no config]', async () => {
9
+ const witness = await XyoPentairScreenlogicWitness.create()
10
+ const [observation] = await witness.observe()
11
+ expect(new PayloadWrapper(observation).valid).toBe(true)
12
+ })
13
+ })
package/src/Witness.ts ADDED
@@ -0,0 +1,41 @@
1
+ import { XyoModuleParams } from '@xyo-network/module'
2
+ import { XyoPayload } from '@xyo-network/payload'
3
+ import { XyoPentairScreenlogicPayload, XyoPentairScreenlogicSchema } from '@xyo-network/pentair-payload-plugin'
4
+ import { AbstractWitness, XyoWitnessConfig } from '@xyo-network/witness'
5
+
6
+ import { Controller } from './screenlogic'
7
+
8
+ export type XyoPentairScreenlogicWitnessConfigSchema = 'network.xyo.pentair.screenlogic.witness.config'
9
+ export const XyoPentairScreenlogicWitnessConfigSchema: XyoPentairScreenlogicWitnessConfigSchema = 'network.xyo.pentair.screenlogic.witness.config'
10
+
11
+ export interface PentairServer {
12
+ address: string
13
+
14
+ gatewayName: string
15
+ gatewaySubtype: number
16
+ gatewayType: number
17
+
18
+ port: number
19
+ type: number
20
+ }
21
+
22
+ export type XyoPentairScreenlogicWitnessConfig = XyoWitnessConfig<{
23
+ schema: XyoPentairScreenlogicWitnessConfigSchema
24
+ }>
25
+
26
+ export class XyoPentairScreenlogicWitness extends AbstractWitness<XyoPentairScreenlogicWitnessConfig> {
27
+ static override configSchema = XyoPentairScreenlogicWitnessConfigSchema
28
+
29
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
30
+ protected controller = new Controller()
31
+
32
+ static override async create(params?: XyoModuleParams<XyoPentairScreenlogicWitnessConfig>): Promise<XyoPentairScreenlogicWitness> {
33
+ return (await super.create(params)) as XyoPentairScreenlogicWitness
34
+ }
35
+
36
+ override async observe(_payloads?: Partial<XyoPayload>[]): Promise<XyoPayload[]> {
37
+ const config = await this.controller.getPoolConfig()
38
+ const status = await this.controller.getPoolStatus()
39
+ return await super.observe([{ config, schema: XyoPentairScreenlogicSchema, status }] as XyoPentairScreenlogicPayload[])
40
+ }
41
+ }
package/src/index.ts ADDED
@@ -0,0 +1,8 @@
1
+ import { XyoPentairScreenlogicPlugin } from './Plugin'
2
+
3
+ export * from './Witness'
4
+
5
+ export { XyoPentairScreenlogicPlugin }
6
+
7
+ // eslint-disable-next-line import/no-default-export
8
+ export default XyoPentairScreenlogicPlugin
@@ -0,0 +1,377 @@
1
+ /* eslint-disable @typescript-eslint/no-explicit-any */
2
+ import ScreenLogic from 'node-screenlogic'
3
+
4
+ /* From https://github.com/schemers/homebridge-screenlogic */
5
+
6
+ interface ControllerOptions {
7
+ ip_address?: string
8
+ log?: typeof console
9
+ password?: string
10
+ port?: number
11
+ username?: string
12
+ }
13
+
14
+ export class Controller {
15
+ static readonly HEAT_MODE_HEAT_PUMP = 3
16
+ static readonly HEAT_MODE_OFF = 0
17
+ static readonly HEAT_MODE_SOLAR = 1
18
+ static readonly HEAT_MODE_SOLAR_PREFERRED = 2
19
+ static readonly HEAT_MODE_UNCHANGED = 4
20
+
21
+ static readonly POOL_CIRCUIT_ID = 505
22
+ static readonly SPA_CIRCUIT_ID = 500
23
+
24
+ private readonly ip_address?: string
25
+ private readonly log: typeof console
26
+
27
+ private readonly password?: string
28
+ private readonly port?: number
29
+ private readonly username?: string
30
+
31
+ constructor(settings?: ControllerOptions) {
32
+ this.log = settings?.log ?? console
33
+ this.ip_address = settings?.ip_address
34
+ this.port = settings?.port
35
+ this.username = settings?.username
36
+ this.password = settings?.password
37
+ }
38
+
39
+ _getConnection(): Promise<ScreenLogic.UnitConnection> {
40
+ if (this.ip_address) {
41
+ return this._getConnectionByIPAddress()
42
+ } else if (this.username && this.password) {
43
+ return this._getConnectionByRemoteLogin()
44
+ } else {
45
+ return this._getConnectionByBroadcast()
46
+ }
47
+ }
48
+
49
+ /** get a connection by udp broadcast */
50
+ _getConnectionByBroadcast(): Promise<ScreenLogic.UnitConnection> {
51
+ return new Promise((resolve, reject) => {
52
+ const finder = new ScreenLogic.FindUnits()
53
+ finder
54
+ .on('serverFound', (server: { gatewayName: any }) => {
55
+ finder.close()
56
+ const connection = new ScreenLogic.UnitConnection(server)
57
+ connection.gatewayName = server.gatewayName
58
+ resolve(connection)
59
+ })
60
+ .on('error', (err: any) => {
61
+ reject(err)
62
+ })
63
+ finder.search()
64
+ })
65
+ }
66
+
67
+ /** get a connection by IP address */
68
+ _getConnectionByIPAddress(): Promise<ScreenLogic.UnitConnection> {
69
+ return new Promise((resolve, _reject) => {
70
+ const connection = new ScreenLogic.UnitConnection(this.port || 80, this.ip_address, this.password)
71
+ connection.gatewayName = this.username ?? 'Pentair: XX-XX-XX'
72
+ resolve(connection)
73
+ })
74
+ }
75
+
76
+ /** find a unit by remote login */
77
+ _getConnectionByRemoteLogin(): Promise<ScreenLogic.UnitConnection> {
78
+ return new Promise((resolve, reject) => {
79
+ const remote = new ScreenLogic.RemoteLogin(this.username)
80
+ remote
81
+ .on('gatewayFound', (unit: { gatewayFound: any; ipAddr: any; port: any }) => {
82
+ remote.close()
83
+ if (unit && unit.gatewayFound) {
84
+ const connection = new ScreenLogic.UnitConnection(unit.port, unit.ipAddr, this.password)
85
+ connection.gatewayName = this.username
86
+ resolve(connection)
87
+ } else {
88
+ reject(new ControllerError('no remote unit found'))
89
+ }
90
+ })
91
+ .on('error', (err: Error) => {
92
+ reject(err)
93
+ })
94
+ remote.connect()
95
+ })
96
+ }
97
+
98
+ _getPoolConfig(connection: ScreenLogic.UnitConnection): Promise<PoolConfig> {
99
+ let softwareVersion = ''
100
+ return new Promise((resolve, reject) => {
101
+ connection
102
+ .once('version', (version: any) => {
103
+ softwareVersion = version.version
104
+ connection.getControllerConfig()
105
+ })
106
+ .once('controllerConfig', (poolConfig: any) => {
107
+ //this.log.debug('controllerConfig', poolConfig)
108
+ resolve(new PoolConfig(connection.gatewayName, softwareVersion, poolConfig))
109
+ })
110
+ .on('error', (err: any) => {
111
+ reject(err)
112
+ })
113
+ connection.getVersion()
114
+ })
115
+ }
116
+
117
+ _getPoolStatus(connection: ScreenLogic.UnitConnection): Promise<PoolStatus> {
118
+ return new Promise((resolve, reject) => {
119
+ connection
120
+ .once('poolStatus', (status) => {
121
+ //this.log.debug('poolStatus', status)
122
+ resolve(new PoolStatus(status))
123
+ })
124
+ .on('error', (err: any) => {
125
+ reject(err)
126
+ })
127
+ connection.getPoolStatus()
128
+ })
129
+ }
130
+
131
+ _login(connection: ScreenLogic.UnitConnection): Promise<void> {
132
+ return new Promise((resolve, reject) => {
133
+ connection
134
+ .once('loggedIn', () => {
135
+ resolve()
136
+ })
137
+ .once('loginFailed', () => {
138
+ reject(new ControllerError('unable to login'))
139
+ })
140
+ .on('error', (err: any) => {
141
+ reject(err)
142
+ })
143
+ connection.connect()
144
+ })
145
+ }
146
+
147
+ _sendLightCommand(connection: ScreenLogic.UnitConnection, cmd: number): Promise<void> {
148
+ return new Promise((resolve, reject) => {
149
+ connection
150
+ .once('sentLightCommand', () => {
151
+ resolve()
152
+ })
153
+ .once('badParameter', () => {
154
+ reject(new ControllerError('bad parameter passed to send light command'))
155
+ })
156
+ .on('error', (err: any) => {
157
+ reject(err)
158
+ })
159
+ connection.sendLightCommand(0, cmd)
160
+ })
161
+ }
162
+
163
+ _setCircuitState(connection: ScreenLogic.UnitConnection, circuitId: number, circuitState: boolean): Promise<void> {
164
+ return new Promise((resolve, reject) => {
165
+ connection
166
+ .once('circuitStateChanged', () => {
167
+ resolve()
168
+ })
169
+ .once('badParameter', () => {
170
+ reject(new ControllerError('bad parameter passed to set command'))
171
+ })
172
+ .on('error', (err: any) => {
173
+ reject(err)
174
+ })
175
+ connection.setCircuitState(0, circuitId, circuitState ? 1 : 0)
176
+ })
177
+ }
178
+
179
+ _setHeatMode(connection: ScreenLogic.UnitConnection, bodyType: number, heatMode: number): Promise<void> {
180
+ return new Promise((resolve, reject) => {
181
+ connection
182
+ .once('heatModeChanged', () => {
183
+ resolve()
184
+ })
185
+ .once('badParameter', () => {
186
+ reject(new ControllerError('bad parameter passed to set command'))
187
+ })
188
+ .on('error', (err: any) => {
189
+ reject(err)
190
+ })
191
+ connection.setHeatMode(0, bodyType, heatMode)
192
+ })
193
+ }
194
+
195
+ _setHeatPoint(connection: ScreenLogic.UnitConnection, bodyType: number, heatPoint: number): Promise<void> {
196
+ return new Promise((resolve, reject) => {
197
+ connection
198
+ .once('setPointChanged', () => {
199
+ resolve()
200
+ })
201
+ .once('badParameter', () => {
202
+ reject(new ControllerError('bad parameter passed to set command'))
203
+ })
204
+ .on('error', (err: any) => {
205
+ reject(err)
206
+ })
207
+ connection.setSetPoint(0, bodyType, heatPoint)
208
+ })
209
+ }
210
+
211
+ async getPoolConfig(): Promise<PoolConfig> {
212
+ const connection = await this._getConnection()
213
+ try {
214
+ await this._login(connection)
215
+ return await this._getPoolConfig(connection)
216
+ } finally {
217
+ connection.close()
218
+ }
219
+ }
220
+
221
+ async getPoolStatus(): Promise<PoolStatus> {
222
+ const connection = await this._getConnection()
223
+ try {
224
+ await this._login(connection)
225
+ return await this._getPoolStatus(connection)
226
+ } finally {
227
+ connection.close()
228
+ }
229
+ }
230
+
231
+ async sendLightCommand(cmd: number): Promise<void> {
232
+ const connection = await this._getConnection()
233
+ try {
234
+ await this._login(connection)
235
+ return await this._sendLightCommand(connection, cmd)
236
+ } finally {
237
+ connection.close()
238
+ }
239
+ }
240
+
241
+ async setCircuitState(circuitId: number, circuitState: boolean): Promise<void> {
242
+ const connection = await this._getConnection()
243
+ try {
244
+ await this._login(connection)
245
+ return await this._setCircuitState(connection, circuitId, circuitState)
246
+ } finally {
247
+ connection.close()
248
+ }
249
+ }
250
+
251
+ async setHeatMode(bodyType: number, heatMode: number): Promise<void> {
252
+ const connection = await this._getConnection()
253
+ try {
254
+ await this._login(connection)
255
+ return await this._setHeatMode(connection, bodyType, heatMode)
256
+ } finally {
257
+ connection.close()
258
+ }
259
+ }
260
+
261
+ async setHeatPoint(bodyType: number, heatPoint: number): Promise<void> {
262
+ const connection = await this._getConnection()
263
+ try {
264
+ await this._login(connection)
265
+ return await this._setHeatPoint(connection, bodyType, heatPoint)
266
+ } finally {
267
+ connection.close()
268
+ }
269
+ }
270
+ }
271
+
272
+ export class ControllerError extends Error {}
273
+
274
+ export interface PoolCircuitJson {
275
+ id: number
276
+ name: string
277
+ }
278
+
279
+ export class PoolCircuit implements PoolCircuitJson {
280
+ constructor(public readonly id: number, public readonly name: string) {}
281
+ }
282
+
283
+ export interface PoolConfigJson {
284
+ circuits: PoolCircuitJson[]
285
+ deviceId: string
286
+ gatewayName: string
287
+ hasPool: boolean
288
+ hasSpa: boolean
289
+ isCelsius: boolean
290
+ poolMaxSetPoint: number
291
+ poolMinSetPoint: number
292
+ softwareVersion: string
293
+ spaMaxSetPoint: number
294
+ spaMinSetPoint: number
295
+ }
296
+
297
+ export class PoolConfig implements PoolConfigJson {
298
+ public circuits: PoolCircuit[] = []
299
+ public readonly deviceId: string
300
+ public readonly gatewayName: string
301
+ public readonly hasPool: boolean
302
+ public readonly hasSpa: boolean
303
+ public readonly isCelsius: boolean
304
+ public readonly poolMaxSetPoint: number
305
+ public readonly poolMinSetPoint: number
306
+ public readonly softwareVersion: string
307
+ public readonly spaMaxSetPoint: number
308
+ public readonly spaMinSetPoint: number
309
+
310
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
311
+ constructor(gatewayName: string, softwareVersion: string, config: any) {
312
+ this.gatewayName = gatewayName
313
+ this.deviceId = gatewayName.replace('Pentair: ', '')
314
+
315
+ this.softwareVersion = softwareVersion
316
+ this.isCelsius = config.degC
317
+ this.poolMinSetPoint = config.minSetPoint[0] ?? 0
318
+ this.poolMaxSetPoint = config.maxSetPoint[0] ?? 0
319
+ this.spaMinSetPoint = config.minSetPoint[1] ?? 0
320
+ this.spaMaxSetPoint = config.maxSetPoint[1] ?? 0
321
+ this.hasSpa = false
322
+ this.hasPool = false
323
+ this.circuits = []
324
+ for (const circuit of config.bodyArray) {
325
+ const poolCircuit = new PoolCircuit(circuit.circuitId, circuit.name)
326
+ this.circuits.push(poolCircuit)
327
+ if (poolCircuit.id === Controller.POOL_CIRCUIT_ID) {
328
+ this.hasPool = true
329
+ } else if (poolCircuit.id === Controller.SPA_CIRCUIT_ID) {
330
+ this.hasSpa = true
331
+ }
332
+ }
333
+ }
334
+ }
335
+
336
+ export class PoolStatus {
337
+ public readonly airTemperature: number
338
+ public readonly circuitState = new Map<number, number>()
339
+ public readonly hasPool: boolean
340
+ public readonly hasSpa: boolean
341
+ public readonly isPoolActive: boolean
342
+ public readonly isPoolHeating: boolean
343
+ public readonly isSpaActive: boolean
344
+ public readonly isSpaHeating: boolean
345
+ public readonly poolHeatMode: number
346
+ public readonly poolSetPoint: number
347
+ public readonly poolTemperature: number
348
+ public readonly spaHeatMode: number
349
+ public readonly spaSetPoint: number
350
+ public readonly spaTemperature: number
351
+
352
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
353
+ constructor(status: any) {
354
+ // save circuit state
355
+ this.circuitState = new Map()
356
+ for (const circuit of status.circuitArray) {
357
+ this.circuitState.set(circuit.id, circuit.state)
358
+ }
359
+
360
+ this.hasPool = this.circuitState.get(Controller.POOL_CIRCUIT_ID) !== undefined
361
+ this.hasSpa = this.circuitState.get(Controller.SPA_CIRCUIT_ID) !== undefined
362
+
363
+ this.poolTemperature = status.currentTemp[0]
364
+ this.poolSetPoint = status.setPoint[0]
365
+ this.isPoolActive = this.hasPool && status.isPoolActive()
366
+ this.isPoolHeating = this.hasPool && status.heatStatus[0] !== 0
367
+ this.poolHeatMode = status.heatMode[0]
368
+
369
+ this.spaTemperature = status.currentTemp[1]
370
+ this.spaSetPoint = status.setPoint[1]
371
+ this.isSpaActive = this.hasSpa && status.isSpaActive()
372
+ this.isSpaHeating = this.hasSpa && status.heatStatus[1] !== 0
373
+ this.spaHeatMode = status.heatMode[1]
374
+
375
+ this.airTemperature = status.airTemp
376
+ }
377
+ }
@@ -0,0 +1 @@
1
+ export * from './controller'
@@ -0,0 +1,135 @@
1
+ declare module 'node-screenlogic' {
2
+ declare class EventEmitter {
3
+ eventNames(): string[]
4
+
5
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
6
+ on<T>(event: string, func: (data: T) => void)
7
+
8
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
9
+ once<T>(event: string, func: (data: T) => void)
10
+ }
11
+
12
+ declare class FindUnits extends EventEmitter {
13
+ constructor()
14
+
15
+ close()
16
+
17
+ foundServer(msg, remote)
18
+
19
+ search()
20
+
21
+ sendServerBroadcast()
22
+ }
23
+
24
+ declare class RemoteLogin extends EventEmitter {
25
+ constructor(systemName)
26
+ close()
27
+
28
+ connect()
29
+
30
+ onClientMessage(msg)
31
+
32
+ onConnected()
33
+ }
34
+
35
+ declare class UnitConnection extends EventEmitter {
36
+ //this is an arbitrary field added in code
37
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
38
+ gatewayName: any
39
+
40
+ constructor(server, address?, password?)
41
+
42
+ addClient(clientId, senderId?)
43
+
44
+ addNewScheduleEvent(scheduleType, senderId?)
45
+
46
+ cancelDelay(senderId?)
47
+
48
+ close()
49
+
50
+ connect()
51
+
52
+ deleteScheduleEventById(scheduleId, senderId?)
53
+
54
+ getChemHistoryData(fromTime, toTime, senderId?)
55
+
56
+ getChemicalData(senderId?)
57
+
58
+ getControllerConfig(senderId?)
59
+
60
+ getEquipmentConfiguration(senderId?)
61
+
62
+ getHistoryData(fromTime, toTime, senderId?)
63
+
64
+ getPoolStatus()
65
+
66
+ getPumpStatus(pumpId, senderId?)
67
+
68
+ getSaltCellConfig(senderId?)
69
+
70
+ getScheduleData(scheduleType, senderId?)
71
+
72
+ getSystemTime(senderId?)
73
+
74
+ getVersion(senderId?)
75
+
76
+ getWeatherForecast(senderId?)
77
+
78
+ login()
79
+
80
+ onClientMessage(msg)
81
+
82
+ onConnected()
83
+
84
+ pingServer(senderId?)
85
+
86
+ processData(msg)
87
+
88
+ removeClient(clientId, senderId?)
89
+
90
+ sendLightCommand(controllerId, command, senderId?)
91
+
92
+ setCircuitRuntimebyId(circuitId, runTime, senderId?)
93
+
94
+ setCircuitState(controllerId, circuitId, circuitState, senderId?)
95
+
96
+ setHeatMode(controllerId, bodyType, heatMode, senderId?)
97
+
98
+ setPumpFlow(pumpId, circuitId, setPoint, isRPMs, senderId?)
99
+
100
+ setSaltCellOutput(controllerId, poolOutput, spaOutput, senderId?)
101
+
102
+ setScheduleEventById(scheduleId, circuitId, startTime, stopTime, dayMask, flags, heatCmd, heatSetPoint, senderId?)
103
+
104
+ setSetPoint(controllerId, bodyType, temperature, senderId?)
105
+
106
+ setSystemTime(date, shouldAdjustForDST, senderId?)
107
+ }
108
+
109
+ declare const HEAT_MODE_DONTCHANGE
110
+ declare const HEAT_MODE_HEATPUMP
111
+ declare const HEAT_MODE_OFF
112
+ declare const HEAT_MODE_SOLAR
113
+ declare const HEAT_MODE_SOLARPREFERRED
114
+ declare const LIGHT_CMD_COLOR_BLUE
115
+ declare const LIGHT_CMD_COLOR_GREEN
116
+ declare const LIGHT_CMD_COLOR_MODE_AMERICAN
117
+ declare const LIGHT_CMD_COLOR_MODE_CARIBBEAN
118
+ declare const LIGHT_CMD_COLOR_MODE_PARTY
119
+ declare const LIGHT_CMD_COLOR_MODE_ROMANCE
120
+ declare const LIGHT_CMD_COLOR_MODE_ROYAL
121
+ declare const LIGHT_CMD_COLOR_MODE_SUNSET
122
+ declare const LIGHT_CMD_COLOR_PURPLE
123
+ declare const LIGHT_CMD_COLOR_RED
124
+ declare const LIGHT_CMD_COLOR_SET
125
+ declare const LIGHT_CMD_COLOR_SET_RECALL
126
+ declare const LIGHT_CMD_COLOR_SET_SAVE
127
+ declare const LIGHT_CMD_COLOR_SWIM
128
+ declare const LIGHT_CMD_COLOR_SYNC
129
+ declare const LIGHT_CMD_COLOR_WHITE
130
+ declare const LIGHT_CMD_LIGHTS_OFF
131
+ declare const LIGHT_CMD_LIGHTS_ON
132
+ declare const PUMP_TYPE_INTELLIFLOVF
133
+ declare const PUMP_TYPE_INTELLIFLOVS
134
+ declare const PUMP_TYPE_INTELLIFLOVSF
135
+ }