## 8 Conclusions  
This paper investigates the effectiveness of the proposed performance-based-tuning controllers for the buck-boost converter to balance the capacitor voltages of a five-level switch-sharing-based multilevel inverter. The buck-boost converter is chosen since it offers the simplest configuration, consisting of four power switches and two inductors, which are connected to four DC-link capacitors. In addition, the complexity of the control approach is considered low since the proposed online tuning mechanism is applied to the proportional gains without the need to adjust the integral gains. With the online tuning module incorporated in the controller's structure, the proposed PI controller is performed to improve the step response and steady-state performances while ensuring the quality of the inverter's output current and the capacitor voltage ripples remain intact. The simulation study shows that the proposed online tuning mechanism improves the quality of the output current, voltage ripples and efficiency as compared with those when no online tuning mechanism is applied. The highest efficiency is recorded at 96.9%, which is approximately 1.0% higher than the efficiency attained when no online tuning is employed. Two stages of the experimental investigation have been conducted to verify the efficacy of the proposed online tuning approach. In the preliminary testing stage, the online tuning mechanism that is based on the correlation between the proportional gains and the input voltage has been established considering the actual measured output current THD of the inverter. In the comparative testing stage, the performance of the controller with and without the proposed online tuning scheme has been evaluated. The experimental results reveal good improvement in terms of the dynamic and steady-state performances desired when the proposed tuning algorithm is applied. The capacitor voltages are able to be balanced satisfactorily with lower output current THD achieved at the inverter's output. Furthermore, capacitor voltage ripples are able to be reduced to 3 V as compared with the result without online tuning, which is 15 V. The rise time, fall time, peak time, settling time and percent overshoot also record encouraging results, denoting the superiority of the controller when the proposed online tuning module is integrated in the controller's structure. The fact that the online tuning mechanism is simple is a great advantage for real-time implementation. Ease of implementation is an important factor for practical application. Therefore, it can be concluded that better capacitor voltage balancing results and improved inverter output performances can be guaranteed via the application of the proposed tuning strategy, regardless of the change in the input voltage.  
**Author Contributions:** Conceptualization, Z.R. and J.J.; methodology, Z.R. and J.J.; software, Z.R. and J.J.; validation, J.J., N.A.R. and S.R.A.; formal analysis, Z.R.; writing--original draft preparation, Z.R.; writing--review and editing, J.J., N.A.R. and S.R.A.; supervision, J.J., N.A.R. and S.R.A. All authors have read and agreed to the published version of the manuscript.  
**Funding:** This research was funded by UM Power Energy Dedicated Advanced Centre (UMPEDAC) and the Higher Institution Centre of Excellence (HICoE) Program Research Grant, UMPEDAC--2017 (MOHE HICOE--UMPEDAC), Ministry of Education Malaysia, RU002-2017 and University of Malaya grant no. BK033-2015.  
**Institutional Review Board Statement:** Not applicable.  
**Informed Consent Statement:** Not applicable.  
**Data Availability Statement:** Data are contained within the article.  
**Acknowledgments:** Authors acknowledge the UMPEDAC staff for the administrative and technical support.  
**Conflicts of Interest:** The authors declare no conflict of interest.