I need help with running a Simulink model with the data from MATLAB workspace contained in structures. Below is a very simplified use-case of what I would like to do
Use Case :
I have a structure in MATLAB workspace called "data_in", and it has two fields x, and y which are vectors. I have a simulink model with two Inports named x and y.
This is what I would like to to :
a. Read the name of the Inports from the Simlunk Model. In this case it would be x and y
b. Programmatically assign the data from the structure - "data_in" to the ports "x" and "y" in the Simulink model. The structure "data_in" contains two vectors "x" and "y" to be mapped to Simulink Inports
The above use case is a very simplified scenario. The model that I intend to use can have 100 inports, and thus I do not want to use "From Workspace" block, as it would be impractical for me to add 100s of them
How can I handle such a situation in Simulink. I am a little more than a beginner in MATLAB and Simulink. So, a detailed answer would help me a lot

