Generating a loop in VHDL using Simulink HDL Coder

回答 (2 件)

Tim McBrayer
Tim McBrayer 2011 年 4 月 11 日

0 投票

While there are certain constructs in Simulink where Simulink HDL Coder will generate a for-generate loop in VHDL, it is best not to be overly concerned about the style of code generation. There is no recipe for creating a for-generate loop.
Andrew
Andrew 2014 年 9 月 24 日

0 投票

"There is a "For Iterator Subsystem" block to do for-loop in Simulink. But your task doesn't sound like it. You might want to consider the "Repeating Sequence" block from Simulink>Source library." [ loop-in-simulink ]
I don't think this solution will work for VHDL, but I may try it soon. Will this feature be added in newer simulink/HDL coder releases? I need to instantiate a block 127 times so I am also interested in this kind of feature.

1 件のコメント

Tim McBrayer
Tim McBrayer 2014 年 9 月 24 日
Neither of the mentioned Simulink constructs are currently supported by HDL Coder. They may exist in the testbench portion of the design, but cannot have HDL Code generated for them.

サインインしてコメントする。

カテゴリ

ヘルプ センター および File ExchangeCode Generation についてさらに検索

製品

タグ

タグが未入力です。

質問済み:

2011 年 4 月 6 日

コメント済み:

2014 年 9 月 24 日

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by