Next Article in Journal
Optimizing the Band Alignment of the MZO/CdSeTe/CdTe Solar Cell by Varying the Substrate Temperature of MZO Film
Next Article in Special Issue
LCL Trap Filter Analysis with a PFC Isolated Ćuk Converter Using SiC MOSFET for DCM
Previous Article in Journal
Increasing the Efficiency of Loading Devices for Biomass Boilers
Previous Article in Special Issue
Universal Input Single-Stage High-Power-Factor LED Driver with Active Low-Frequency Current Ripple Suppressed
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

Efficient Prototyping of a Field-Programmable Gate Array-Based Real-Time Model of a Modular Multilevel Converter

1
The Key Laboratory of HVDC, Electric Power Research Institute China Southern Grid, Guangzhou 510663, China
2
Department of Electrical Engineering, Zhengzhou University, Zhengzhou 450001, China
*
Author to whom correspondence should be addressed.
Energies 2024, 17(3), 591; https://doi.org/10.3390/en17030591
Submission received: 21 November 2023 / Revised: 29 December 2023 / Accepted: 9 January 2024 / Published: 26 January 2024
(This article belongs to the Special Issue Optimal Design and Application of High-Performance Power Converters)

Abstract

:
Field-programmable gate array (FPGA)-based real-time simulation plays a crucial role in testing power–electronic dominated systems with the formation of controller hardware-in-the-loop (CHIL) or power hardware-in-the-loop (PHIL). This work describes an efficient implementation of computation time and resource usage in the FPGA-based study of a modular multilevel converter (MMC) with detailed electromagnetic transients. The proposed modeling technique can be used in continuous control mode (CCM) and discontinuous control mode (DCM) for high-switching frequency semiconductor technologies. An FPGA-based designed solver structure is also presented to take advantage of the parallel features of FPGAs to achieve an ultra-fast calculation speed. In addition, two different switch modeling techniques are discussed with a five-level MMC case study. Experimental results on the NI PXIe platform show the feasibility of the proposed implementation, and a time step of 100 nanoseconds is achieved.

1. Introduction

Modular multilevel converters (MMCs) are widely applied in power transmission and conversion in power grids and electrified transportation. However, testing MMCs with high power is a great danger due to the high voltage and current involved. In addition, the prototype is prone to be damaged without precautions. On the other hand, hardware-in-the-loop simulation (HiLs) serves as an effective form of testing and validation of the prototype by simulating the power electronic system using a digital real-time simulator (DRTS) [1]. This can minimize the developing period and reduce the danger of damaging and destroying prototypes [2]. However, the design of HiLs depends on the mathematical model of the MMC, the calculation time of which will affect the stability of the real-time system.
In a power-electronic-dominated system simulation, the choice of the time step relates to the typical application and the implementation hardware. A relatively low time step is required to maintain numerical stability for studying power systems or electrical machines. A time step ranging from 50 µs to 200 µs is necessary to consider the effect of the third or fifth harmonic in the power system [3]. This time step can provide acceptable results for electromagnetic transients up to 1 kHz. This can be implemented on a simulator using CPU/DSP as the core computational engine [4]. A power system involving multiple power electronic systems requires a time below 50 µs to perform the transient analysis of power systems.
For time steps below microseconds, FPGAs have to be involved [5]. This time step presents a detailed representation of electromagnetic transients and high frequencies inside power electronic systems. A higher-order numerical solver can achieve greater precision. The transient process of the switch devices, similar to the IGBT, can be simulated [6]. Compared with processor-based studies, the FPGA-based simulator can affect the system’s behavior by sampling the controller’s signals with an ultra-high resolution. This gives an acceptable accuracy with an interpolation method compensating for the internal switch events [7].
From this discussion, we can conclude that an FPGA simulator is essential for achieving a time step with hundreds of nanoseconds. In addition, the discrete solver and the modeling of the power switch are two main parts. In discrete solver design, paper [6] presents an FPGA-based DRTS environment for analyzing the electromagnetic transients of power systems, including multiple power electronic converters. Different subsystems are divided by utilizing the Switching-Network Partitioning (SNP) method. Using the parallel calculation of FPGAs enables sub-microsecond simulation time steps. Paper [7] utilizes the LabVIEW Platform 2021 and implements the power converters model using LabVIEW FPGAs. LabVIEW provides a single-cycle time loop structure and achieves a time step of hundreds of nanoseconds. Paper [8] presents a general implementation of the FPGA-based simulation of photovoltaic applications. After representing the system with ODEs using Xilinx system generator tools, a time step below 1 microsecond is obtained.
However, this solver is restricted by sequential calculation, and parallel solving can improve the solving speed [9,10]. Paper [11] proposes a similar approach to real-time simulation using a multi-rate structure. By modeling the power electronic system using different time resolutions, the solving is not sequential, and all subsystems can be solved simultaneously. Paper [12] proposes apredictor–corrector parallel solver for FPGA implementation. An independent solving process is obtained after separating the solving relationship between the predictor and corrector calculation. After implementing LabVIEW FPGAs, the time step is significantly reduced to 100 nanoseconds. The other decoupling method is a multi-rate simulation with a different solver [13,14]. A parallel process can be achieved by partitioning the whole system using different time steps. However, the latency among different subsystems and the synchrony of the subsystem are two potential problems.
The other key factor that affects the calculation speed is the judgment of the switches. In general, the ideal switch function model [15], the Ron/Roff model [16], and the associated discrete circuit model [17] are three commonly used models for system-level simulations with a detailed representation of the switch steady-state effect. Although the transient state of the switch can further improve the system accuracy, the model size is largely limited due to the hardware resource of FPGAs [18]. In system-level simulations, similar to the DCM condition, an iteration is required to maintain the stability of the real-time model. Paper [19,20] utilizes the iteration process to find the value when the current reaches zero. The maximum iteration times are defined to avoid overrun under the real-time constraint. On the other hand, paper [21] proposes a zero-crossing method seeking the current value when the MMC’s bridge is in the blocked mode. The zero-crossing method forces the current value to zero once the transmission from CCM to DCM is captured. This avoids the complex iteration process and can be used for CCM and DCM statutes.
This paper aims to develop a highly efficient MMC model using FPGAs. The rest of this article is organized as follows: Section 2 describes the FPGA solver design, including the ODE-solving and switch judgment processes. Section 3 presents the system model of MMCs using the ideal and Ron/Roff switch models. Section 4 offers the conclusion.

