User`s guide
9 Working with Target PC Files and File Systems
Use the method syntax to run an xpctarget.fs object method. The sy ntax
method_name(fs_object, argument_list) can be replaced with
fs_object.method_name(argument_list)
For example, to display the information for the file identifier fid1,
1 Ifyouhavenotalreadydoneso,intheMATLABwindow,typethefollowing
to assign the
xpctarget.fs object to a variable.
fsys=xpctarget.fs;
2 Type
fid1=fsys.fopen('data.dat');
This opens the file data.dat for reading and assigns the file identifier
to
fid1.
3 Type
fsys.fileinfo(fid1);
This returns disk information like the following for the C:\ drive file
system.
ans =
FilePos: 0
AllocatedSize: 12288
ClusterChains: 1
VolumeSerialNumber: 1.0450e+009
FullName: 'C:\DATA.DAT'
Getting Information about a Disk on the Target PC
You can display information for a disk on the tar get PC file system from the
host PC by using xPC Target m ethods 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)
9-16