omron — Disk I/O

Disk I/O Disk I/O NOTE: The ACE software provides the following functionality through its graphical user interface. Therefore, Omron Adept strongly recommends that you use the ACE software. The following sections discuss disk I/O. Attaching Disk Devices A disk LUN refers to a local disk device, such as the SDI card in a SmartController EX system. Also, a remote disk may be accessed via a network. The type of device to be accessed is determined by the DEFAULT command or the ATTACH instruction. If the default device type set by the DEFAULT command is not appropriate at a particular time, the ATTACH instruction can be used to override the default. The syntax of the ATTACH instruction is:

ATTACH ( lun , mode) $device See the documentation for the ATTACH program instruction for the mode options and possible device names. The instruction: ATTACH (dlun, 4) "DISK" attaches to an available disk logical unit and returns the number of the logical unit in the variable dlun, which can then be used in other disk I/O instructions. If the device name is omitted from the instruction, the default device for the specified LUN is used. Omron Adept recommends that you always specify a device name with the ATTACH instruction.

(The device SYSTEM refers to the device specified with the DEFAULT monitor command.) Once the attachment is made, the device cannot be changed until the logical unit is detached. However, any of the units available on the device can be specified when opening a file. For example, the eV+ DISK units are A, C and D. After attaching a DISK device LUN, a program can open and close files on either of these disk units before detaching the LUN. Disk I/O and the Network File System (NFS) In addition to local disk devices, an Omron Adept system equipped with Ethernet hardware and the TCP/IP license can access remote disk drives in the same fashion as local disks.

The following sections describe accessing a disk drive regardless of whether it is a local drive or a remotely-accessed drive. Disk Directories The FOPEN_ instructions, which open disk files for reading and writing, use directory paths in the same fashion as the monitor commands LOAD, STORE, etc. Files on a disk are grouped in eV+Language User's Guide, v2.x, 18318-000 Rev A Page 143