Accurate light sensor. First, consider the light-attenuation problem.