In this study a physiological closed-loop system for arterial CO2 partial pressure control was designed and comprehensively tested using a set of models of the respiratory CO2 gas exchange. The underlying preclinical data were collected from 12 pigs in presence of severe changes in hemodynamic and pulmonary condition. A minimally complex nonlinear state space model of CO2 gas exchange was identified post hoc in different lung conditions. The control variable was measured noninvasively using the endtidal CO2 partial pressure. For the simulation study the output signal of the controller was defined as the alveolar minute volume set value of an underlying adaptive lung protective ventilation mode. A linearisation of the two-compartment CO2 gas exchange model was used for the design of a model predictive controller (MPC). It was augmented by a tube based controller suppressing prediction errors due to model uncertainties. The controller was subject to comparative testing in interaction with each of the CO2 gas exchange models previously identified on the preclinical study data. The performance was evaluated for the system response towards the following five tests in comparison to a PID controller: recruitment maneuver, PEEP titration maneuver, stepwise change in the CO2 production, breath-hold maneuver and a step in the reference signal. A root mean square error of 2.69 mmHg between arterial CO2 partial pressure and the reference signal was achieved throughout the trial. The reference-variable response of the model predictive controller was superior regarding overshoot and settling time.