2. FPGA Solver Design

In this section, the solver of a power electronic system is illustrated. Three factors are involved. One is the discrete integration solver. The second part is the judgment of the switch status. The last is the circuit implementation on FPGAs.

2.1. ODE Solver Design

In power electronic simulations, the ordinary differential equation (ODE) form in Equation (1) can be used to describe the system behavior.
x ˙ = f t n , x n y = C x + D u
where u is the input vector, x is the state vector,  f t n , x n is the derivative function, and f t n , x n = A x + B u , y is the output vector. A ,   B ,   C ,   D is the coefficient matrix containing the system parameters.
In general, the solving of (1) involves the integration method. One commonly used method is the Backward Euler (BE) method. In the n -th time step, (1) is rewritten using BE as Equation (2) [22],
x n = h · f t n , x n + x n 1 = h · A x n + h · B u n + x n 1 y ( n ) = C x n + D u n
To solve x(n), two methods have been used in the literature. One is the iteration method. The other is the direct solution [23]. The error should be defined in the iteration method to end the calculation loop in each time step. The maximum iteration times are restricted so that real-time constraints can be met. One type of iteration is the improved Euler method, with the formation in Equation (3)
x ^ n = h · f t n , x n 1 + x n 1 x n = h · f t n , x ^ n + x n 1 y ( n ) = C x n + D u n
where x n is the value first calculated with the forward Euler method, and it is used to approximate the value of x n . Then, in the backward Euler formation, x(n) is replaced with x n to finish the calculation. This significantly saves the calculation time without much iteration time. The other method is the direct solution. In this method, Equation (2) is deduced from Equation (4),
x n = 1 h · A 1 ( h · B u n + x n 1 ) y ( n ) = C x n + D u n
Equation (3) is a direct solution to Equation (2). Since 1 h · A 1 exists in Equation (4), x(n) has value with the condition that 1 h · A 1 0 . Compared with the iteration method in Equation (2), the direct solution requires more mathematical power and calculation time to solve the inverse matrix of 1 h · A . So, usually, the iteration process with limited iteration time has the advantage of fast calculation. However, iteration is a sequential process, the calculation time of which can be further accelerated with a parallel process.
As shown in Figure 1, the parallel structure calculates the value x ^ n + 2 at time point t n with a time step of 2 h . At the same time, x n is calculated with the value x ^ n obtained from the time step of t n 2 . The value of x ^ n is calculated and known at the beginning of time step t n . Thus, the calculation of x n does not need to wait for the calculation of x ^ n at the time step of t n . Since the solving of x ^ n + 2 and x n is independent, they can be calculated at the same time. This method can be effectively used when the simulation time step is relatively small.
The parallel solving process can be written as shown in Equation (5),
x ^ n + 2 = y n + 2 · h · f t n , y n x n = h · f t n , x ^ n + x n 1 y ( n ) = C x n + D u n
Compared with Equation (4), the solving process is independent. The implementation of Equation (5) will have a speed advantage.

2.2. Switch Status Update and DCM Modeling

