There shouldn't be any issue in running a Simulink model with callback through app designer. Does your model work outside of app designer after introducing the callback? From the error message posted, it seems like 'initFcn' is causing the issue.
Init function with the App designer
9 次查看(过去 30 天)
显示 更早的评论
Good afternoon,
I am trying to run a simulink model from the app designer. Through a normal mfile the simulink model runs without issues. I put all my numbers now in an interface and a few lookup tables in a InitFcn. The problem is when I run the model through the app the following error appears
Error using matlab.ui.control.internal.controller.ComponentController/executeUserCallback (line 335)
Error while evaluating Button PrivateButtonPushedFcn.
Error using Q...../RunmodelButtonPushed (line 99)
Error evaluating 'InitFcn' callback of block_diagram 'quartercar_airspring_V11'.
Callback string is 'Data_read'
Caused by:
Error using Q......./RunmodelButtonPushed (line 99)
Matrix dimensions must agree.
Is there an issue when I have a callback initfcn in my simulink model when I use it through the app designer? I could not find anything about this on the internet or in the help section.
I would be greatful for help.
Kind regards
Berend
回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Simulink Environment Customization 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!