## 1 Introduction
When only a portion of the power elements is emulated and the rest are made up of real elements, it is a PHIL simulation. Finally, if the power elements are emulated while their controller or part of it is embedded in an external device, it is a CHIL simulation [27]. In this study an MS CHIL is proposed. With a CHIL simulation it is possible to test real controllers, with algorithms and parameters similar to those used in the field, providing a wide range of operating conditions in the experimental stage without the risk of damaging real equipment [28]. Commercial hardware exists dedicated to the development of this technique, but its use may represent a disadvantage due to its high cost, as an alternative the development of this technique using low-cost hardware is being sought. Ref. [29; 30] uses hardware from National Instruments (NI-cRIO 9082) to emulate the model of a tractor used in agriculture. Ref. [31] uses hardware from National Instruments (cRIO-9033) to emulate the transient electromagnetic behavior of electronic power devices. The platform was tested emulating a three-phase inverter and network. In this application, the model requires six FPGA cycles for its solution, which taking into account the frequency of its clock, translates into an integration time of 150 ns. Finally, [32] uses Texas Instruments hardware (EK-TM4 CI294 XL) to develop a platform for educational purposes, in which the user defines a plant and carries out experiments using HIL, this application presented end-to-end latency between 1.1 and 19.9 ms, for two case studies analyzed. These alternatives provide accurate emulation results, facilitate the rapid verification of different controllers, helping the user to define their own design and experimentation, methodology, as well as representing platforms that can be replicated by educators and researchers. Other HIL applications are autonomous vehicles [33; 34; 35], motor control [36; 37; 38] and the traction system of a railway [39]. In addition, it is used in the design of PVSs. In [40], the development of a three-level coordinated control method for PV inverters is presented. This study is validated through a PHIL simulation using a real time digital simulator (RTDS) that includes a 7-bus distribution network. In the RTDS, the distribution network model was emulated at a time step of 50 \(\upmu\)s. In [41], a distributed control for remote islanded microgrids (MGs) via cloud server was presented, in this research, a multiagent system was developed where the physical entity of islanded MGs was emulated at 50 \(\upmu\)s time step on OPAL-RT. In [42], a platform of a PVS composed of a PVP, a DC-DC PEC and a P&O controller was implemented using an NI myRIO 1900 development board programmed in Matlab's Simulink using NI Veristand--this platform works 1 ms integration time. Study [43] uses HIL based on the RT-Lab platform to emulate a virtual synchronous photovoltaic generator, the platform used in this research can reproduce a simulation step every 20 \(\upmu\)s. Ref. [44] tests the operation of a cascade H-bridge inverter used for interconnection of the PVS with the AC main grid, in this platform an OP4510 simulator was implemented and it performed a simulation step every 10 \(\upmu\)s. Ref. [45] uses a TM32F103 ARM microcontroller to design a test bench for the analysis of a photovoltaic energy storage system using batteries. Ref. [46] uses an arrangement with cRIO, FPGAs and a processor to simulate a MG that includes a PVS, achieving simulation steps of around 5 \(\upmu\)s. Ref. [47] uses the HIL methodology to validate the management system in a MG where the PVS represents the only source of energy. In this research, an OP5700 simulator was used. This platform has a Xilinx Virtex 7 FPGA and generates steps simulation between 200 ns and 2 \(\upmu\)s. The most important aspect in a HIL simulation is that the behavior of the embedded physical system is reproduced in real time. This characteristic proved satisfactory in the research presented given the integration time with which they operate.