• No results found

2 SETTING UP TCP/IP

3.6 FTP SERVICES

3.6.1 Overview

The following FTP services are provided:

• Environment services

• File transfer services

• Directory services

These services can be performed only by server devices.

Figure 3.6.1 shows the relationship of host communications to the controller system. It also shows the devices and the services that can be accessed.

Fig. 3.6.1 Host Communications model

A host device operating as a client will make service requests via the Ethernet cable to the server. All service requests pass through the controller system library functions.

3.6.2 Environment Services

FTP provides the following environment services:

• open

• close

• username

• password

• type

open

Open is used to establish a connection between the host computer and the controller.

close

The close service is used to close a connection.

When Inactivity times out, the Close request is sent to the attached host computer. You can set the Inactivity Time to zero, which turns off the Inactivity Timer. Timer values can be set between 1 and 99,999 minutes.

username

Username is checked if the password protection option is installed on the robot controller.

password

Password is checked only if the password protection option is installed on the robot controller.

NOTE

Server passwords require the Password Protection option. The Operator level can upload files and perform a directory. The Program level can perform Operator tasks and download .TP, .PC, .IO, and .VR files. The Setup/Installation level can perform Operator and Program tasks and download .SV files. If the password protection option is not installed, you are placed in the Setup/Installation level by default. You can use the FTP Server Access control feature to modify this

behavior.

type

Type sets the file transfer type to BINARY before transferring binary type files, such as .IO, .PC, .SV, .TP, and .VR.

3.6.3 File Transfer Services

FTP provides the following file transfer services:

• get

• put

• mget

• mput

User program and data files can be transferred to and from I/O devices (such as the RAM disk, serial ports, and the memory device). System files can be transferred to and from the memory device only.

Refer to Section 3.7 .

The FTP protocol uses the standard input and output services available in the controller. Any device accessible by a KAREL program, except client devices C1: through C8:, can be accessed.

3.6.4 Directory Services

FTP provides the following directory services:

• cd

The cd service is used to change the default device.

delete

The delete service works with devices such as P3: and FLPY:. You can delete all files except system files (such as SYSVARS.SV) with the Memory Device.

dir

Wildcard operations are allowed for dir using the wildcard character, "*" in the file name or extension.

Wildcards can be used as follows:

• word No wildcard. The name must match exactly.

• word* Matches names that begin with word plus zero or more characters.

• *word Matches names that end with word preceded by zero or more characters.

• *word* Matches names that contain word in the beginning, middle, or end.

NOTE

On some screens, the controller might display the teach pendant file attribute as a file type, such as job (.JB), macro (.MR), or process (.PR). However, these are all stored on external devices as files with the teach pendant file type extension. The controller will not allow teach pendant file names to be used with different attribute types. For example, there cannot be a TEST99.TP with attribute type job (.JB) and a TEST99.TP with attribute type macro (.MR).

mkdir

The mkdir service allows you to create a directory. NOTE that directories cannot be created on MD: or other memory devices. Refer to Section 3.7 for more information on the memory devices.

pwd

The pwd service is used to display the default device.

NOTE

If you use Distinct FTP on your host computer, the Distinct FTP client cannot change to hidden drives and cannot transfer hidden files. You can transfer only those files that are displayed in the directory of the memory device (MD:), the default device of the FTP server.

rename

Rename is not available on the memory device (MD:) and memory card (MC:). Refer to Section 3.7 for more information on the memory device.

rmdir

The rmdir service allows a user to remove or delete a directory. Note that directories cannot be removed from MD: or other memory devices. Refer to Section 3.7 for more information on memory devices.

3.6.5 Miscellaneous FTP Information

The FTP implementation on the robot conforms to Internet standard specifications (as given by RFC 959).

In particular, the FTP server recognizes the internal commands listed in Table 3.6.5 .

Table 3.6.5 FTP Server Internal Commands

ABOR LIST PWD PASV MODE

Generally, UNIX based FTP servers are case sensitive, and the robot controller is case insensitive. When using FTP client tags to communicate with a remote UNIX FTP server, by default the robot assumes everything is lower-case. This means the robot will create directories with lower-case names, navigate directory structures assuming all directories have lower-case names, and will access files (read/write/open/create) assuming lower-case file names. When coming across a file or directory with an upper-case name, the robot will be able to display the file or directory when doing a directory listing, but will not be able to access it. Setting the system variable $FTP_CTRL.$SUBDIRCAPS to TRUE reverses this and causes the robot controller to assume all file and directory names are upper-case. When this system variable is changed, the robot controller must be power-cycled to take effect. However, note that the path entered into the Remote Path/Share field of the Client Tag Setup screen is case sensitive. This root path can be mixed case and does not assume either lower or upper case.

In general, the FTP server on the robot is compatible with any FTP client (command-line or GUI-based) that conforms to the standard FTP specification.

In particular, the FTP server has been tested against standard UNIX and Windows-based command line FTP clients and the following graphical FTP clients:

• GlobalScope Inc.'s CuteFTP Version 6.0

• IPSwitch's WS_FTP Pro Version 9.01

• FileZilla Version 3.2.3.1

For newer versions of FileZilla, use Procedure 3-5 to configure FileZilla to work with the robot controller's file system.

Procedure 3-5 Configure FileZilla FTP Client

Steps

1. Launch FileZilla, select the File menu, and open the Site Manager.

2. Enter appropriate information in the General tab.

3. Select the Advanced tab and set Servertype to DOS.

4. Optionally, enter in a default remote directory.

5. Click on OK.

3.7 ACCESSING USER PROGRAM, SETUP, AND