This paper describes the design and implementation of a discrete controller for grid-connected voltage-source inverters with an <i xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:xlink="http://www.w3.org/1999/xlink">LCL</i> filter usually found in wind power generation systems. First, a theorem that relates the controllability of the discrete dynamic equation of the inverter with <i xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:xlink="http://www.w3.org/1999/xlink">LCL</i> filter and the sampling frequency is derived. Then, a condition to obtain a partial state feedback controller robust to grid impedance uncertainties and based on linear matrix inequalities is proposed. This controller guarantees the stability and damping of the <i xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:xlink="http://www.w3.org/1999/xlink">LCL</i> filter resonance for a large set of grid conditions without requiring self-tuning procedures. Finally, an internal model controller is added to ensure asymptotic reference tracking and disturbance rejection, significantly reducing the impact of grid background voltage distortion on the output currents. Experimental results are presented to support the theoretical analysis and to demonstrate the system performance.