Is there a way to log variables from a Matlab Function Block (in Simulink), that is not output?
I would like to log variables from a Matlab Function Block (in Simulink) similar to the functionality of a "To Workspace" block saving them in a SimulinkOutput object. As those variables are only internal I cannot connect them to said block. I know, I could simply define them as outputs and only connect them to the "To Workspace" block, but I would like to avoid this work around to keep my model clean (it would be around 10 variables). I have browsed through docu, but could not find something that would solve my issue. So, I am wondering if there is an elegant way to log also variables from a Matlab Function Block (in Simulink) as a an array, like it is possible for signals (connecting them to a "To Workspace" block)?I would like to log variables from a Matlab Function Block (in Simulink) similar to the functionality of a "To Workspace" block saving them in a SimulinkOutput object. As those variables are only internal I cannot connect them to said block. I know, I could simply define them as outputs and only connect them to the "To Workspace" block, but I would like to avoid this work around to keep my model clean (it would be around 10 variables). I have browsed through docu, but could not find something that would solve my issue. So, I am wondering if there is an elegant way to log also variables from a Matlab Function Block (in Simulink) as a an array, like it is possible for signals (connecting them to a "To Workspace" block)? I would like to log variables from a Matlab Function Block (in Simulink) similar to the functionality of a "To Workspace" block saving them in a SimulinkOutput object. As those variables are only internal I cannot connect them to said block. I know, I could simply define them as outputs and only connect them to the "To Workspace" block, but I would like to avoid this work around to keep my model clean (it would be around 10 variables). I have browsed through docu, but could not find something that would solve my issue. So, I am wondering if there is an elegant way to log also variables from a Matlab Function Block (in Simulink) as a an array, like it is possible for signals (connecting them to a "To Workspace" block)? simulink, save, data MATLAB Answers — New Questions