One of the essential elements in the power electronic system is the power semiconductor device. The number of possible topologies in one power electronic system relates to the number of switches. If N is the switch’s total number, the potential power electronic system’s combination is 2 N . This time-varying feature of the power electronic system is one of the biggest challenges in modeling. For instance, if N = 10, the size of the data required to store all the statuses of the circuit elements can be enormous.
For non-controlled switches such as diode elements, its state depends on i s w i t c h or V s w i t c h as input for the current calculation step. In Table 1, the three basic subsystem types of switches are summarized. In the parallel calculation structure, the calculation of Iswitch has to be associated with the inductor connected to it. When the diode is in parallel with an insulated gate bipolar transistor (IGBT), its status will also be decided by the injection current as long as the drive signal is equal to zero. The switch state update comes after the value of the predictor or corrector is calculated.
The system modeling separates the switch’s status from the inductor or the capacitor. The circuit partitioning with the switch is shown in Figure 2, with the formation of a tow-port subsystem. In one time step, since the current flowing through the inductance or the voltage between the capacitance is constant, the connected capacitor is treated as the voltage source, and the inductance is treated as the current source. After obtaining the switch statutes from Table 1, the calculation of the unknown value [ V o u t , I i n ] is deduced from Equation (6).
V o u t I i n =   S s w i t c h 0 0 S s w i t c h V i n I o u t
From Table 1, the value of Iswitch decides the switch statutes and acts as the guard function describing the time-varying feature in one bridge. The value of Iswitch is calculated using Equation (5). Three different derivative functions can be used to describe the time-varying topology in both DCM and CCM. A basic model is shown in Equation (7).
d x d t = f 1 t n , x n i f   g t n 1 , x n 1 0 f 2 t n , x n i f   g t n 1 , x n 1 = 0
where g t n 1 , x n 1 is the guard function, f 1 t n , x n is the derivative function of CCM, and f 2 t n , x n are the derivative functions of DCM. When the power electronic system translates from CCM statues to DCM statues, the zero-crossing function has to find the zero point t r meeting  g t r , x n 1 = 0 . To reduce the calculation burden in simulation, g t r , x n 1 = 0 can be approximated with a defined neighborhood  g t n 1 , x n 1 α . Thus, (3) can be rewritten as
d x d t = f 1 t n , x n i f   g t n 1 , x n 1 > α f 2 t n , x n i f   g t n 1 , x n 1 α
Combining (8) and (5), the calculation of the corrector x n and x t + h p are shown in Equations (9) and (10), respectively.
x n = x n 1 + h · f 1 t , x n p i f   I s w i t c h p n > α x n 1 + h · f 2 t , x n p i f   I s w i t c h p n α
x n + 1 p = x n 1 + 2 h · f 1 t , x n 1 i f   I s w i t c h n 1 > α x n 1 + 2 h · f 2 t , x n 1 i f   I s w i t c h n 1 α
Once I s w i t c h p n α is met, the next step is to obtain the numerical value of f 2 t n , x n . However, f 2 t n , x n and f 1 t n , x n are different. Different iteration equations will be involved, which will require more hardware resources.
For a bridge with two switches, f 1 t n , x n indicates that the switch status of S 1 , S 2 is O N , O F F or [ O F F , O N ], f 2 t n , x n is the DCM indicating that the switch S 1 , S 2 is O F F , O F F . With the defined boundary α , here, we define the point translating from f 1 t n , x n to f 2 t n , x n .
  • Condition I: g p t n , x n > α & & g t n 1 , x n 1 < α ;
  • Condition II: g p t n , x n < α & & g t n 1 , x n 1 > α .
When switch S 1 , S 2 is O F F , O F F , I s w i t c h 0 . Here, the value of I s w i t c h during the DCM conditions is limited to a small value β that can be neglected.
f l a g ( t n ) = 1 C o n d i t i o n   I 2 C o n d i t i o n   I I 0 e l s e
x n = β f l a g t n = 1 β f l a g t n = 2 β f l a g t n 1 = 1 β f l a g t n 1 = 2
x n + 1 p = β f l a g t n = 1 β f l a g t n = 2 β f l a g t n 1 = 1 β f l a g t n 1 = 2
At the time point t n , (12) and (13) are the calculations dealing with the predictor and the corrector. The function f l a g ( t n ) is used to monitor whether the system is in a chattering situation. Once chattering is detected, the value x n and x n + 1 p in the chattering zone will be assigned to β or −β using (16) and (17). Thus, in the next simulation step t n + 1 , since the sign of x n and x n + 1 p are different, and the DCM will be recognized as the point crossing zero. Therefore, the following point will continue to be recognized as the DCM points in both the predictor and the corrector, but the value of x n + 1 and x n + 2 p are set to −β and β, which are negligible.

2.3. FPGA Implementation Structure

