Plexim RT Box TSP 2.0.5 User Manual Download Page 5

Modular Multilevel Converter

and therefore fidelity of the real-time simulation is improved.

2.2 Controls

The demo model is operated in open-loop. The PWM generation is executed in the same box and
routed to the digital output be means of the PWM Out block. Those PWM signals are then feed back
to the digital inputs by using a physical loop-back cable. The PWM signals are then brought into the
real-time simulation with the PWM Capture block.

3 Simulation

This model can run both in offline mode on a computer or in real-time mode on the PLECS RT Box.

Please follow the instructions below to run in real-time mode on an RT Box:

• Connect the Digital In interface to the Digital Out interface of the RT Box, i.e. by using a 37 pin

Sub-D cable.

• From the

System

tab of the

Coder options...

window, select the “Plant” and go to the

Scheduling

tab. Chose either

single-tasking

or

multi-tasking

as the tasking mode and accept your choice.

Please note that multi-tasking mode is only available for RT Box 2 and RT Box 3.

• Return to the

System

tab, select the “Plant” and

Build

it onto the RT Box.

• Once the model is uploaded, from the

External Mode

tab,

Connect

to the RT Box and

Activate

autotriggering

.

During the real-time operation under

External Mode

the measurements can be observed using the

PLECS Scope “Measurements”. The arm voltage and AC grid currents are shown in Fig. 5.

Arm Voltage

Grid current

vo

lt

ag

(V

)

-400

-200

0

200

400

× 1e-2

0.0

0.5

1.0

1.5

2.0

2.5

3.0

3.5

cu

rr

en

(A

)

-1000

0

1000

Figure 5: Real-time measurements obtained on the RT Box in multi-tasking mode

4 Conclusion

This RT Box demo model demonstrates a grid-connected MMC inverter under open-loop control. The
demo model can run both in single-tasking mode on one CPU core of the RT Box 1, 2 or 3, or in multi-
tasking mode on three CPU cores of the RT Box 2 or 3. Multi-tasking has the benefit that the average
execution time can be reduced considerably.

www.plexim.com

4

Summary of Contents for RT Box TSP 2.0.5

Page 1: ...nse Get the latest RT Box Target Support Package Check the PLECS and RT Box documentation RT Box DEMO MODEL Modular Multilevel Converter Multi tasking simulation of a grid connected modular multilevel con verter on the RT Box 2 3 Last updated in RT Box TSP 2 0 5 ...

Page 2: ...ngle Tasking Average Execution Time Multi Tasking 6 µs 3 7 µs 2 0 µs 1 1 Requirements To run this demo model the following items are needed available at www plexim com One PLECS RT Box 1 2 or 3 and one PLECS Coder license One 37 pin Sub D cable to connect the digital I Os of the box front to front The RT Box Target Support Library Follow the step by step instructions on configuring PLECS and the R...

Page 3: ... explained in the tutorial Implicit Model Vectorization available in the tutorials section of the Plexim website Swa PWM Capture PWMa PWM Out ma Qa 1 Qa 4 Qa 2 Qa 3 U I Qa 2 Qa 3 Qa 1 Qa 4 Swb PWM Capture PWMb PWM Out mb Qb 1 Qb 4 Qb 2 Qb 3 Qb 2 Qb 3 Qb 1 Qb 4 Swc PWM Capture PWMc PWM Out mc Qc 1 Qc 4 Qc 2 Qc 3 Qc 2 Qc 3 Qc 1 Qc 4 U I U I U I U I U I U I U I U I U I U I U I U I U I U I PWMa1 PWM O...

Page 4: ...ysical model has to be split at strategic locations by using a coupling circuit To do so a controlled current source is placed in one part of the model and a con trolled voltage source in the other part Both sources are controlled by the respectively measured volt age current state variables from the other part of the model To avoid state source dependence one measured signal has to be delayed by ...

Page 5: ...asking or multi tasking as the tasking mode and accept your choice Please note that multi tasking mode is only available for RT Box 2 and RT Box 3 Return to the System tab select the Plant and Build it onto the RT Box Once the model is uploaded from the External Mode tab Connect to the RT Box and Activate autotriggering During the real time operation under External Mode the measurements can be obs...

Page 6: ...cribed in this document is furnished under a license agreement The software may be used or copied only under the terms of the license agreement No part of this manual may be photocopied or reproduced in any form without prior written consent from Plexim GmbH PLECS is a registered trademark of Plexim GmbH MATLAB Simulink and Simulink Coder are regis tered trademarks of The MathWorks Inc Other produ...

Reviews: