A lighting system comprising a lamp arranged to transform electricity into a light beam having different properties; a light control means arranged to adjust said light beam properties; an ultrasonic transmitter arranged to transmit ultrasonic signals; an ultrasonic receiver arranged to receive reflected ultrasonic signals; and a processing means arranged to derive a time-of-flight signal representing the time differences between said transmitted and received ultrasonic signals and to send control signals to said light control means in dependence of said time-of-flight signal. The processing means performs a reference calibration step: the time-of-flight is repeatedly measured a multitude of times, and calculates the average of said measured time-of-flight values and stores the average in memory means as a reference time-of-flight value if said deviation of the majority of the measured time-of-flight values of said multitude of measurements is lower than a predetermined threshold.
展开▼