i668-e-01_v+
i668-e-01_v+
i668-e-01_v+
Reference Manual
I668-E-01
NOTE
All rights reserved. No part of this publication may be reproduced, stored in a retrieval system, or
transmitted, in any form, or by any means, mechanical, electronic, photocopying, recording, or other-
wise, without the prior written permission of OMRON.
No patent liability is assumed with respect to the use of the information contained herein. Moreover,
because OMRON is constantly striving to improve its high-quality products, the information contained
in this manual is subject to change without notice. Every precaution has been taken in the preparation
of this manual. Nevertheless, OMRON assumes no responsibility for errors or omissions. Neither is
any liability assumed for damages resulting from the use of the information contained in this publica-
tion.
Trademarks
Company names and product names in this document are the trademarks or registered trademarks of
their respective companies.
Copyrights
Microsoft product screen shots reprinted with permission from Microsoft Corporation.
Introduction
Introduction
This manual is OMRON's original instructions describing the use of V+ Modules.
These modules can only be used when the ACE server is running or a connection to ACE is present.
Please read this manual and make sure you understand the functionality and performance of the sys-
tem before attempting to use these modules.
Keep this manual in a safe place where it will be available for reference during programming and con-
figuration.
2
1 V+ AceServer Module
3
3 V+ End-effector Module
5
CONTENTS
Introduction .............................................................................................................. 1
2-2 check_tracking.......................................................................................................................2-3
2-3 clear_queue ............................................................................................................................2-4
2-4 getinstance .............................................................................................................................2-5
2-5 reset_seq ................................................................................................................................2-6
2-6 set_as_exec_mod ..................................................................................................................2-7
4-17 pm.get.type...........................................................................................................................4-21
4-18 pm.gr.clroff ...........................................................................................................................4-22
4-19 pm.gr.release........................................................................................................................4-23
4-20 pm.gr.select ..........................................................................................................................4-24
4-21 pm.gr.select.ck .....................................................................................................................4-26
4-22 pm.gr.setoff ..........................................................................................................................4-27
4-23 pm.gr.settle...........................................................................................................................4-29
4-24 pm.gr.state............................................................................................................................4-30
4-25 pm.gr.trans ...........................................................................................................................4-32
4-26 pm.gr.unselect......................................................................................................................4-34
4-27 pm.log ...................................................................................................................................4-35
4-28 pm.mv ...................................................................................................................................4-36
4-29 pm.mv.attach ........................................................................................................................4-38
4-30 pm.mv.chkbrk.......................................................................................................................4-40
4-31 pm.mv.dest ...........................................................................................................................4-41
4-32 pm.mv.idle ............................................................................................................................4-43
4-33 pm.proc.enable ....................................................................................................................4-45
4-34 pm.prt.avail...........................................................................................................................4-46
4-35 pm.prt.done ..........................................................................................................................4-47
4-36 pm.prt.get .............................................................................................................................4-48
4-37 pm.prt.get.idx .......................................................................................................................4-50
4-38 pm.prt.getloc ........................................................................................................................4-51
4-39 pm.prt.move.ptr....................................................................................................................4-53
4-40 pm.ps.error ...........................................................................................................................4-55
4-41 pm.ps.map.idx......................................................................................................................4-56
4-42 pm.ps.power.........................................................................................................................4-58
4-43 pm.rob.chkidle .....................................................................................................................4-59
4-44 pm.rob.clear .........................................................................................................................4-60
4-45 pm.rob.gettag .......................................................................................................................4-62
4-46 pm.rob.idlemd ......................................................................................................................4-63
4-47 pm.rob.init ............................................................................................................................4-65
4-48 pm.rob.monque....................................................................................................................4-67
4-49 pm.rob.pick...........................................................................................................................4-68
4-50 pm.rob.place.........................................................................................................................4-70
4-51 pm.rob.process ....................................................................................................................4-72
4-52 pm.rob.refine ........................................................................................................................4-74
4-53 pm.rob.settag .......................................................................................................................4-75
4-54 pm.sig.check ........................................................................................................................4-76
4-55 pm.sig.clear ..........................................................................................................................4-77
4-56 pm.src.clear..........................................................................................................................4-78
4-57 pm.src.clearall......................................................................................................................4-79
4-58 pm.trg.avail...........................................................................................................................4-80
Warranty
• Exclusive Warranty
Omron’s exclusive warranty is that the Products will be free from defects in materials and workman-
ship for a period of twelve months from the date of sale by Omron (or such other period expressed
in writing by Omron). Omron disclaims all other warranties, expressed or implied.
• Limitations
OMRON MAKES NO WARRANTY OR REPRESENTATION, EXPRESS OR IMPLIED, ABOUT
NON-INFRINGEMENT, MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE OF
THE PRODUCTS. BUYER ACKNOWLEDGES THAT IT ALONE HAS DETERMINED THAT THE
PRODUCTS WILL SUITABLY MEET THE REQUIREMENTS OF THEIR INTENDED USE.
Omron further disclaims all warranties and responsibility of any type for claims or expenses based
on infringement by the Products or otherwise of any intellectual property right.
• Buyer Remedy
Omron’s sole obligation hereunder shall be, at Omron’s election, to (i) replace (in the form originally
shipped with Buyer responsible for labor charges for removal or replacement thereof) the non-com-
plying Product, (ii) repair the non-complying Product, or (iii) repay or credit Buyer an amount equal
to the purchase price of the non-complying Product; provided that in no event shall Omron be re-
sponsible for warranty, repair, indemnity or any other claims or expenses regarding the Products un-
less Omron’s analysis confirms that the Products were properly handled, stored, installed and main-
tained and not subject to contamination, abuse, misuse or inappropriate modification. Return of any
Products by Buyer must be approved in writing by Omron before shipment. Omron Companies shall
not be liable for the suitability or unsuitability or the results from the use of Products in combination
with any electrical or electronic components, circuits, system assemblies or any other materials or
substances or environments. Any advice, recommendations or information given orally or in writing,
are not to be construed as an amendment or addition to the above warranty.
See http://www.omron.com/global/ or contact your Omron representative for published information.
Limitations of Liability
OMRON COMPANIES SHALL NOT BE LIABLE FOR SPECIAL, INDIRECT, INCIDENTAL, OR CON-
SEQUENTIAL DAMAGES, LOSS OF PROFITS OR PRODUCTION OR COMMERCIAL LOSS IN ANY
WAY CONNECTED WITH THE PRODUCTS, WHETHER SUCH CLAIM IS BASED IN CONTRACT,
WARRANTY, NEGLIGENCE OR STRICT LIABILITY. Further, in no event shall liability of Omron Com-
panies exceed the individual price of the Product on which liability is asserted.
Application Considerations
Programmable Products
• Omron Companies shall not be responsible for the user’s programming of a programmable Product,
or any consequence thereof.
• Omron Companies shall not be responsible for the operation of the user accessible operating sys-
tem (e.g. Windows, Linux), or any consequence thereof.
Disclaimers
Performance Data
Data presented in Omron Company websites, catalogs and other materials is provided as a guide for
the user in determining suitability and does not constitute a warranty. It may represent the result of
Omron’s test conditions, and the user must correlate it to actual application requirements. Actual per-
formance is subject to the Omron’s Warranty and Limitations of Liability.
Change in Specifications
Product specifications and accessories may be changed at any time based on improvements and oth-
er reasons. It is our practice to change part numbers when published ratings or features are changed,
or when significant construction changes are made. However, some specifications of the Product may
be changed without any notice. When in doubt, special part numbers may be assigned to fix or estab-
lish key specifications for your application. Please consult with your Omron’s representative at any
time to confirm actual specifications of purchased Product.
V+ AceServer Module
The information in this section documents the V+ programs that a user might use in
the process of customizing an application leveraging ACE.
1-1 sv.create_msg
1-1 sv.create_msg
Creates a new message, initializing the header for writing.
Syntax
1
sv.create_msg(msg_num, handle, ptr)
Input Parameters
Parameter Description
msg_num Message number to create
Outputs Parameters
Parameter Description
handle Handle to new message
ptr Pointer into the new message
1-2 sv.read_adouble
Read an array of double-precision floats from the message buffer. The message pointer is increment-
ed after the read.
Syntax
sv.read_adouble(handle, ptr, offset, value[], n_items)
Input Parameters
Parameter Description
handle Index of the message to read from
ptr Position in the message buffer to read at
offset Offset into output array for first item. 0 is default
Output Parameters
Parameter Description
ptr Index pointing to the next data item in the message
value[] Array filled with data read
n_items Number of items read
1-3 sv.read_ashort
1-3 sv.read_ashort
Read an array of 16-bit integers from the message buffer. The message pointer is incremented after
the read.
Syntax 1
sv.read_ashort(handle, ptr, offset, value[], n_items)
Input Parameters
Parameter Description
handle Index of the message to read from
ptr Position in the message buffer to read at
offset Offset into output array for first item. 0 is default
Output Parameters
Parameter Description
ptr Index pointing to the next data item in the message
value[] Array filled with data read
n_items Number of items read
1-4 sv.read_asingle
Read an array of single-precision float variables from the message buffer. The message pointer is in-
cremented after the read.
Syntax
sv.read_asingle(handle, ptr, offset, value[], n_items)
Input Parameters
Parameter Description
handle Index of the message to read from
ptr Position in the message buffer to read at
offset Offset into output array for first item. 0 is default
Output Parameters
Parameter Description
ptr Index pointing to the next data item in the message
value[] Array filled with data read
n_items Number of items read
1-5 sv.read_astring
1-5 sv.read_astring
Read an array of strings from the message buffer. The message pointer is incremented after the read
Syntax
1
sv.read_astring(handle, ptr, offset, $value[], n_items)
Input Parameters
Parameter Description
handle Index of the message to read from
ptr Position in the message buffer to read at
offset Offset into output array for first item. 0 is default
Output Parameters
Parameter Description
ptr Index pointing to the next data item in the message
$value[] Array filled with data read
n_items Number of items read
1-6 sv.read_bool
Read a boolean from the message buffer. The message pointer is incremented after the read.
Syntax
sv.read_bool(handle, ptr, value)
Input Parameters
Parameter Description
handle Index of the message to read from
ptr Position in the message buffer to read at
Output Parameters
Parameter Description
ptr Index pointing to the next data item in the message
value Value of the parameter read from the message stream
Example
.PROGRAM ex1.msg(handle, ptr)
; ABSTRACT: Demonstrate writing then reading to a message buffer
;
INPUTS: handle: Index of the message to write into
; ptr: Position in the message buffer
1-6 sv.read_bool
; Read the data that was written
CALL sv.read_bool(handle, saved.ptr, bool.val)
CALL sv.read_byte(handle, saved.ptr, byte.val)
CALL sv.read_double(handle, saved.ptr, double.val)
CALL sv.read_short(handle, saved.ptr, short.val)
CALL sv.read_single(handle, saved.ptr, single.val) 1
CALL sv.read_string(handle, saved.ptr, $string.val)
CALL sv.read_trans(handle, saved.ptr, trans.val)
.END
1-7 sv.read_byte
Reads a byte from the message buffer. The message pointer is incremented after the read.
Syntax
sv.read_byte(handle, ptr, value)
Input Parameters
Parameter Description
handle Index of the message to read from
ptr Position in the message buffer to read at
Output Parameters
Parameter Description
ptr Index pointing to the next data item in the message
value Value of the parameter read from the message stream
Example
.PROGRAM ex1.msg(handle, ptr)
; ABSTRACT: Demonstrate writing then reading to a message buffer
;
INPUTS: handle: Index of the message to write into
; ptr: Position in the message buffer
1-7 sv.read_byte
; Read the data that was written
CALL sv.read_bool(handle, saved.ptr, bool.val)
CALL sv.read_byte(handle, saved.ptr, byte.val)
CALL sv.read_double(handle, saved.ptr, double.val)
CALL sv.read_short(handle, saved.ptr, short.val)
CALL sv.read_single(handle, saved.ptr, single.val) 1
CALL sv.read_string(handle, saved.ptr, $string.val)
CALL sv.read_trans(handle, saved.ptr, trans.val)
.END
1-8 sv.read_double
Read a double-precision float from the message buffer. The message pointer is incremented after the
read.
Syntax
sv.read_double(handle, ptr, value)
Input Parameters
Parameter Description
handle Index of the message to read from
ptr Position in the message buffer to read at
Output Parameters
Parameter Description
ptr Index pointing to the next data item in the message
value Value of the parameter read from the message stream
Example
.PROGRAM ex1.msg(handle, ptr)
; ABSTRACT: Demonstrate writing then reading to a message buffer
;
INPUTS: handle: Index of the message to write into
; ptr: Position in the message buffer
1-8 sv.read_double
CALL sv.write_trans(NULL, handle, ptr)
1-9 sv.read_short
Read a 16-bit integer from the message buffer. The message pointer is incremented after the read.
Syntax
sv.read_short(handle, ptr, value)
Input Parameters
Parameter Description
handle Index of the message to read from
ptr Position in the message buffer to read at
Output Parameters
Parameter Description
ptr Index pointing to the next data item in the message
value Value of the parameter read from the message stream
Example
.PROGRAM ex1.msg(handle, ptr)
; ABSTRACT: Demonstrate writing then reading to a message buffer
;
INPUTS: handle: Index of the message to write into
; ptr: Position in the message buffer
1-9 sv.read_short
; Read the data that was written
CALL sv.read_bool(handle, saved.ptr, bool.val)
CALL sv.read_byte(handle, saved.ptr, byte.val)
CALL sv.read_double(handle, saved.ptr, double.val)
CALL sv.read_short(handle, saved.ptr, short.val)
CALL sv.read_single(handle, saved.ptr, single.val) 1
CALL sv.read_string(handle, saved.ptr, $string.val)
CALL sv.read_trans(handle, saved.ptr, trans.val)
.END
1-10 sv.read_single
Read a single-precision float from the message buffer. The message pointer is incremented after the
read.
Syntax
sv.read_single(handle, ptr, value)
Input Parameters
Parameter Description
handle Index of the message to read from
ptr Position in the message buffer to read at
Output Parameters
Parameter Description
ptr Index pointing to the next data item in the message
value Value of the parameter read from the message stream
Example
.PROGRAM ex1.msg(handle, ptr)
; ABSTRACT: Demonstrate writing then reading to a message buffer
;
INPUTS: handle: Index of the message to write into
; ptr: Position in the message buffer
1-10 sv.read_single
CALL sv.write_trans(NULL, handle, ptr)
1-11 sv.read_string
Read a string from the message buffer. The message pointer is incremented after the read.
Syntax
sv.read_string(handle, ptr, $string)
Input Parameters
Parameter Description
handle Index of the message to read from
ptr Position in the message buffer to read at
Output Parameters
Parameter Description
ptr Index pointing to the next data item in the message
$string Value of the parameter read from the message stream
Example
.PROGRAM ex1.msg(handle, ptr)
; ABSTRACT: Demonstrate writing then reading to a message buffer
;
INPUTS: handle: Index of the message to write into
; ptr: Position in the message buffer
1-11 sv.read_string
; Read the data that was written
CALL sv.read_bool(handle, saved.ptr, bool.val)
CALL sv.read_byte(handle, saved.ptr, byte.val)
CALL sv.read_double(handle, saved.ptr, double.val)
CALL sv.read_short(handle, saved.ptr, short.val)
CALL sv.read_single(handle, saved.ptr, single.val) 1
CALL sv.read_string(handle, saved.ptr, $string.val)
CALL sv.read_trans(handle, saved.ptr, trans.val)
.END
1-12 sv.read_trans
Read a transform from the message buffer. The message pointer is incremented after the read.
Syntax
sv.read_trans(handle, ptr, trans)
Input Parameters
Parameter Description
handle Index of the message to read from
ptr Position in the message buffer to read at
Output Parameters
Parameter Description
ptr Index pointing to the next data item in the message
value Value of the parameter read from the message stream
Example
.PROGRAM ex1.msg(handle, ptr)
; ABSTRACT: Demonstrate writing then reading to a message buffer
;
INPUTS: handle: Index of the message to write into
; ptr: Position in the message buffer
1-12 sv.read_trans
; Read the data that was written
CALL sv.read_bool(handle, saved.ptr, bool.val)
CALL sv.read_byte(handle, saved.ptr, byte.val)
CALL sv.read_double(handle, saved.ptr, double.val)
CALL sv.read_short(handle, saved.ptr, short.val)
CALL sv.read_single(handle, saved.ptr, single.val) 1
CALL sv.read_string(handle, saved.ptr, $string.val)
CALL sv.read_trans(handle, saved.ptr, trans.val)
.END
1-13 sv.sig.is.equal
Compares a signal to an expected value. This method is employed when a program checks if a signal
is at the expected state. It encapsulates the comparison process but it also manages whether a pro-
gram is running on an emulator or not. In the case of an emulator, reading inputs can be a problem as
in emulator mode an external system generating the input signals is not available. In emulator mode,
this method will always consider the signal to be at the expected state and then always return true.
Syntax
sv.sig.is.equal(sig.num, expected.val, is.equal.res)
Input Parameters
Parameter Description
sig.num The signal number we want to check.
expected.val The expected signal value.
Output Parameters
Parameter Description
is.equal.res The result value, indicating if signal is at the expected
value.
Example
.PROGRAM ex1()
; ABSTRACT: Demonstrate comparing a signal to an expected value
;;
INPUTS:
AUTO REAL my.signal1 = 1001
AUTO REAL my.signal2 = 1002
AUTO REAL is.off, is.on
; Check a signal is not at an incorrect value. This is checking an error case
; In emulator mode, is.off will always be true and program will not generate errors
CALL sv.sig.is.equal(my.signal1, FALSE, is.off)
IF NOT is.off THEN
TYPE "input is not at the correct state : it is on and should be off."
END
; wait a signal is at the expected value. If emulation mode is active, true will be
returned and program can continue.
; In normal mode, the signal is read periodically and is compared to expected value
.
DO
1-13 sv.sig.is.equal
UNTIL is.on
.END
1-14 sv.stop_collect
Stop the data collection operations on the specified robot.
Syntax
sv.stop_collect(robot.num)
Input Parameters
Parameter Description
robot.num The robot number to stop data collection on.
Output Parameters
None
1-15 sv.write
1-15 sv.write
Write a message to the client.
Syntax
1
sv.write(handle, ptr)
Input Parameters
Parameter Description
handle Index of the message to write to
ptr Position in the message buffer to write at
offset Offset into output array for first item. 0 is default
Output Parameters
Parameter Description
ptr Index pointing to the next data item in the message
1-16 sv.write_abyte
Write an array of bytes to the output message at the specified offset.
Syntax
sv.write_abyte($string[], offset, count, handle, ptr)
Input Parameters
Parameter Description
$string Array of strings to write
offset 1-based starting byte offset in thestring array
count Number of bytes to transfer
handle Index of the message to write to
ptr Position in the message buffer to write at
Output Parameters
Parameter Description
ptr Index pointing to the next data item in the message
1-17 sv.write_adoubl
1-17 sv.write_adoubl
Write an array of doubles to the output message at the specified offset.
Syntax
1
sv.write_adoubl(first_index, value[], n_items, handle, ptr)
Input Parameters
Parameter Description
first_index First index in the array to write
value[] Array of data values to write
n_items Number of items in value[] to write into the buffer
handle Index of the message to write to
ptr Position in the message buffer to write at
Output Parameters
Parameter Description
ptr Index pointing to the next data item in the message
1-18 sv.write_ashort
Write an array of shorts to the output message at the specified offset.
Syntax
sv.write_ashort(first_index, value[], n_items, handle, ptr)
Input Parameters
Parameter Description
first_index First index in the array to write
value[] Array of data values to write
n_items Number of items in value[] to write into the buffer
handle Index of the message to write to
ptr Position in the message buffer to write at
Output Parameters
Parameter Description
ptr Index pointing to the next data item in the message
1-19 sv.write_asingl
1-19 sv.write_asingl
Write an array of floats to the output message at the specified offset.
Syntax
1
sv.write_asingl(first_index, value[], n_items, handle, ptr)
Input Parameters
Parameter Description
first_index First index in the array to write
value[] Array of data values to write
n_items Number of items in value[] to write into the buffer
handle Index of the message to write to
ptr Position in the message buffer to write at
Output Parameters
Parameter Description
ptr Index pointing to the next data item in the message
1-20 sv.write_astrin
Write an array of strings to the output message at the specified offset.
Syntax
sv.write_astrin(first_index, $value[], n_items, handle, ptr)
Input Parameters
Parameter Description
first_index First index in the array to write
$value[] Array of data values to write
n_items Number of items in value[] to write into the buffer
handle Index of the message to write to
ptr Position in the message buffer to write at
Output Parameters
Parameter Description
ptr Index pointing to the next data item in the message
1-21 sv.write_bool
1-21 sv.write_bool
Write a boolean to the output message at the specified offset.
Syntax
1
sv.write_bool(value, handle, ptr)
Input Parameters
Parameter Description
value Value to write
handle Index of the message to write to
ptr Position in the message buffer to write at
Output Parameters
Parameter Description
ptr Index pointing to the next data item in the message
Example
.PROGRAM ex1.msg(handle, ptr)
; ABSTRACT: Demonstrate writing then reading to a message buffer
;
INPUTS: handle: Index of the message to write into
; ptr: Position in the message buffer
1-22 sv.write_byte
1-22 sv.write_byte
Write a byte to the output message at the specified offset.
Syntax
1
sv.write_byte(value, handle, ptr)
Input Parameters
Parameter Description
value Value to write
handle Index of the message to write to
ptr Position in the message buffer to write at
Output Parameters
Parameter Description
ptr Index pointing to the next data item in the message
Example
.PROGRAM ex1.msg(handle, ptr)
; ABSTRACT: Demonstrate writing then reading to a message buffer
;
INPUTS: handle: Index of the message to write into
; ptr: Position in the message buffer
1-23 sv.write_hdr
1-23 sv.write_hdr
Write the header for an output message.
Syntax
1
sv.write_hdr(handle, ptr)
Input Parameters
Parameter Description
handle Index of the message to write to
ptr Position in the message buffer to write at
Output Parameters
None
1-24 sv.write_short
Write a 16-bit integer to the output message at the specified offset.
Syntax
sv.write_short(value, handle, ptr)
Input Parameters
Parameter Description
value Value to write
handle Index of the message to write to
ptr Position in the message buffer to write at
Output Parameters
Parameter Description
ptr Index pointing to the next data item in the message
Example
.PROGRAM ex1.msg(handle, ptr)
; ABSTRACT: Demonstrate writing then reading to a message buffer
;
INPUTS: handle: Index of the message to write into
; ptr: Position in the message buffer
1-24 sv.write_short
; Read the data that was written
CALL sv.read_bool(handle, saved.ptr, bool.val)
CALL sv.read_byte(handle, saved.ptr, byte.val)
CALL sv.read_double(handle, saved.ptr, double.val)
CALL sv.read_short(handle, saved.ptr, short.val)
CALL sv.read_single(handle, saved.ptr, single.val) 1
CALL sv.read_string(handle, saved.ptr, $string.val)
CALL sv.read_trans(handle, saved.ptr, trans.val)
.END
1-25 sv.write_single
Write a float to the output message at the specified offset.
Syntax
sv.write_single(value, handle, ptr)
Input Parameters
Parameter Description
value Value to write
handle Index of the message to write to
ptr Position in the message buffer to write at
Output Parameters
Parameter Description
ptr Index pointing to the next data item in the message
Example
.PROGRAM ex1.msg(handle, ptr)
; ABSTRACT: Demonstrate writing then reading to a message buffer
;
INPUTS: handle: Index of the message to write into
; ptr: Position in the message buffer
1-25 sv.write_single
; Read the data that was written
CALL sv.read_bool(handle, saved.ptr, bool.val)
CALL sv.read_byte(handle, saved.ptr, byte.val)
CALL sv.read_double(handle, saved.ptr, double.val)
CALL sv.read_short(handle, saved.ptr, short.val)
CALL sv.read_single(handle, saved.ptr, single.val) 1
CALL sv.read_string(handle, saved.ptr, $string.val)
CALL sv.read_trans(handle, saved.ptr, trans.val)
.END
1-26 sv.write_string
Write a string to the output message at the specified offset.
Syntax
sv.write_string($string, handle, ptr)
Input Parameters
Parameter Description
$string Value to write
handle Index of the message to write to
ptr Position in the message buffer to write at
Output Parameters
Parameter Description
ptr Index pointing to the next data item in the message
Example
.PROGRAM ex1.msg(handle, ptr)
; ABSTRACT: Demonstrate writing then reading to a message buffer
;
INPUTS: handle: Index of the message to write into
; ptr: Position in the message buffer
1-26 sv.write_string
; Read the data that was written
CALL sv.read_bool(handle, saved.ptr, bool.val)
CALL sv.read_byte(handle, saved.ptr, byte.val)
CALL sv.read_double(handle, saved.ptr, double.val)
CALL sv.read_short(handle, saved.ptr, short.val)
CALL sv.read_single(handle, saved.ptr, single.val) 1
CALL sv.read_string(handle, saved.ptr, $string.val)
CALL sv.read_trans(handle, saved.ptr, trans.val)
.END
1-27 sv.write_trans
Write a transform to the output message at the specified offset.
Syntax
sv.write_trans(trans, handle, ptr)
Input Parameters
Parameter Description
trans Value to write
handle Index of the message to write to
ptr Position in the message buffer to write at
Output Parameters
Parameter Description
ptr Index pointing to the next data item in the message
Example
.PROGRAM ex1.msg(handle, ptr)
; ABSTRACT: Demonstrate writing then reading to a message buffer
;
INPUTS: handle: Index of the message to write into
; ptr: Position in the message buffer
1-27 sv.write_trans
; Read the data that was written
CALL sv.read_bool(handle, saved.ptr, bool.val)
CALL sv.read_byte(handle, saved.ptr, byte.val)
CALL sv.read_double(handle, saved.ptr, double.val)
CALL sv.read_short(handle, saved.ptr, short.val)
CALL sv.read_single(handle, saved.ptr, single.val) 1
CALL sv.read_string(handle, saved.ptr, $string.val)
CALL sv.read_trans(handle, saved.ptr, trans.val)
.END
2-1 as.save.image
Save the image associated with the vision tool into a file.
Syntax
as.save.image($filename, $ip, seq.idx, tool.idx, status)
Input Parameters
Parameter Description
$filename The name of the file to save into
$ip The IP address of the PC
seq.idx The index of the sequence
tool.idx The index of the virtual camera ; or other image tool
Output Parameters
Parameter Description
status Status of the operation. 0 = Success
2-2 check_tracking
This function is used to check if the robot is successfully tracking the belt
2-2 check_tracking
Syntax
check_tracking(tracking_ok)
2
Input Parameters
None
Output Parameters
Parameter Description
tracking_ok If true, the robot is tracking the belt successfully; other-
wise an error occured while tracking the belt
2-3 clear_queue
Clears a Robot Vision Manager queue.
Syntax
clear_queue(queue_index)
Input Parameters
Parameter Description
queue_index The index of the queue to clear
Output Parameters
None
2-4 getinstance
This function is the main function called to retrieve the instance.
2-4 getinstance
Syntax
getinstance(queue_index, flags, location, model, encoder, visionx, visiony, visionrot)
2
Input Parameters
Parameter Description
queue_index This is the queue index in which we want to retrieve
the instance
flags Flag bits to control operation of the routine:
• Bit 1: If set, routine waits for queue element to be
defined; otherwise, "fail" if the element is not de-
fined
• Bit 2: If set, do not remove the instance from the
queue; otherwise, remove the instance from the
queue.
• Bit 3: If set, we are sure there is an instance in the
queue. When using this bit, the calling program is
responsible for checking if an instance is ready in
the queue; otherwise, getinstance will check if there
is an instance before retrieving it from the queue.
Output Parameters
Parameter Description
location Location of the part found by the Robot Vision Manag-
er. The location can be relative to the belt reference
frame or the robot reference frame depending on the
option selected in the communication tool on the Ro-
bot Vision Manager side.model.
model Model Index (-1 if there was an error)
encoder Contains the encoder value when the instance was
found.
visionx Countains the part X position in the vision coordinates
reference frame
visiony Countains the part Y position in the vision coordinates
reference frame
visionrot Countains the part Rotation in the vision coordinates
reference frame
2-5 reset_seq
Reset a Robot Vision Manager sequence.
Syntax
reset_seq($myip, seq_id)
Input Parameters
Parameter Description
$myip String containing the IP Address of the Robot Vision
Manager vision server
seq_id Index of the sequence to reset
Output Parameters
None
2-6 set_as_exec_mod
2-6 set_as_exec_mod
Set the Robot Vision Manager execution mode for a given sequence.
Syntax
set_as_exec_mod($myip, seq_id, mode)
2
Input Parameters
Parameter Description
$myip String containing the IP Address of the Robot Vision
Manager vision server
seq_id Index of the sequence to reset
mode Desired Robot Vision Manager execution.
0 = Single execution mode; otherwise: Continuous ex-
ecution mode
Output Parameters
None
3-1 ee.chk.er
Checks the status of the end-effector for extend or release input signals. The gripper waits until the
end-effector reaches the desired state before moving.
Syntax
ee.chk.er(ee.idx, tip.idx, state, sts)
Input Parameters
Parameter Description
ee.idx Index of the end-effector
tip.idx Zero-based index of the tip to access
state State of the gripper
Output Parameters
Parameter Description
sts Status of operation
3-2 ee.chk.oc
Checks the status of the gripper for an open or close input signal. The robot waits until the gripper
reaches the desired state.
Syntax
3-2 ee.chk.oc
ee.chk.oc(tsk.idx, tip.idx, state, sts)
Input Parameters
Parameter Description 3
tsk.idx Index of the task
tip.idx Zero-based index of the tip to access
state State of the gripper
Output Parameters
Parameter Description
sts Status of operation
3-3 ee.clroff
Clears all refinement offsets associated with the end-effector.
Syntax
ee.clroff(ee.idx, sts)
Input Parameters
Parameter Description
ee.idx Index of the end-effector
Output Parameters
Parameter Description
sts Status of operation
3-4 ee.gr.settle
Waits for the required settling time for the end-effector.
Syntax
3-4 ee.gr.settle
ee.gr.settle(ee.idx, tip.idx, state, sts)
Input Parameters
Parameter Description
ee.idx Index of the end-effector
3
tip.idx Zero-based index of the tip to access
state State of the gripper
Output Parameters
Parameter Description
sts Status of operation
3-5 ee.gr.tip.er
Changes the extend or retract state of the gripper tip for the specified robot.
Syntax
ee.gr.tip.er(tsk.idx, tip.idx, state)
Input Parameters
Parameter Description
tsk.idx Index of the task
tip.idx Zero-based index of the tip to access
state State of the gripper
Output Parameters
None
3-6 ee.presence
Check if the part presence sensor is in the desired state. The robot waits until the gripper reaches the
desired state.
Syntax
3-6 ee.presence
ee.presence(tsk.idx, tip.idx, state, sts)
Input Parameters
Parameter Description 3
tsk.idx Index of the end-task
tip.idx Zero-based index of the tip to access
state Desired state of the part presence sensors
Output Parameters
Parameter Description
sts Status of operation
3-7 ee.release
Turns the release signals on the end-effector on or off.
Syntax
ee.release(ee.idx, tip.idx, state, sts)
Input Parameters
Parameter Description
tip.idx Zero-based index of the tip to access:
-1 All tips
Output Parameters
Parameter Description
sts Status of operation
3-8 ee.select
Performs a tip selection, extending or retracting tips as needed. It also checks to see if a tip selection
programis associated with the current robot end-effector. If one is specified it is executed.
Abstract
3-8 ee.select
ee.select(ee.idx, tip.idx)
Input Parameters
Parameter Description 3
ee.idx Index of the end-effector
tip.idx Zero-based index of the tip to access:
-1 All tips
Output Parameters
None
Example
.PROGRAM a.ex2.gripper(ee.idx)
;
AUTO REAL sts
AUTO LOC tool.trans
.END
3-9 ee.select.ck
Checks for any end-effector selection errors.
Syntax
3-9 ee.select.ck
ee.select.ck(ee.idx, tip.idx, sts)
Input Parameters
Parameter Description
ee.idx Index of the end-effector
3
tip.idx Zero-based index of the tip to access
Output Parameters
Parameter Description
sts Status of operation
3-10 ee.setoff
Associates an offset with a specific end-effector tip.
Syntax
ee.setoff(ee.idx, tip.idx, tool.trans, sts)
Input Parameters
Parameter Description
ee.idx Index of the end-effector
tip.idx Zero-based index of the tip to access
tool.trans Gripper tip transform
Output Parameters
Parameter Description
sts Status of operation
Example
.PROGRAM a.ex2.gripper(ee.idx)
;
AUTO REAL sts
AUTO LOC tool.trans
.END
3-10 ee.setoff
3
3-11 ee.state
Changes the state of the end-effector tip.
Syntax
ee.state(ee.idx, tip.idx, state, check.inputs, sts)
Input Parameters
Parameter Description
ee.idx Index of the end-effector
tip.idx Zero-based index of the tip to access
state State of the gripper
check.inputs Check to see if the end-effector is waiting for an input
Output Parameters
Parameter Description
sts Status of operation
Example
.PROGRAM a.ex2.gripper(ee.idx)
;
AUTO REAL sts
AUTO LOC tool.trans
.END
3-11 ee.state
3
3-12 ee.tip.erdw
Performs the required extend or retract dwell of the end-effector tip.
Syntax
ee.tip.erdw(ee.idx, tip.idx)
Input Parameters
Parameter Description
ee.idx Index of the end-effector
tip.idx Zero-based index of the tip to access
Output Parameters
None
3-13 ee.tip.oc
Changes the open and closed state of the end-effector tip.
Syntax
ee.tip.oc(ee.idx, tip.idx, state, sts)
3-13 ee.tip.oc
Input Parameters
Parameter Description
ee.idx Index of the end-effector
3
tip.idx Zero-based index of the tip to access
state State of the gripper
Output Parameters
Parameter Description
sts Status of operation
3-14 ee.unselect
Retracts all of the end-effector tips.
Syntax
ee.unselect(ee.idx)
Input Parameters
Parameter Description
ee.idx Index of the end-effector
Output Parameters
None
Example
.PROGRAM a.ex2.gripper(ee.idx)
;
AUTO REAL sts
AUTO LOC tool.trans
.END
4-1 pm.ace.blt.cam
Indicate to ACE that a camera needs to be triggered.
Syntax
pm.ace.blt.cam(tsk.idx, $camera, remote, encoder)
4-1 pm.ace.blt.cam
Input Parameters
Parameter Description
tsk.idx Index of the task
$camera Name of the camera that needs to be triggered
remote Is the camera remote or local?
encoder Encoder reference 4
Output Parameters
None
Typical Use
This program is always used in the context of a belt monitoring program. Create a custom belt pro-
gram to see this in use.
4-2 pm.ace.blt.ltch
Send a command to the PC that a latch has been detected.
Syntax
pm.ace.blt.ltch(blt.idx, enc, latch, value, $tag)
Input Parameters
Parameter Description
tsk.idx Index of the task
$camera Name of the camera that needs to be triggered
remote Is the camera remote or local?
encoder Encoder reference
Output Parameters
None
Typical Use
This program is always used in the context of a belt monitoring program. Create a custom belt pro-
gram to see this in use or refer to the Process Manager documentation under the Belt Monitoring sec-
tion.
Note that if the user passes in a $tag, all instances created relative to that latch event will be assigned
the specified tag.
4-3 pm.ace.blt.pos
Send the current belt position to the PC.
Syntax
pm.ace.blt.pos(blt.idx, encoder, encoder.value, encoder.vel)
4-3 pm.ace.blt.pos
Input Parameters
Parameter Description
tsk.idx Index of the task that owns the belt being updated
encoder Index of the encoder being updated
encoder.value The encoder position
encoder.vel The encoder velocity 4
Output Parameters
None
Typical Use
This program is always used in the context of a belt monitoring program. Create a custom belt pro-
gram to see this in use.
4-4 pm.ace.blt.sp
Indicate to ACE that a part/target belt spacing event has occurred.
Syntax
pm.ace.blt.sp(blt.idx, $spacing, value, $tag)
Input Parameters
Parameter Description
blt.idx Index of the task that owns the belt being updated
$spacing Name of the part/target to which the spacing is relative
value Encoder value defining the location
$tag Tag to associate with instances created
Output Parameters
None
Typical Use
This program is always used in the context of a belt monitoring program. Create a custom belt pro-
gram to see this in use or refer to the Process Manager documentation under the Belt Monitoring sec-
tion.
Note that if the user passes in a $tag, all instances created relative to that spacing event will be as-
signed the specified tag.
.
4-5 pm.ace.pkstate
Change the run state of a process manager. This program is called by the startup program to start/
stop a process manager application.
Syntax
pm.ace.pkstate($manager, state, time.out, sts)
4-5 pm.ace.pkstate
Input Parameters
Parameter Description
$manager Process manager name
state The desired state where True = Start False = Stop
time.out Time (in s) which rm.execute is allowed to run 4
Output Parameters
Parameter Description
sts Status of the operation
4-6 pm.ace.ref
Sends a refinement request to the PC.
Syntax
pm.ace.ref(tsk.idx, $ref.name, sts)
Input Parameters
Parameter Description
tsk.idx Index of the task requiring refinement
$ref.name Name of the refinement operation
Output Parameters
Parameter Description
sts Status of the operation
Typical Use
This program is always used in the context of a refinement program. Create a custom refinement pro-
gram to see an example.
4-7 pm.ace.ref.wt
Wait for the refinement operation to complete.
Syntax
pm.ace.ref.wt(tsk.idx, time.out, loc, sts)
4-7 pm.ace.ref.wt
Input Parameters
Parameter Description
tsk.idx Index of the task
time.out Maximum amount of time to wait for the operation
4
Output Parameters
Parameter Description
sts Status of the operation
Typical Use
This program is always used in the context of a refinement program. Create a custom refinement pro-
gram to see an example.
4-8 pm.blt.convert
Convert a real world reference location to an encoder value in range between min/max.
This program is always used in the context of a belt monitoring program. Create a custom belt pro-
gram to see this in use.
Syntax
pm.blt.convert(encoder)
Input Parameters
Parameter Description
encoder The encoder reference to convert
Output Parameters
Parameter Description
encoder The converted position
4-9 pm.blt.travel
Determine the distance the belt has traveled between 2 encoder values.
Syntax
pm.blt.travel(point.1, point.2, distance)
4-9 pm.blt.travel
Input Parameters
Parameter Description
point.1 The first encoder position
point.2 The second encoder position
4
Output Parameters
Parameter Description
distance The distance between the 2 positions
Typical Use
This program is always used in the context of a belt monitoring program. Create a custom belt pro-
gram to see this in use.
.
4-10 pm.chk.run
Check to see if a process application is running.
Syntax
pm.chk.run(run)
Input Parameters
None
Output Parameters
Parameter Description
run Checks to see if a process manager application is run-
ning
True - ACE and a process manager application are
running
False - ACE and/or the process manager application
are not running.
4-11 pm.chk.stat
Determine if both the process manager application is running and the ACE server is running. Process
manager tasks uses this method to check if they should continue running.
Syntax
pm.chk.stat(run)
4-11 pm.chk.stat
Input Parameters
None
Output Parameters 4
Parameter Description
run True - ACE and a process manager application are
running
False - ACE and/or the process manager application
are not running
Example
.PROGRAM cu.robot()
; ABSTRACT: Custom robot program for the Process Manager
; Process Strategy.
tsk.idx = TASK()
; Control loop
DO
; Perform a pick
CALL pm.rob.pick(tsk.idx, part.idx, -1, , is.reset, sts)
; Perform a place
CALL pm.rob.place(tsk.idx, target.idx, part.idx, -1, , is.reset, sts)
4-12 pm.chk.tskerr
Check for error conditions and display an error if one exists on the specified task.
Syntax
pm.chk.tskerr(tsk.idx, resp.mask, code, resp)
4-12 pm.chk.tskerr
Input Parameters
Parameter Description
tsk.idx Index of the task
resp.mask Possible responses to the error
4
Output Parameters
Parameter Description
code Detected error code, or 0 if no error detected
resp Response to the error
Example
.PROGRAM cu.robot()
; ABSTRACT: Custom robot program for the Process Manager
; Process Strategy.
tsk.idx = TASK()
; Control loop
DO
; Perform a pick
CALL pm.rob.pick(tsk.idx, part.idx, -1, , is.reset, sts)
; Perform a place
CALL pm.rob.place(tsk.idx, target.idx, part.idx, -1, , is.reset, sts)
4-13 pm.def.btn.txt
Define the text associated with a response button for the next error reported on a given task. This
method must be called before calling pm.error.
Syntax
pm.def.btn.txt(tsk.idx, button, $text)
4-13 pm.def.btn.txt
Input Parameters
Parameter Description
tsk.idx Index of the task
button Response code associated with the button
$text Text associated with the button. "" will clear the text. 4
Output Parameters
None
4-14 pm.def.err.txt
Define a custom text message associated with an error for the next error reported on the specified
task index. This method must be called before calling pm.error.
Syntax
pm.def.err.txt(tsk.idx, $text)
Input Parameters
Parameter Description
tsk.idx Index of the task
$text Text associated with the error. "" will clear the text.
Output Parameters
None
4-15 pm.fdr.state
Updates the state of a feeder on the PC.
Syntax
pm.fdr.state($name, state)
4-15 pm.fdr.state
Input Parameters
Parameter Description
$name Name of the feeder part or target
state State of the feeder:
pm.fst.avail Is available
pm.fst.busy Is not available 4
pm.fst.cycle Is cycling
pm.fst.hshk Waiting for handshake
Output Parameters
None
4-16 pm.get.free.tsk
Selects an available task that can be used. Tasks from first.tsk to last.tsk are scanned and the first
available one is returned
Syntax
pm.get.free.tsk(first.tsk, last.tsk, tsk.num)
Input Parameters
Parameter Description
first.task The task number at which to start scanning
last.task The task number at which we want to stop scanning
Output Parameters
Parameter Description
task.num The task number. If value is -1, no available task was
found.
4-17 pm.get.type
Gets the friendly name for a given part / target type name
Syntax
pm.get.type(rob.idx, $type, $f.name)
4-17 pm.get.type
Input Parameters
Parameter Description
rob.idx Index of the robot task
$type The name of the type
4
Output Parameters
Parameter Description
$f.name The friendly name of the type
4-18 pm.gr.clroff
Clears all refinement offsets associated with the gripper.
Syntax
pm.gr.clroff(tsk.idx, sts)
Input Parameters
Parameter Description
tsk.idx Index of the task
Output Parameters
Parameter Description
sts Status of the operation
4-19 pm.gr.release
Turn on/off the gripper release signals.
Syntax
pm.gr.release(tsk.idx, tip.idx, state, sts)
4-19 pm.gr.release
Input Parameters
Parameter Description
tsk.idx Index of the task
tip.idx Zero-based index of the tip to access
-1 = All tips
0...N = The tip to operate with 4
state State of the gripper
Output Parameters
Parameter Description
sts Status of the task
4-20 pm.gr.select
Perform a tip selection, extending or retracting tips as needed. It also checks if a tip selection program
is associated with the current robot gripper. If one is specified it will be executed.
Syntax
pm.gr.select(tsk.idx, tip.idx)
Input Parameters
Parameter Description
tsk.idx Index of the task
tip.idx Zero-based index of the tip to access
-1 = All tips
0...N = The tip to operate with
Output Parameters
None
Example
.PROGRAM a.ex2.gripper(ee.idx)
;
AUTO REAL sts
AUTO LOC tool.trans
.END
4-20 pm.gr.select
4
4-21 pm.gr.select.ck
Check for any gripper selection errors.
Syntax
pm.gr.select.ck(tsk.idx, tip.idx, resp)
Input Parameters
Parameter Description
tsk.idx Index of the task
tip.idx Zero-based index of the tip to access
Output Parameters
Parameter Description
resp User response to an error
4-22 pm.gr.setoff
Associates an offset with a specific gripper tip.
Syntax
pm.gr.setoff(tsk.idx, tip.idx, tool.trans, sts)
4-22 pm.gr.setoff
Input Parameters
Parameter Description
tsk.idx Index of the task
tip.idx Zero-based index of the tip to access
tool.trans Gripper tip transform
4
Output Parameters
Parameter Description
sts Status of the operation
Example
.PROGRAM a.ex2.gripper(ee.idx)
;
AUTO REAL sts
AUTO LOC tool.trans
.END
4-23 pm.gr.settle
Wait for the required settling time for the gripper.
Syntax
pm.gr.settle(tsk.idx, tip.idx, state, sts)
4-23 pm.gr.settle
Input Parameters
Parameter Description
tsk.idx Index of the task
tip.idx Zero-based index of the tip to access
state Desired state of the gripper
4
Output Parameters
Parameter Description
sts Status of the operation
4-24 pm.gr.state
Change the state of the gripper tip for the specified robot.
Syntax
pm.gr.state(tsk.idx, tip.idx, state, check.inputs, sts)
Input Parameters
Parameter Description
tsk.idx Index of the task
tip.idx Zero-based index of the tip to access
state Desired state of the gripper
check.inputs Do we wait for inputs?
Output Parameters
Parameter Description
sts Status of the operation
Example
.PROGRAM a.ex2.gripper(ee.idx)
;
AUTO REAL sts
AUTO LOC tool.trans
.END
4-24 pm.gr.state
4
4-25 pm.gr.trans
Associates an offset with a specific gripper tip.
Syntax
pm.gr.trans(tsk.idx, tip.idx, tool.trans, sts)
Input Parameters
Parameter Description
tsk.idx Index of the task
tip.idx Zero-based index of the tip to access
Output Parameters
Parameter Description
tool.trans The gripper tip transformation
sts Status of the operation
Example
.PROGRAM a.ex2.gripper(ee.idx)
;
AUTO REAL sts
AUTO LOC tool.trans
.END
4-25 pm.gr.trans
4
4-26 pm.gr.unselect
Retract all the tips.
Syntax
pm.gr.unselect(tsk.idx)
Input Parameters
Parameter Description
tsk.idx Index of the task
Output Parameters
None
Example
.PROGRAM a.ex2.gripper(ee.idx)
;
AUTO REAL sts
AUTO LOC tool.trans
.END
4-27 pm.log
Send text associated with the current task to the AceServer log file.
Syntax
pm.log($text)
Input Parameters
4-27 pm.log
Parameter Description
$text The text to append to the AceServer log on the PC
Output Parameters 4
None
Additional Notes
The pm.log method should only be called on a process manager task. The program will check to see
if logging is enabled before sending the log string to the PC. The variable pm.log will enable logging
on all V+ process manager tasks. If you want to enable logging for an individual V+ task, the variable
pm.tsk.log [TASK()] can be set to TRUE.
4-28 pm.mv
Perform a move to the location using the specified motion parameters.
Syntax
pm.mv(blt.idx, position, offset, pars[])
Input Parameters
Parameter Description
blt.idx Belt number to move relative to.
• 0 = Non-belt relative move
• > 0 = Belt relative move
position Position to move to
offset Starting index in the motion parameters array
pars[] Motion parameters array
Output Parameters
None
Additional Notes
The pars[] parameter uses the following offset values when applying the motion parameters:
Variable Usage
pm.fv.spd The speed percentage
pm.fmv.spdmd The Speed Mode
pm.fmv.accel The accelaration percentage
pm.fmv.decel The deceleration percentage
pm.fmv.dur The move duration
pm.fmv.scv The S-curve profile
pm.fmv.straigh Is straight line motion requested?
pm.fmv.motend Motioin end parameter
pm.fmv.stlpct The settle percentage
pm.fmv.break Should it wait until motion is done?
pm.fmv.single Single/multiple mode
pm.fmv.righty Right/Lefty mode
pm.fmv.above Above/below mode
pm.fmv.flip Flip/No-flip
For a standard motion sequence, the following values are used for the offset parameter.
Variable Usage
pm.ms.aoffset Approach motion segment
pm.ms.poffset Move motion segment
For a standard vision refinement sequence, the following values are used for the offset parameter.
Variable Usage
pm.vrf.aoffset Approch motion segment
pm.vrf.poffset Move motion segment
pm.vrf.doffset Depart motion segment
4-28 pm.mv
4
4-29 pm.mv.attach
Attach the robot to the current task.
Syntax
pm.mv.attach(tsk.idx, rob.num)
Output Parameters
None
Input Parameters
Parameter Description
tsk.idx Index of the task
rob.num Robot number to attach
Additional Notes
For a robot task, the global variable pm.tsk.robnum[] saves the robot number associated with the
task.
Example
.PROGRAM cu.robot()
; ABSTRACT: Custom robot program for the Process Manager
; Process Strategy.
tsk.idx = TASK()
; Control loop
DO
; Perform a pick
CALL pm.rob.pick(tsk.idx, part.idx, -1, , is.reset, sts)
; Perform a place
CALL pm.rob.place(tsk.idx, target.idx, part.idx, -1, , is.reset, sts)
4-29 pm.mv.attach
; Move to the current destination to ensure
; we are no longer tracking a belt.
CALL pm.mv.dest(tsk.idx)
4-30 pm.mv.chkbrk
Check for a break in motion using the specified motion parameters.
Syntax
pm.mv.chkbrk(offset, pars[])
Input Parameters
Parameter Description
offset Starting index in the motion parameters array
pars[] Motion parameters array
Output Parameters
None
4-31 pm.mv.dest
Move to the current destination. Used to stop robot from tracking a part.
Syntax
pm.mv.dest(rob.idx)
4-31 pm.mv.dest
Input Parameters
Parameter Description
rob.idx Index of the robot
Output Parameters 4
None
Example
.PROGRAM cu.robot()
; ABSTRACT: Custom robot program for the Process Manager
; Process Strategy.
tsk.idx = TASK()
; Control loop
DO
; Perform a pick
CALL pm.rob.pick(tsk.idx, part.idx, -1, , is.reset, sts)
; Perform a place
CALL pm.rob.place(tsk.idx, target.idx, part.idx, -1, , is.reset, sts)
4-32 pm.mv.idle
Move a robot to the idle location. The robot first retracts the Z axis (maintaining the current XY posi-
tion) to the level of the idle position. Once retracted it moves to idle.
Syntax
pm.mv.idle(rob.idx)
4-32 pm.mv.idle
Input Parameters
Parameter Description
rob.idx Index of the robot
4
Output Parameters
None
Example
.PROGRAM cu.robot()
; ABSTRACT: Custom robot program for the Process Manager
; Process Strategy.
tsk.idx = TASK()
; Control loop
DO
; Perform a pick
CALL pm.rob.pick(tsk.idx, part.idx, -1, , is.reset, sts)
; Perform a place
4-33 pm.proc.enable
Enable or disable a process based on the process index.
Syntax
pm.proc.enable($manager, proc.idx, state, sts)
4-33 pm.proc.enable
Input Parameters
Parameter Description
$manager Name of the process manager
proc.idx Index of the process
state State of the process
• TRUE = Enable the process 4
• FALSE = Disable the process
Output Parameters
Parameter Description
sts Status of the operation:
• 0 = successs
• <0 = error
4-34 pm.prt.avail
Gets the number of available parts for the robot.
Syntax
pm.prt.avail(rob.idx, part.idx, count)
Input Parameters
Parameter Description
rob.idx Index of the robot task
part.idx Part index to access
Output Parameters
Parameter Description
count Number of items available in the queue
Example
.PROGRAM a.ex2.qlookup()
4-35 pm.prt.done
Indicate a part has been processed.
Syntax
pm.prt.done(rob.idx, part.idx, obj.idx, sts)
4-35 pm.prt.done
Input Parameters
Parameter Description
rob.idx Index of the robot
part.idx Part index to access
obj.idx Index of the instance/object to mark as done
sts Was the part processed by the robot: 4
• TRUE = part was processed
• FALSE = part was not processed
Output Parameters
None
4-36 pm.prt.get
Gets a part from the buffer.
Syntax
pm.prt.get(rob.idx, part.idx, obj.idx, $id, position, reference, pal.idx)
Input Parameters
Parameter Description
rob.idx Index of the robot
part.idx Part index to access
obj.idx Index of the object/instance to extract
Output Parameters
Parameter Description
$id Unique identifier of the part
position Position of the part
reference Reference position of the part
pal.idx Pallet index associated with the instance
Example
.PROGRAM a.ex2.queues()
;
AUTO REAL i, rob.idx, inst.idx
AUTO REAL reference, pal.idx, sts, time, pct
AUTO LOC position
AUTO.$id, $source
TYPE " Position = ", DX(position), ", ", DY(position), ", ", DZ(position)
TYPE " Reference = ", reference
TYPE " Pallet Index = ", pal.idx
TYPE " Status = ", sts
TYPE " Time = ", time
TYPE " Source = ", $source
TYPE " Location % = ", pct
TYPE " "
CALL pm.prt.move.ptr(inst.idx)
END
4-36 pm.prt.get
END
CALL pm.trg.move.ptr(inst.idx)
END
END
.END
4-37 pm.prt.get.idx
Get the index of the part buffer for a given robot task.
Syntax
pm.prt.get.idx(rob.idx, $part, part.idx)
Input Parameters
Parameter Description
rob.idx Index of the robot
$part Part name to search for
Output Parameters
Parameter Description
part.idx Part index in the robot part buffer. -1 = No matching
part was found
Example
.PROGRAM a.ex2.qlookup()
4-38 pm.prt.getloc
Get the location of a given part in the belt window.
Syntax
pm.prt.getloc(rob.idx, part.idx, obj.idx, pct)
4-38 pm.prt.getloc
Input Parameters
Parameter Description
rob.idx Index of the robot task
part.idx Part index to access
obj.idx Index of the object/instance to access
4
Output Parameters
Parameter Description
pct Percentage of travel along the belt
Example
.PROGRAM a.ex2.queues()
;
AUTO REAL i, rob.idx, inst.idx
AUTO REAL reference, pal.idx, sts, time, pct
AUTO LOC position
AUTO.$id, $source
CALL pm.prt.move.ptr(inst.idx)
END
END
CALL pm.trg.move.ptr(inst.idx)
END
END
.END
4-39 pm.prt.move.ptr
Increment the pointer to the next slot in the buffer.
Syntax
pm.prt.move.ptr(ptr)
4-39 pm.prt.move.ptr
Input Parameters
Parameter Description
ptr The pointer to increment
Output Parameters 4
Parameter Description
ptr The incremented pointer
Example
.PROGRAM a.ex2.queues()
;
AUTO REAL i, rob.idx, inst.idx
AUTO REAL reference, pal.idx, sts, time, pct
AUTO LOC position
AUTO.$id, $source
CALL pm.prt.move.ptr(inst.idx)
END
END
CALL pm.trg.move.ptr(inst.idx)
END
END
.END
4-40 pm.ps.error
Report an error and wait for a response.
Syntax
pm.ps.error(tsk.idx, code, resp.mask, resp)
4-40 pm.ps.error
Input Parameters
Parameter Description
tsk.idx Index of the task
code Error code/status of the operation
resp.mask Mask of available response options
4
Output Parameters
Parameter Description
resp The user response to the error
4-41 pm.ps.map.idx
Converts a process index from the PC to a robot-relative index.
Syntax
pm.ps.map.idx(proc.idx, map.idx)
Input Parameters
Parameter Description
proc.idx Process index from the PC
Output Parameters
Parameter Description
map.idx Robot relative index for the process
Example
.PROGRAM cu.robot2()
; ABSTRACT: Custom robot program for the Process Manager
; Process Strategy.
tsk.idx = TASK()
; Get the index associated with the first two processes in the process manager
CALL pm.ps.map.idx(0, proc.idx.1)
CALL pm.ps.map.idx(1, proc.idx.2)
; Control loop
DO
RETURN
4-41 pm.ps.map.idx
.END
4-42 pm.ps.power
Change the power status of the system. If power is enabled, issue a calibration request, if needed. If
power cannot be enabled, it will report an error. Because of this, this method is not intended to be
used from within a custom error program. It may lead to a recursive call and a stack overflow.
Syntax
pm.ps.power(tsk.idx, enable)
Input Parameters
Parameter Description
tsk.idx The task index for error reporting
enable Enable the power.
Output Parameters
None
4-43 pm.rob.chkidle
Check the status when the robot is idle, including checking for the robot cycle stop condition.
Syntax
pm.rob.chkidle(rob.idx, part.type, grip.idx, excl[], is.reset, sts)
4-43 pm.rob.chkidle
Input Parameters
Parameter Description
tsk.idx Index of the robot task
start.time The reference time when the robot entered idle mode
in.idle Is the robot in idle mode
at.wait Is the robot at the waiting position 4
Output Parameters
Parameter Description
in.idle Is the robot in idle mode
at.wait Is the robot at the waiting position
4-44 pm.rob.clear
Move the robot to the idle position and clear the robot gripper.
Syntax
pm.rob.clear(rob.idx)
Input Parameters
Parameter Description
rob.idx Index of the robot
Output Parameters
None
Example
.PROGRAM cu.robot()
; ABSTRACT: Custom robot program for the Process Manager
; Process Strategy.
tsk.idx = TASK()
; Control loop
DO
; Perform a pick
CALL pm.rob.pick(tsk.idx, part.idx, -1, , is.reset, sts)
; Perform a place
CALL pm.rob.place(tsk.idx, target.idx, part.idx, -1, , is.reset, sts)
4-44 pm.rob.clear
; Check to see if any errors occured while we were delaying
CALL pm.chk.tskerr(tsk.idx, pm.tsk.retry, , sts)
IF (sts <> pm.tsk.success) THEN
CALL pm.mv.attach(tsk.idx, pm.tsk.robnum[tsk.idx])
END
4
; Indicate we are leaving idle mode
CALL pm.rob.idlemd(tsk.idx, FALSE, 0, "")
4-45 pm.rob.gettag
Returns the tag associated with the part or target instance currently being operated on by the robot.
Typically, this would be called from within a custom motion sequence program to access information
that was associated with a VisionTransform Tag associated with a custom vision tool or the Tag asso-
ciated with a LocatedInstance set by a custom allocation script.
Syntax
pm.rob.gettag(rob.idx, $tag)
Input Parameters
Parameter Description
tsk.idx Index of the robot
Output Parameters
Parameter Description
$tag Tag associated with the instance being processed
Example
.PROGRAM cu.mv.sequence(tsk.idx, $type, blt.idx, reference, pal.idx, grip.idx, grip
.state, pos, vals[], sts)
sts = pm.tsk.success
4-46 pm.rob.idlemd
Change the idle status of the robot. This program sets the status in global memory. It expects the proc-
ess strategy background program to perform the sending of the status to the PC.
Syntax
pm.rob.idlemd(rob.tsk, in.idle, code, $info)
4-46 pm.rob.idlemd
Input Parameters
Parameter Description
rob.tsk Index of the robot
in.idle Is the robot in idle mode?
• True = Robot is idle 4
• False = Robot is running
code Error code associated with the idle mode state. If non-
zero, an error will be reported
$info Additional information to send with the error code. This
is used by 'pm.err.no.inst' to send the name of the part
or target the robot is waiting for.
Output Parameters
None
Example
.PROGRAM cu.robot()
; ABSTRACT: Custom robot program for the Process Manager
; Process Strategy.
tsk.idx = TASK()
; Control loop
DO
; Perform a pick
CALL pm.rob.pick(tsk.idx, part.idx, -1, , is.reset, sts)
; Perform a place
CALL pm.rob.place(tsk.idx, target.idx, part.idx, -1, , is.reset, sts)
4-47 pm.rob.init
Initialize the robot by attaching the robot, clearing the TOOL, moving to the idle position, and turning
off all gripper signals.
Syntax
pm.rob.init(rob.idx)
4-47 pm.rob.init
Input Parameters
Parameter Description
rob.idx Index of the robot
4
Output Parameters
None
Example
.PROGRAM cu.robot()
; ABSTRACT: Custom robot program for the Process Manager
; Process Strategy.
tsk.idx = TASK()
; Control loop
DO
; Perform a pick
CALL pm.rob.pick(tsk.idx, part.idx, -1, , is.reset, sts)
; Perform a place
4-48 pm.rob.monque
Process the active part and targets queues and mark any out-of-range instances as done. This meth-
od should only be called on a robot task when the robot is waiting for some operation to complete.
This ensures any instances that go out of range of the robot are properly released and sent back to
the PC.
If the robot is currently processing a part or target, the index of the associated queue should be
passed as a parameter to the method.
4-48 pm.rob.monque
Syntax
pm.rob.monque(rob.tsk, part.idx, trg.idx)
Input Parameters 4
Parameter Description
rob.tsk Index of the robot
part.idx Index of a part queue to not check. -1 indicates all
queues will be checked
trg.idx Index of a target queue to not check. -1 indicates all
queues will be checked
Output Parameters
None
Example
.CALL pm.rob.monque(robtsk, -1 -1)
4-49 pm.rob.pick
Perform a single pick operation with the robot in the current task.
Syntax
pm.rob.pick(rob.idx, part.type, grip.idx, excl[], is.reset, sts)
Input Parameters
Parameter Description
rob.tsk Index of the robot
part.idx Type of part to pick
grip.idx The index of the gripper tip to use -1 = All tips
ms.type The move segment type:
• pm.ms.mv.norm - Normal Move
• pm.ms.mv.iad - Pick / place motion with intra ap-
proach and intra depart
• pm.ms.mv.iand - Pick / place with intra approach
and normal depart
• pm.ms.mv.naid - Pick / place with normal approach
and intra depart
excl[] The exclusions used when picking
Output Parameters
Parameter Description
is.reset Was the queue reset during the operation
sts Status code:
• pm.tsk.success = Successful operation
• pm.tsk.abort = Abort the operation
Example
.PROGRAM cu.robot()
; ABSTRACT: Custom robot program for the Process Manager
; Process Strategy.
tsk.idx = TASK()
; Control loop
DO
; Perform a pick
CALL pm.rob.pick(tsk.idx, part.idx, -1, , is.reset, sts)
4-49 pm.rob.pick
; Perform a place
CALL pm.rob.place(tsk.idx, target.idx, part.idx, -1, , is.reset, sts)
4-50 pm.rob.place
Perform a single place operation with the robot in the current task.
Syntax
pm.rob.place(rob.idx, target.type, part.type, grip.idx, ms.type, excl[], is.reset, sts)
Input Parameters
Parameter Description
rob.tsk Index of the robot
target.type Type of target to place
part.type The type of part being placed
grip.idx The index of the gripper tip to use -1 = All tips
ms.type The move segment type:
• pm.ms.mv.norm - Normal Move
• pm.ms.mv.iad - Pick / place motion with intra ap-
proach and intra depart
• pm.ms.mv.iand - Pick / place with intra approach
and normal depart
• pm.ms.mv.naid - Pick / place with normal approach
and intra depart
excl[] The exclusions used when picking
Output Parameters
Parameter Description
is.reset Was the queue reset during the operation
sts Status code:
• pm.tsk.success = Successful operation
• pm.tsk.abort = Abort the operation
Example
.PROGRAM cu.robot()
; ABSTRACT: Custom robot program for the Process Manager
; Process Strategy.
tsk.idx = TASK()
CALL pm.rob.init(tsk.idx)
CALL pm.rob.idlemd(tsk.idx, TRUE, 0, "")
; Control loop
DO
4-50 pm.rob.place
; Perform a pick
CALL pm.rob.pick(tsk.idx, part.idx, -1, , is.reset, sts)
; Perform a place
CALL pm.rob.place(tsk.idx, target.idx, part.idx, -1, , is.reset, sts)
4-51 pm.rob.process
Converts a process index from the PC to a robot-relative index.
Syntax
pm.rob.process(rob.idx, proc.idx, sts)
Input Parameters
Parameter Description
rob.idx Index of the robot to drive
proc.idx Process to operate with
Output Parameters
Parameter Description
sts Status code:
• pm.tsk.success = Successful operation
• pm.tsk.skip = Skip the operation
• pm.tsk.abort = Abort the operation
Example
.PROGRAM cu.robot2()
; ABSTRACT: Custom robot program for the Process Manager
; Process Strategy.
tsk.idx = TASK()
; Get the index associated with the first two processes in the process manager
CALL pm.ps.map.idx(0, proc.idx.1)
CALL pm.ps.map.idx(1, proc.idx.2)
; Control loop
DO
FOR i = 1 TO 3
CALL pm.rob.process(tsk.idx, proc.idx.1, sts)
END
4-51 pm.rob.process
UNTIL is.running == FALSE
RETURN
.END
4-52 pm.rob.refine
Refine the part in the robot gripper using vision.
Syntax
pm.rob.refine(rob.idx, refine.idx, grip.idx, sts)
Input Parameters
Parameter Description
rob.tsk Index of the robot
refine.idx Index of the refinement station
grip.idx The index of the gripper tip to use. -1 = All tips
excl[] The exclusions used when picking
Output Parameters
Parameter Description
sts Status code:
• pm.tsk.success = Successful operation
• pm.tsk.retry = Retry the operation
• pm.tsk.abort = Abort the operation
4-53 pm.rob.settag
Sets the tag associated with the part or target instance currently being operated on by the robot. Typi-
cally, this would be called from within a custom motion sequence program to set a string for the Tag
associated with a LocatedInstance set by a custom allocation script.
Syntax
4-53 pm.rob.settag
pm.rob.settag(tsk.idx, $tag)
Input Parameters
Parameter Description
tsk.idx Index of the robot
$tag Tag associated with the instance 4
Output Parameters
None
Example
.PROGRAM cu.mv.sequence(tsk.idx, $type, blt.idx, reference, pal.idx, grip.idx, grip
.state, pos, vals[], sts)
sts = pm.tsk.success
4-54 pm.sig.check
Checks for the status of a digital signal ensuring the state is valid for the specified amount of time.
This method does not block execution.
Syntax
pm.sig.check(sig, time, is.valid)
Input Parameters
Parameter Description
sig Signal to be checked
time Amount of time the signal is expected to be in the
state
Output Parameters
Parameter Description
is.valid Is the signal in the specified state
Example
.PROGRAM a.ex2.debounce()
AUTO REAL sig, is.on, debounce.time
; Define the signal and the amount of time we want the signal
; to remain on before we recognize it is on
sig = 2100
debounce.time = 2.5
is.on = FALSE
; Clear the tracking structures for the signal
CALL pm.sig.clear(sig)
; Trun the signal on
SIGNAL sig
TYPE $TIME()
; Wait until the signal has been on for the required amount of time
WHILE (is.on == FALSE) DO
CALL pm.sig.check(sig, debounce.time, is.on)
END
TYPE $TIME()
SIGNAL -sig
.END
4-55 pm.sig.clear
Clears the variables used to track the status of a signal.
Syntax
pm.sig.clear(sig)
4-55 pm.sig.clear
Input Parameters
Parameter Description
sig Signal to clear
Output Parameters 4
None
Example
.PROGRAM a.ex2.debounce()
AUTO REAL sig, is.on, debounce.time
; Define the signal and the amount of time we want the signal
; to remain on before we recognize it is on
sig = 2100
debounce.time = 2.5
is.on = FALSE
; Clear the tracking structures for the signal
CALL pm.sig.clear(sig)
; Trun the signal on
SIGNAL sig
TYPE $TIME()
; Wait until the signal has been on for the required amount of time
WHILE (is.on == FALSE) DO
CALL pm.sig.check(sig, debounce.time, is.on)
END
TYPE $TIME()
SIGNAL -sig
.END
4-56 pm.src.clear
Clear the specified source
Syntax
pm.src.clear($manager, $source, sts)
Input Parameters
Parameter Description
$manager Name of the process manager
$source The name of the source to clear
Output Parameters
Parameter Description
sts Status of operation
Example
.PROGRAM a.ex2.srcclr()
AUTO $manager
AUTO REAL sts
4-57 pm.src.clearall
Clears all sources for the specified process manager
Syntax
pm.src.clearall($manager, sts)
4-57 pm.src.clearall
Input Parameters
Parameter Description
$source The name of the source to clear
Output Parameters 4
Parameter Description
sts Status of operation
Example
.PROGRAM a.ex2.srcclr()
AUTO $manager
AUTO REAL sts
4-58 pm.trg.avail
Gets the number of available targets for the robot.
Syntax
pm.trg.avail(rob.idx, trg.idx, count)
Input Parameters
Parameter Description
rob.idx Index of the robot task
trg.idx Target index to access
Output Parameters
Parameter Description
count Number of items available in the queue
Example
.PROGRAM a.ex2.qlookup()
4-59 pm.trg.done
Indicate a target has been processed.
Syntax
pm.trg.done(rob.idx, trg.idx, obj.idx, sts)
4-59 pm.trg.done
Input Parameters
Parameter Description
rob.idx Index of the robot task
trg.idx Target index to access
obj.idx Index of the instance/object to mark as done
sts Was the instance processed by the robot: 4
• TRUE = part was processed
• FALSE = part was not processed
Output Parameters
None
4-60 pm.trg.get
Gets a target from the buffer.
Syntax
pm.trg.get(rob.idx, trg.idx, obj.idx, $id, position, reference, pal.idx)
Input Parameters
Parameter Description
rob.idx Index of the robot task
trg.idx Target index to access
obj.idx Index of the object/instance to extract
Output Parameters
Parameter Description
$id Unique identifier of the instance
position Position of the instance
reference Reference position of the instance
pal.idx Pallet index associated with the instance
Example
.PROGRAM a.ex2.queues()
;
AUTO REAL i, rob.idx, inst.idx
AUTO REAL reference, pal.idx, sts, time, pct
AUTO LOC position
AUTO.$id, $source
TYPE " Position = ", DX(position), ", ", DY(position), ", ", DZ(position)
TYPE " Reference = ", reference
TYPE " Pallet Index = ", pal.idx
TYPE " Status = ", sts
TYPE " Time = ", time
TYPE " Source = ", $source
TYPE " Location % = ", pct
TYPE " "
CALL pm.prt.move.ptr(inst.idx)
END
4-60 pm.trg.get
END
CALL pm.trg.move.ptr(inst.idx)
END
END
.END
4-61 pm.trg.get.idx
Get the index of the target buffer for a given robot task.
Syntax
pm.trg.get.idx(rob.idx, $target, target.idx)
Input Parameters
Parameter Description
rob.idx Index of the robot task
$target Target name to search for
Output Parameters
Parameter Description
target.idx Target index in the robot target buffer. -1 = No match-
ing target was found
Example
.PROGRAM a.ex2.qlookup()
4-62 pm.trg.getloc
Get the location of a given target in the belt window.
Syntax
pm.trg.getloc(rob.idx, trg.idx, obj.idx, pct)
4-62 pm.trg.getloc
Input Parameters
Parameter Description
rob.idx Index of the robot task
trg.idx Target index to access
obj.idx Index of the object/instance to access
4
Output Parameters
Parameter Description
pct Percentage of travel along the belt
Example
.PROGRAM a.ex2.queues()
;
AUTO REAL i, rob.idx, inst.idx
AUTO REAL reference, pal.idx, sts, time, pct
AUTO LOC position
AUTO.$id, $source
CALL pm.prt.move.ptr(inst.idx)
END
END
CALL pm.trg.move.ptr(inst.idx)
END
END
.END
4-63 pm.trg.move.ptr
Increment the pointer to the next slot in the buffer.
Syntax
pm.trg.move.ptr(ptr)
4-63 pm.trg.move.ptr
Input Parameters
Parameter Description
ptr The pointer to increment
Output Parameters 4
Parameter Description
ptr The incremented pointer
Example
.PROGRAM a.ex2.queues()
;
AUTO REAL i, rob.idx, inst.idx
AUTO REAL reference, pal.idx, sts, time, pct
AUTO LOC position
AUTO.$id, $source
CALL pm.prt.move.ptr(inst.idx)
END
END
CALL pm.trg.move.ptr(inst.idx)
END
END
.END
5-2 rm.app.event
Generates an application event on the PC associated with this controller.
Syntax
rm.app.event(value, wait.time, status)
Input Parameters
Parameter Description
value Numeric code representing the event.
wait.time The amount of time to wait for the operation to com-
plete.
Output Parameters
Parameter Description
status Status of the operation: 0 = success, < 0 = error
Example
.PROGRAM ex1.rm.appevt()
AUTO REAL status
CALL rm.app.event(101, 1, status)
IF (status < 0) THEN
TYPE "Unable To Send Event Code: ", status
PAUSE
END
.END
5-3 rm.chk.server
Check to see if the ACE server is running
Syntax
rm.chk.server(is.alive)
Input Parameters
None
5-3 rm.chk.server
Output Parameters
Parameter Description
is.alive Is the server alive
5
Example
.PROGRAM ex1.rm.ex()
; Execute a script on the server and wait for 3 seconds for it to complete
$object = "/C# Program"
$method = "Execute"
CALL rm.execute($object, $method, 0, $args[], 3, status)
IF (status < 0) THEN
TYPE "Problem executing script: ", status
PAUSE
END
.END
5-4 rm.execute
Execute a method on the PC and optionally wait until it has completed. The number of arguments
must match the arguments defined by the method signature of the specified method. Additionally, the
arguments must be convertable to the type expected in the method signature using a standard Type-
Converter on the PC.
Syntax
rm.execute($object, $method, num.args, $args[], wait.time, status)
Input Parameters
Parameter Description
$object The name of the remote object to access. This must
include the full path name of the object to access. e.g.
"/directory/Robot 1"
$method The name of the method to execute
num.args The number of arguments to send
$args[] The arguments to pass
wait.time The amount of time to wait for the execution to com-
plete. Units are in seconds. A value less than or equal
to 0 indicates no waiting.
Output Parameters
Parameter Description
status Status of the operation: 0 = success, < 0 = error
Example
.PROGRAM ex1.rm.ex()
; Execute a script on the server and wait for 3 seconds for it to complete
.END
5-4 rm.execute
5
5-5 rm.execute3
Execute a method on the PC and optionally wait until it has completed. The number of arguments
must match the arguments defined by the method signature of the specified method. Additionally, the
arguments must be convertable to the type expected in the method signature using a standard Type-
Converter on the PC.
Syntax
rm.execute3($ip, $object, $method, num.args, $args[], wait.time, status)
Input Parameters
Parameter Description
$ip The IP address of the PC to send the request to
$object The name of the remote object to access. This must
include the full path name of the object to access. e.g.
"/directory/Robot 1"
$method The name of the method to execute
num.args The number of arguments to send
$args[] The arguments to pass
wait.time The amount of time to wait for the execution to com-
plete. Units are in seconds. A value less than or equal
to 0 indicates no waiting.
Output Parameters
Parameter Description
status Status of the operation: 0 = success, < 0 = error
Example
.PROGRAM ex1.rm.ex()
; Execute a script on the server and wait for 3 seconds for it to complete
$object = "/C# Program"
$method = "Execute"
CALL rm.execute($object, $method, 0, $args[], 3, status)
IF (status < 0) THEN
TYPE "Problem executing script: ", status
PAUSE
END
.END
5-5 rm.execute3
5
5-6 rm.find_ip
Finds the client_handle associated with a specific IP address
Syntax
rm.find_ip($ip, client_handle)
Input Parameters
Parameter Description
$ip The IP address to find
Output Parameters
Parameter Description
client_handle The client handle associated with the IP address or -1
if not found
5-7 rm.pc.fapp
Append a single line to a file on the PC
Syntax
rm.pc.fapp($file, $line, wait.time, status)
Input Parameters
Parameter Description
$file The name of the file to append to on the PC
5-7 rm.pc.fapp
$line The line to append to the file
wait.time The amount of time to wait for the operation to com-
plete
Output Parameters 5
Parameter Description
status Status of the operation: 0 = success, < 0 = error
Example
.PROGRAM ex1.rm.pc()
$file = "C:\log.txt"
FOR i = 1 TO num.items
TYPE $items[i-1]
IF (types[i-1] == 0) THEN
TYPE " Is a file"
ELSE
TYPE " Is a directory"
END
END
5-8 rm.pc.fapps
Append an array of lines to a file on the PC
Syntax
rm.pc.fapps($file, num.lines, $lines[], wait.time, status)
Input Parameters
Parameter Description
$file The name of the file to append to on the PC
5-8 rm.pc.fapps
num.lines The number of lines in the array to copy
$lines[] The lines to append to the file, starting at index 0
wait.time The amount of time to wait for the operation to com-
plete
5
Output Parameters
Parameter Description
status Status of the operation: 0 = success, < 0 = error
Example
.PROGRAM ex1.rm.pc()
$file = "C:\log.txt"
FOR i = 1 TO num.items
TYPE $items[i-1]
IF (types[i-1] == 0) THEN
TYPE " Is a file"
ELSE
TYPE " Is a directory"
END
END
5-9 rm.pc.fapps2
Append an array of lines to a file on the PC
Syntax
rm.pc.fapps2($file, start.idx, num.lines, $lines[], wait.time, status)
Input Parameters
Parameter Description
5-9 rm.pc.fapps2
$file The name of the file to append to on the PC
start.idx The starting index in the array
num.lines The number of lines in the array to copy
$lines[] The lines to append to the file, starting at the start.in-
dex
wait.time The amount of time to wait for the operation to com-
plete 5
Output Parameters
Parameter Description
status Status of the operation: 0 = success, < 0 = error
Example
.PROGRAM ex1.rm.pc()
$file = "C:\log.txt"
FOR i = 1 TO num.items
TYPE $items[i-1]
IF (types[i-1] == 0) THEN
TYPE " Is a file"
ELSE
TYPE " Is a directory"
END
END
5-10 rm.pc.fcopy
Copy a file between the controller and the PC.
When specifying the file, one of the files must start with the prefix of 'DISK>'. This is used to determine
the direction of the file copy. If neither of the files starts with 'DISK', then it is considered a file copy
from 1 PC file to another entirely on the PC.
Syntax
rm.pc.fcopy($from.file, $to.file, wait.time, status)
5-10 rm.pc.fcopy
Input Parameters
Parameter Description
$from.file The file to copy from
$to.file The file to copy to
wait.time The amount of time to wait for the operation to com-
plete 5
Output Parameters
Parameter Description
status Status of the operation: 0 = success, < 0 = error
Example
.PROGRAM ex1.rm.pc()
$file = "C:\log.txt"
FOR i = 1 TO num.items
TYPE $items[i-1]
IF (types[i-1] == 0) THEN
TYPE " Is a file"
ELSE
TYPE " Is a directory"
END
END
5-11 rm.pc.fdel
Delete a file on the PC
Syntax
rm.pc.fdel($file, wait.time, status)
Input Parameters
Parameter Description
$file The name of the file to delete on the PC
5-11 rm.pc.fdel
wait.time The amount of time to wait for the operation to com-
plete
Output Parameters
5
Parameter Description
status Status of the operation: 0 = success, < 0 = error
Example
.PROGRAM ex1.rm.pc()
$file = "C:\log.txt"
FOR i = 1 TO num.items
TYPE $items[i-1]
IF (types[i-1] == 0) THEN
TYPE " Is a file"
ELSE
TYPE " Is a directory"
END
END
5-12 rm.pc.fdir
Perform a file and directory listing on the PC
Syntax
rm.pc.fdir($file.spec, wait.time, num.items, $items[], types[], status)
Input Parameters
Parameter Description
$file.spec The file specification to match
5-12 rm.pc.fdir
wait.time The amount of time to wait for the operation to com-
plete
Output Parameters
5
Parameter Description
num.items The number of items returned
$items[] The listing of files and directories found
types[] The types of the items found: 0 = File, 1 = Directory
status Status of the operation: 0 = success, < 0 = error
Example
.PROGRAM ex1.rm.pc()
$file = "C:\log.txt"
FOR i = 1 TO num.items
TYPE $items[i-1]
IF (types[i-1] == 0) THEN
TYPE " Is a file"
ELSE
TYPE " Is a directory"
END
END
5-13 rm.pc.log
Append text to the AceServer log on the PC
Syntax
rm.pc.log($source, $text[], length, wait.time, status)
Input Parameters
Parameter Description
$source The source generating the log message
5-13 rm.pc.log
$text The text to append to the log
wait.time The amount of time to wait for the operation to com-
plete
Output Parameters 5
Parameter Description
status Status of the operation: 0 = success, < 0 = error
Example
.PROGRAM ex1.rm.log()
5-14 rm.read.anums
Read a list of numeric property variables associated with multiple objects on the PC. The variable ref-
erenced must all be numeric types
Syntax
rm.read.anums($objects[], $variables[], wait.time, values[], status)
Input Parameters
Parameter Description
$objects[] The name of the remote objects to access. This must
include the full path name of the object to access. e.g.
"/directory/Robot 1"
$variables[] The name of the variables to access
wait.time The amount of time to wait for the operation to com-
plete
Output Parameters
Parameter Description
values[] The values of the variables
status Status of the operation: 0 = success, < 0 = error
Example
.PROGRAM ex1.rm.vars.ns()
5-14 rm.read.anums
.END
5-15 rm.read.num
Read a numeric property variable associated with an object on the PC. The variable referenced must
be a numeric type
Syntax
rm.read.num($object, $variable, wait.time, value, status)
Input Parameters
Parameter Description
$object The name of the remote object to access. This must
include the full path name of the object to access. e.g.
"/directory/Robot 1"
$variable The name of the variable to access
wait.time The amount of time to wait for the operation to com-
plete
Output Parameters
Parameter Description
value The value of the variables
status Status of the operation: 0 = success, < 0 = error
Example
.PROGRAM ex1.rm.vars.n()
5-15 rm.read.num
5
5-16 rm.read.nums
Read a list of numeric property variables associated with an object on the PC. The variable referenced
must all be numeric types
Syntax
rm.read.nums($object, $variables[], wait.time, values[], status)
Input Parameters
Parameter Description
$object The name of the remote object to access. This must
include the full path name of the object to access. e.g.
"/directory/Robot 1"
$variables[] The name of the variables to access
wait.time The amount of time to wait for the operation to com-
plete
Output Parameters
Parameter Description
values[] The values of the variables
status Status of the operation: 0 = success, < 0 = error
Example
.PROGRAM ex1.rm.vars.ns()
5-16 rm.read.nums
.END
5-17 rm.read.str
Read a string property variable associated with an object on the PC. The variable referenced must be
a string type
Syntax
rm.read.str($object, $variable, wait.time, $value, status)
Input Parameters
Parameter Description
$object The name of the remote object to access. This must
include the full path name of the object to access. e.g.
"/directory/Robot 1"
$variable The name of the variable to access
wait.time The amount of time to wait for the operation to com-
plete
Output Parameters
Parameter Description
$values The value of the variable
status Status of the operation: 0 = success, < 0 = error
Example
.PROGRAM ex1.rm.vars.s()
5-17 rm.read.str
5
5-18 rm.read.strs
Read a list of string property variables associated with an object on the PC. The variable referenced
must all be string types
Syntax
rm.read.strs($object, $variables[], wait.time, $values[], status)
Input Parameters
Parameter Description
$object The name of the remote object to access. This must
include the full path name of the object to access. e.g.
"/directory/Robot 1"
$variables[] The names of the variables to access
wait.time The amount of time to wait for the operation to com-
plete
Output Parameters
Parameter Description
$values[] The values of the variables
status Status of the operation: 0 = success, < 0 = error
5-19 rm.read.trns
Read a transform property variable associated with an object on the PC. The variable referenced must
be a Transform3D type
Syntax
rm.read.trns($object, $variable, wait.time, value, status)
Input Parameters
5-19 rm.read.trns
Parameter Description
$object The name of the remote object to access. This must
include the full path name of the object to access. e.g.
"/directory/Robot 1"
$variable The name of the variable to access
wait.time The amount of time to wait for the operation to com-
plete 5
Output Parameters
Parameter Description
value The value of the variable
status Status of the operation: 0 = success, < 0 = error
Example
.PROGRAM ex1.rm.vars.t()
5-20 rm.read.trnss
Read a list of transform property variables associated with an object on the PC. The variable refer-
enced must all be Transform3D types
Syntax
rm.read.trnss($object, $variables[], wait.time, values[], status)
Input Parameters
5-20 rm.read.trnss
Parameter Description
$object The name of the remote object to access. This must
include the full path name of the object to access. e.g.
"/directory/Robot 1"
$variable The names of the variables to access
wait.time The amount of time to wait for the operation to com-
plete 5
Output Parameters
Parameter Description
values[] The values of the variables
status Status of the operation: 0 = success, < 0 = error
5-21 rm.save
Saves the workspace file on the PC
Syntax
rm.save(wait.time, status)
Input Parameters
Parameter Description
$file Name of the file on the PC to save. If empty, save to
the current file
wait.time The amount of time to wait for the operation to com-
plete
Output Parameters
Parameter Description
status Status of the operation: 0 = success, < 0 = error
Example
.PROGRAM ex1.rm.save()
AUTO REAL status
AUTO $file
$file = "C:\workspace.awp"
CALL rm.save($file, 10, status)
IF (status < 0) THEN
TYPE "Unable To Save Workspace: ", status
PAUSE
END
.END
5-22 rm.write.anums
Set the values of an array of numeric properties associated with a collection of objects on the PC. The
property variables referenced must all be of a numeric type
Syntax
rm.write.anums($objects[], $variables[], wait.time, values[], status)
Input Parameters
5-22 rm.write.anums
Parameter Description
$objects[] The name of the remote objects to access. This must
include the full path name of the object to access. e.g.
"/directory/Robot 1"
$variables[] The name of the variables to access
wait.time The amount of time to wait for the operation to com-
plete 5
values[] The values of the variables
Output Parameters
Parameter Description
status Status of the operation: 0 = success, < 0 = error
Example
.PROGRAM ex1.rm.vars.nws()
PAUSE
END
.END
5-23 rm.write.num
Set the value of a numeric property associated with an object on the PC. The property variable refer-
enced must be of a numeric type
Syntax
rm.write.num($object, $variable, wait.time, value, status)
Input Parameters
5-23 rm.write.num
Parameter Description
$object The name of the remote object to access. This must
include the full path name of the object to access. e.g.
"/directory/Robot 1"
$variable The name of the variable to access
wait.time The amount of time to wait for the operation to com-
plete 5
value The value of the variable
Output Parameters
Parameter Description
status Status of the operation: 0 = success, < 0 = error
Example
.PROGRAM ex1.rm.vars.n()
5-24 rm.write.nums
Set the values of an array of numeric properties associated with an object on the PC. The property
variables referenced must all be of a numeric type.
Syntax
rm.write.nums($object, $variables[], wait.time, values[], status)
Input Parameters
5-24 rm.write.nums
Parameter Description
$object The name of the remote object to access. This must
include the full path name of the object to access. e.g.
"/directory/Robot 1"
$variables[] The name of the variables to access
wait.time The amount of time to wait for the operation to com-
plete 5
values[] The values of the variables
Output Parameters
Parameter Description
status Status of the operation: 0 = success, < 0 = error
Example
.PROGRAM ex1.rm.vars.nws()
PAUSE
END
.END
5-25 rm.write.str
Set the value of a string property associated with an object on the PC. The property variable refer-
enced must be of a string type
Syntax
rm.write.str($object, $variable, wait.time, $value, status)
Input Parameters
Parameter Description
5-25 rm.write.str
$object The name of the remote object to access. This must
include the full path name of the object to access. e.g.
"/directory/Robot 1"
$variable The name of the variable to access
wait.time The amount of time to wait for the operation to com-
plete 5
value The value of the variable
Output Parameters
Parameter Description
status Status of the operation: 0 = success, < 0 = error
Example
.PROGRAM ex1.rm.vars.s()
5-26 rm.write.strs
Set the values of an array of string properties associated with an object on the PC. The property varia-
bles referenced must all be of a string type
Syntax
rm.write.strs($object, $variables[], wait.time, $values[], status)
Input Parameters
5-26 rm.write.strs
Parameter Description
$object The name of the remote object to access. This must
include the full path name of the object to access. e.g.
"/directory/Robot 1"
$variable[] The names of the variables to access
wait.time The amount of time to wait for the operation to com-
plete 5
$values[] The values of the variables
Output Parameters
Parameter Description
status Status of the operation: 0 = success, < 0 = error
5-27 rm.write.trns
Set the value of a transformation property associated with an object on the PC. The property variable
referenced must be of a Transform3D type
Syntax
rm.write.trns($object, $variable, wait.time, value, status)
Input Parameters
Parameter Description
$object The name of the remote object to access. This must
include the full path name of the object to access. e.g.
"/directory/Robot 1"
$variable The name of the variable to access
wait.time The amount of time to wait for the operation to com-
plete
values The value of the variable
Output Parameters
Parameter Description
status Status of the operation: 0 = success, < 0 = error
Example
.PROGRAM ex1.rm.vars.t()
5-27 rm.write.trns
5
5-28 rm.write.trnss
Read a list of transform property variables associated with an object on the PC. The variable refer-
enced must all be Transform3D types
Syntax
rm.write.trnss($object, $variables[], wait.time, values[], status)
Input Parameters
Parameter Description
$object The name of the remote object to access. This must
include the full path name of the object to access. e.g.
"/directory/Robot 1"
$variables[] The names of the variables to access
wait.time The amount of time to wait for the operation to com-
plete
Output Parameters
Parameter Description
values[] The values of the variables
status Status of the operation: 0 = success, < 0 = error