-
Notifications
You must be signed in to change notification settings - Fork 0
/
Mqtt.ts
48 lines (44 loc) · 1.13 KB
/
Mqtt.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
export interface House {
rooms: Room[];
thermostat: Thermostat;
modeDaytimePayload?: string;
modeNighttimePayload?: string;
modeStateTopic?: string;
}
export interface Room {
actualTemperatureStateTopic: string;
isNighttimeRoom?: boolean;
name: string;
modeCommandTopic: string;
targetTemperatureStateTopic: string;
vents: Vent[];
}
export interface Vent {
closePositionPayload: string;
closedStatePayload: string;
closedWhenIdle?: boolean;
positionCommandTopic: string;
name: string;
openPositionPayload: string;
openedStatePayload: string;
positionStateTopic: string;
}
export interface Thermostat {
actionStateTopic: string;
actualTemperatureStateTopic: string;
coolingActionPayload: string;
coolModePayload: string;
heatingActionPayload: string;
heatModePayload: string;
idleActionPayload: string;
modeStateTopic: string;
name: string;
targetTemperatureCommandTopic: string;
targetTemperatureStateTopic: string;
}
export interface MqttConnection {
host: string;
port: number;
username?: string;
password?: string;
}