In the case of using a Permanent Magnet Synchronous Motor (PMSM) linear model of limited-range parametric variations and of relatively low dynamic of the load torque, the Field Oriented Control (FOC) type strategy ensures good performance of the PMSM control. Therefore, when using a non-linear model of wide-range parametric variations and of high dynamic of the load torque, a backstepping-type controller is proposed, whose tuning parameters are optimized by using a Particle Swarm Optimization (PSO) method. By designing an Extended State Observer (ESO), which provides a good estimate of the PMSM rotor position and speed under uncertainty conditions and with a response time shorter than that of the backstepping-type controller, this observer can be incorporated into the PMSM sensorless control system. The superior performance of the proposed sensorless control system based on the backstepping-PSO-type controller and an ESO-type observer is demonstrated through numerical simulations. Given that the real-time implementation of the control algorithms and observers in an embedded system is a difficult task, consisting of several steps, it is presented after the numerical simulations, which can be assimilated into the Software-in-the-Loop (SIL) step, the Processor-in-the-Loop (PIL) intermediate step, and the Hardware-in-the-Loop (HIL) final step. A comparison between the backstepping-PSO-type controller and the PI-PSO-type controller is presented by means of the real-time implementation of these controllers and demonstrates the superiority of the backstepping-PSO-type controller.