How to import MATLAB code with GUI into the SIMULINK?
1 次查看(过去 30 天)
显示 更早的评论
Dears,
I have done a software in Matlab. It has many modules as m-file functions, with GUI created in GUIDE. The code imports some image files and does various processing on them.
Now, I'd like to make each module (m-file function that I wrote) as a simulink block, so that I will be able to drag-drop various modules depending on the input images.
My question is if I can simply import my m-files functions into the simulink and create Simulink blocks? Or do I need to re-write them and do lots of modifications?
So far, I tried to create a simulink model, discrete solver mode (fixed step), only one time step, when I put my code in the matlab function block of simulink, I get many errors, specifically Simulink generates error for the GUI files. such as: - "Simulink does not have enough information to determine output sizes for this block" (I guess because of the varargout and varargin).
- "Function handles in structures are not supported." ( for gui_State struct).
and other errors such as: "The function 'strcat' is not supported for standalone code generation."
Any help regarding moving the matlab m function codes intro Simulink, is highly appreciated.
(p.s. I am using Matlab 2014a)
0 个评论
回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Sources 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!