How are the commands sent from the cloud to the individual devices? For example, Turn on the light at 10 o’clock. Where are the settings saved? In the cloud or on the device? How are the commands sent thru my router?
The device keeps a login session to the cloud; this could be done over UDP with heartbeats, or over TCP connections. As long as the session is active, the cloud can send instructions to the device whenever needed, either when you adjust lighting status via APPs or when any scheduled task is fired.