Data store memory(DSM)
Show older comments
Hello
I am using Data store memory block in my simulink model to initialize a variable(array) to use in a matlab function block.Its a big model with tight tolerances. When I run I see that the DSM block looks into the full array(variable is size 50) at every time step so basically the simulation is EXTREMELY SLOW. How can I get rid of this.
Thank you
James
Accepted Answer
More Answers (2)
Nirmal Gunaseelan
on 27 Feb 2012
0 votes
Hi James,
Could you give more details on what blocks are being used with the DSM block? Are you using a Data Store Write block as well?
Is the problem that the DSM block is accessing at every time step, or is it that you want only certain parts to be accessed? Have you tried Element wise assignment/selection?
-Nirmal
4 Comments
James
on 27 Feb 2012
Nirmal Gunaseelan
on 27 Feb 2012
Could you also post the error message here? I'm wondering if the message you're getting is about the DSM blocks not being in sync (read before write) or actually about DSM initializing many times.
As I understand, you are using DSM to initialize a chunk of memory and after that, that array is used in a MATLAB Fcn block. And you are suspecting that the DSM block is accessing the memory again (initializing again?) or the Data Store Read/Write block is accessing at every time step? (this seems normal to me).
James
on 27 Feb 2012
James
on 27 Feb 2012
James
on 28 Feb 2012
0 votes
2 Comments
Nirmal Gunaseelan
on 28 Feb 2012
Hi James,
I wanted to try out other ways of achieving your functionality without using shiftu/if conditions. I am not sure if we are preventing full access by using those lines. I'll get back to you.
-Nirmal
James
on 28 Feb 2012
Categories
Find more on Linear Plant Specification in Help Center and File Exchange
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!