警告

あなたはこのドキュメントの古いバージョンを読んでいます。 最新の情報を知りたい場合は、以下を参照してください 5.0 .

URCap global variables

The EYE+ URCap creates global variables dynamically to store some useful information. As soon as a URCap program node is opened with a connected EYE+, all global variables listed in the 表 33 are automatically created.

表 33 List of static global variables

Name

説明

Type

By default

EYE1Prm

Store the last EYE+ parameter after using get_parameter

String

""

EYE1AR

Store the last Asycube response after using feeder

String

""

EYE1Pos

Store the last EYE+ pick point position 1 read

ポジション

p[0,0,0,0,0,0]

If the command set_parameter part_quantity n is used with n > 1, the global variables listed in 表 34 are automatically created (according to the value of n).

表 34 List of global variable created dynamically for part_quantity = 5

Name

説明

Type

By default

EYE1Pos2

Store the last EYE+ pick point position 2 read

ポジション

p[0,0,0,0,0,0]

...

...

...

EYE1Pos5

Store the last EYE+ pick point position 5 read

ポジション

p[0,0,0,0,0,0]

EYE1Pos, EYE1Pos2, ..., EYE1Pos5

These global variables store the last part coordinates received after sending a Basic command - get_part. The position variable is defined as: p[X,Y,0,0,0,RZ].

  • The X and Y coordinates of the part stored in the variable are only valid in the robot frame that you defined during the hand-eye calibration. These coordinates are also only valid with the same Tool Center Point (TCP) as used during the hand-eye calibration.

    警告

    For positioning the robot in space, the system uses meters.

  • The Z coordinate is set to 0. You have to add an offset in the Z direction in the position to avoid hitting the plate of the Asycube when picking up a part.

  • RZ is the angle sent by EYE+ in radian.

警告

The global variable EYE1Pos is expressed in terms of roll, pitch and yaw. As the robot is expecting a rotation vector, you cannot directly move to the position. You at least have to add the 0-position of the robot as presented below.

../../../_images/correction_before_move.png

図 193 Position correction before Move

Most of the time, an RX or RY angle offset must be added to reach the part position.

../../../_images/correction_before_move2.png

図 194 Position correction before Move with a correction on RX angle

To move the robot to the global variable coordinates, you can select the basic robot command called Move. Make sure you use the right TCP and frame (図 195) and then choose the type of move you want to perform (MoveJ, MoveL or MoveP). Finally, set the Waypoint to the part coordinates variable EYE1Pos. (図 196).

../../../_images/move_select_frame_tool.png

図 195 Choose the right robot frame and TCP in the Move command

../../../_images/move_select_variable.png

図 196 Select the global variable EYE1Pos

EYE1Prm

This global variable is used to store the return value of the Advanced command - get_parameter command. Each time a new parameter is read, the last parameter stored in the variable is erased and replaced by the new one.

重要

If you run the get_parameter command using the URScript EYErawCommand(<name>, <command>) function, the EYE1Prm global variable will not be modified.

EYE1AR

This global variable is used to store the return value of the Advanced command - feeder command. Each time a new Asycube response is received, the last response stored in the variable is deleted and replaced by the new one.

重要

If you run the get_parameter command using the URScript EYErawCommand(<name>, <command>) function, the EYE1AR global variable will not be modified.