Simulink and MATLAB - When to use workspace variable vs inport / outport

I am new to using Simulink and am creating some models / libraries that have approximately five inputs and five outputs. As far as I can tell, I can read the variable from the workspace and write it to the workspace in my library, or I can use inports and outports to do the same.

Is one method better than the other? I assume that each has its own advantages and disadvantages, but I have not found them yet.

+3
source share
1 answer

, script m . inport/outports , .

simulink m . . -. , . , , - .

, , . .

, , . , , , , .

+2

All Articles