from file simulink real time
2 views (last 30 days)
Show older comments
I am running a simulink model on a real time machine. I want to load a certain vector of signal values stored in a mat file and output them whenever a certain boolean flag is turned on. Basically everytime the boolean turns on due to some conditions I want the pre saved vector values output as a signal. Im doing this now by placing a from file block within an enabled subsystem which is enabled by the boolean flag. My mat file has two rows the first has time values 0:0.0001:0.01 (total of 10 ms) and my second row has corresponding signal values. However when I use this the signal output takes much longer than 10 ms although the signal values are correct. Do I have to specify the exact timestamps of the real time clock when these values should be read out? This is not possible since I dont know when certain conditions would occur to turn the boolean flag on. Is there a smarter way to do this? Thank you in advance
0 Comments
Answers (0)
See Also
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!