Figure 3 shows the FPGA implementation structure using the proposed zero-crossing and predictor–corrector methods.
As shown in Figure 3, the system can be divided into independent subsystems by using a current source, voltage source, and two ports as a division. In each predictor calculation or corrector calculation process, the switch calculation and circuit solving have a serial connection relationship. At the time step t n , the solver first uses Equation (5) to calculate x ^ ( n + 2 ) and x ( n ) after sampling the information of gate signals. x ^ ( n + 2 h ) is a value after two steps, and x ( n + h ) is the calculated system status. Because each variable in x ^ ( n + 2 ) and x ( n ) is independent, x ^ ( n + 2 ) and x ( n ) can be calculated at the same time. Compared with the forward Euler Method, the order in the parallel structure is improved to 2 [12,24].
These two values are further used to decide the system’s status in CCM or DCM using Equations (11)–(13). Furthermore, in Equations (11)–(13), the FPGA resources utilized in the zero-crossing process only involve the comparison unit, and no math calculation is used. As a result, the calculation speed is almost unaffected by the zero-crossing unit insertion.

3. System Model and Experimental Results

In this section, we show the effectiveness and the general results of the proposed method. The other case study of a five-level MMC is shown in Figure 4. Figure 4 divides the system into two parts: N1 and N2. N1 is the subsystem with inductance and capacitance. The N2 subsystem consists of the switches, which are made of a large number of power electronic submodules (SMs). The related simulation parameters are shown in Table 2.

3.1. Real-Time Simulation with ISF Model

The switch device of the SM in the upper bridge is shown in Figure 5a. When S1 and S2 operate in the dead zone, the switch function can be obtained with (14).
S 1 p _ j = 0 i f   I i n < 0 1 i f   I i n 0     S 2 p _ j = 1 i f   I i n < 0 0 i f   I i n 0
where p = A 1 ,   B 1 ,   a n d   C 1 , which represent phases A, B, and C, respectively, and j is the number of SM in the upper bridge.
The output nodal voltage V o u t and the output current I o u t  can be calculated with (15).
V o u t = S 1 p _ j · V c _ p _ j I o u t _ p _ j = S 2 p _ j · I i n + S 1 p _ j · I i n I c _ p _ j = I i n ·   S 1 p _ j
Thus, the current and voltage relationship in the upper bridge can be calculated with (16)
V p 1 _ N = V d c 1 j = 1 4 V o u t _ p _ j I i n _ p _ j = S 2 · I i n _ p _ j S 1 j · I i n _ p _ j I i n _ p _ j = I o u t _ p _ ( j 1 )
where I o u t _ 0 = i L p 1 .
With the same method, the current and voltage relationship in the lower bridge (A2, B2, C2) can be calculated with (17)–(19).
S 1 q _ j = 0 i f   I i n < 0 1 i f   I i n 0     S 2 q _ j = 1 i f   I i n < 0 0 i f   I i n 0
V o u t _ q _ j = S 1 q _ j · V c _ q _ j I o u t _ q _ j = S 2 q _ j · I i n + S 1 q _ j · I i n I c _ q _ j = I i n ·   S 1 q _ j
V p 2 _ N = V d c 2 + j = 1 4 V o u t _ p _ j I o u t _ p _ j = S 2 · I i n _ p _ j + S 1 j · I i n _ p _ j I i n _ p _ j = I o u t _ p _ ( j 1 )
where q = A 2 ,   B 2 ,   a n d   C 2 , which represent phases A, B, and C, respectively, j is the number of SM in the upper bridge, and I o u t _ 0 = i L p 2 .
After obtaining V p 1 _ N and V p 2 _ N , the voltage relationship inside the N1 subsystem can be expressed with KVL as shown in (20),
V p 1 _ N V L p 1 = V p N = V p O V N O V p 2 _ N V L p 2 = V p N = V p O V N O V N O = ( V A N + V B N + V C N ) / 3 V p O = R l i p
Using (20), V N O ,   V L p 1 ,  and  V L p 2 can be obtained. Then, the status of the inductances can be calculated with (21):
L p 1 d i p 1 d t = V L p 1 L p 2 d i p 2 d t = V L p 2
Its discretization formulation with the predictor–corrector method can be expressed as (22),
i p 1 n + 2 p = i p 1 n + 2 h L s p V L p 1 n i p 1 n + 1 = i p 1 n + h L s p V L p 1 n + 1 p i p 2 n + 2 p = i p 1 n + 2 h L s p V L p 2 n i p 2 n + 1 = i p 1 n + h L s p V L p 2 n + 1 p
For the capacitance in each SM, the mathematical model can be described as (23):
C d U c d t = I c _ p _ j
Its discretization formulation with the predictor–corrector method can be expressed as (24),
u c n + 2 p = u c n + 2 h C · I c _ p _ j ( n ) u c n + 1 = u c n + h L s i I c _ p _ j ( n + 1 ) p
With an FPGA Kintex-7 XC7K410T embedded in the National Instrument (NI, Austin, TX, USA) PXIe-7975R FlexRIO PX, the model is implemented in the Express FPGA module with the structure shown in Figure 6.
The model is implemented using the NI platform, as shown in Figure 6. The FlexRIO PXI platform contains a Kintex-7 XC7K410T FPGA. The single-cycle time loop (SCTL) allows all functions inside the loop to execute within a single tick [25,26]. The implementation of FPGAs has four sequential steps. Firstly, based on (14) and (17), the driving signals and the predictor values i p l i 1 ( n + 1 ) and i p l i 2 ( n + 1 )  determine the switch status in the correction process. Meanwhile, the driving signals and the corrector values  i l i 1 ( n + 1 ) and i l i 2 ( n + 1 ) determine the switch status in the prediction calculation process. Secondly, we substitute the corresponding switch function into (15)–(16) and (18)–(19), so the nodal voltages and the branch currents are calculated. Then, the port voltage and current are updated using (20). Finally, (22) and (24) are computed in parallel.
After building on the FPGAs, the hardware resource utilization is shown in Figure 7, which compares the P-C method with the zero-crossing method, the P-C method without the zero-crossing method, and the forward Euler method. Although the P-C method (with/without the zero-crossing unit) has the same calculation speed (−100 ns) as the forward Euler method, the resource of the DSP48s is doubled in the P-C method. Furthermore, it can be noted that the zero-crossing process only increases by 0.5% in the Slice L.U.T.s and 0.3% in the total slices. In the meantime, the zero-crossing unit does not cause an increase in the time step or the DSP48s utilization.
With a simulation step of 100 ns, the simulation results of i L a 1 are shown in Figure 8. Due to a long dead time of 30 µs in the PWM pulses, the current i L a 1 is not continuous. In the zero-crossing setup, the value of β is 1 × 10−7, and the value of α is 2 × 10−7. Figure 8a compares the Simulink results with the proposed zero-crossing method. In the Simulink results, when the current is close to zero and the MMC is in the blocked mode, the current is calculated to a value that relates to the open voltage of the IGBT device. However, the calculation of this current is a complex process. The Simulink model utilizes iteration and zero-crossing methods to seek this point. This is an offline process requiring much calculation time to finish. For a real-time simulation, the calculation burden is too heavy to seek the point crossing zero.
Figure 8b shows the results of the method without using the zero-crossing method. Although the system can work normally, high oscillation exists when i L a 1 is close to zero, which causes a potential unstable problem in the real-time simulation. Furthermore, the high current oscillation also causes the blocked model’s virtual losses. However, in the proposed MMC model, when the bridge is in the blocked mode and the current is around zero, the proposed method can regulate the current oscillation with −1 × 10−7 and 1 × 10−7. It can also achieve a real-time simulation step of 100 nanoseconds. The proposed zero-crossing method can reduce the error and improve the accuracy when the current is around zero.

