How to solve "unsupported unbounded loop structure" error when generate hdl code from stateflow
2 views (last 30 days)
Show older comments
The error information is :
Found an unsupported unbounded loop structure. This loop may be user
written or automatically generated due to the use of specific vector
expressions or functions. For more information on unsupported loop
structures, please refer to the documentation.
I have encountered this problem once, and I followed this solution How can I work around unbounded loops when .... It worked!
But recently I encountered again. This time it differs from the previous. The error information doesn't give the error poistion such as "transmission xxx". I have checked, the stateflow doesn't have an loop condition contains two variables. So I think the problem is "automatically generated due to the use of specific vector expressions or functions".
I deleted something and generated again. By repeat this action, I targeted the error in a array inside a loop.
As the image show, when I delete the "mf_pool[mf_num]=MFT[i]", the error disappeared. After some further test, I found it is because the use of array in the left of "=".
Now, how can I solve problem? I don't found many information on the internet, neither does the matlab help doc. Any information is appreciate!
0 Comments
Answers (2)
Tim McBrayer
on 19 May 2014
How many times is your loop going to execute? If you can't answer that by examining the state chart (and you can't), then the loop is unbounded. Your conditional transition [MFT(i) > 0] is likely the problem one. Loops are turned into repeated sets of hardware; if the loop is unbounded, HDL Coder can't determine how many times to repeat the hardware.
See Also
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!