How can I profile a Simscape Electrical Model for C2000 MCU?
Show older comments
I have a simple buck converter model adapted to run on a C2000 (F28379D LaunchPad XL) using the C2000 MCU blockset, which just runs fine there. Now I want to see how much CPU time it consumes using the "Hardware Profiler" block and placing the model in a function-call subsystem. When I now try to compile the model, I get an error:
"Error:Goto/From connections cannot cross nonvirtual subsystem boundaries. The only exception is when a goto is connected to a state output port"
I've attached the model that throws the error.
How can I create a model using "powergui" that is suitable for profiling on the C2000 platform?
Many thanks in advance!
1 Comment
Raghava S N
on 3 Apr 2025
The issue seems to arise from the Goto/From blocks used in the "powergui" and "Buck Converter/Current Measurement" subsystems.
Please refer to these MATLAB Answers posts regarding the same issue-
- https://www.mathworks.com/matlabcentral/answers/2046170-goto-from-connections-cannot-cross-nonvirtual-subsystem-boundaries-the-only-exception-is-when-a-got
- https://www.mathworks.com/matlabcentral/answers/39443-goto-from-connections-cannot-cross-nonvirtual-subsystem-boundaries-the-only-exception-is-when-a-got#:~:text=Use%20normal%20signals%20instead%20to%20exist%20the%20triggered%20subsystem.
There are a few possible solutions you may choose to employ-
- Use normal signals to exit the "powergui" block
- Use global Data Store Read and Write - https://www.mathworks.com/help/simulink/slref/datastorewrite.html, https://www.mathworks.com/help/simulink/slref/datastoreread.html
Hope this helps.
Regards.
Accepted Answer
More Answers (0)
Categories
Find more on Electrical Sensors 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!