Dynamic Response Correction (equalization)

Not sure about this yet, but I suspect that, when feeding an LED with PWM, the relation between duty cycle and luminosity is not linear. It must be a way to measure that relation and make the appropriate corrections in code... this will be interesting.