Switch off a device when it's daylight