First working version of in turn MPC/simulation.