Mitsubishi Electric CR800 Series Instruction Manual page 147

For industrial robot
Hide thumbs Also See for CR800 Series:
Table of Contents

Advertisement

EBRead(EasyBuilder Read)
[Function]
Reads out the data by specifying the tag name of the vision sensor.
The data read from the vision sensor is stored in the specified variable.
Please read out data specifying the tag name by using this command when the vision program (job) is made
with the vision tool EasyBuilder made by Cognex Corporation.
[Format]
EBRead□#<Vision sensor number>, [<Tag name>], <variable name 1> [, <variable name 2>]...[, <Time out>]
[Term]
<Vision sensor number> (Can not be omitted)
This specifies the number of the vision sensor to control.
Setting range: 1 - 8
<Tag name> (Can be omitted)
Specifies the name of symbolic tag where data read out by the vision sensor is stored .
When omitting it, the value of paraemter EBRDTAG ( initial value is the custom format tag name
"Job.Robot.FormatString") is set to it.
<variable name>(Can not be omitted)
Specifies the variable where the data read from the vision sensor is stored.
It is possible to use two or more variables by delimited with commas.
It is possible to specify the Numeric value variable, Position variable or String variable.
When the Position variable is specified, the value is set to X, Y, and C element, and 0 is set to other
elements.
<Time out> (If omitted, 10)
Specifies the time-out time (in seconds).
Specification range: Integer 1-32767
[Sample sentence]
If M_NvOpen(1)<>1 Then
NVOpen "COM2:" As #1
End If
Wait M_NvOpen(1)=1
NVLoad #1,"TEST"
TrkTrg #1,2,M1#,M2#
EBRead #1,,MNUM,PVS1,PVS2
--------
:
NVClose #1
[Explanation]
(1) Gets the data by specifying the tag name from an active vision program in the specified vision sensor.
(2) The data read from the vision sensor is stored in the specified variable.
(3) When the specified variable identifier is delimited by comma and enumerated when the data of the vision
sensor is two or more values (character string) delimited by comma, data is stored in order of describing
the variable identifier. In this case, the type of the object data should be the same as the type of the
variable.
(4) When the position variable is specified, the vision data is stored in X, Y, and C element. And the value of
other elements are 0.
The value converted into the radian is set to C element.
(5) The value of receiving data are set only to the specified variables when the number of specified variables
is less than that of receive data.
(6) The variable more than the number of receiving data is not updated when the number of specified
variables is more than that of receive data.
(7) When the tag name is omitted, the value of parameter EBRDTAG is set instead of the tag name. (The
factory shipment setting is " Job.Robot.FormatString".)
'If vision sensor number 1 log on is not complete
'Connects with the vision sensor connected to COM2.
' Connects with vision sensor number 1 and waits for logon to be completed.
'Loads the "Test" program.
'Starts the "Test" program..
'The data of "Job.Robot.FormatString" tag is read,
and they are preserved in the variable MNUM, PVS1, and PVS2.
'Cuts the line with the vision sensor connected to COM2.
MELFA-BASIC V or MELFA-BASIC VI instruction 15-135
15 Maintenance of robot program

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

Cr800-rCr800-qCr800-d

Table of Contents