Define actions based on predefined schedules using the Light Scheduler node. This functionality is based on two conditions: a created schedule and a check if itâ€™s dark (only when dark). When both are true, the light turns on.
Info 

Checking whether it is dark is based on time and geographic coordinates. The coordinates are entered by the user at the configuration stage of this flow, and the time is automatically downloaded from the Vertex controller. 
Flow
Code Block 

[{"id":"adbbbe1dc08e3583","type":"lightscheduler","z":"766cd0d9afd9a034","settings":"b17a207d2a6309f3","events":"[{\"start\":{\"dow\":1,\"mod\":1270},\"end\":{\"dow\":2,\"mod\":0}},{\"start\":{\"dow\":3,\"mod\":1270},\"end\":{\"dow\":4,\"mod\":0}},{\"start\":{\"dow\":4,\"mod\":1270},\"end\":{\"dow\":5,\"mod\":0}},{\"start\":{\"dow\":5,\"mod\":1270},\"end\":{\"dow\":6,\"mod\":0}},{\"start\":{\"dow\":6,\"mod\":1270},\"end\":{\"dow\":0,\"mod\":0}},{\"start\":{\"dow\":0,\"mod\":1270},\"end\":{\"dow\":1,\"mod\":0}},{\"start\":{\"dow\":2,\"mod\":0},\"end\":{\"dow\":2,\"mod\":365}},{\"start\":{\"dow\":4,\"mod\":0},\"end\":{\"dow\":4,\"mod\":365}},{\"start\":{\"dow\":3,\"mod\":0},\"end\":{\"dow\":3,\"mod\":365}},{\"start\":{\"dow\":5,\"mod\":0},\"end\":{\"dow\":5,\"mod\":365}},{\"start\":{\"dow\":6,\"mod\":0},\"end\":{\"dow\":6,\"mod\":365}},{\"start\":{\"dow\":0,\"mod\":0},\"end\":{\"dow\":0,\"mod\":365}},{\"start\":{\"dow\":1,\"mod\":0},\"end\":{\"dow\":1,\"mod\":365}},{\"start\":{\"dow\":2,\"mod\":1270},\"end\":{\"dow\":3,\"mod\":0}}]","topic":"","name":"","onPayload":"100","onPayloadType":"num","offPayload":"0","offPayloadType":"num","onlyWhenDark":true,"scheduleRndMax":"","sunElevationThreshold":"18","sunShowElevationInStatus":true,"outputfreq":"output.statechange.startup","x":540,"y":400,"wires":[["670b617a79cf6db3"]]},{"id":"ad6ed22c3d3afd97","type":"vertex cluster","z":"766cd0d9afd9a034","rate":90,"x":1050,"y":400,"wires":[]},{"id":"d5c72a044c791cfc","type":"comment","z":"766cd0d9afd9a034","name":"Setting sheduler","info":"","x":540,"y":360,"wires":[]},{"id":"d34708f7ff68a086","type":"comment","z":"766cd0d9afd9a034","name":"Direct value","info":"","x":790,"y":360,"wires":[]},{"id":"670b617a79cf6db3","type":"vertex action","z":"766cd0d9afd9a034","name":"","typeButton":"directv","bPayload":{"action":"setbrightness","group":"95c5b32707068e426c23abc3506faaaa","param":0,"priority":"254"},"bState":"","defaultpriority":true,"x":790,"y":400,"wires":[["ad6ed22c3d3afd97"]]},{"id":"b17a207d2a6309f3","type":"lightschedulersettings","name":"test","latitude":"50.049272","longitude":"19.957367"}] 
Instructions
Find the following nodes in the palette on the left side of the NodeRED:
Light Scheduler
vertex action
vertex cluster
Drag the nodes and drop them onto the workspace.
Go to the Light scheduler node, in the section Globals, select the icon with a pen.
3. Set the name, longitude and latitude of your investment/building.
4. Create your schedule according to your requirements (in this example it is from 10 p.m. to 6 a.m.) and choose proper payloads and output.
5. Select only when dark and proper Threshold.
6. Go to the vertex action node and choose direct value mode with action set brightness (scale percent).
7. Link all the nodes and select the Deploy button.
Filter by label (Content by label)  