3.2. Real-Time Simulation with the Ron/Roff Model

In the Ron/Roff model, the current flowing through the switch is calculated using (25) with the value of the current I i n .
I c _ p _ j = I i n ·   S 1 p _ j
where the status of S 1 p _ j is updated by the direction of the current I i n . If I i n < 0 , S 1 p _ j = 0 ; otherwise, S 1 p _ j = 1 .
As shown in Figure 9, based on Thevetin’s theorem, the SM is substituted with a voltage source V e q in a series connection with a resistance  R e q . The value of V e q and R e q can be calculated with (29).
R e q _ p _ j = ( h / C + R s 1 ) · R s 2 R s 1 + R s 2 + ( h / C ) V e q _ p _ j = U c R s 2 R s 1 + R s 2 + ( h / C )
where p = A ,   B ,   a n d   C , which represent phases A, B, and C, respectively, and j is the number of SM in the upper bridge.
With R e q _ p _ j and V e q _ p _ j , the equivalent voltage V e q u p p e r and V e q l o w e r in the upper phase and the equivalent resistance R e q u p p e r and R e q l o w e r can be calculated with (27).
V e q _ p u p p e r = j = 1 4 V e q _ _ p _ j R e q _ p l o w e r = j = 1 4 R e q _ p _ j V e q _ p l o w e r = j = 1 4 V e q _ p _ j R e q _ p l o w e r = j = 1 4 R e q _ p _ j
The current and voltage relationship in the upper and lower bridges can be calculated with (27) and (28).
V p 1 _ N = V d c 1 V e q _ p u p p e r R e q _ p u p p e r · I L p 1 I o u t _ p _ j = S 2 · I i n _ p _ j S 1 j · I i n _ p _ j I i n _ p _ j = I o u t _ p _ ( j 1 ) I o u t _ p _ 0 = i L p 1
V p 2 _ N = V d c 2 + V e q _ p l o w e r + R e q _ p l o w e r · I L p 2 I o u t _ p _ j = S 2 · I i n _ p _ j + S 1 j · I i n _ p _ j I i n _ p _ j = I o u t _ p _ ( j 1 ) I o u t _ p _ 0 = i L p 2
After obtaining V p 1 _ N and V p 2 _ N , (25)–(27) can be further used to calculate the voltage/current status of the system. The implementation structure on the FPGA board using LabVIEW is also based on Figure 10, where the SM update unit is calculated with (28) and (29). The final FPGA resource utilization is shown in Figure 10.
Compared with Figure 7 and Figure 10, the ISF and Ron/Roff models can achieve a calculation speed of 100 nanoseconds. And, because the calculation of (26) in the Ron/Roff model requires more math operations, the Ron/Roff model occupies more FPGA resources than the ISF model.
Figure 11 shows the simulation results of the current i L a 1 in the Ron/Roff model. In Figure 11a, the Simulink results reference the proposed zero-crossing method. The proposed method can regulate the current oscillation with −1 × 10−7 and 1 × 10−7 when the current is around zero. Compared with the P-C method without the zero-crossing method (Figure 11b), the proposed zero-crossing method increases the stability and the accuracy of the whole system simulation.

