MATLAB Answers

0

How to "activate" or "deativate" 'to Workspace' simlunk block from m-code?

Asked by Hugo Mendonça on 18 Jul 2014
Latest activity Commented on by Hugo Mendonça on 18 Jul 2014
Hi, folks!
I am just wondering if there is any way to activate or deactivate the Simulink block 'to Worspace' from m-code.
Being clearer, imagine a system has: out1, out2, ..., outN outputs and before starting simulation I must define which one I want to see in workspace indeed without changing the simulink system.
Thanks in advance!

  0 Comments

Sign in to comment.

1 Answer

Answer by Azzi Abdelmalek
on 18 Jul 2014
 Accepted Answer

You have N output given by N to worksapce blocks, then you can display the output you want, What is the problem with that?

  1 Comment

The system has N 'to workspace' blocks for all possible outputs. However, depending on the simulation, it would be satisfactory to define which outputs are desired to be exported to free memory (this is an useful trick when it is a long simulation). So, the idea is to select which 'to workspace' will be exported, without changing the blocks in the system.
Thanks for your answer! Cheers!

Sign in to comment.