code generation: difference between grt and ert model

Hi all, I'm generating a target for embedded hardware. And I need the most efficient code and take up little memory.
  • What is the difference between a model generated with grt.tlc or ert.tlc?
  • In order to generate embedded code is enough to put these two lines in my entry tlc?
%assign CodeFormat = "Embedded-C"
rtwgensettings.DerivedFrom = 'ert.tlc';
Thank you,

 採用された回答

Titus Edelhofer
Titus Edelhofer 2011 年 11 月 10 日

2 投票

Hi,
for the first question: grt uses a larger memory model and is a target for generic use (as the name says) mostly on the host PC. ert (embedded real-time target) is using a smaller memory model, and optimizes better for speed and memory. To generate code using ert you might just choose the ert.tlc on the Simulink Parameters page.
Titus

1 件のコメント

Kaustubha Govind
Kaustubha Govind 2011 年 11 月 10 日
編集済み: Rena Berman 2025 年 6 月 16 日
To add to Titus' answer, there is some more information about how ert.tlc (Embedded Coder) extends the capabilities of grt.tlc (Simulink Coder): http://www.mathworks.com/help/toolbox/ecoder/gs/bs5y9rk.html
Also, if you are writing your own custom target (or entry TLC as you called it), yes, I believe what you described is the right way to do it. In fact, the description in the documentation for custom target development does use ert.tlc: http://www.mathworks.com/help/toolbox/rtw/ug/bse3b2z.html

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

その他の回答 (0 件)

カテゴリ

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

質問済み:

2011 年 11 月 10 日

編集済み:

2025 年 6 月 16 日

Community Treasure Hunt

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

Start Hunting!

Translated by