<< Prev        Next >>

ID : 5376

TrackSetVision

Function

Store workpiece-related data detected by a vision sensor into tracking buffer.

This command is available in Ver.1.6.* or higher.

Syntax

TrackSetVision Conveyor number, Number of workpieces to detect,
               Sensor detection coordinate [, UserData [, Attribute data]]

Guaranteed Entry

Conveyor number

Specify the conveyor number (1-16) to be used by integer type data.
(If your robot controller is Ver.1.11.* or lower, available conveyor number is 1 or 2.)

Number of workpieces to detect

Specify the number of workpieces to be stored in the tracking buffer area at a time by integer type data.
If negative value is set, the internal trigger mode, which does not require trigger input from I/O, will be set.
(Entering negative value will cause an error if your robot controller is Ver.1.11.* or lower.)

Value Description
Positive values Specify the number of workpieces detected by the vision sensor by positive value.
The conveyor encoder value must be stored beforehand by receiving I/O input from the vision sensor.
0 Error
Negative values Specify the number of workpieces you want to set based on the internal trigger by negative value.
This does not require I/O input from the vision sensor, and the conveyor encoder value when this command is executed is stored.
Sensor detection coordinate

Specify the vision sensor detection coordinates as much as the Number of workpieces to detect. The following three types of coordinates are available.

Data Type Description
Vector Type Available only when the Number of workpieces to detect is one.
One dimensional array of variant type data Available when the Number of workpieces to detect is one or more.
To enter the value of each element, use vector type data.
One dimensional array of vector type data Available when the Number of workpieces to detect is one or more.
To enter the value of each element, use vector type data.
This entry is available in Ver.2.0.* or higher.

 

UserData

If you set Userdata for workpieces, the workpieces with specified Userdata value can be exclusively taken out from the tracking buffer at the TrackTargetPos execution. The following three data types are available to specify UserData. This is an optional value. This should be "-1" if this is omitted. If minus value is set, it is treated same as when it is omitted.

Data Type Description
Integer type Available only when the Number of workpieces to detect is one.
One dimensional array of variant type data Available when the Number of workpieces to detect is one or more.
To enter the value of each element, use integer type data.
If the numbers of element is less than Number of workpieces to detect, "-1" will be assigned to the rest of elements.
One dimensional array of integer type data Available when the Number of workpieces to detect is one or more.
To enter the value of each element, use integer type data.
If the numbers of element is less than Number of workpieces to detect, "-1" will be assigned to the rest of elements.

 

Attribute data

Attribute value that can be assigned by user to respective workpieces detected. This entry is available in Ver.1.10.* or higher. The following three data types are available to specify Attribute data. This is an optional value. This should be "-1" if this is omitted.

Data Type Description
Integer type Available only when the Number of workpieces to detect is one.
One dimensional array of variant type data Available when the Number of workpieces to detect is one or more.
To enter the value of each element, use integer type data.
If the numbers of element is less than Number of workpieces to detect, "-1" will be assigned to the rest of elements.
One dimensional array of integer type data Available when the Number of workpieces to detect is one or more.
To enter the value of each element, use integer type data.
If the numbers of element is less than Number of workpieces to detect, "-1" will be assigned to the rest of elements.

Description

Store workpiece-related data detected by a vision sensor into tracking buffer.
The following data is stored when a workpiece is registered.

  Stored values Direct input
(1) Index value in the tracking buffer (integer type data) Not available
(2) Conveyor encoder value at workpiece detection (integer type data) Not available
(3) Vision sensor detection coordinates (variant type data array) Available
(4) User data (integer type data) Available
(5) Attribute data (integer type data) Available

Attention

  • This command is available only for the vision tracking.

Example

Vision sensor detects Work 1 whose image coordinates are x=100[pixel], y=10[pixel] and the workpiece's attitude angle is θ=30[deg].

Dim visPos1 As Variant
visPos1 = Array(100, 10, 30)

Vision sensor detects Work 2 whose image coordinates are x=100[pixel], y=200[pixel] and the workpiece's attitude angle is θ=0[deg].

Dim visPos2 As Variant
visPos2 = Array(100, 200, 0)

Vision sensor detects Work 3 whose image coordinates are x=10[pixel], y=200[pixel] and the workpiece's attitude angle is θ=45[deg].

Dim visPos3 As Variant
visPos3 = Array(10, 200, 45)

Store three of work data that have been detected by the vision sensor in the tracking buffer with specifying user data and attributes.

TrackSetVision 1,3, Array(visPos1, visPos2, visPos3), Array(1, 2, 3), Array(1, 1, 1)

ID : 5376

<< Prev        Next >>