UPGRADE YOUR BROWSER

We have detected your current browser version is not the latest one. Xilinx.com uses the latest web technologies to bring you the best online experience possible. Please upgrade to a Xilinx.com supported browser:Chrome, Firefox, Internet Explorer 11, Safari. Thank you!

cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Visitor fl_guy
Visitor
2,864 Views
Registered: ‎06-17-2010

Zynq Reading Matlab objects (.MAT file) in C

Hi,

I am looking for some instructions in reading .MAT file from Matlab.

Any hints would be appreciated.

Thanks,

TV

0 Kudos
3 Replies
Xilinx Employee
Xilinx Employee
2,857 Views
Registered: ‎08-02-2011

Re: Zynq Reading Matlab objects (.MAT file) in C

The 'load' function should do it:
http://www.mathworks.com/help/matlab/ref/load.html
www.xilinx.com
0 Kudos
Visitor fl_guy
Visitor
2,815 Views
Registered: ‎06-17-2010

Re: Zynq Reading Matlab objects (.MAT file) in C

bwiec,

My concern is reading the MAT data into embedded environment. So I am looking for some C codes which reading or parsing the MAT file which was stored in Flash.

TV

0 Kudos
Explorer
Explorer
2,805 Views
Registered: ‎11-13-2009

Re: Zynq Reading Matlab objects (.MAT file) in C

MAT files are binary, there are several good sources of information as to the content and how to decode them, including your MATLAB install directory for the format.  You can write a binary file to flash but I think your real concern is reading and using the data.  This is where google is your friend.  I might suggest that you just output them from MATLAB in a form that you can easily parse and compress with a known algorthim like PERL "pack" function for example.  Most of the time this is what I have resorted to instead of dealing with al the overhead in the MAT file.

 

TomT...

0 Kudos