Here is a quick demo showing how Sapphire handles an event where either the sun has set or a cloud has blocked out the sun enough to darken the room. Once the room reaches a limit the lights are either switched on or off depending on the lights previous state.