omron — SELECT program instruction

SELECT program instruction SELECT program instruction Syntax SELECT device_type = unit Function Select a unit of the named device for access by the current task. Usage Considerations The SELECT instruction needs to be used only if there are multiple devices of the same type connected to your system controller. This option is available only if your system is equipped with the eV+ Extensions option. The SELECT instruction affects only the task in which the instruction is executed. The instruction SELECT ROBOT can be executed only if there is no robot attached to the current task.

(If there is any doubt about whether or not a robot is attached, a program should execute a DETACH instruction before executing the SELECT instruction.) Parameters device_type Keyword that identifies the type of device that is to be selected. Valid device types are ROBOT, VISION, and FORCE (which must be specified without quotation marks). The device-type keyword can be abbreviated. unit Real value, variable, or expression (interpreted as an integer) that specifies the particular unit to be selected. The values that are accepted depend on the configuration of the system.

Details SELECT ROBOT In a multiple-robot system, this program instruction selects the robot with which the current task is to communicate. (The SELECT monitor command specifies which robot the eV+ monitor is to access.) The program instruction specifies which robot receives motion instructions (for example, APPROACH and MOVE) and returns robot-related information (for example, for the HERE function). Each time a program task begins execution, robot #1 is automatically selected. If a robot is selected, information about the robot (for example, its current position) can be accessed.

In order for a program to move a robot, however, the robot must be selected and attached (with the ATTACH instruction). eV+Language Reference Guide, v2.x, 18319-000 Rev A Page 456