[{"id":"952fcefb.7159f8","type":"hubitat device","z":"c200f504.6ecb68","name":"MultiSenDomeU (office3)","server":"c3a39a36.1bf95","deviceId":"98","attribute":"motion","sendEvent":true,"x":312,"y":342,"wires":[["3ec5420e.42656e","40617f76.81b02"]]},{"id":"1275c24b.ee9d36","type":"switch","z":"c200f504.6ecb68","name":"Active/Inactive","property":"payload.value","propertyType":"msg","rules":[{"t":"eq","v":"active","vt":"str"},{"t":"eq","v":"inactive","vt":"str"}],"checkall":"true","repair":false,"outputs":2,"x":528,"y":413,"wires":[["b4ddee7.4a0369"],["cf5c9337.0f6db"]]},{"id":"54b83846.b5e5d","type":"hubitat command","z":"c200f504.6ecb68","name":"Office Ceiling Light ON","server":"c3a39a36.1bf95","deviceId":"76","command":"on","commandArgs":"","x":1167,"y":399,"wires":[["19fc670d.d21879"]]},{"id":"d3d92099.a2bf68","type":"hubitat command","z":"c200f504.6ecb68","name":"Office Ceiling Light OFF","server":"c3a39a36.1bf95","deviceId":"76","command":"off","commandArgs":"","x":1156,"y":523,"wires":[["19fc670d.d21879"]]},{"id":"efe25a0b.8cffd8","type":"hubitat mode","z":"c200f504.6ecb68","name":"Mode Is","server":"c3a39a36.1bf95","sendEvent":true,"x":310,"y":142,"wires":[["3282232a.0d743c"]]},{"id":"3ec5420e.42656e","type":"switch","z":"c200f504.6ecb68","d":true,"name":"Mode Switch","property":"currentMode","propertyType":"global","rules":[{"t":"eq","v":"Day","vt":"str"},{"t":"eq","v":"Evening","vt":"str"},{"t":"eq","v":"Night","vt":"str"},{"t":"else"}],"checkall":"true","repair":false,"outputs":4,"x":252,"y":508,"wires":[["1275c24b.ee9d36"],["1275c24b.ee9d36"],["1275c24b.ee9d36"],["d3d92099.a2bf68"]]},{"id":"b5dd4545.cd9178","type":"change","z":"c200f504.6ecb68","name":"saveCurrentMode","rules":[{"t":"set","p":"currentMode","pt":"global","to":"payload.value","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":655,"y":142,"wires":[["901fc539.012088"]]},{"id":"3282232a.0d743c","type":"rbe","z":"c200f504.6ecb68","name":"","func":"rbe","gap":"","start":"","inout":"out","property":"payload","x":475,"y":142,"wires":[["b5dd4545.cd9178"]]},{"id":"901fc539.012088","type":"debug","z":"c200f504.6ecb68","d":true,"name":"SavedMode IS","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","x":1280,"y":146,"wires":},{"id":"62f0a316.3b0894","type":"inject","z":"c200f504.6ecb68","name":"","topic":"","payload":"true","payloadType":"bool","repeat":"","crontab":"","once":false,"onceDelay":0.1,"x":112,"y":342,"wires":[["952fcefb.7159f8"]]},{"id":"40617f76.81b02","type":"debug","z":"c200f504.6ecb68","d":true,"name":"Motion IS","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","x":1312,"y":342,"wires":},{"id":"10a420f0.53cc6f","type":"comment","z":"c200f504.6ecb68","name":"set a global mode variable, global.currentMode, useful everywhere in this Flow.","info":"","x":340,"y":80,"wires":},{"id":"1433c34c.cb5c5d","type":"comment","z":"c200f504.6ecb68","name":"sample of Motion by Mode","info":"","x":170,"y":283,"wires":},{"id":"bc9829c5.84af","type":"inject","z":"c200f504.6ecb68","name":"","topic":"","payload":"Started!","payloadType":"str","repeat":"","crontab":"","once":true,"onceDelay":"0.1","x":120,"y":143,"wires":[["efe25a0b.8cffd8"]]},{"id":"b4ddee7.4a0369","type":"change","z":"c200f504.6ecb68","name":"Cancelable","rules":[{"t":"delete","p":"payload.value","pt":"msg"},{"t":"set","p":"payload","pt":"msg","to":"stop","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":729,"y":406,"wires":[["91e7bcf3.60a0a8","cf5c9337.0f6db"]]},{"id":"91e7bcf3.60a0a8","type":"time-range-switch","z":"c200f504.6ecb68","name":"Dawn-8PM","lat":"37.3230","lon":"-122.0322","startTime":"sunrise","endTime":"20:00","startOffset":0,"endOffset":0,"x":904,"y":406,"wires":[["54b83846.b5e5d"],["cce8f08a.09307"]]},{"id":"7613c8ca.ab1ec8","type":"comment","z":"c200f504.6ecb68","name":"Duplicate Mode vs Time of Day","info":"This is a Sample flow, thus it has both a Time of day restriction as well as a 'by Mode' restriction. If both are used, then readability is improved if the two match: Dawn to 8pm doesn't work when Mode is not including Day. If both are NOT needed, copy the sample and after pasting, delete one or the other. ","x":561,"y":482,"wires":},{"id":"cce8f08a.09307","type":"hubitat command","z":"c200f504.6ecb68","name":"Office Ceiling Light 10%","server":"c3a39a36.1bf95","deviceId":"76","command":"setLevel","commandArgs":"10","x":1157,"y":460,"wires":[]},{"id":"19fc670d.d21879","type":"debug","z":"c200f504.6ecb68","d":true,"name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","x":1430,"y":460,"wires":},{"id":"cf5c9337.0f6db","type":"stoptimer-varidelay","z":"c200f504.6ecb68","duration":"15","durationType":"num","units":"Second","payloadtype":"num","payloadval":"0","name":"","reporting":"none","x":890,"y":480,"wires":[["d3d92099.a2bf68"],,]},{"id":"c3a39a36.1bf95","type":"hubitat config","z":"","name":"ThirdHubitat","usetls":false,"host":"192.168.7.64","port":"80","appId":"780","nodeRedServer":"http://192.168.7.129:1880","webhookPath":"/hubitat/webhook","autoRefresh":false,"useWebsocket":false}]