Using Simulink from .m file
Afficher commentaires plus anciens
I have my whole code written in a gigantic .m file. In a certain process I am doing in my code, I want to call this block (shown in picture) and give it "F" and "Ma" and take its outputs back from simulink to my code's workspace. I am struggling to do this correctly and the sim command page is poorly written to help me with this. Any help is appreciated.

6 commentaires
Paul
le 16 Jan 2023
Hi Ali,
Are the blocks for F and Ma both Constant blocks? If so, what is their respective "Constant value" fields? If not, what are those blocks?
Ali Almakhmari
le 16 Jan 2023
Modifié(e) : Ali Almakhmari
le 16 Jan 2023
Paul
le 16 Jan 2023
Yes, I understand what your're doing (I assume you have a good reason for doing step 3 in the .m file instead of in the simulation itself). To help you solve the problem, I'd need to know:
Are the blocks for F and Ma both Constant blocks? If so, what is their respective "Constant value" fields? If not, what are those blocks?
Ali Almakhmari
le 16 Jan 2023
I'm not asking about the values, I'm asking about the blocks themselves. Can you double click on each block and post a screenshot of the block parameters window that pops up for each? Image files can be uploaded using either the paperclip icon or the image icon (to the left of link icon) in the Insert menu.
Ali Almakhmari
le 17 Jan 2023
Réponse acceptée
Plus de réponses (0)
Catégories
En savoir plus sur Simulink Environment Customization dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
