Import Excel files directly to simulink (R2010a)
显示 更早的评论
Import Excel files directly to simulink (R2010a)
I need to use data in a excel sheet as an input in simulink. I want to actuate a simmechanics model (through a revolute joint) according to a signal that is generated based on values in a excel file (time and angle, kind of a sine wave)
Anyone know a solution??
回答(1 个)
Andreas Goser
2012-12-10
0 个投票
"Directly" is a relative term... I suggest the following:
- Achieve to import the data int MATLAB with a command like XLSREAD
- Maybe post process the data in a way it satisfies the formatting needs of your Simulink source block
- Add those couple of line into your Simulink as a callback that gets exectutes befor you start simulating the model, e.g. the PRELOADFCN
类别
在 帮助中心 和 File Exchange 中查找有关 Data Import from MATLAB 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!