how does it know if the headlights are on?