4. Conclusions

This paper proposes an efficient real-time FPGA model of MMC to give a full representation of transient with a time step of 100 ns. Performance evaluations on different switch models (ISF and Ron/Roff models) using a five-level MMC are carried out. Compared with the traditional FPGA solver, the proposed solving structure keeps the same speed as the FE method, and the total calculation time is only 100 ns under the STCL of the LabVIEW FPGA. When the PWM has a dead-time zone, and the switch operates in the blocked mode, the proposed method can regulate the current to −1 × 10−7 and 1 × 10−7. Furthermore, the proposed method has a strong generality, which can be used in the ISF and Ron/Roff models.
The proposed solver for the power electronic system contains a parallel ODE-solving structure and the zero-crossing method. The solver can enhance the robustness by allowing the simulation of DCM and CCM with the same model. Implementing the FPGA will further reduce the simulation step under 100 ns with the detailed representation of the MMC electromagnetically transient. The ultra-fast speed advantage also allows for predicting the system behavior as fast as possible. Thus, it can be further used in the digital twin setup [27] and the model predictive control.

Author Contributions

Conceptualization, methodology, and writing—original draft preparation, W.G.; software, validation, formal analysis, investigation, resources, and data curation, C.L.; supervision, M.W.; project administration and funding acquisition, X.Z. All authors have read and agreed to the published version of the manuscript.

Funding

This work was supported by the Key Laboratory of HVDC, Electric Power Research Institute China Southern Grid, Grant agreement No: SEPRI-K223001.

Data Availability Statement

The data presented in this study are available on request from the corresponding author. The data are not publicly available due to unpublished work in process.

Conflicts of Interest

The authors declare no conflicts of interest.

