1. A method for measuring illumination by a lighting unit of a target surface within a lighting environment, the method comprising the steps of:illuminating, with a light source of the lighting unit, the target surface;
detecting, with a light sensor, a light intensity for a plurality of locations of the target surface;
detecting a parameter of the lighting environment;
detecting, using the detected parameter, an obstruction situated in the lighting environment between the light source and the target surface;
selecting, by a controller of the lighting unit, a subset of the plurality of light intensities based on the detected parameter of the lighting environment and the detected obstruction, wherein the subset comprises light intensities from an unobstructed portion of the target surface; and
estimating, using the selected subset of light intensities, a lux of the target surface.