Automatic functioning of street lights can be done by the use of:

Emf

Inductor

Comparator

Rectifier