References

  1. Bai, H.; Liu, C.; Breaz, E.; Al-Haddad, K.; Gao, F. A review on the device-level real-time simulation of power electronic converters: Motivations for improving performance. IEEE Ind. Electron. Mag. 2020, 15, 12–27. [Google Scholar] [CrossRef]
  2. Bélanger, J.; Venne, P.; Paquin, J.-N. The what, where and why of real-time simulation. Planet Rt 2010, 1, 25–29. [Google Scholar]
  3. Dufour, C.; Ould Bachir, T.; Grégoire, L.A.; Bélanger, J. Real-time simulation of power electronic systems and devices. In Dynamics and Control of Switched Electronic Systems: Advanced Perspectives for Modeling, Simulation and Control of Power Converters; Springer: London, UK, 2012; pp. 451–487. [Google Scholar]
  4. Kumar, P.; Kashyap, Y.; Castelino, R.V.; Karthikeyan, A.; Sharma, K.M.; Karmakar, D.; Kosmopoulos, P. Laboratory-Scale Airborne Wind Energy Conversion Emulator Using OPAL-RT Real-Time Simulator. Energies 2023, 16, 6804. [Google Scholar] [CrossRef]
  5. Castellini, L.; Gallorini, F.; Alessandri, G.; Alves, E.F.; Montoya, D.; Mudigonda, B.; Tedeschi, E. Comparison of Offline, Real-Time Models and Hardware-in-the-Loop Test Results of a Power Take-Off for Wave Energy Applications. J. Mar. Sci. Eng. 2022, 10, 1744. [Google Scholar] [CrossRef]
  6. Maguire, T.; Warkentin, B.; Chen, Y.; Hasler, J. Efficient techniques for real time simulation of MMC systems. In Proceedings of the International Conference on Power Systems Transients (IPST), Vancouver, BC, Canada, 18–20 July 2013; pp. 1–7. [Google Scholar]
  7. Ashourloo, M.; Mirzahosseini, R.; Iravani, R. Enhanced model and real-time simulation architecture for modular multilevel converter. IEEE Trans. Power Deliv. 2017, 33, 466–476. [Google Scholar] [CrossRef]
  8. Mirzahosseini, R.; Iravani, R. Small time-step FPGA-based real-time simulation of power systems including multiple converters. IEEE Trans. Power Deliv. 2019, 34, 2089–2099. [Google Scholar] [CrossRef]
  9. Estrada, L.; Vázquez, N.; Vaquero, J.; de Castro, Á.; Arau, J. Real-Time Hardware in the Loop Simulation Methodology for Power Converters Using LabVIEW FPGA. Energies 2020, 13, 373. [Google Scholar] [CrossRef]
  10. Koutroulis, E.; Kalaitzakis, K.; Tzitzilonis, V. Development of an FPGA-based system for real-time simulation of photovoltaic modules. Microelectron. J. 2009, 40, 1094–1102. [Google Scholar] [CrossRef]
  11. Benigni, A.; Monti, A. A parallel approach to real-time simulation of power electronics systems. IEEE Trans. Power Electron. 2014, 30, 5192–5206. [Google Scholar] [CrossRef]
  12. Liu, C.; Ma, R.; Bai, H.; Gechter, F.; Gao, F. A new approach for FPGA-based real-time simulation of power electronic system with no simulation latency in subsystem partitioning. Int. J. Electr. Power Energy Syst. 2018, 99, 650–658. [Google Scholar] [CrossRef]
  13. Milton, M.; Benigni, A. Latency insertion method based real-time simulation of power electronic systems. IEEE Trans. Power Electron. 2017, 33, 7166–7177. [Google Scholar] [CrossRef]
  14. Yang, G.; Li, Y.; Hao, Z.; Chen, Z.; He, P.; Zhang, J. Multi-Rate Parallel Real-Time Simulation Method for Doubly Fed Wind Power Systems Based on FPGA–CPU. Machines 2022, 10, 1073. [Google Scholar] [CrossRef]
  15. Ali, S.; Badar, J.; Akhter, F.; Bukhari, S.S.H.; Ro, J.-S. Real-Time Controller Design Test Bench for High-Voltage Direct Current Modular Multilevel Converters. Appl. Sci. 2020, 10, 6004. [Google Scholar] [CrossRef]
  16. Sang, Z.; Li, S.; Huang, Y.; Gao, X.; Qiao, R. Indirect Matrix Converter Hardware-in-the-Loop Semi-Physical Simulation Based on Latency-Free Decoupling. Electronics 2023, 12, 4802. [Google Scholar] [CrossRef]
  17. Alsarayreh, S.; Sütő, Z. Optimal Selection of Switch Model Parameters for ADC-Based Power Converters. Energies 2024, 17, 56. [Google Scholar] [CrossRef]
  18. Bai, H.; Luo, H.; Liu, C.; Paire, D.; Gao, F. A Device-Level Transient Modeling Approach for the FPGA-Based Real-Time Simulation of Power Converters. IEEE Trans. Power Electron. 2020, 35, 1282–1292. [Google Scholar] [CrossRef]
  19. Matar, M.; Iravani, R. Massively parallel implementation of AC machine models for FPGA-based real-time simulation of electromagnetic transients. IEEE Trans. Power Deliv. 2010, 26, 830–840. [Google Scholar] [CrossRef]
  20. Saad, H.; Dufour, C.; Mahseredjian, J.; Dennetière, S.; Nguefeu, S. Real time simulation of MMCs using the state-space nodal approach. In Proceedings of the IPST, Vancouver, BC, Canada, 18–20 July 2013; pp. 18–20. [Google Scholar]
  21. Matar, M.; Iravani, R. FPGA implementation of the power electronic converter model for real-time simulation of electromagnetic transients. IEEE Trans. Power Deliv. 2009, 25, 852–860. [Google Scholar] [CrossRef]
  22. Soomro, J.B.B.; Akhtar, F.; Hussain, R.; Ansari, J.A.; Munir, H.M. A detailed review of MMC circuit topologies and modelling issues. Int. Trans. Electr. Energy Syst. 2022, 2022, 8734010. [Google Scholar]
  23. Dufour, C.; Jalili-Marandi, V.; Bélanger, J.; Snider, L. Power system simulation algorithms for parallel computer architectures. In Proceedings of the 2012 IEEE Power and Energy Society General Meeting, San Diego, CA, USA, 22–26 July 2012; pp. 1–6. [Google Scholar]
  24. Li, Z.; Xu, J.; Wang, K.; Li, G.; Wu, P. A Discrete Small-Step Synthesis Real-Time Simulation Method for Power Converters. IEEE Trans. Ind. Electron. 2022, 69, 3667–3676. [Google Scholar] [CrossRef]
  25. Tormo, D.; Vidal-Albalate, R.; Idkhajine, L.; Monmasson, E.; Blasco-Gimenez, R. Embedded Real-Time Simulator for Sensorless Control of Modular Multi-Level Converters. Electronics 2022, 11, 719. [Google Scholar] [CrossRef]
  26. Single-Cycle Timed Loop FAQ for the LabVIEW FPGA Module. Available online: https://knowledge.ni.com/KnowledgeArticleDetails?id=kA00Z000000P8sWSAS (accessed on 6 November 2023).
  27. Dong, X.; Huang, J.; Luo, N.; Hu, W.; Lei, Z. Design and Implementation of Digital Twin Diesel Generator Systems. Energies 2023, 16, 6422. [Google Scholar] [CrossRef]
