How to load data form specific memory address of the computer
4 次查看(过去 30 天)
显示 更早的评论
Hi all,
I want to load data form specific memory address of the computer,
with c/c++ it's simple ,just setting the pointer to desired address.
How to do it with matlab ?
Thx,
0 个评论
回答(2 个)
Gerd
2011-6-22
Hi zohar,
I guess you want to share large data sets with functions without the need to copy the data. Please have a look at Lorens blog, maybe this is what you need.
Another option is to use global varibles, what I think is not the "nicest" way
Gerd
0 个评论
Walter Roberson
2011-6-22
You wrote, "with c/c++ it's simple, just setting the pointer to desired address", but that is not really correct. In C, setting a pointer to an integral value has "implementation defined" behavior for (void *), and is (formally) an error for any other pointer type.
You should expect to have to write some system-dependent mex code to perform this task. You should not assume that it will be possible to do as an unprivileged user; for example, Windows after XP makes it very difficult to access the parallel ports.
Is this task for the interactive MATLAB or is it for code being generated to run on a different processor such as one of the TMS or dPIC series?
0 个评论
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Logical 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!