User`s guide
Using xpctarget.fs Objects
7-11
1 In the MATLAB window, type a command like the following to assign the
xpctarget.fs object to a variable.
fsys=xpctarget.fs;
xPC Target assigns the fsys variable to the default target PC.
2 Type
fsys.dir;
Retrieving the Contents of a File from the Target PC
to the Host PC
You can retrieve the contents of a data file from the target PC by using xPC
Target methods on the host PC for the
xpctarget.fs object.
Use the method syntax to run an
xpctarget.fs object method. The syntax
method_name(fs_object, argument_list) can be replaced with
fs_object.method_name(argument_list)
For example, to retrieve the contents of a file named data.dat from the target
PC C:\ drive (default),
1 If you have not already done so, in the MATLAB window, type the following
to assign the
xpctarget.fs object to a variable.
fsys=xpctarget.fs;
2 Type
h=fsys.fopen('data.dat');
or
h=fopen(fsys,'data.dat');
This opens the file data.dat for reading and assigns the file identifier to h.
3 Type
data2=fsys.fread(h);
or