Exactly what I want, too. Looking forward for a solution. Ambient light sensor would also be nice, and possibility to combine trigger conditions (AND/OR etc.) in software. Turn light on IF sensor movement AND time is in range OR it's dark... turn light off after 10 minutes from last detection... instead of the ambient light sensor, an astronomical clock would probably be sufficient, too (but sunrise and sunset times differ greatly on different areas, in my country the difference is several hours between the north and south in the winter, so you would need latitude, longitude and time zone to make it work).