How to Synchronize CPU and CLA execution on C2000 MCU
Show older comments
I am designing a control algorithm with a strict 50-microsecond execution budget, triggered by ePWM+ADC. To meet this budget, I am offloading a portion of the computation to the CLA to run in parallel with the CPU.
Workflow:
- The main CPU task starts the CLA task once the input data is ready.
- The CPU continues with its own computations while the CLA runs in parallel.
- The CPU must then wait for the CLA task to finish to use its results.
Constraint: The CLA's end-of-task interrupt cannot be handled inside the 50 µs fast loop. It must be implemented as a top-level interrupt.
Question: What are the recommended synchronization methods in Simulink for the CPU to wait for a completion flag from the CLA's top-level interrupt? I need a mechanism that functions like a semaphore, allowing the CPU to efficiently wait for the CLA to complete before proceeding.
Thanks.
Accepted Answer
More Answers (0)
Categories
Find more on Deployment, Integration, and Supported Hardware 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!