User`s guide
9 Working with Target PC Files and File Systems
Accessing Files o n a Specific Target PC
You can access specific target PC files from the host PC for the xpctarget.ftp
object.
Use the
xpctarget.ftp creator function. If your sy stem has multiple targets,
you can access specific target PC files from the host PC for the
xpctarget.ftp
object.
For example, to list the name of the current folder of a target PC through
a TCP/IP connection,
1 In the MATLAB Command Window, type a com mand like the following to
assign the
xpctarget.ftp object to a variable.
f=xpctarget.ftp('TCPIP','192.168.0.10','22222');
2 Type
f.pwd;
Alternatively, you can use the xpctarget.xpc constructor to first construct a
target object, then use that target object as an argument to
xpctarget.ftp.
1 In the MATLAB window, type a command like the following to assign the
xpctarget.xpc object to a v ariable.
tg1=xpctarget.xpc('TCPIP','192.168.0.10','22222');
2 Type the following command to assign the xpctarget.ftp object to the
tg1 target object variable.
f=xpctarget.ftp(tg1);
Alternatively, if you want to work with the
files of the default target PC, you
can use the
xpctarget.ftp constructor wit
hout arguments.
In the MATLAB w indow , type a command like th
e following to assign the
xpctarget.ftp object to a variable.
f=xpctarget.ftp;
The xPC Target software assigns the f variable to the default target PC.
9-6