Is the F280049C fast enough for closed loop inverter control?
Show older comments
TLDR:
- I want to build a 3-phase inverter with a voltage and current control loop and a switching frequency of 30 kHz
- I’m using MATLAB Simulink with the C2000 block set to build the control loop, but it takes over 60 μs to complete on the board, limiting me to ~15 kHz.
- Should the F280049C be fast enough for closed loop inverter control?
- Do I really need to run the inverter control loop for every switching cycle?
- Is building the control loop in Simulink slower than using CCS or PSIM?
- Should I look for a different chip, if so, any suggestions?
Hello everyone, I am building a 3-phase inverter with voltage and current control loops with a switching frequency of 30 kHz.
Thanks to the ePWM features of the F280049C I have no trouble realizing the switching speed, but from what I have seen in other inverter models I should also take voltage and current measurements and feed them through a control loop for every switching cycle.
I have configured one of the ePWMs to trigger the start of conversion of my current and voltage measurements (3 Voltage, 3 Current, 1 DC voltage) once per switching cycle, and the end of conversion of the last ADC then triggers an interrupt which executes the control loop and generates direct and quadrature values of the output voltage, which is then converter to abc values and used to feed the ePWM generators.
The control loop contains:
- an offset added to all measurements
- 2 abc to dq0 transformations (of current and voltage)
- 4 pi controllers (2 inside the current loop and 2 inside the voltage loop)
- Some other summing and product blocks
The system works fine in simulation, but when I use the C2000 block set package to generate code and program the board for real-time operation, the control loop takes over 60 μs to execute (the clock frequency is 100 MHz). So, if I want to complete the control loop once per switching cycle I am limited to around 15 kHz.
So, my questions are:
- Should I expect the control loop to take this long to execute, or are there some terrible inefficiencies in my design?
- Is building the control loop in Simulink slower than using CCS or PSIM?
- Should the F280049C be fast enough to realize a system like this, or should I look for a different chip?
- Do I really need to run the control loop for every switching cycle?
This is my first major design project, and I am new to the forum, so I appreciate any and all feedback on both the questions and/or how to improve my posts.
Thanks for your time!
Accepted Answer
More Answers (0)
Categories
Find more on C2000 Microcontroller Blockset in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!