Adding path explorations for initializations.
[smartthings-infrastructure.git] / Variables and events for each device
1 //
2 //For Alarms:
3 String currentAlarm or String alarm
4 /*events*/
5 //No events based on this device
6 /*events*/
7 //
8 -------------------------------------------------------------------------------
9
10
11 //For Contact Sensor:
12 String currentContact or String contactState
13 /*events*/
14 /////
15 contact closed event:
16 contactObject.setValue([name: "contact.closed", value: "closed", deviceId: "contactSensorID0", descriptionText: "",
17 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
18 /////
19 contact open event:
20 contactObject.setValue([name: "contact.open", value: "open", deviceId: "contactSensorID0", descriptionText: "",
21 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
22 /////
23 /*events*/
24 //
25 -------------------------------------------------------------------------------
26
27
28 //For DoorControl:
29 String doorState
30 /*events*/
31 door closed event using doorControl:
32 doorControlObject.setValue([name: "doorState", value: "closed", deviceId: "doorControlID0", descriptionText: "",
33 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
34 /////
35 door open event using doorControl:
36 doorControlObject.setValue([name: "doorState", value: "open", deviceId: "doorControlID0", descriptionText: "",
37 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
38 /////
39 /*events*/
40 //
41 -------------------------------------------------------------------------------
42
43
44 //For Location:
45 String location.mode
46 /*events*/
47 location changes event:
48 locationObject.setValue([name: "Location", value: "away", deviceId: "locationID0", descriptionText: "",
49 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
50 locationObject.setValue([name: "Location", value: "home", deviceId: "locationID0", descriptionText: "",
51 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
52 locationObject.setValue([name: "Location", value: "night", deviceId: "locationID0", descriptionText: "",
53 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
54 /*events*/
55 //
56 -------------------------------------------------------------------------------
57
58
59 //For Locks:
60 String currentLock or String lockState
61 /*events*/
62 lock event:
63 lockObject.setValue([name: "lock", value: "locked", deviceId: "lockID0", descriptionText: "",
64 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
65 /////
66 unlock event:
67 lockObject.setValue([name: "unlock", value: "unlocked ", deviceId: "lockID0", descriptionText: "",
68 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
69 /////
70 /*events*/
71 //
72 -------------------------------------------------------------------------------
73
74
75 //For MotionSensors:
76 String currentMotion or String motion
77 /*events*/
78 Motion sensor event: motion detected:
79 motionSensorObject.setValue([name: "motion", value: "active", deviceId: "motionSensorID0", descriptionText: "",
80 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
81 /////
82 Motion sensor event: motion not detected:
83 motionSensorObject.setValue([name: "motion", value: "inactive", deviceId: "motionSensorID0", descriptionText: "",
84 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
85 /////
86 /*events*/
87 //
88 -------------------------------------------------------------------------------
89
90
91 //For MusicPlayer:
92 String status
93 /*events*/
94 //No events based on this device
95 /*events*/
96 //
97 -------------------------------------------------------------------------------
98
99
100 //For PresenceSensor:
101 String currentPresence or String presenceState
102 /*events*/
103 presence sensor, present event:
104 presenceSensorObject.setValue([name: "presence", value: "present", deviceId: "presenceSensorID0", descriptionText: "",
105 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
106 /////
107 presence sensor, left event:
108 presenceSensorObject.setValue([name: "presence", value: "not present", deviceId: "presenceSensorID0", descriptionText: "",
109 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
110 /////
111 /*events*/
112 //
113 -------------------------------------------------------------------------------
114
115
116 //For SmokeDetector:
117 String currentSmokeValue or String smoke
118 /*events*/
119 smoke is clear event:
120 smokeDetectorObject.setValue([name: "smoke", value: "clear", deviceId: "smokeDetectorID0", descriptionText: "",
121 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
122 /////
123 smoke is detected event:
124 smokeDetectorObject.setValue([name: "smoke", value: "detected", deviceId: "smokeDetectorID0", descriptionText: "",
125 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
126 /////
127 smoke is tested event:
128 smokeDetectorObject.setValue([name: "smoke", value: "tested", deviceId: "smokeDetectorID0", descriptionText: "",
129 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
130 /////
131 carbonMonoxide is clear event:
132 smokeDetectorObject.setValue([name: "carbonMonoxide", value: "clear", deviceId: "smokeDetectorID0", descriptionText: "",
133 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
134 /////
135 carbonMonoxide is detected event:
136 smokeDetectorObject.setValue([name: "carbonMonoxide", value: "detected", deviceId: "smokeDetectorID0", descriptionText: "",
137 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
138 /////
139 carbonMonoxide is tested event:
140 smokeDetectorObject.setValue([name: "carbonMonoxide", value: "tested", deviceId: "smokeDetectorID0", descriptionText: "",
141 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
142 /////
143 battery charge value event:
144 smokeDetectorObject.setValue([name: "battery", value: "5"/*A number between 0 to 100 as a charge*/, deviceId: "smokeDetectorID0", descriptionText: "",
145 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
146 /////
147 battery charge value event:
148 smokeDetectorObject.setValue([name: "battery", value: "5"/*A number between 0 to 100 as a charge*/, deviceId: "smokeDetectorID0", descriptionText: "",
149 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
150 /////
151 /*events*/
152 //
153 -------------------------------------------------------------------------------
154
155
156 //For Thermostats:(we have different features in each line)
157 String heatingSetpoint or currentHeatingSetpoint //heating set point
158 String thermostatSetpoint //normal set point
159 String coolingSetpoint or currentCoolingSetpoint //cooling set point
160 String thermostatOperatingState //operating state
161 String thermostatFanMode //fan mode
162 String thermostatMode or currentThermostatMode //mode
163 /*events*/
164 thermostad mode change event: to auto
165 thermostatObject.setValue([name: "thermostatMode", value: "auto", deviceId: "thermostatID0", descriptionText: "",
166 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
167 /////
168 thermostad mode change event: to cool
169 thermostatObject.setValue([name: "thermostatMode", value: "cool", deviceId: "thermostatID0", descriptionText: "",
170 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
171 /////
172 thermostad mode change event: to emergencyHeat
173 thermostatObject.setValue([name: "thermostatMode", value: "emergencyHeat", deviceId: "thermostatID0", descriptionText: "",
174 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
175 /////
176 thermostad mode change event: to heat
177 thermostatObject.setValue([name: "thermostatMode", value: "heat", deviceId: "thermostatID0", descriptionText: "",
178 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
179 /////
180 thermostad mode change event: to off
181 thermostatObject.setValue([name: "thermostatMode", value: "off", deviceId: "thermostatID0", descriptionText: "",
182 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
183 /////
184 /*events*/
185 //
186 -------------------------------------------------------------------------------
187
188
189 //For Switches:
190 String currentSwitch or switchState
191 /*events*/
192 switch changes to off:
193 switchObject.setValue([name: "switch", value: "off", deviceId: "switchID0", descriptionText: "",
194 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
195 /////
196 switch changes to on:
197 switchObject.setValue([name: "switch", value: "on", deviceId: "switchID0", descriptionText: "",
198 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
199 /////
200 /*events*/
201 //
202 -------------------------------------------------------------------------------
203
204
205 //For appTouch:
206 /*events*/
207 appObject.setValue([name: "Touched", value: "touched", deviceId: "touchedSensorID0", descriptionText: "",
208 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
209 /////
210 /*events*/
211 //
212 -------------------------------------------------------------------------------
213
214
215 //For nfcTouch:
216 /*events*/
217 Nfc touched event:
218 appObject.setValue([name: "nfcTouch", value: "touched", deviceId: "nfcSensorID0", descriptionText: "",
219 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
220 /////
221 /*events*/
222 //
223 -------------------------------------------------------------------------------
224
225
226 //For aeonKeyFob push button:
227 /*events*/
228 button pushed event:
229 aeonKeyFobObject.setValue([name: "button", value: "pushed", deviceId: "aeonKeyFobID0", descriptionText: "",
230 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
231 /////
232 button held event:
233 aeonKeyFobObject.setValue([name: "button", value: "held", deviceId: "aeonKeyFobID0", descriptionText: "",
234 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
235 /////
236 /////
237 /*events*/
238 //
239 -------------------------------------------------------------------------------
240
241
242 //For acceleration sensor:
243 String currentAcceleration or String acceleration
244 /*events*/
245 Acceleration sensor event: acceleration detected:
246 accelerationSensorObject.setValue([name: "acceleration", value: "active", deviceId: "accelerationSensorID0", descriptionText: "",
247 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
248 /////
249 Acceleration sensor event: acceleration not detected:
250 accelerationSensorObject.setValue([name: "acceleration", value: "inactive", deviceId: "accelerationSensorID0", descriptionText: "",
251 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
252 /////
253 /*events*/
254 //
255 -------------------------------------------------------------------------------
256
257
258 //For battery:
259 String currentBattery or String battery
260 /*events*/
261 //No events based on this device
262 /*events*/
263 //
264 -------------------------------------------------------------------------------
265
266
267 //For beacon sensor:
268 String currentPresence or String presence
269 /*events*/
270 beacon sensor, present event:
271 beaconSensorObject.setValue([name: "beacon", value: "present", deviceId: "beaconeSensorID0", descriptionText: "",
272 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
273 /////
274 beacon sensor, left event:
275 beaconSensorObject.setValue([name: "beacon", value: "not present", deviceId: "beaconSensorID0", descriptionText: "",
276 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
277 /////
278 /*events*/
279 //
280 -------------------------------------------------------------------------------
281
282
283 //For carbon monoxide:
284 String currentCarbonMonoxideValue or String carbonMonoxide
285 /*events*/
286 carbonMonoxide is clear event:
287 carbonMonoxideDetectorObject.setValue([name: "carbonMonoxide", value: "clear", deviceId: "carbonMonoxideDetectorID0", descriptionText: "",
288 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
289 /////
290 carbonMonoxide is detected event:
291 carbonMonoxideDetectorObject.setValue([name: "carbonMonoxide", value: "detected", deviceId: "carbonMonoxideDetectorID0", descriptionText: "",
292 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
293 /////
294 carbonMonoxide is tested event:
295 carbonMonoxideDetectorObject.setValue([name: "carbonMonoxide", value: "tested", deviceId: "carbonMonoxideDetectorID0", descriptionText: "",
296 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
297 /*events*/
298 //
299 -------------------------------------------------------------------------------
300
301
302 //For color control:
303 String color
304 String hue
305 String saturation
306 /*events*/
307 color changed:
308 colorControlObject.setValue([name: "color", value: "red", deviceId: "colorControlID0", descriptionText: "",
309 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
310 /////
311 hue changed:
312 colorControlObject.setValue([name: "hue", value: "50", deviceId: "colorControlID0", descriptionText: "",
313 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
314 /////
315 saturation changed:
316 colorControlObject.setValue([name: "saturation", value: "50", deviceId: "colorControlID0", descriptionText: "",
317 displayed: true, linkText: "", isStateChange: false, unit: "", data: [info: "info"]])
318 /*events*/
319 //