Error when generating code from model with S-Function Builder block

6 次查看(过去 30 天)
There is a model (2022b) containing custom code, implemented as S-Function Builder block. The block has one output of "bus" type. When i trying to generate code (system target file : ert.tlc, generate code only, toolchain: MSVS 2019), an error appears.
Cannot initialize the width of data type work vector 1 of 'Test_IO_22/S-Function Builder'. The data type work vector width is set to dynamically sized (-1). Initialize the data type work vector width in mdlInitializeSizes or mdlSetWorkWidths
The same example created in 2019b generates code without problems.

回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Simulink Coder 的更多信息

产品


版本

R2022b

Community Treasure Hunt

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

Start Hunting!

Translated by