Why does the code generated using the 'Build subsystem...' with Real-Time Workshop 5.1 (R13SP1) use the default step size instead of the specified step size?

The code generated using the 'Build subsystem...' with Real-Time Workshop 5.1 (R13SP1) uses the default step size instead of the specified step size.
The default step size is (Tstop - Tstart) / 50.
This problem only occurs if the solver is set to fixed-step, subsystem contains only continuous time blocks with inherited sample times, and the subsystem does not contain a continuous state.

 採用された回答

MathWorks Support Team
MathWorks Support Team 2009 年 6 月 27 日

0 投票

This bug has been fixed in Release 14 Service Pack 3 (R14SP3). For previous product releases, read below for any possible workarounds:
This is a bug in Real-Time Workshop 5.1 (R13SP1) in the way that subsystems are built with fixed-step solvers.
To work around this issue, try adding a 'dummy' discrete state to the model, or specify a discrete step size for all of the blocks. As an example of a dummy state, connect a Ground to a Unit-delay to a Terminator then set the sample time of the Unit Delay block.

その他の回答 (0 件)

カテゴリ

ヘルプ センター および File ExchangeDeployment, Integration, and Supported Hardware についてさらに検索

製品

リリース

R13SP1

Community Treasure Hunt

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

Start Hunting!

Translated by