Figure 1. The parallel solving structures.
Figure 1. The parallel solving structures.
Energies 17 00591 g001
Figure 2. Circuit partitioning with switch.
Figure 2. Circuit partitioning with switch.
Energies 17 00591 g002
Figure 3. Power electronic simulation with parallel calculation.
Figure 3. Power electronic simulation with parallel calculation.
Energies 17 00591 g003
Figure 4. Topology of a five-level MMC.
Figure 4. Topology of a five-level MMC.
Energies 17 00591 g004
Figure 5. The system partitioning. (a) SM is in the upper bridge; (b) SM is in the lower bridge; and (c) the N1 and N2 subsystems.
Figure 5. The system partitioning. (a) SM is in the upper bridge; (b) SM is in the lower bridge; and (c) the N1 and N2 subsystems.
Energies 17 00591 g005
Figure 6. Implementation on LabVIEW FPGA.
Figure 6. Implementation on LabVIEW FPGA.
Energies 17 00591 g006
Figure 7. The hardware resource utilization.
Figure 7. The hardware resource utilization.
Energies 17 00591 g007
Figure 8. Current i L a 1 in the ISF model: (a) comparison with the Simulink results and (b) comparison with the non-zero-crossing method.
Figure 8. Current i L a 1 in the ISF model: (a) comparison with the Simulink results and (b) comparison with the non-zero-crossing method.
Energies 17 00591 g008
Figure 9. The system partitioning: (a) SM is in the upper bridge; (b) SM is in the lower bridge; and (c) the N1 subsystem and N2 subsystem.
Figure 9. The system partitioning: (a) SM is in the upper bridge; (b) SM is in the lower bridge; and (c) the N1 subsystem and N2 subsystem.
Energies 17 00591 g009
Figure 10. The hardware resource utilization.
Figure 10. The hardware resource utilization.
Energies 17 00591 g010
Figure 11. Current i L a 1 in the Ron/Roff model: (a) comparison with the Simulink results and (b) comparison with the non-zero-crossing method.
Figure 11. Current i L a 1 in the Ron/Roff model: (a) comparison with the Simulink results and (b) comparison with the non-zero-crossing method.
Energies 17 00591 g011
Table 1. Switch judgment.
Table 1. Switch judgment.
Subsystem
Type
I s w i t c h   >   0 I s w i t c h   <   0 Gate Signal
Energies 17 00591 i001ONOFF------
Energies 17 00591 i002OFFONS = 0
ONOFFS = 1
Energies 17 00591 i003S1 ONS2 ONS1 = 0 S2 = 0
S1 ONS1 ONS1 = 1 S2 = 0
S2 ONS2 ONS1 = 0 S2 = 1
------------S1 = 1 S2 = 1
Table 2. Simulation parameters.
Table 2. Simulation parameters.
SymbolDescriptionValue
h Simulation step100 ns
U r e f Single-phase sinusoidal reference signal1 V, 50 Hz
f c Frequency of carrier waveforms 3 kHz
T T D Turn-on dead-time30 µs
V d c 1 Voltage source1000 V
V d c 2 Voltage source−1000 V
R o n Switch turn-on resistance0.001 ohm
R o f f Switch turn-off resistance1000 ohm
C Capacitance30 × 10−4 F
L a 1 , L b 1  and  L c 1 Capacitance2 × 10−4 H
L a 2 , L b 2  and  L c 2 Inductance2 × 10−4 H
R L Resistance10 ohm
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Share and Cite

MDPI and ACS Style

Gong, W.; Liu, C.; Wang, M.; Zhao, X. Efficient Prototyping of a Field-Programmable Gate Array-Based Real-Time Model of a Modular Multilevel Converter. Energies 2024, 17, 591. https://doi.org/10.3390/en17030591

AMA Style

Gong W, Liu C, Wang M, Zhao X. Efficient Prototyping of a Field-Programmable Gate Array-Based Real-Time Model of a Modular Multilevel Converter. Energies. 2024; 17(3):591. https://doi.org/10.3390/en17030591

Chicago/Turabian Style

Gong, Wenming, Chaofan Liu, Mingdong Wang, and Xiaobing Zhao. 2024. "Efficient Prototyping of a Field-Programmable Gate Array-Based Real-Time Model of a Modular Multilevel Converter" Energies 17, no. 3: 591. https://doi.org/10.3390/en17030591

APA Style

Gong, W., Liu, C., Wang, M., & Zhao, X. (2024). Efficient Prototyping of a Field-Programmable Gate Array-Based Real-Time Model of a Modular Multilevel Converter. Energies, 17(3), 591. https://doi.org/10.3390/en17030591

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop