IMSpost Guide
IMSpost Guide
Version 8.2
Document Revision A
Copyright © 2016 by Intelligent Manufacturing Software, Inc.
All rights reserved. Intelligent Manufacturing Software, Inc. reserves the right to change the information
in this document without notice. No part of this work may be processed, reproduced, or transmitted in any
form or by any means, electronic or mechanical, including photocopying and recording, or by any
information storage or retrieval system, except as may be expressly permitted in writing by Intelligent
Manufacturing Software, Inc.
Printed in the United States of America.
All other product names herein are used for identification purposes only and are recognized as properties
(including trademarks, registered trademarks, and referenced copyrighted materials) of their respective
companies.
OVERVIEW ................................................................................................................................................ 1
Company Profile .....................................................................................................................................................1
IMSpost Overview .................................................................................................................................................1
Installing the IMSpost Software and Getting Started ............................................................................................. 1
Before You Begin............................................................................................................................................2
Licensing .........................................................................................................................................................2
Loading a Postprocessor ..................................................................................................................................3
If You Encounter a Problem... .........................................................................................................................3
IMSpost Structure ...................................................................................................................................................4
Postprocessor (CLdata) Statements ........................................................................................................................4
Syntax Checking .............................................................................................................................................5
POSTCMD: Using Postprocessor Commands via the PPRINT Statement .....................................................6
Menus and Tool Bars..............................................................................................................................................6
Menu and Option Notation .............................................................................................................................. 6
Tool Tips .........................................................................................................................................................6
Environment Modes and Tool Bars ........................................................................................................................8
Postprocessor...................................................................................................................................................8
Controller Emulator .........................................................................................................................................8
Terms ......................................................................................................................................................................8
APT Source Statement ....................................................................................................................................8
Block Numeration ...........................................................................................................................................8
Checklist ..........................................................................................................................................................8
CL File ............................................................................................................................................................ 9
Comment Block...............................................................................................................................................9
Component Types ......................................................................................................................................... 10
Control Register ............................................................................................................................................ 10
Custom Postprocessor ................................................................................................................................... 10
Cutter Compensation ..................................................................................................................................... 10
Environment and Modes ............................................................................................................................... 10
Expression ..................................................................................................................................................... 11
Function Code ............................................................................................................................................... 11
Function Group ............................................................................................................................................. 11
Graphics Window .......................................................................................................................................... 12
Helical Interpolation ...................................................................................................................................... 12
Integer ........................................................................................................................................................... 12
Machine Control Code .................................................................................................................................. 12
Macro ............................................................................................................................................................ 12
NC Program .................................................................................................................................................. 12
Pointer ........................................................................................................................................................... 13
Postprocessing ............................................................................................................................................... 13
Project ........................................................................................................................................................... 13
Project File .................................................................................................................................................... 13
Real Number ................................................................................................................................................. 13
Static Table.................................................................................................................................................... 14
String ............................................................................................................................................................. 14
Tape Format .................................................................................................................................................. 14
Tracking the Tool .......................................................................................................................................... 14
Variable ......................................................................................................................................................... 14
Work Coordinate System .............................................................................................................................. 15
iv IMSpost Guide
Spindle .................................................................................................................................................................. 70
Drill Cycles........................................................................................................................................................... 71
End Operation (Catia Only) .................................................................................................................................. 74
End Program ......................................................................................................................................................... 75
Threading.............................................................................................................................................................. 75
Motion Codes ....................................................................................................................................................... 76
Rapid / Form.................................................................................................................................................. 77
Linear ............................................................................................................................................................ 78
Circle ............................................................................................................................................................. 82
Nurbs ............................................................................................................................................................. 85
Arc Fit ........................................................................................................................................................... 87
Line Fit .......................................................................................................................................................... 90
Shape Repetition ........................................................................................................................................... 91
Sort Output ........................................................................................................................................................... 93
Sequences ............................................................................................................................................................. 94
Advanced Settings ......................................................................................................................................... 97
Macro Interaction .......................................................................................................................................... 99
New Command ................................................................................................................................................... 100
Macro manager ................................................................................................................................................... 104
New ............................................................................................................................................................. 107
Edit .............................................................................................................................................................. 108
Import .......................................................................................................................................................... 109
Macro Properties ......................................................................................................................................... 110
Search .......................................................................................................................................................... 112
CONTROLLER MENU AND OPTIONS ............................................................................................ 113
Block Number .................................................................................................................................................... 114
Comment Blocks ................................................................................................................................................ 116
Register Format .................................................................................................................................................. 117
Basic ............................................................................................................................................................ 118
Advanced ..................................................................................................................................................... 119
Deleting a Register ...................................................................................................................................... 121
Changing Control Register Formats During Execution............................................................................... 121
Function Codes ................................................................................................................................................... 123
USE and One-Shot USE1 Parameters ......................................................................................................... 125
Function Groups ................................................................................................................................................. 126
Subprograms ....................................................................................................................................................... 127
Tables ................................................................................................................................................................. 128
Example of Defining a Lookup Table ......................................................................................................... 129
Tape Format ....................................................................................................................................................... 132
Import Controller ................................................................................................................................................ 133
Apt Definition..................................................................................................................................................... 133
Grammar ............................................................................................................................................................. 133
MACHINE MENU AND OPTIONS ..................................................................................................... 135
Motion ................................................................................................................................................................ 136
Co-Linear Axes ........................................................................................................................................... 142
Components ........................................................................................................................................................ 144
References .......................................................................................................................................................... 145
Defining Machine Z Zero ............................................................................................................................ 147
Multi-Axis .......................................................................................................................................................... 149
Multi-axis Setup .......................................................................................................................................... 151
Work Plane New ......................................................................................................................................... 156
Transitions ................................................................................................................................................... 159
General Strategy .......................................................................................................................................... 161
IMSpost Guide v
Import Machine .................................................................................................................................................. 163
IMS Project File .......................................................................................................................................... 163
IMSmodel File............................................................................................................................................. 163
Pre-defined Machines .................................................................................................................................. 164
REPORT MENU AND OPTIONS ........................................................................................................ 167
List ...................................................................................................................................................................... 170
Block Definition .......................................................................................................................................... 170
Program Header........................................................................................................................................... 171
Program Footer ............................................................................................................................................ 172
Page Header................................................................................................................................................. 174
Page Footer.................................................................................................................................................. 175
Page Size ..................................................................................................................................................... 177
Table ................................................................................................................................................................... 178
Table Definition .......................................................................................................................................... 178
Program Header........................................................................................................................................... 179
Program Footer ............................................................................................................................................ 180
Page Footer.................................................................................................................................................. 182
Page Header................................................................................................................................................. 183
USER MENU AND OPTIONS .............................................................................................................. 185
User Dialog......................................................................................................................................................... 185
Examples ............................................................................................................................................................ 191
Descriptive Comments ................................................................................................................................ 191
MULTI HOME ........................................................................................................................................... 191
Opstop ......................................................................................................................................................... 192
HELP MENU AND OPTIONS .............................................................................................................. 193
Activate PP File .................................................................................................................................................. 194
Diagnostics ......................................................................................................................................................... 195
Sample Diagnostic Report File .................................................................................................................... 196
MACRO LANGUAGE COMMANDS.................................................................................................. 199
Accessing Variables Within Macros .................................................................................................................. 199
Assignment Statements ...................................................................................................................................... 201
Math Functions in a Macro ................................................................................................................................. 202
Including Operations in Macros ......................................................................................................................... 203
Setting Strings in the Macro Language .............................................................................................................. 203
FINAL Macro ..................................................................................................................................................... 204
ADD ............................................................................................................................................................ 204
BOUND....................................................................................................................................................... 204
COPY .......................................................................................................................................................... 205
DELETE ...................................................................................................................................................... 205
LOCATE ..................................................................................................................................................... 205
MOVE ......................................................................................................................................................... 206
UPDATE ..................................................................................................................................................... 206
Macro Statements ............................................................................................................................................... 207
ASSIGN Statements ........................................................................................................................................... 208
BREAK Statements ............................................................................................................................................ 208
CALL Statements ............................................................................................................................................... 208
Passing Arguments in the CALL Statement ................................................................................................ 209
CASE Statements ............................................................................................................................................... 209
CLREAD Statements.......................................................................................................................................... 210
CUT Statements ................................................................................................................................................. 211
FILE Statements ................................................................................................................................................. 211
GETAPT Statements .......................................................................................................................................... 212
GETAT Statements ............................................................................................................................................ 212
vi IMSpost Guide
GETISO statements ............................................................................................................................................ 212
HOOK Statements .............................................................................................................................................. 213
IF Statements ...................................................................................................................................................... 214
OPTIMIZE Statements ....................................................................................................................................... 215
OUTPUT Statements .......................................................................................................................................... 215
Using REGISTER, FUNCTION, and MODE Variables and Values in an OUTPUT Statement................ 216
PRINT and DISPLAY Statements ..................................................................................................................... 217
PRIORITY Statements ....................................................................................................................................... 218
PUSH and POP statements ................................................................................................................................. 218
REPORT Statements .......................................................................................................................................... 218
RETURN Statements.......................................................................................................................................... 218
ROUND Statements ........................................................................................................................................... 219
RUN Statements ................................................................................................................................................. 219
SEQNO Statements ............................................................................................................................................ 219
SETAT Statements ............................................................................................................................................. 220
SOLUTION Statements...................................................................................................................................... 220
SOLUTION Statements: Format 1 .............................................................................................................. 220
SOLUTION Statements: Format 2 .............................................................................................................. 226
SOLUTION Statements: Format 3 .............................................................................................................. 229
SOLUTION Statements: Format 4 .............................................................................................................. 230
SOLUTION Statements: Format 5 .............................................................................................................. 231
SORT Statements ............................................................................................................................................... 231
Sorting Output Example .............................................................................................................................. 232
SPLIT Statements ............................................................................................................................................... 232
SPRINT Statements ............................................................................................................................................ 233
STREXT Statements .......................................................................................................................................... 234
STRLEN Statements .......................................................................................................................................... 234
STRSTR Statements ........................................................................................................................................... 234
TABLE Statements ............................................................................................................................................. 234
TOKEN Statements ............................................................................................................................................ 235
TOOL_ALONG Statements ............................................................................................................................... 235
TRIMLEFT and TRIMRIGHT Statements ........................................................................................................ 236
UCASE and LCASE Statements ........................................................................................................................ 236
USER STATEMENTS ....................................................................................................................................... 236
WHILE Statements ............................................................................................................................................. 236
MACRO LANGUAGE VARIABLES ................................................................................................... 238
CLDATA Variables............................................................................................................................................ 238
CLREAD Variables ............................................................................................................................................ 239
Component Model Example ............................................................................................................................... 240
COMPONENT Variables ................................................................................................................................... 241
COOLANT Variables ......................................................................................................................................... 243
CUTCOM (Cutter Compensation) Variables ..................................................................................................... 244
CYCLE Variables ............................................................................................................................................... 244
FEED (Feedrate Definition) Variables ............................................................................................................... 245
FUNCTION Variables........................................................................................................................................ 246
Geometry Functions ........................................................................................................................................... 247
ARC............................................................................................................................................................. 247
BACKMAT ................................................................................................................................................. 248
ISIDENT ..................................................................................................................................................... 248
LINE_ANGLE_LINE ................................................................................................................................. 248
LINE_DIST_PARREL ................................................................................................................................ 248
LINE_PARREL .......................................................................................................................................... 249
MATIDNT .................................................................................................................................................. 249
MATPNTVEC ............................................................................................................................................ 249
MATROT .................................................................................................................................................... 249
PNT_LINE_CIR_INTRSC ......................................................................................................................... 249
Company Profile
Intelligent Manufacturing Software, Inc. is a corporation with over twenty-five years of industry
experience in delivering postprocessing solutions; a company that takes pride in delivering total
solutions that are tailored to each individual client, and a company that has a vested interest in
keeping the customer satisfied. We pride ourselves on delivering industry leading levels of
service and support, and we deliver these products and services at a fraction of the cost of our
competitors.
IMSpost Overview
IMSpost is the IMS executable module designed for users who wish to develop or maintain their
own postprocessors. The IMS product family includes:
Postprocessor configuration.
IMSpost Guide 1
Overview: Installing the IMSpost Software and Getting Started
Licensing
The IMS protection system provides the means for the protection of both software modules and
individual postprocessor project files. This allows a high level of protection for IMS partners,
dealers, and resellers against unauthorized use of project files they have developed. The service
time and revenue involved in producing postprocessors represents an investment by our partners,
and we want to be sure this investment is adequately protected.
The steps involved in obtaining a license are:
1. Decide which license options you require.
For a new license, send your request to sales@[Link].
For an update of an existing license, send your request to support@[Link].
In either case, include the following information with your request.
Customer Information
Customer Name
Address
City, State, Country, ZIP/Postal Code
Telephone Number
Fax Number
Contact Information
The contact information is important, as the license code will be sent by email to this address.
First Name
Last Name
Title/Position
E-mail
2. Request a license code from IMS or your IMS reseller.
3. Install the license code you receive on your system. To do so, refer to
IMS_license_installation.PDF and see the Hardware Info entries on the Diagnostic dialog.
4. Set up the IMS software environment on your system.
Customize the IMS software environment to better meet your needs by setting preferences for
how you would like to use the features of the software (open the FILE menu and select the
Preferences option). A default version of this file is created in the install directory during the
installation process. In order for the IMSpexec or IMSpost software to locate this file, it is
suggested that you set an environment variable (see your System Administrator) named
IMSDIR_POST_INI.
2 IMSpost Guide
Overview: Installing the IMSpost Software and Getting Started
Loading a Postprocessor
Once the environment and preferences are set up correctly, you must load a postprocessor file.
You can:
Load a new postprocessor from the IMS postprocessor library, or
Load an existing postprocessor that you or someone else customized.
IMSpost Guide 3
Overview: IMSpost Structure
IMSpost Structure
With the proper controller and machine libraries loaded the simplest form of the IMSpost
hierarchy is:
1. Read the INIT/* macro. This macro is designed to declare all variables and machining modes
for program start-up.
2. Read the INIT_CFG/* macro. It is here that optional dialogs may be displayed, the controller
registers are sorted in their specified order, sequence numbering, and any codes from the Start
of Program dialog (GENERAL menu, Start Program option) are output.
3. Begin reading each statement passed in through the APT/CL file. Typically, this is the only
file the postprocessor is going to read.
If there is not a macro defined for the statement, the statement will be ignored. Various CAM
systems pass data to their CL/APT files that has nothing to do with machining. In these cases,
macros are not required to support this type of data.
4. Continue reading until the end of the file. Then it generates the FINI_CFG/* macro which
will output any specified code from the End of Program dialog (GENERAL menu, End
Program option), generate all necessary output and error files, then close the file.
4 IMSpost Guide
Overview: Postprocessor (CLdata) Statements
Postprocessors need a way to retract parameters from statements which contain more than one
parameter. The hierarchy of these parameters begins with the left and goes to the right. IMSpost
keeps track of the values with the CLDATAN. It keeps track of the minor words with
CLDATAM. It keeps track of all the parameters (words + values) with CLDATA. For example:
CYCLE/DRILL,-25,MMPM,3000,RAPTO,10,RTRCTO,10,30
[Link] = CLDATAN.1 The 1st value (-25)
[Link] = CLDATAN.3 The 3rd value (10)
[Link] = [Link] Gets the value to the right of minor word
RAPTO (10)
[Link] = CLDATAN.2 The 2nd value (3000)
[Link] = [Link] 3000
[Link] = CLDATA.9 The 9th parameter (30)
[Link] = CLDATAN.5 The 5th value (30)
If you connect your values with minor words (such as SWITCH/OFF), your APT statements are
not restricted to a specific format. As long as the postprocessor finds the minor word, it will
automatically connect its value with it.
Syntax Checking
If your postprocessor statement only has two choices (ON/OFF), you could use an IF statement to
see what is coming in (such as SWITCH/OFF). These examples check for minor word OFF:
IF(CLDATAM.1 = "OFF")
IF([Link])
IF([Link] = 1)
The first example is looking for OFF to be the first minor word. The second and third examples
do not care where the word OFF is located in the postprocessor statement. It is just checking to
see if it exists.
When command can have numerous minor words, use the CASE and ENDCASE statements. For
example:
CASE (CLDATAM)
DRILL statement(s)
TAP statement(s)
OFF statement(s)
AUTO statement(s)
ENDCASE
There may be a time when you want your macro to determine how many parameters are being
passed within the postprocessor statement. Let’s assume you have this postprocessor statement:
HEAD/LEFT,XOFF,120,YOFF,130,OPTION,54
HEAD/*
WORDS = CLDATAM.0 Counts minor words (4): LEFT,XOFF,YOFF,OPTION
NUMBERS = CLDATAN.0 Counts numbers (3): 120,130,54
PARAMETERS = CLDATA.0 Counts minor words and numbers (7)
IMSpost Guide 5
Overview: Menus and Tool Bars
Tool Tips
When you set your mouse on (but do not click) an option on the secondary tool bar, you will see a
tool tip providing a brief description of the feature. For example, when you set your mouse on:
6 IMSpost Guide
Overview: Menus and Tool Bars
Another type of tool type is provided for some options. It shows the IMSpost function group
variable associated with the option. For example, when you set your mouse on:
Coolant off
You see a tool tip for the associated variable:
Similarly, when you set your mouse on an option associated with a macro, the macro is shown:
IMSpost Guide 7
Overview: Environment Modes and Tool Bars
Postprocessor
Postprocessor is an operating mode in IMSpost that is active when is
displayed on the secondary tool bar:
A postprocessor is a program that formats a neutral CL file into an NC file that is suitable for a
specific machine/control combination. The name refers to the fact that the processing takes place
after the tool path has been generated.
Controller Emulator
A Controller Emulator or reverse processing option is an integrated part of IMSpost. All library
posts now contain the data necessary to convert from ISO format (NC code) to APT/CL
commands.
The Controller Emulator is active when is displayed on the secondary
tool bar:
NOTE: The IMS Controller Emulator functionality includes support for canned cycles, controller
subroutines, controller variables and expressions, and multi-axis machines. Refer to the
IMScontroller Emulator Guide for details.
Terms
Terms used in this document and the basic tools provided with IMSpost are described below.
They are listed in alphabetical order for easy referencing.
Block Numeration
This is the ordering of blocks of information in a machine code file. Block numbering most
commonly uses the N register to store this information. See CONTROLLER > Block Number.
Checklist
IMSpost provides you with a checklist to guide you through the postprocessor development
process, ensuring that you have access to all necessary features, including program codes,
controller format, and machine format.
The IMSpost Checklist is a list of steps suggesting a set of tasks necessary to complete your
postprocessor. For example:
8 IMSpost Guide
Overview: Terms
You can access the IMSpost dialog sections directly using the checklist. Simply click on the text
line of a particular step and the corresponding dialog will display.
When you have completed a dialog and exited the dialog using the OK/Save buttons (not Cancel),
a checkmark will appear in the IMSpost checklist next to the appropriate line. You can toggle the
checkmarks on/off for a specific line by double-clicking on the checkmark or empty box.
All checklist information is saved with the postprocessor data file, so it is recalled each time you
reload a specific postprocessor.
TIP: You can delete all the checkmarks by selecting them with your mouse. Now when you
double-click on a particular dialog to review, a checkmark is displayed.
CL File
A Center Line or Cutter Location (CL) file is a neutral toolpath file that contains generic
commands to perform tasks such as changing a tool or turning on the coolant. A CL file, which is
produced by a CAM system, is not intended for a specific machine.
These files are produced in response to the virtually unlimited number of machine and control
combinations. Producing a neutral toolpath file accommodates this large variety of output
requirements.
CL files are postprocessed into NC files.
Comment Block
A comment block is a block of code stored in the machine code file that is not acted on by the
machine controller. The block is most often used to comment the machine code file or to provide
operator instructions or messages on the controller screen. See CONTROLLER > Comment
Blocks.
IMSpost Guide 9
Overview: Terms
Component Types
A machine component must be one of the four basic types:
TABLE The machine table or rotary table on which the part to be machined is mounted. At
least one table piece is a base component, meaning it is not mounted on another
component. You may define any number of TABLE type pieces to represent
movement of linear or rotary type axes.
PART Component that can be mounted to the topmost TABLE component. This approach is
unnecessary, however, because IMSpost automatically adds this component for you if
it is not added explicitly.
HEAD Component used to represent a spindle or rotary axis mounted to the spindle. A HEAD
type, unlike a TABLE type, can have direction associated with it, so a direction
specifier should be entered in the direction field. Note that this is NOT motion
direction, but rather the directional setup of the component itself.
TOOL The cutter that will be doing the machining. Typically, PART components represent
what is being machined and TOOL components represent the cutter itself. Both the
PART and the TOOL components are specified within the CUT statement. For
example, to cut a part component with tools tip:
CUT(PART,[Link])
These component types, or pieces, let you physically describe or “build” your machine for the
postprocessor mathematical model. See MACHINE > Components.
Control Register
This is a code, sometimes called a letter address, that stores data to be read and interpreted by the
machine control. Typically, it is not enough for a postprocessor to output a value. This value is
usually associated with a particular address (G,X,Y,Z,F,S,M) and also needs a proper format. See
CONTROLLER > Register Format.
Custom Postprocessor
Intelligent Manufacturing Software will develop custom postprocessors for any machine and
controller configuration. You can then maintain the posts and make any enhancements you want
in-house. Contact IMS for more details:
Telephone: 978-556-0077
Fax: 978-556-0171
Postal address: 800 Broadway, Haverhill, MA 01832
Electronic mail: info@[Link]
Cutter Compensation
Cutter compensation is the correction of the cutter line to the left or right of center, from the
programmed line. See GENERAL > Cutter Comp.
10 IMSpost Guide
Overview: Terms
Expression
An expression can consist of any supported combination of data types, variables, operations, or
functions. For example:
[Link] > 24
Combined expressions must be separated with parenthesis. For example:
([Link]="LINEAR") AND ([Link])
(MACHINE.B > 90) OR (MACHINE.Y < 3.75)
Function Code
A function is a controller code, usually in the form of a G-code or M-code, that causes the
machine to take some action. For example, M08 is a function that turns on the coolant. See
CONTROLLER > Function Codes.
Function Group
Function groups (also referred to as MODES) provide a means for assigning functions into user-
defined groups. For example, the MOTION group may contain G00, G01, G02, G03 functions
that describe some type of movement to the machine controller. These codes are mutually
exclusive within each group. That is G01 remains in effect until cancelled by another code within
the MOTION group.
You categorize functions into groups for two reasons:
To group together families of functions (such as MOTION, COOLANT, SPINDLE, and
CYCLE).
To assign variable names to functions used repeatedly to simplify macro programming.
See CONTROLLER > Function Groups.
Each member of a group is assigned a specific function code. For example, the MOTION group
links the following members and functions:
The member POSITION for the ISO function G00
The member LINEAR for the ISO function G01
The member CLW for the ISO function G02
The member CCLW for the ISO function G03
Most of the functions associated with grouping functions are intended for advanced users. You
typically must create new function groups or modify existing groups.
A function can only be assigned to one group. If you attempt to assign a function to a group that
has already been assigned to another group, you will get an error message. You must first remove
the function from the group it is in, and then assign it to a different group.
There are many default groups assigned for commonly used codes. Selecting one of the default
postprocessor templates automatically sets up a group definition for commonly used functions.
IMSpost Guide 11
Overview: Terms
NOTE: You do not have to assign every function to a member of a group. The function groups
(modes) are for convenience in macro programming and are not required.
Some of the dialog and menus in IMSpost use the group/mode variables. Changing a function in a
dialog may change the function assigned to a group variable. Similarly, changing a group
member’s function assignment may change the setting in a dialog.
Graphics Window
The graphics window (highlighted in the following example) is the largest part of the application
display. It is where all of the machine graphics are displayed.
Helical Interpolation
For controllers that can support helical interpolation, IMSpost offers helical interpolation support
using the powerful CIRCLE SOLUTION statement. The library postprocessors also have updated
CIRCLE macros to support this feature.
In order to enable processing of helical interpolation, check the “Helical interpolation supported”
option on the Circle definition dialog. See GENERAL > Motion Codes (Circle tab).
Within the ArcFit routine, check the Screw option. See GENERAL > Motion Codes (Arc Fit tab).
Integer
An integer value consists of one or more digits, which can be preceded by a sign (+ or -). An
integer does not contain a decimal point. Examples of integers are:
[Link] = - 3
COUNTER = 1
Macro
An IMS macro is a set of programming language statements that instructs the postprocessor as to
how to respond to a certain event. Each APT source command to be processed by the
postprocessor has an IMS macro of the same name associated with it. All postprocessor output is
generated through the execution of an IMS macro.
If any APT source commands do not exist in the macro library, these commands will be ignored
by the postprocessor.
See GENERAL > Macro manager.
NC Program
An NC program is produced by a CAM systems to run machine tools such as 2-axis lathes, mills
(3-, 4-, and 5-axis), wire EDM machines, mill/turns, lasers, routers, grinders, and punch presses.
12 IMSpost Guide
Overview: Terms
Pointer
Pointers are used in conjunction with the LOCATE macro statement. These statements are
commonly used throughout the IMS Revpost product.
Postprocessing
Postprocessing is the process of transforming a neutral toolpath file (called a Center Line, Cutter
Location, or CL file) into an NC program that will run a machine tool. Postprocessing is
performed by a postprocessor program.
Postprocessing is a simple task with IMSpost. Most of the work occurs beforehand when you
create or modify the postprocessor. In most cases, you can edit parameters for controller format,
machine structural definition, output file format, and macros using the IMSpost dialogs.
Advanced users also have the option of writing macros.
There are two options for running a processor:
Using the [Link] file that is installed with IMSpost, or
Using the IMSpost generator (see EXECUTE > Postprocess).
The historical and modification data associated with a postprocessor file is saved so you can track
the file’s history. You can view or modify this information throughout the development cycle of
the postprocessor file.
Project
An IMSpost project is a data file consisting of all the parameters necessary for a complete
postprocessor. This includes controller definition, machine kinematic description, IMSpost
macros, and other postprocessor data.
Multiple projects may be loaded simultaneously in IMSpost. Use FILE > Open to select an
existing project. Use FILE > New to create a new project.
Project File
A project file is a complete postprocessor stored as an external file. The file is saved in encrypted
ASCII format. This data file contains a complete description of the parameters necessary to
postprocess a file, including:
Controller description
Machine description
Output file definition
Macro programs
Use FILE > Open to select an existing project file. Use FILE > New to create a new project file.
Real Number
Real number values must be written in standard notation. A real number consists of one or more
digits on both sides of a decimal point, which can be preceded by a sign (+ or -). Although input
data can have an integral value, such as 3.0, such a number is considered to be a real number by
the system. A value is written and stored as a real number unless entered without the decimal
point. An example of real numbers is:
[Link] = 15.375 + 5.775
IMSpost Guide 13
Overview: Terms
Static Table
A static table is a table attached to a register. For example, a spindle table might represent 100
rpm by S1, 125 rpm by S2, etc.
S1 = 100
S2 = 125
See REPORT > Table to construct these tables within IMSpost.
String
A string is a sequence of any number of characters enclosed in double quotes. Only printable
ASCII characters are permitted. Control characters are not supported. However, it is possible to
substitute a character in a string with a control character.
Examples of strings are:
"1234"
"S"
MYSTRING = "AB4E" + "G85"
TOOL_BLOCK = "(** RETRACT FOR SAFETY CLEARANCE **)"
DIR = "G90 M3"
Tape Format
Tape format defines the characteristics required by the machine controller to mark the start or end
of a file, end of block, or end of program information. See CONTROLLER > Tape Format.
Variable
For detailed information, refer to Macro Language Variables.
There are four general types of variables (data) allowed in IMS macros: integer, real number,
character string, and pointer. Examples are:
Integer INDEX = 1
Real number GLOBAL.TABLE_FEED = 1200.0
Character string MYTEXT = "G91G28Z0"
Pointer PTH = LOCATE(REGISTER.H)
variable = expression
Typically, if you are setting a variable to a number or another variable name, the expression value
should not be surrounded with quotes. For example:
[Link] = 2000
GLOBAL.RPM_SPEED = GLOBAL.LAST_RPM_SPEED
When you are setting the variable to text, it must be enclosed in quotes:
[Link] = "OFF"
[Link] = "G28G91XY"
14 IMSpost Guide
Overview: Terms
Besides these, IMSpost categorizes its own system variables: REGISTER, FUNCTION, MODE,
MACHINE, SOLUTION, and COMPONENT.
REGISTER is associated with the controller address.
[Link] = "YES"
[Link] = "? + 100"
[Link] = 1500.0
FUNCTION is associated with the machine function.
[Link] = "M13"
[Link] = "X,Z,I,K,F"
MODE is the current machining mode.
[Link]="CLW"
MACHINE is a parameter associated with the machine axis.
[Link] = 4500.0
[Link] = 0
SOLUTION is associated with current motion block.
COMPONENT is associated with the machine models component.
[Link] = "0,1,0"
The REGISTER, FUNCTION, MODE, MACHINE, and COMPONENT variables are dependent
upon what was selected through the various postprocessor dialogs. They are all accessible via the
IMS macro language.
The SOLUTION variables are dependent upon the type of motion currently being processed.
There is a different set of SOLUTION variables for 3-axis, linear motion, circular motion, and
multi-axis motion.
TIP: In your macro debug mode, enter the names of these variable types in the “watch” area. If
they are defined, IMSpost will return the results.
IMSpost Guide 15
Overview: Terms
For experienced IMS macro users, these codes are supported with the UCS_MULTI/* macro. The
G54-G59 codes are represented by the [Link] variables.
Notes
16 IMSpost Guide
Main and Secondary Tool Bars
The main and secondary tool bars in the upper left of the window.
A detailed description of each menu on the main tool bar is provided in this section. Also noted
are corresponding buttons on the secondary tool bar as well as control key combinations, if
applicable, to access the option.
FILE
The FILE menu includes the following options:
Option Button Keys Description
New — — Creates a new postprocessor file (*.lib, *.prj).
Open Ctrl O Opens a browsing dialog that enables you to choose a
previously defined postprocessor file (*.lib, *.prj).
Close — Ctrl Shift C Closes the currently active postprocessor file.
Save Ctrl Shift S Saves the currently postprocessor file using the same
name.
Save As — — Saves the currently postprocessor file using a different
name that you specify.
Jobs — — Saves the current working environment (saves
breakpoints for debugging). Two options are
available:
Load Job Loads a saved job file.
Save Job Saves a job to a file.
Preferences — — Customizes working directories, file extensions, and
other IMS default conditions.
Error — — Opens a dialog for error checking.
Definition
Apt Definition — — Translates the CAM system APT language.
Description — — Maintains a history of the postprocessor development.
Exit — Quits the application. Prompts you to save documents.
IMSpost Guide 17
Main and Secondary Tool Bars: Main Tool Bar
EDIT
The EDIT menu includes the following options that are used when working with the Debug
feature or Macro Manager.
Option Button Keys Description
Undo — Alt Reverses the previous action.
Backspace
Redo — Ctrl Y Restores the previous action that was reversed
(undone).
Cut Ctrl X Cuts the current selection and places it on the
Clipboard.
Copy Ctrl C Copies the current selection and places it on the
Clipboard.
Paste Ctrl V Pastes the cut or copied selection from the Clipboard.
Select All — Ctrl A Selects all information, such as all lines of code in a
macro.
Find Ctrl F Searches for specified text.
click .
Remove All — Removes all existing breakpoints.
Breakpoints
Line Numbers — — Displays line numbers, when this option is checked.
18 IMSpost Guide
Main and Secondary Tool Bars: Main Tool Bar
VIEW
The VIEW menu includes the following options:
Option Button Description
ISO (3D) Automatically rotates the world coordinates of the current machine
to fit the Isometric view.
XZ (Front) Automatically rotates the world coordinates of the current machine
to fit the Front view. The Y axis will be perceived as depth.
YZ (Side) Automatically rotates the world coordinates of the current machine
to fit the Side view. The X axis will be perceived as depth.
XY (Top) Automatically rotates the world coordinates of the current machine
to fit the Top view. The Z axis will be perceived as depth.
Fit View Fits the view to all objects. This centralizes the graphics window on
all of the displayed objects.
Debug — Enables you to select the windows displayed for use while
Windows debugging:
Macro Manager
APT-CL
ISO Code
Watch Window
Machine
Reset Default Layout
Refer to Debug.
Application — Provides a variety of options to display the IMSpost application.
Look
IMSpost Guide 19
Main and Secondary Tool Bars: Main Tool Bar
EXECUTE
The EXECUTE menu includes the following options:
Option Button Description
Postprocess Displays options and enables you to execute an entire program. In
Controller Emulator mode, you can reverse postprocess.
Test Displays options and enables you to perform an on-line test of
Commands commands, executing a partial program.
Breakpoints — Manages IMS macro language breakpoints.
GENERAL
The GENERAL menu includes the following options:
Option Button Description
Start Program — Enables you to enter code for the start of every program.
Input/Output — Enables you to enter default units.
Units
Part Number — Specifies how the postprocessor should handle part number
processing.
Start — (Catia Only) Enables you to enter code for the beginning of all Catia
Operation operations.
Tool Change — Opens a tool change dialog.
Coolant Opens the Coolant dialog to set coolant codes and conditions.
Drill Cycles Opens the Cycle dialog to define drill cycle parameters.
End Operation — (Catia Only) Enables you to enter code for the ending of all Catia
operations.
End Program — Enables you to enter code for the end of every program.
Threading — Available in the next software revision.
Motion Codes Sets function codes and conditions for rapid and contouring motion.
20 IMSpost Guide
Main and Secondary Tool Bars: Main Tool Bar
CONTROLLER
The CONTROLLER menu includes the following options:
Option Button Description
Block Number Specifies block number sequencing (Nxxxx).
Comment Enables you to enter operator comments and set parameters for the
Blocks comment block.
Register Defines tables for controller register formats. You can set the format
Format of controller letter addresses.
Function Defines controller function codes. All G/M codes in the
Codes postprocessor are listed.
Function — Lists all Mode/Group variables.
Groups
Subprograms — Provides options to support subroutines.
Tables — Enables you to create look-up tables.
Tape Format — Provides options for special characters needed on tape (such as %).
Import — Overrides the existing controller file with another controller file.
Controller
Apt Definition Sets the APT definition to convert.
MACHINE
The MACHINE menu includes the following options:
Option Description
Motion Displays all programmable machine axes.
Components Specifies model components.
References Specifies machine offsets (pivot points).
Multi-axis Provides setup options for tool tracking.
Multi-axis Setup Sets specific formatting and conditions for multi-axis
programming.
Work Plane Sets formatting for a multi-axis machine with a controller
that supports different working planes.
Import Overrides the existing machine model with:
Machine IMS project file From another postprocessor file.
IMS model file From an existing machine model.
Pre-defined machines View and select predefined machine model.
IMSpost Guide 21
Main and Secondary Tool Bars: Main Tool Bar
REPORT
The REPORT menu includes the following options:
Option Button Description
List Creates an optional *.lis output file (enter commentary data along
with the machine code).
Table Creates an optional tool data table and displays specified tool/cutter
data.
USER
The USER menu includes the following options:
Option Description
User Dialog Enables you to create custom dialogs.
Descriptive Comments EXAMPLE of a user dialog:
Activates tape comments. This is an IMS-developed dialog.
Opstop EXAMPLE of a user dialog:
Activates output of M01 codes. This is an IMS-developed dialog.
MULTI HOME EXAMPLE of a user dialog:
Enables you to active work coordinate systems. This is an IMS-
developed dialog.
HELP
The HELP menu provides options to displayed information about the IMSpost application or visit
the IMS Web site.
The HELP menu includes the following options:
Option Button Description
Help Topics Displays IMSpost help information.
22 IMSpost Guide
Main and Secondary Tool Bars: Secondary Tool Bar
Cuts the current selection and places it on the Clipboard. You can also access this
option with this key combination: Shift Delete
Copies the current selection and places it on the Clipboard. You can also access this
option with this key combination: Ctrl C
Pastes the cut or copied selection from the Clipboard. You can also access this option
with this key combination: Ctrl V
Toggles between the Postprocessor and Control Emulator mode
environments.
Displays options and enables you to perform an on-line test of commands, executing
a partial program.
Opens the IMS macro file management utility. (Your license must support this.) All
macros for the active postprocessor are listed.
Sets function codes and conditions for rapid and contouring motion.
(Available with Postprocessor only.) Enables you to enter operator comments and set
parameters for the comment block.
Defines tables for controller register formats. You can set the format of controller
letter addresses.
Defines controller function codes. All G/M codes in the postprocessor are listed.
IMSpost Guide 23
Main and Secondary Tool Bars: Secondary Tool Bar
Button Description
Controls registers, functions, and other code output using a dialog mechanism that
can be enabled at relevant intervals.
(Available with Postprocessor only.) Creates an optional *.lis output file (enter
commentary data along with the machine code).
Creates an optional tool data table and displays specified tool/cutter data.
(Available with Postprocessor only.) Opens the Cycle dialog to define drill cycle
parameters.
(Available with Control Emulator only.) Sets the grammar format.
(Available with Control Emulator only.) Sets the APT definition to convert.
Control the camera view. From left to right, the buttons are Isometric
(3D) view, Front view, Side view, and Top view.
Control camera zoom features. From left to right, the buttons zoom in
(closer), zoom out (away), and zoom onto a captured window in a
bounding rectangle.
Fits the view to all objects. This centralizes the graphics window on all of the
displayed objects.
Jogs the machine axis.
Notes
24 IMSpost Guide
FILE Menu and Options
IMSpost Guide 25
FILE Menu and Options: New
New
Creating a postprocessor through IMS consists of selecting a controller and connecting it to a
machine model.
1. When you select FILE > New, IMSpost guides you through the necessary steps to ensure the
proper machine definition:
a. Select a postprocessor library file from the Postprocessor Listing. A description of this
postprocessor and sample ISO code will display immediately in the areas to the right of
the listing.
b. Select your machine configuration from the machine model library. Click the Browse
button to view the choices.
c. Click Next.
2. Various dialogs will prompt you to enter specific information based on the postprocessor file
you selected. Work through these and click Next after each dialog. If necessary use the Back
button to return to any previous dialogs.
NOTE: The dialogs are related to the options available on the GENERAL menu.
3. Save the new postprocessor file by selecting FILE > Save.
26 IMSpost Guide
FILE Menu and Options: Open
Open
This option (also available with ) opens a browsing dialog that enables you to choose a
previously defined postprocessor file (*.lib, *.prj).
NOTE: Multiple project files can be open at a time. Be sure to save your work before opening a
different postprocessor file.
1. When you select FILE > New, IMSpost displays a projects browser in the directory you
selected as the default postprocessor directory.
2. Select a project file from the list.
3. Click Open. The name of the project file appears in the window title bar.
General Options
Several options available on the FILE menu are common to most applications: New, Open, Close,
Save, Save As, and Exit. Procedures for these options are self-explanatory.
Option Button Keys Description
Close — Ctrl Shift C Closes the currently active postprocessor file.
Save Ctrl Shift S Saves the currently postprocessor file using the same
name.
Save As — — Saves the currently postprocessor file using a different
name that you specify.
Exit — Quits the application. Prompts you to save documents.
Jobs
A job in IMSpost is a collection of data that represents a complete working environment. You can
save a job, exit IMSpost, and then load the same job to maintain your complete working
environment between IMSpost sessions. Jobs are saved as ASCII-type data files, with the file
extension: .job
When you select the Jobs option, two additional options are available:
Load Job to load a saved job.
Save Job to save a job.
The data saved in a job file consists of the following:
Current postprocessor (project) file name.
APT input file name.
NC code output file name.
APT/CL input type
Test commands entered in the Test Dialog.
Debug ON/OFF status
Debugger breakpoints
Debugger watch variables
IMSpost Guide 27
FILE Menu and Options: Preferences
Preferences
The Preferences option enables you to customize the working environment to your requirements.
You can customize working directories, file extensions, and other IMS default conditions.
28 IMSpost Guide
FILE Menu and Options: Preferences
Working Directories
Directories that you can customize are:
Field Description
Project files Pathname and directory where postprocessor files reside.
APT/CL files Directory containing APT/CL data input files.
Output files Default output directory for NC code files (*.nc, *.log).
List files Directory for *.lst files (optional output file with commentary data).
APT def files Directory for APT/CL definition translation files.
Error files Directory for IMS system and user-defined errors.
Language files Directory containing language conversion text files.
Temporary files Directory where any temporary files are created during execution.
Machine files Directory where IMSmodel machine definition files reside.
User files Directory where user-created files are stored if you extend IMSpost to
incorporate your own programs or DLLs.
Doc files Directory where postprocessor specification files reside.
The following directories also are used by the IMSpexec and/or IMSpost software. Note that you
cannot customize the directories for these files.
Type Description
Not specified Directory for the [Link] file.
Not specified Directory for IMS software executable modules.
Bitmap files Directory containing IMSpost bitmap images.
Help files Directory of help system files.
File Extensions
File extensions that you can customize are listed below. Note that the extension on the right side
of the dialog is associated with the file type immediately to the left.
Field Description
Project files… Extension Default file extension for project files.
APT/CL files… Extension Default file extension for APT/CL files.
Output files… Extension Default file extension for NC output files.
List files… Extension Default file extension for output list files.
The following extension also is used by the IMSpexec and/or IMSpost software. Note that you
cannot customize this extension.
Type Description
Not specified… Extension Default file extension for APT/CL definition files.
IMSpost Guide 29
FILE Menu and Options: Error Definition
Editor
The default user editor is most commonly used for displaying output data when necessary (such
as to display the output NC file when postprocessing is completed). For IMSpost Standard, or
IMSpost Professional users, the user editor may also be used as an editor for the Macro Manager.
In the windows environment, the default is usually: notepad
In the UNIX environment, the default is usually: vi
The IMS macro has special features built in the default editor. If you change your editor, these
features may not be supported.
Error Definition
This option opens a dialog for error checking. IMSpost maintains the error routines in the
following directories:
[Link] for standard system error messages.
[Link] for user-defined (custom) error messages.
NOTE: Your IMS license must include the postprocessor macro utility to support this feature.
When defining error messages, there are two important steps to consider:
1. Defining the error message (ID number and descriptive message).
2. Setting conditions to execute the error message (this is usually set up in a postprocessor
macro).
1. Select the System Error Definition or User Error Definition tab, as appropriate.
2. You can edit an existing error message. To do so, click on the Id or Message description and
change the number and/or text. You also can click to select/unselect error conditions
(described below).
The remainder of this procedure describes how to add an error message.
30 IMSpost Guide
FILE Menu and Options: Apt Definition
3. Click in the Id column at the bottom of the list. Enter an integer to represent the error
message ID number.
4. Enter the text for the error message in the Message column.
5. Specify the condition(s) for the error message. Select (check) a box for these conditions, as
appropriate:
Condition Description
Error Increment the error counter.
Warning Increment the warning counter.
Stop Stop execution of the program.
SCOL Show the current output line.
SCAC Show the current APT command.
SCEM Show the current execution macro.
SCEML Show the current line within macros execution.
DBreak Break in the Debug mode.
Format Indicate that the error contains a formatted string.
Log Write the error to a log file.
PPrint Write as a PPRINT command.
List Write to the list file.
Dialog Display a pop-up dialog message.
Apt Definition
The Apt Definition option is used to translate the CAM system APT language.
Because IMSpost accepts different CL/APT formats from a variety of CAM systems, each
individual CAM system has its own definition file. In the past, accounting for the differences
between APT or CLdata formats for various CAM systems meant a different postprocessor for
each format type. IMSpost makes it possible to use the same postprocessor, even if the input file
formats are different. One way this is accomplished is through the use of an APT definition file. It
is possible to have an APT definition file for each of the supported CLdata types within IMSpost.
Definition files translate the incoming postprocessor statements into the standard IMSpost
statements. This enables IMSpost to translate all the incoming APT/CL statements before they are
processed. Because of this, it enables you to use the existing macros in the library files.
An APT definition file contains a mapping of input commands and input command formats from
the input CLdata format into the standard IMS format (or any format that you choose). Major
words, minor words, the order of parameters programmed, and CLdata values can be mapped to a
standard format.
IMSpost offers you two ways to edit these files. You can edit the DEF file (see Using DEF
(Definition) Files) or use the Apt Definition option (on the FILE menu) to alter the definition file
as described below.
IMSpost Guide 31
FILE Menu and Options: Apt Definition
Tab Description
Major Words Indicates the mapping of major and minor words. The word in the Name
Minor Words column represents your CAM system. The word in the Replace column
represents the IMS term to which the CAM system word will be changed.
Commands Enables you to specify a translation statement that requires values or modify
the order of the command syntax (the order in which the values are output).
For example, to convert this APT statement, it would appear in the Name
column:
LOAD/TOOL,1,ZOFF,5,ADJUST,1
The following would appear in the Replace column:
LOADTL/1,ADJUST,1
You can use the Minor and Variable buttons to modify minor word or
variable definitions. You can change the word or variable index and/or
value/expression. To do so, click to highlight the information to change and
then enter new information. For example:
32 IMSpost Guide
FILE Menu and Options: Apt Definition
Tab Description
IMSpost Guide 33
FILE Menu and Options: Apt Definition
34 IMSpost Guide
FILE Menu and Options: Apt Definition
IMSpost Guide 35
FILE Menu and Options: Description
Use the following numbers as the first value in a line in a DEF file:
1 Use when only translating major words (UNITS/xxx).
2 Use when translating all minor words (xxx/INCHES).
3 INCOMING statement (your CAM system).
4 OUTGOING statement (IMSpost translation).
5 Set order of values. It is not necessary to rearrange values not recognized by the
postprocessor macro.
6 End of statement translation. This is not necessary when only using 1 or 2. All others should
close with this.
Description
The Description option enables you to maintain a history of the postprocessor development. The
Description dialog includes several tabs, as described below.
Description
Click this tab to enter freeform text describing the postprocessor. Place your cursor in the text
area and enter text.
36 IMSpost Guide
FILE Menu and Options: Description
History
Click this tab to enter freeform text regarding the history of the postprocessors development and
use. The following information and buttons are provided:
Field/Button Description
Text Area Displays freeform text describing the history of the project. Place the cursor
in the text area and enter text.
Date List Displays the dates of the text entries. Click the date to see the text entry
(displayed in the text area) for that date.
New Adds the current date to the list. If you add enough history entries, this date
list will scroll.
Delete Deletes a selected date and the associated freeform text from the tab.
TIP: History can be very useful for postprocessor development and modifications, particularly if
more than one person is supporting postprocessor development. It is a good idea to comment on
macros that have been changed, added, or deleted.
IMSpost Guide 37
FILE Menu and Options: Description
Detail
Click this tab to provide detailed information about the postprocessor in one easily accessible
location. The following information is provided:
Field Description
Support Cam Indicates the supported format as one of the following:
APT (general APT), STRIM (STRIM APT), EUCLID (EUCLID APT),
PRELUDE (Prelude Machinist), MACHINIST (EUCLID Machinist), NCI
(NCI Intermediate), CATIA, PTC APT, CV APT, UG APT, IBM Binary
(IBM 360/370 binary CL), or DUCT.
Confidence Indicates the confidence as:
PROVE Approved by usage testing.
IMS Approved by IMS.
PPCC Approved by PPCC.
PARTNER Created by an IMS partner.
AGENT Created by an IMS AGENT.
USER Created by an IMS user.
TRY Untested post.
Controller Specifies the controller that the postprocessor describes.
Machine Specifies the machine that the postprocessor is designed to control.
Post Version Specifies the number (version) of the post.
Project Version Specifies the number (version) of the project.
User Version Specifies the number (version) of the user.
Create
Specify the dates on which the project is created, modified, or frozen. Use
Modify
the arrows to select dates.
Freeze
38 IMSpost Guide
FILE Menu and Options: Description
Macro
Click this tab to enter freeform text regarding the macros used in the project.
Field/Button Description
Text Area Displays freeform text describing the macro selected from the macro list.
Place the cursor in the text area and enter text.
Macro List Specifies the macro for which you want to display information. Click the
dropdown arrow and select a macro.
TIP: You can also enter descriptive comments directly into the macro by opening the macro file
from the Macro Manager.
IMSpost Guide 39
FILE Menu and Options: Description
IsoCode
Click this tab to list an example of the output of this postprocessor. You can place the cursor in
the text area and enter text. (Cut-and-paste ISO code from a proven program.)
Notes
40 IMSpost Guide
EXECUTE Menu and Options
You can easily test the postprocessor as it is being developed. For example, you can define one
set of parameters, test them, and then move on to the next set of parameters.
With options on the EXECUTE menu, you can postprocess and debug an entire file or enter the
specific commands you want to test. The EXECUTE menu provides options to customize
postprocessor execution:
Option Button Description
Postprocess Displays options and enables you to execute an entire program.
Postprocess
The Postprocess option (also available with ) displays options and enables you to
postprocess a complete part file. For example:
IMSpost Guide 41
EXECUTE Menu and Options: Postprocess
If you are in Controller Emulator mode, this is a reverse postprocessing option. For example:
42 IMSpost Guide
EXECUTE Menu and Options: Test Commands
Field/Button Description
List file Indicates that List file information is included in a report. Refer to
Report.
Input type Sets a flag that can be checked internally so IMSpost knows what CAM
system generated the file, or if it is just a general format.
Display output file Identifies whether the file will be displayed after postprocessing is
completed.
The EDT line in the INI file determines which editor is used for this
display. By default, Notepad is used.
Enable machine Enables animation of the machine graphic.
animation
Execute Begins postprocessing (Postprocessor mode) or reverse postprocessing
(Controller Emulator mode).
Debug Opens the Debug window used for debugging errors in the code. Refer
to the Debug description.
Test Commands
The Test Commands option (also available with ) displays options and enables you to
perform online testing of a single APT command or group of commands. You can manually enter
the command(s) you want to test, or cut-and-paste a section from an existing APT/CL program
into the top display.
NOTE: In Test mode, IMSpost does not interpret or translate various CAM systems. The
statements processed in the Test dialog must meet the standard APT format
As shown on the next page, the following fields and buttons are available.
Field/Button Description
Input Commands Displays the input commands (in the upper scrollable area). Click to
place your cursor in this area and enter as many commands as you would
like to test. Enter one command per line.
Output Displays the postprocessed output from the commands entered in the
upper scrollable area. The output is displayed after you click Execute.
List file Indicates that List file information is included in a report. Refer to
Report.
Input type (Postprocessor mode only)
Sets a flag that can be checked internally so IMSpost knows what CAM
system generated the file, or if it is just a general format.
Enable machine Enables animation of the machine graphic.
animation
Execute Tests the commands entered in the Input Commands (upper scrollable
area). the results appear in the Output box.
Debug Opens the Debug window used for debugging errors in the code. Refer
to the Debug description.
IMSpost Guide 43
EXECUTE Menu and Options: Test Commands
44 IMSpost Guide
EXECUTE Menu and Options: Debug
Debug
The Debug feature (accessed with the button) is used to troubleshoot errors in the
code. You can debug one or more APT commands (through testing) or an entire postprocessor
file.
NOTE: If you use Debug from the Postprocess feature (EXECUTE > Postprocess) and you select
or enter an output file that already exists, the system will prompt you to overwrite the file. If you
do not want to do so, click No and enter a different file name. Otherwise, click Yes to overwrite.
The system opens debug windows. For example:
Double-click on a macro listed in the Macro Manager list. The associated code will display to the
right. The windows that open can include the following. Information displayed in these windows
changes to reflect changes within the selected macro.
Macro Manager—the macro list.
Selected Macro or Machine—details of the selected macro or the machine (if the
Machine option is selected via VIEW > Debug Windows.
APT-CL View—the APT/CL command being executed.
ISO (Code) View—the ISO code of the command being executed.
Output Window—the area where you can test variables. This window includes four
“watch” tabs:
— Autos automatically displays variables and values.
To examine a variable, double-click it and then enter a value to test. Note that all text
must be enclosed in quotation marks.
— Watch enables you to set what you want to look at.
— Call Stack shows where you came from in a stack if you want to step in.
— Error—the list of macros and messages where errors occurred.
IMSpost Guide 45
EXECUTE Menu and Options: Debug
To determine the windows that open, select VIEW > Debug Windows and then check each
desired window title. Use these windows to debug one or more APT commands (through testing)
or an entire postprocessor file.
When you set (but do not click) your mouse on a variable, value information is displayed. For
example:
Click (or press F5) to start debugging. This instructs IMSpost to execute the program until a
breakpoint is encountered.
NOTE: When in debug mode, IMSpost automatically sets breakpoints at the beginning of the
INIT and INIT_CFG macros as well as the first statement encountered in your test or part file.
When you complete your debugging work, click (tool bar options are described below). If
the system cannot find the output you indicated, you are asked if you want to create one. If you
click Yes, you can then use the text editor to modify and save the file.
46 IMSpost Guide
EXECUTE Menu and Options: Debug
F11 Step In—Steps in and enters the macro that is being called by the current
instruction.
— Step Out—Steps out of (exits) the macro that was called and returns to
the next statement it was called from.
— Run to Cursor—Runs (executes) to a statement designated by the cursor
line.
— Next Input—Steps to read the next instruction line.
In addition to the options on the Debug tool bar, you can use the buttons on the Macro Manager:
Button Description
New—Enables you to define a new macro.
Edit—Enables you to edit a macro after selecting it on the Macro Manager list.
IMSpost Guide 47
EXECUTE Menu and Options: Debug
Button Description
Save—Saves the current macro status.
Delete—Deletes a macro that is selected on the Macro Manager list. The macro that
you want to delete cannot be displayed in the “Selected Macro” area. If it is, close
the tab.
NOTE: It is not a good idea to delete a macro unless you are absolutely sure the
macro should not be supported within the postprocessor. The library files contain
macros that are called up with other macros. It is not a good idea to delete a macro
just because it does not look familiar.
Rather than deleting the macro, enter a BREAK statement as the first macro
instruction. For example:
SPINDL/*
BREAK
Later, you can “comment out” the BREAK statement and the macro will be
reactivated. For example:
SPINDL/*
*BREAK
Export—Opens a browser and enables you to export the selected macro(s) to another
postprocessor.
Import—Opens a browser and enables you to import a macro(s) from another
postprocessor.
Macro Properties—Specifies the macro type.
48 IMSpost Guide
EXECUTE Menu and Options: Debug
Additional options are available on the EDIT menu. Note that some of the Edit options are
duplicated on the tool bars described above and are not repeated here:
Option Button Keys Description
Undo — Alt Reverses the previous action.
Backspace
Redo — Ctrl Y Restores the previous action that was reversed
(undone).
Cut Ctrl X Cuts the current selection and places it on the
Clipboard.
Copy Ctrl C Copies the current selection and places it on the
Clipboard.
Paste Ctrl V Pastes the cut or copied selection from the Clipboard.
Select All — Ctrl A Selects all information, such as all lines of code in a
macro.
Replace — Ctrl H Replaces currently selected text with the information
on the Clipboard.
Line Numbers — — Displays line numbers, when this option is checked.
Go to line — Ctrl G Enables you to go to a line number that you specify:
IMSpost Guide 49
EXECUTE Menu and Options: Breakpoints
Breakpoints
There are two ways to manage IMS macro language breakpoints:
Or, interactively set breakpoints using while in the IMS macro language debugger.
To insert a breakpoint, position your cursor at the line where you want to insert a
breakpoint. Click . A red marker appears to the left of the line. For example, a
breakpoint is inserted here at line 28:
To delete a breakpoint, position your cursor at a line where a breakpoint exists (such as line
Create a new breakpoint by clicking in a blank “Break at” field. Then, From the dropdown list of
macros, select the macro to break.
50 IMSpost Guide
EXECUTE Menu and Options: Breakpoints
As a default, each macro selected will set a breakpoint at the beginning of the macro (Line 2).
You may specify the desired line number for the breakpoint.
Each breakpoint contains an Active checkbox that enables you to turn the breakpoint on or off.
With this feature, you can temporarily disable the breakpoint without deleting it.
To delete a breakpoint(s), highlight and right-click on the row(s) and select the Delete row(s)
option or press the Del key.
An optional conditional breakpoint can be set by programming any valid expression in the
Condition/Expression field.
Note: If multiple breakpoints (within the same macro) are required, you must pick the macro each
time, and enter the new breakpoint).
IMSpost Guide 51
EXECUTE Menu and Options: Breakpoints
Notes
52 IMSpost Guide
GENERAL Menu and Options
The GENERAL menu includes the following options, which are not specifically associated with
machines and machine controllers:
Option Button Description
Start Program — Enables you to enter code for the start of every program.
Input/Output — Enables you to enter default units.
Units
Part Number — Specifies how the postprocessor should handle part number
processing.
Start — (Catia Only) Enables you to enter code for the beginning of all Catia
Operation operations.
Tool Change — Opens a tool change dialog.
Coolant Opens the Coolant dialog to set coolant codes and conditions.
Drill Cycles Opens the Cycle dialog to define drill cycle parameters.
End Operation — (Catia Only) Enables you to enter code for the ending of all Catia
operations.
End Program — Enables you to enter code for the end of every program.
Threading — Available in the next software revision.
Motion Codes Sets function codes and conditions for rapid and contouring motion.
IMSpost Guide 53
GENERAL Menu and Options: Start Program
Start Program
This option enables you to enter text to be displayed at the start of a postprocessor output file.
Enter the line or lines of text as you would like them to appear in the output file.
NOTE: This option also is available with Start of Program on the Checklist.
Note the following while entering text:
You do not need to include sequence numbers (N-codes). These are automatically added
to the blocks at output if you turned sequence numbering on (see Block Number on the
CONTROLLER menu).
Spaces are not required between the codes.
You can sort the output (see Sort Output on the GENERAL menu).
Any data that you enter in double quotation marks (") is output directly without sorting or
tokenizing by the postprocessor.
If your output file ends with a special character (such as %), this character should be
entered using the Tape Format option.
NOTE: The lines of code you enter here are converted to OUTPUT macro commands and
entered in the INIT_CFG macro. You can add additional macro logic to this macro to perform
more sophisticated start-of-program sequences.
54 IMSpost Guide
GENERAL Menu and Options: Input/Output Units
Input/Output Units
This option enables you to customize the input and output units and the associated function codes
for your postprocessor.
Field Description
Metric Units Displays the function code used to specify that the format of the
postprocessor is output in metric units.
English Units Displays the function code used to specify that the format of the
postprocessor is output in English units.
Input Specifies Metric (MM) or English (INCH) to describe the format of the
Input file (APT/CL) values.
Output Specifies Metric (MM) or English (INCH) to describe the format of the
values written to the output NC code file.
The Input and Output selections made in the “Units type” section of this dialog will also be
reflected in the Input and Output Units fields in the Register Format dialog.
NOTE: If the Input type and Output type are not the same, the input values and output values
will be different. For example, using Input type English and Output type Metric, GOTO/1, 2, 3
would output G1 X25.4 Y50.8 Z76.2
IMSpost Guide 55
GENERAL Menu and Options: Part Number
Part Number
This option specifies how the postprocessor should handle part number processing.
If you are being prompted at each execution of your postprocessor for a part number, you may
stop this option by selecting either one of these options (as described below):
Ignore Part Number processing
Read from APT/CL PARTNO statement
Field Description
Par Number Options Enables you to define how the part number is processed. Select one
of the following:
Ignore Part Number Indicates the postprocessor will not output
processing any codes or prompt the user for any part
number information.
Read from APT/CL Indicates the postprocessor will get the part
PARTNO statement number from the APT/CL file and, if not
found, use the default number value as
specified below.
Read from APT/CL Indicates the postprocessor will get the part
if exists; else prompt number from the APT/CL file and, if not
user found, prompt the user to enter a value.
Prompt user at Indicates the postprocessor will always
runtime prompt the user at runtime and ignore the
PARTNO command from the APT/CL file.
Prefix string for output Specifies a character string to be output before the PARTNO
with part number number.
56 IMSpost Guide
GENERAL Menu and Options: Start Operation (Catia Only)
Field Description
Part number register Specifies the controller register to be output with the part number
value.
Default Part number Uses this value for the part number unless one is entered by the user
value at runtime or found in the APT/CL PARTNO statement (depending
on the Part Number Option selected above).
Sequence numbers off Outputs a part number without a sequence number on the N-code
with part number output.
Enter the line or lines of text as you would like them to appear in the output file. It is not
necessary to include spaces or sequence numbers.
NOTE: If your output file begins with a special character (such as %), this character should be
entered with the Tape Format option.
IMSpost Guide 57
GENERAL Menu and Options: Tool Change
Tool Change
This option opens a Tool Change dialog to customize the tool change output for your
postprocessor. Two tabs are provided: Tool Change and Turret Index.
NOTE: This option also is available with Tool Change on the Checklist.
Tool Change
NOTE: The parameters set in this dialog are used in the LOADTL macro (or other macro
specified). Default variables for this dialog are set in the INIT macro. If your license supports the
macro programming language, you can add additional macro programming to the LOADTL
macro to perform more sophisticated tool change sequences. Be careful, however, because it is
possible to modify or disable the use of the dialog parameters.
58 IMSpost Guide
GENERAL Menu and Options: Tool Change
Field Description
Auto tool change Displays the function code used to specify an automatic tool change.
function For example, enter M06.
For Advanced Users: The function specified in this field uses the
function group variable [Link].
Tool number register Displays the code to be output with the tool number. Select from a list
of predefined registers. For example, select T.
Length Compensation Displays the code to be output with the length compensation value.
Register Select from a list of predefined registers. For example, select H.
Time (mins) to change Displays the time in the format 0.0 that is needed to change tools. For
tools a 30 second tool change, you would enter 0.5
Output codes on a Specifies how you would like the tool change codes to be output.
separate block Select either this radio button or the one below it.
Output codes on the Specifies how you would like the tool change codes to be output.
next motion block Select either this radio button or the one above it.
Cancel coolant before Determines whether (checked) or not (unchecked) the postprocessor
tool change outputs a command to cancel the coolant before a tool change.
Cancel spindle before Determines whether (checked) or not (unchecked) the postprocessor
tool change outputs a command to turn off the spindle before the tool change.
Auto coolant after tool Automatically reinstates the coolant condition after the tool change.
change
Enable tool pre- Activates tool pre-selection. The postprocessor will read ahead to get
selection the next tool number and output the next tool value after the current
tool change.
Reload 1st tool at the Reloads the first tool at the end of the program.
end
Ignore same tool Instructs the postprocessor to ignore redundant tool change
statements.
Tool Number Ignores the tool numbers programmed in the APT/CL file and outputs
Incremental Start tool numbers increasing incrementally by one. The start value can be
set in this field as well.
Output before tool Specifies the ISO code lines required to be output before the initial
change tool change code block (one entry field for initial tool, another for all
subsequent tools).
Output after tool Specifies the ISO code lines required to be output after the tool
change change code block (one entry field for initial tool, another for all
subsequent tools).
Force Register Output Enables you to enter register addresses you want the postprocessor to
after Tool Change force out. For more than one register, separate with a comma
delimiter (for example: X,Y).
If your output shows Z motion first after a tool change and you prefer to see XY, before the Z
axis motion click the More… button (on the MACHINE > Motion dialog )for the Z axis in order
to display the extended axis dialog. Then activate the checkbox for “Move to home at tool
change” and enter a value for the Z home position. The postprocessor will not output this point,
IMSpost Guide 59
GENERAL Menu and Options: Tool Change
but it will be updated internally. This home position should reflect a point higher than the point it
will be traveling to after the tool change.
Turret Index
Field Description
Turret index CLW Displays the function code used to specify a clockwise turret index.
function
Turret index CCLW Displays the function code used to specify a counterclockwise turret
function index.
Turret index register Displays the code to be output with the turret index. Select from a list
of predefined registers. For example, select T.
Offset Register Displays the code to be output with the offset. Select from a list of
predefined registers. For example, select H.
60 IMSpost Guide
GENERAL Menu and Options: Tool Change
Field Description
Time (mins) to index Displays the time in the format 0.0 that is needed to index the turret.
turret For a 30 second turret index, you would enter 0.5
Output codes on a Specifies how you would like the turret index codes to be output.
separate block Select either this radio button or the one below it.
Output codes on the Specifies how you would like the turret index codes to be output.
next motion block Select either this radio button or the one above it.
Cancel coolant before Determines whether (checked) or not (unchecked) the postprocessor
turret index outputs a command to cancel the coolant before a turret index.
Cancel spindle before Determines whether (checked) or not (unchecked) the postprocessor
turret index outputs a command to turn off the spindle before the turret index.
Auto coolant after Automatically reinstates the coolant condition after the turret index.
turret index
Turret Number Ignores the turret numbers programmed in the APT/CL file and
Incremental Start outputs turret numbers increasing incrementally by one. The start
value can be set in this field as well.
Output before turret Specifies the ISO code lines required to be output before the initial
index turret index code block (one entry field for initial turret, another for
all subsequent turrets).
Output after turret Specifies the ISO code lines required to be output after the turret
index index code block (one entry field for initial turret, another for all
subsequent turrets).
Force Register Output Enables you to enter register addresses you want the postprocessor to
after turret index force out. For more than one register, separate with a comma
delimiter (for example: X,Y).
IMSpost Guide 61
GENERAL Menu and Options: Coolant
Coolant
The Coolant option (also available with ) opens the Coolant dialog to customize the output of
coolant codes for your postprocessor.
NOTE: This option also is available with Coolant Definition on the Checklist.
NOTE: The parameters set in this dialog are used in the COOLNT macro. Default variables for
this dialog are set in the INIT macro. If your license supports the macro programming language,
you can add additional macro programming to the COOLNT macro. Be careful, however,
because it is possible to modify or disable the use of the dialog parameters.
Field Description
Coolant off Displays the function code used to output code to turn off the coolant.
For example, enter M09.
For Advanced Users: The function specified in this field uses the
IMSpost function group variable [Link].
Mist coolant Displays the function code used to output code to activate the mist (or
similar) coolant type. For example, enter M07.
For Advanced Users: The function specified in this field uses the
IMSpost function group variable [Link].
Flood coolant Displays the function code used to output code to activate the flood (or
similar) coolant type. For example, enter M08.
For Advanced Users: The function specified in this field uses the
IMSpost function group variable [Link].
Thru coolant Displays the function code used to output code to activate the Thru tool
(or similar) coolant type. For example, enter M53.
For Advanced Users: The function specified in this field uses the
IMSpost function group variable [Link].
62 IMSpost Guide
GENERAL Menu and Options: Cutter Comp
Field Description
Air coolant Displays the function code used to output code to activate the Air (or
similar) coolant type. For example, enter M54.
For Advanced Users: The function specified in this field uses the
IMSpost function group variable [Link].
Output code on a Outputs codes immediately if this option is selected.
separate block
Output on the next Outputs codes with the following motion block if this option is selected.
motion block
NOTE: Each function is unique within IMSpost. If you want to use the same code (such as M8)
for more than 1 option, you must enter it this way: M8@MIST
Cutter Comp
This option opens the Cutter Comp dialog to customize the output of cutter compensation codes
for your postprocessor.
NOTE: This option also is available with Cutter Compensation on the Checklist.
NOTE: The parameters set in this dialog are used in the CUTCOM macro. Default variables for
this dialog are set in the INIT macro. If your license supports the macro programming language,
you can add additional macro programming to the CUTCOM macro. Be careful, however,
because it is possible to modify or disable the use of the dialog parameters.
IMSpost Guide 63
GENERAL Menu and Options: Cutter Comp
Field Description
Cutter compensation Displays the function code used to output code to activate cutter
left code compensation to the left of the cutter center line. For example, enter
G41.
For Advanced Users: The function specified in this field uses the
IMSpost function group variable [Link].
Cutter compensation Displays the function code used to output code to activate cutter
right code compensation to the right of the cutter center line. For example, enter
G42.
For Advanced Users: The function specified in this field uses the
IMSpost function group variable [Link].
Cutter Compensation Specifies the function code for special 3D compensation. If your
3d code controller does not support this, leave this field empty.
Cutter compensation Displays the function code used to output code to cancel cutter
off code compensation. For example, enter G40.
For Advanced Users: The function specified in this field uses the
IMSpost function group variable [Link].
Compensation Displays the code to be output with the cutter compensation value.
Register Name You select from a list of defined registers. For example, select D. If
the register does not exist, you must add it with the Register Format
option.
Normal X Register Enables you to browse and select the registers that represent machine
Normal Y Register X, Y, and Z (P, Q, and R) if your controller supports cutcom vectors.
Normal Z Register
Output codes on a Outputs cutter compensation codes immediately.
separate block
Output codes on the Outputs cutter compensation codes in following motion block.
next motion block
Output cutter Turns off output of cutter compensation codes in following motion
compensation off on block.
the next motion block
Diameter Uses the tool number as the diameter compensation value.
compensation value
same as tool number
64 IMSpost Guide
GENERAL Menu and Options: Feedrate
Feedrate
The Feedrate option customizes the output of feedrate codes for your postprocessor.
NOTE: This option also is available with Feedrate Definition on the Checklist.
NOTE: The parameters set in this dialog are used in the FEDRAT macro. Default variables for
this dialog are set in the INIT macro. If your license supports the macro programming language,
you can add additional macro programming to the FEDRAT macro. Be careful, however, because
it is possible to modify or disable the use of the dialog parameters.
Field/Tab Description
Register used for Displays the code to be output with the feedrate value. You select from
feedrate value a list of defined registers. (Refer also to the Register Format option.)
Default feedrate Specifies the feed value you want the postprocessor to use if the
value program does not contain a FEDRAT statement before the cutting
motion.
Output codes on a Outputs feed codes immediately.
separate block
Output codes on the Outputs feed codes in the following motion interpolation block.
next motion block
Feed/Minute tab Provides options to specify the function code and feed format for per
minute values (either mm per minute or inch per minute).
Feed/Revolution tab Provides options to specify the function code and feed format for per-
revolution values (either mm per revolution or inch per revolution).
IMSpost Guide 65
GENERAL Menu and Options: Feedrate
Field/Tab Description
Inverse Time tab Provides options to specify the special 1/T format used for some multi-
axis motion definitions.
NOTE: The register format values defined in this dialog will be used for feedrate output values,
regardless of the letter address format specified with the Register Format option. For example,
changing the “Digit” format for the F register in the register format will have no effect on the
output format of the F code, unless the format is also changed in this dialog.
Feed/Minute
Use the options on this tab to specify the feed formats used for millimeters or inches per minute.
Field Description
Function code Enables you to enter the machine code that represents feed per
minute mode.
Register format (mm) Specifies the number format for millimeter mode.
Register format (inch) Specifies the number format for inch mode.
Minimum feed/min. (mm) Enables you to enter the minimum per minute feedrate used for
millimeter mode.
Maximum feed/min. (mm) Enables you to enter the maximum per minute feedrate used for
millimeter mode.
Minimum feed/min. (inch) Enables you to enter the minimum per minute feedrate used for
inch mode.
Maximum feed/min. (inch) Enables you to enter the maximum per minute feedrate used for
inch mode.
Per minute federate is Forces a feedrate (F) code on every block if checked. If not
modal checked, only the feedrate code is output when the value
changes.
If you program a feedrate over the maximum and you want the postprocessor to use the specified
maximum feed, this maximum feed must be represented in the Register Format. Refer to
CONTROLLER > Register Format (Advanced tab).
66 IMSpost Guide
GENERAL Menu and Options: Feedrate
Feed/Revolution
Use the options on this tab to specify the feed formats used for revolutions (per revolution feed
mode).
Field Description
Function code Enables you to enter the machine code that represents per
revolution feed mode.
Register format (mm) Specifies the number format for mm per revolution mode.
Register format (inch) Specifies the number format for inch per revolution mode.
Minimum feed per rev. Specifies the minimum per revolution value.
Maximum feed per rev. Specifies the maximum per revolution value.
Per revolution federate is Forces a feedrate (F) code on every block if checked. If not
modal checked, only the feedrate code is output when the value
changes.
IMSpost Guide 67
GENERAL Menu and Options: Feedrate
Inverse Time
Some controllers use a formula to obtain a more efficient contouring feedrate. Typically the
inverse time (I/T) feed number is calculated by dividing the programmed feed by the tool path
distance. This calculated F-code is the inverse of the time required to move the programmed
distance.
The tool path distance is the vectoral distance resulting from the combined axes for that motion.
Field Description
Function code Specifies the machine code that represents inverse time feed mode.
Register format Specifies the number format for inverse time feed mode.
Minimum feed per min Defines the minimum calculated feed number.
Maximum feed per min Defines the maximum calculated feed number.
Inverse time formula Enables you to specify the formula the postprocessor should use
when calculating the inverse time feed value.
Active for motion type Provides options for the motion type:
Linear and Rotary Calculates I/T feed if the move contains both
linear and rotary motion.
Rotary Calculates I/T feed if the move contains rotary
motion only.
Linear Calculates I/T feed if the move contains linear
motion only.
68 IMSpost Guide
GENERAL Menu and Options: Feedrate
Field Description
Cancel inverse time Specifies that the postprocessor will cancel I/T mode for all RAPID
mode for rapid motions. I/T mode will automatically be reactivated based upon
positioning motion initial parameters.
NOTE: To cancel, you can clear all the checkboxes for the Motion
Type or comment out the HOOK statements in the INIT_CFG/*
macro.
Inverse time federate is Forces a feedrate (F) code on every block if checked. If not checked,
modal only the feedrate code is output when the value changes.
Simulate inverse time Instructs the postprocessor to calculate the feed number based upon
feedrate mode the actual length the tool tip moves.
NOTE: The formula you specify must be a valid definition that IMSpost can interpret, such as:
[Link]/SOLUTION.TOTAL_MOVE
This feature also works with the ASSIGN macro statement. This formula is stored in the system
variable, SYSTEM.INV_TIME_FORMULA.
ASSIGN("REGISTER.[SYSTEM.FEEDRATE_NAME].VALUE",SYSTEM.INV_TIME_FORMULA)
As an explanation:
[Link] = programmed feed / total delta motion
SPECIAL NOTE: Because IMSpost utilizes SOLUTION variables for various inverse time
formulas, it is important to turn off the internal motion processing within IMSpost. See the Linear
tab for Motion Codes. These SOLUTION variables are only processed within the SOLUTION
statements in the GOTO macro.
The controller manual for the particular machine will describe what inverse formula it supports.
The four choices the formula browser provides are:
Formula Description
SOLUTION.TOTAL_MOVE Uses total linear and rotary delta motion. This is generally
the formula most commonly used.
SOLUTION.LINE_DIST Uses the linear distance between the current tool position to
the next tool position in part coordinates.
SOLUTION.CURVE_DIST Uses the linear distance between the current tool position
and the next position. This involves interpolation that can
dramatically slow down the processing time (not
recommended of most cases).
SOLUTION.DELTA_DIST Uses the combination (delta) of linear and rotary axes
without converting the rotary motion to mm or inches.
If the formula in your controller manual does not match any of these, you can enter it through the
SYSTEM.INV_TIME_FORMULA = " ", or you can enter the formula in the blank display in the
formula browser.
IMSpost Guide 69
GENERAL Menu and Options: Spindle
Spindle
The Spindle option (also available with ) opens the Spindle dialog to customize the output of
spindle codes for your postprocessor.
NOTE: This option also is available with Spindle Definition on the Checklist.
NOTE: The parameters set in this dialog are used in the SPINDL macro. Default variables for
this dialog are set in the INIT macro. If your license supports the macro programming language,
you can add additional macro programming to the SPINDL macro. Be careful, however, because
it is possible to modify or disable the use of the dialog parameters.
Field Description
Clockwise rotation Displays the function code used to output code to activate spindle
rotation in the clockwise direction. For example, enter M03.
For Advanced Users: The function specified in this field uses the
IMSpost function group variable [Link].
Counter-clockwise Displays the function code used to output code to activate spindle
rotation rotation in the counterclockwise direction. For example, enter M04.
For Advanced Users: The function specified in this field uses the
IMSpost function group variable [Link].
Spindle off Displays the function code used to turn off the spindle. For example,
enter M05.
For Advanced Users: The function specified in this field uses the
IMSpost function group variable [Link].
Spindle register Displays a list of defined registers from which you select the code to
be output with the spindle speed value. For example, select S.
Default value (rpm) Displays the spindle speed in rpm. This value is used if the spindle is
turned on and no value is specified.
Output codes on a Determines how you would like the codes to be output. Select this
separate block radio button or the one below.
70 IMSpost Guide
GENERAL Menu and Options: Drill Cycles
Field Description
Output codes on the Determines how you would like the codes to be output. Select this
next motion block radio button or the one above.
Drill Cycles
The Drill Cycles option (also available with ) opens the Cycles dialog to customize the
output of canned cycle codes for your postprocessor.
NOTE: This option also is available with Drill Cycles on the Checklist.
NOTE: The parameters set in this dialog are used in the CYCLE and CYCLMOTN macros.
Default variables for this dialog are set in the INIT macro. If your license supports the macro
programming language, you can add additional macro programming to the CYCLE and
CYCLMOTN macros. Be careful, however, because it is possible to modify or disable the use of
the dialog parameters.
IMSpost Guide 71
GENERAL Menu and Options: Drill Cycles
Field Description
Cancel Displays the function code used to output code to cancel a drilling cycle.
For example, enter G80.
For Advanced Users: The function specified in this field uses the IMSpost
function group variable [Link].
Drill Displays the function code used to output code to activate a standard
drilling cycle. For example, enter G81.
For Advanced Users: The function specified in this field uses the IMSpost
function group variable [Link].
APT word: DRILL
Face Displays the function code used to output code to activate a drill with dwell,
or spot drill cycle. For example, enter G82.
For Advanced Users: The function specified in this field uses the IMSpost
function group variable [Link].
APT word: FACE
Deep Displays the function code used to output code activate a deep drill cycle.
For example, enter G83.
For Advanced Users: The function specified in this field uses the IMSpost
function group variable [Link].
APT word: DEEP
Tap Displays the function code used to output code to activate a tapping cycle.
For example, enter G84.
For Advanced Users: The function specified in this field uses the IMSpost
function group variable [Link].
APT word: TAP
Bore Displays the function code used to output code to activate a boring cycle.
For example, enter G85.
For Advanced Users: The function specified in this field uses the IMSpost
function group variable [Link].
APT word: BORE
Ream Displays the function code used to output code to activate a reaming cycle.
For example, enter G86.
For Advanced Users: The function specified in this field uses the IMSpost
function group variable [Link].
APT word: REAM
Bakbor Displays the function code used to output code to activate a back boring
cycle.
For Advanced Users: The function specified in this field uses the IMSpost
function group variable [Link].
APT word: BAKBOR
Manbor Displays the function code used to output code to activate a manual boring
cycle.
For Advanced Users: The function specified in this field uses the IMSpost
function group variable [Link].
APT word: MANBOR
72 IMSpost Guide
GENERAL Menu and Options: Drill Cycles
Field Description
Stpbor Displays the function code used to output code to activate a step boring
cycle.
For Advanced Users: The function specified in this field uses the IMSpost
function group variable [Link].
APT word: STPBOR
Brkchp Displays the function code used to output code to activate a break chip
cycle.
For Advanced Users: The function specified in this field uses the IMSpost
function group variable [Link].
APT word: BRKCHP
LH Tap Displays the function code used to output code to activate a left-hand
tapping cycle.
For Advanced Users: The function specified in this field uses the IMSpost
function group variable [Link].
APT word: LHTAP
Finbor Displays the function code used to output code to activate a fine boring
cycle.
For Advanced Users: The function specified in this field uses the IMSpost
function group variable [Link].
APT word: FINBOR
User Indicates a user-defined cycle type.
Cycle off output Determines the mode of output for the cycle off code—either on a block by
itself or on the next motion block.
Depth Format Provides options to describe the depth format:
Register for total Displays the register for the total drilling depth
depth parameter.
Register for deep Displays the register for the incremental depth for
increment deep drilling cycles.
Register for deep Displays the register for the retract parameter for deep
retract drilling cycles.
Format Displays the format for the register depth parameter.
Absolute: Always absolute mode.
Incremental: Always incremental mode.
Absolute or Incremental: Based on current mode.
Invert sign (+/-): Sign reverse of standard tool
direction
Clearance Plane Provides options to describe the clearance plane format:
Format Register for Displays the register for the clearance pane and/or
clearance plane retraction plane parameter (for example, R).
IMSpost Guide 73
GENERAL Menu and Options: End Operation (Catia Only)
Field Description
Format Displays the format for register depth parameter.
Absolute: Always absolute mode.
Incremental: Always incremental mode.
Absolute or Incremental: Based on current mode.
Invert sign (+/-): Sign reverse of standard tool
direction.
Other Codes Provides options to describe other codes.
Register for dwell Displays the register used if a delay time code is
required with this cycle.
Cycle block codes Adds the ISO codes entered in this edit box to the
cycle definition block.
Simulated Cycle Sets this box to perform simulated drilling cycles. If
canned drill codes do not exist, simulated cycles will
be performed with a series of rapid motion, feed
motion, dwells, etc.
Position Before Sets this box to position the tool in the non-drilling
Cycle axes before the canned cycle block. If this block is not
checked, positioning may occur on the same block as
the canned drill codes.
74 IMSpost Guide
GENERAL Menu and Options: End Program
End Program
This option enables you to enter text to be displayed at the end of a postprocessor output file.
Simply enter the line or lines of text as you would like them to appear in the output file. Note the
following while entering text:
You do not need to include sequence numbers (N-codes). These are automatically added
to the blocks at output if you turned sequence numbering on (see Block Number on the
CONTROLLER menu).
Spaces are not required between the codes.
You can sort the output (see Sort Output on the GENERAL menu).
Any data that you enter in double quotation marks (") is output directly without sorting or
tokenizing by the postprocessor.
If your output file ends with a special character (such as %), this character should be
entered using the Tape Format option.
NOTE: The lines of code you enter here are converted to OUTPUT macro commands and
entered in the FINI_CFG macro. You can add additional macro logic to this macro to perform
more sophisticated end-of-program sequences.
Threading
The Threading option will be available in the next software revision.
IMSpost Guide 75
GENERAL Menu and Options: Motion Codes
Motion Codes
The Motion Codes option (also available with ) opens the Motion Parameters dialog to set
function codes and conditions for rapid and contouring motion.
NOTE: This option also is available with Motion Functions on the Checklist.
NOTE: The parameters set in this dialog are used in the CIRCLE macro. Default variables for
this dialog are set in the INIT macro. If your license supports the macro programming language,
you can add additional macro programming to the CIRCLE macro. Be careful, however, because
it is possible to modify or disable the use of the dialog parameters.
76 IMSpost Guide
GENERAL Menu and Options: Motion Codes
Rapid / Form
The setting of rapid or positioning motion is designed to allow you to specify the following
options (refer to the screen example on the previous page):
Field Description
Rapid Motion Code Specifies the function code, usually a G-code, that specifies positioning
motion. In the above example, a G0 is entered.
Rapid block, Indicates special codes. This is only for machines that require a special
special codes code to instruct the controller in rapid mode (such as F0, R, or F999). If
your controller does not require this, leave it blank.
Text strings may be added within these areas. For example, if you need
an R letter to signify rapid motion, enter it in the special code box. If this
letter is also a register used for something else, enclose it in single
quotes: ‘R’
Break up rapid Instruct the postprocessor to make work plane checks on all rapid
moves motion based upon these conditions.
When the tool is moving away from the part, motion will be made along
the tool axis (Z) first, retracting from the part, and then to the final
position(X,Y).
When moving toward the part, motion will be along the X,Y axes first,
followed by the movement down in Z.
Restore feedrate Indicates you would like the feedrate to be reinstated on the next non-
after rapid move rapid move following the rapid motion.
From Provides options for handling the starting point, or FROM point of a
program. Select one of the four radio buttons.
Output from command Outputs the point as a rapid positioning move.
as rapid motion
Output from command Outputs the point as a linear/feed move.
as linear motion
Save as home position Saves the point as a home position, but does
(no output) not output.
Ignore from command Ignores the FROM command.
You can select the last option listed in the From area independent of
your selection above:
Apply to list from Instructs the postprocessor as to how to treat
command only successive From statements.
NOTE: If your controller uses the same G-code for rapid positioning and linear motion, enter the
code this way:
G1@LINEAR
G1@POSITION
IMSpost Guide 77
GENERAL Menu and Options: Motion Codes
Linear
The Linear tab is used to specify the function code used with linear interpolation. You can set
your own acceleration/deceleration spans for the postprocessor. Since IMSpost maintains an
internal record of variables and current machining conditions, you can determine how the
postprocessor could break up the linear motion.
The example above illustrates a slow-down span for all linear motions. IMSpost will subtract 10
mm from the incoming motion and output that distance with the programmed feedrate, then
output the remaining distance with half of the programmed feedrate. That is:
FROM/0,0,0
FEDRAT/1500
GOTO/100,0,0 Nxxx G1 X90. F1500
Nxxx X100 F750.
If more than one axis is involved in the motion, IMSpost will calculate the vector distance based
upon the total delta motion.
78 IMSpost Guide
GENERAL Menu and Options: Motion Codes
IMSpost Guide 79
GENERAL Menu and Options: Motion Codes
Linear Break
You can adjust the linear motion based upon the preset conditions such as the length of the move
or the angle of the next motion. By using these preset variables, you could construct an
acceleration/deceleration factor within the postprocessor without adjusting the GOTO macro
logic.
80 IMSpost Guide
GENERAL Menu and Options: Motion Codes
[Link] > 36
[Link] = 10
[Link] = 'OFF'
[Link] <> 'FLOOD'
Note that when setting a variable to a text result, the text must be enclosed in single quotes.
IMSpost Guide 81
GENERAL Menu and Options: Motion Codes
Circle
IMSpost supports circular interpolation in any plane (not just standard XY, YZ, and ZX planes).
Depending on the capabilities of your controller and machine, you can process circular input data
for any circle or arc and generate circular interpolation moves (for example G2,G3). Or, if your
controller or machine can only work in major planes, then generate a point to point representation
of the arc or circle that is outside of the plane.
The Circle feature lets you specify the type of circular interpolation your particular controller
supports.
82 IMSpost Guide
GENERAL Menu and Options: Motion Codes
Field Description
Clockwise code used Displays the function code used to define clockwise circular
movement. For example, enter G02. The function specified in this
field uses the IMSpost function group variable
[Link].
Counter-clockwise Displays the function code used to define counter (anti) clockwise
code used circular movement. For example, enter G03. The function specified in
this field uses the IMSpost function group variable
[Link].
3d Clockwise code Displays the function code used to define three-dimensional clockwise
used circular movement, if supported by the controller. The function
specified in this field uses the IMSpost function group variable
[Link].3DCLW.
3d Counter- Displays the function code used to define three-dimensional counter
Clockwise code used (anti) clockwise circular movement, if supported by the controller. The
function specified in this field uses the IMSpost function group
variable [Link].3DCCLW.
Radius format Displays choices for circular interpolation, center coordinate, and
output. Select one of the I,J,K options or the R option.
Break into linear Indicates the postprocessor will simulate an arc by generating multiple
moves straight line moves.
Linear Tolerance Sets the tolerance for the postprocessor to use if the circle radius is
Break outside of the minimum/maximum limits (that is, 0.01). Smaller
tolerances result in more linear motion. This tolerance is in effect only
if the postprocessor has to break the circle into straight lines.
Maximum radius for Sets maximum limits for circular interpolation. This tolerance is in
circular interpolation effect only if the postprocessor has to break the circle into straight
lines.
Minimum radius for Sets minimum limits for circular interpolation. This tolerance is in
circular interpolation effect only if the postprocessor has to break the circle into straight
lines.
Maximum chord Sets the maximum circular chord length allowed, or else break to
length linear moves. This tolerance is in effect only if the postprocessor has
to break the circle into straight lines.
Break up circle on Instructs the postprocessor to make quadrant checks.
quadrant boundaries
Helical Interpolation Instructs the postprocessor that machine is capable of helical
supported interpolation.
Support circular Instructs the postprocessor to process circles outside of the three major
interpolation in any planes.
plane
The parameters set in this dialog are used in the CIRCLE macro. Default variables for this dialog
are set in the INIT macro. You can add additional macro programming to the CIRCLE macro.
The Circle dialog uses a number of macro variables. The following example from a portion of an
INIT macro shows the macro variables used by this dialog with default settings and description.
Be careful—It is possible to modify or disable the use of the dialog parameters.
IMSpost Guide 83
GENERAL Menu and Options: Motion Codes
INIT/*
84 IMSpost Guide
GENERAL Menu and Options: Motion Codes
Nurbs
The Nurbs feature controls the output of NURBS processing, as supported within the NURBS
macro. The registers and output data are set using the Nurbs dialog. An algorithm is built within
IMSpost to evaluate and calculate NURBS data from GOTO points, and the OPTIMIZE macro
statement activates or deactivates this NURBS processing algorithm.
Field Description
Format style Selects the nurb format style.
Output before nurbs Specifies required code for output before nurbs.
Nurbs motion Specifies machine code.
function code
Register used for Defines the register used for the order value. If the controller register
order value does not exist, you must add it to the Register Table using the Register
Format option.
IMSpost Guide 85
GENERAL Menu and Options: Motion Codes
Field Description
Register used for Defines the register used for the weight value. If the controller register
weight value does not exist, you must add it to the Register Table using the Register
Format option.
Register used for Defines the register used for the knot value. If the controller register
knot value does not exist, you must add it to the Register Table using the Register
Format option.
Maximum order # Specifies the mathematical degree + 1 (usually 4).
Nurbs tolerance Specifies the tolerance band for nurbs.
Output after nurbs Specifies required code for output after nurbs.
Activate nurbs Activate optimization for nurbs processing control.
optimization
For advanced users, consult the OPTIMIZE macro statement and refer to the NURBS macro
within your postprocessor.
86 IMSpost Guide
GENERAL Menu and Options: Motion Codes
Arc Fit
The Arc Fit feature is a routine designed to fit an arc into a series of points. If the result is
successful, the postprocessor will act on the motion like a circular record. If not, a series of small
linear moves will be made.
Field Description
Minimum # of Defines the minimum number of points, which must be at least 4.
points
Minimum angle Defines the minimum required angle.
Minimum radius Defines the minimum required radius.
Maximum radius Defines the maximum radius.
Plane Tolerance Defines the plane fluctuation number.
Radius Tolerance Defines the radius fluctuation number.
Point Tolerance Defines the point fluctuation number.
Multax Allows the tool vector to vary during the arc.
IMSpost Guide 87
GENERAL Menu and Options: Motion Codes
Field Description
Vector change Specifies the vector change tolerance in degrees. This can be used either:
tolerance (deg) With the helical interpolation (SCREW). This option then specifies the
tolerance in the IJK vectors from one to another.
When the IJKs are constant while going about a cylinder (SPIRAL).
This option then specifies how many degrees the IJK vectors can be
outside of the plane.
XY Plane Enable you to select any combination of the three major planes. If a circle
YZ Plane can be outside a major plane, select ALL Plane.
ZX Plane
ALL Plane
Screw Looks for a third axis linear motion (helical interpolation).
Spiral Instructs IMSpost to look ahead and determine if the points are made about
a cylinder. If they are, the postprocessor will output the final rotation, thus
bypassing all the points between the start and finish. (This is only for
machines capable of making such a move). If this option is active, the
dialog will enable you to enter the vector direction along the cylinder.
Use exact end Indicates that the circle should begin and end on a programmed point.
points
Use tangents Creates lines through points, then attempts to fit an arc tangent within
these lines.
Activate arc-fit Activates arc-fit optimization. When this option is selected, the
optimization preprocessor performs a point-to-point motion to try to fit the arc. If this
option is not selected, there is no point checking.
Direction Defines the direction of the arc:
Parallel to Tool Points must be parallel to the tool.
Major Plane Points must be in one of the three major planes.
All Points can be outside the major planes.
The Arc Fit feature uses a number of macro variables. The following example from a portion of
an INIT macro shows the macro variables used with default settings and description. Be careful—
It is possible to modify or disable the use of the Arc Fitdialog parameters.
*
* Setup arcfit definition parameters
SYSTEM.ARCFIT_EXECT = 1
SYSTEM.ARCFIT_TOLRAD = 0.050000
SYSTEM.ARCFIT_TOLPLN = 0.050000
SYSTEM.ARCFIT_MINANG = 0.000000
SYSTEM.ARCFIT_MAXRAD = 99999.000000
SYSTEM.ARCFIT_MINRAD = 0.001000
SYSTEM.ARCFIT_POINTS = 4
OPTIMIZE(CIRCLE,0,XYPLANE,1,YZPLANE,1,ZXPLANE,1,ALLPLANE,0)
*
The OPTIMIZE command controls the ARCFIT routine. Each of these parameters consists of a
Boolean condition for On and Off. The condition is dependent upon the selection within the Arc
Fit dialog. If you have the macro programming package, you can control this command at any
time.
88 IMSpost Guide
GENERAL Menu and Options: Motion Codes
The following is an example. It is important to note that any three points can mathematically
define a circle. Therefore, the tolerance limitations are very important in determining the series of
points that will be converted to arcs, and those that will not.
In the drawing above, straight line moves A to B and B to C can possibly fit within an arc.
However, if the programmed radius tolerance is less than the actual tolerance (as shown in the
drawing), no arc output will be generated.
For advanced IMSpost macro users:
The Spiral option, if successful, will pass on a SOLUTION(SPIRAL/TYPE) statement to the
SPIRAL/* macro.
IMSpost Guide 89
GENERAL Menu and Options: Motion Codes
Line Fit
The Line Fit feature instructs IMSpost to look at a series of incoming points and try to fit a
straight line within them. If the result is successful, the postprocessor will output one straight line
as opposed to numerous smaller lines.
Specify a tolerance for the points. Optionally, activate line fit optimization. The Line Fit dialog
uses a number of macro variables. The following example is from a portion of an INIT macro that
shows the macro variables used by this dialog with default settings and description. Be careful—
It is possible to modify or disable the use of the dialog parameters.
* Setup linefit definition parameters
SYSTEM.LINEFIT_TOLER = 0.005000
OPTIMIZE(LINE,0)
*
The OPTIMIZE command controls the LINEFIT routine. Each of these parameters consists of a
Boolean condition for On and Off. The condition is dependent upon the selection within the
LINEFIT dialog. If you have the macro programming package, you can control this command at
any time.
90 IMSpost Guide
GENERAL Menu and Options: Motion Codes
Shape Repetition
The Shape Repetition feature provides the ability to repeat a geometric shape definition routine in
the APT file. The repetitive geometric pattern can be in a different location or the same location
as the original. The Shape Repetition feature can shorten the output file by using subroutines.
Field Description
Translation Provides translation options:
None Indicates no check.
Same location Searches for a shape in exactly same shape and
orientation.
Other Location Searches for a shape in different positions.
Rotation Provides rotation options:
X-Axis Searches for a shape rotated about X-axis.
Y-Axis Searches for a shape rotated about Y-axis.
Z-Axis Searches for a shape rotated about Z-axis.
IMSpost Guide 91
GENERAL Menu and Options: Motion Codes
Field Description
Combination Searches for a shape that coincides with any
combination.
Scale Enabled Activates the scale feature.
Allow combinations Allows a combination of translation, rotation, and/or scaling.
Ignore All Post Ignores all postprocessor commands.
Commands
Include Post Command Enables you to enter postprocessor commands to include.
Exclude Post Command Enables you to enter postprocessor commands to exclude.
Only check drill cycle Checks only cycle point geometry.
points
Distance Tolerance Specifies the general tolerance used.
Angle Tolerance Specifies a tolerance used for plane factors.
Minimum Points Specifies the minimum points for the shape.
Start check at command Specifies a postprocessor command (for example, LOADTL). As
an option you can include (in the Occurrence box) how many times
to locate it (the default is 1).
End check at command Specifies a postprocessor command (for example, STOP). As an
option you can include (in the Occurrence box) how many times to
locate it (the default is 1).
Activate shape repetition Controls the Shape Repeat feature within the postprocessor.
checking
The Shape Repetition feature generates a SHAPE REPEAT statement, which can have nested
embedded shape repetitions. In the following syntax example:
SHAPE_REPEAT,MAIN,START,SUBID,1,REPEAT,4,TRANS
START indicates that the repetition routine is started.
SUBID,1 is the shape identification.
REPEAT,4 indicates that the shape is repeated 4 times.
TRANS specifies the type of repetition as translation.
92 IMSpost Guide
GENERAL Menu and Options: Sort Output
Sort Output
This option sorts the contents of the output line.
NOTE: This option also is available with Sort Output on the Checklist.
1. Select functions and registers you want to sort in the output. Double-click the function or
register or select it.
2. Click Add >>> to add the function or register to the sort list (Sort Order).
When the function or register moves to the Sort Order column, it is no longer displayed in the
Functions or Registers column.
3. Use additional options, as described below.
Field/Button Description
Functions Displays all the available functions. Double-click a function to add it to the
Sort Order column.
Registers Displays all the available registers. Double-click a register to add it to the
Sort Order column.
Sort Order Displays the functions and registers that are being sorted in the output file,
as well as the order in which those items will be displayed. Double-click an
item to remove it from the sort order.
Add >>> Enables you to select multiple functions or registers and add them to the
Sort Order.
<<< Remove Enables you to select multiple functions or registers in the Sort Order list
and remove them.
Add String >>> Enables you to enter registers, function codes, or text strings that are not
displayed in the Functions or Registerscolumn. Enter the text in the text box
and then click Add String to add it to the Sort Order.
Move Up Moves the selected item(s) in the Sort Order column up one entry in the sort
order list.
IMSpost Guide 93
GENERAL Menu and Options: Sequences
Field/Button Description
Move Down Moves the selected item(s) in the Sort Order column down one entry in the
sort order list.
Reverse Reverses the order of the items in the Sort Order column.
For example, highlight the G90 and G91 codes. Then click Add. Repeatedly click Move Up until
these codes are above the G on the Sort Order list. Then select the G17, G18, and G19 codes and
repeat the process until these codes are between the G90/G91 and the G address.
Note that you can also set the order of G and M codes. For example:
Nxxx G90 G17 G00
For IMS macro users:
You can also use the IMS macro SORT command to reorder any letter addresses or function
(G/M) codes. The initial SORT statement resides in the INIT_CFG/* macro.
Sequences
The Sequences feature allows for the control of registers, functions, and other code output, using
a dialog mechanism that can be enabled at relevant intervals.
94 IMSpost Guide
GENERAL Menu and Options: Sequences
Each row on the Output Sequences dialog (Output Line column) is a line of output with registers,
variables, and codes representing what should appear on the output line.
Field/Button Description
Select Sequence Enables you to choose an existing defined sequence from a dropdown list.
In addition to existing sequences, two options are available:
<New…> to create a new sequence.
<Delete…> to delete an existing sequence.
Output Line Shows the output line data consisting of registers, variables, codes, etc.
… Displays the Sequence Tokens dialog, which provides additional controls
over each tokenized object on the line.
IMSpost Guide 95
GENERAL Menu and Options: Sequences
Field/Button Description
Force Off Overrides the current state of the postprocessor and forces
line numbering OFF for all sequence lines.
The Seqno button is highlighted with a red X:
Force button Controls whether redundant codes are forced to be output for all lines
defined in the Output Line column. This button has two states:
Inherited Takes the standard output rules from the postprocessor.
The Force button is gray:
Condition Applies a conditional state to determine whether or not the Output Line is
output. This condition state can be any macro language expression that
evaluates to true or false. The Condition button has two states:
No Condition Does not have any effect on the Output Lines.
96 IMSpost Guide
GENERAL Menu and Options: Sequences
Advanced Settings
The Advanced Settings option enables you to program more detailed parameters for each
individual Output Line. When this option is toggled ON, additional buttons are displayed to the
right of each Output Line.
Button Description
Seqno Controls line numbering output for THIS SPECIFIC Output Line. You can
override the global setting on a line-by-line basis.
This button has five states:
Force On inherited condition from the global setting (gray button with
green +).
Force Off inherited condition from the global setting (gray button
with red X).
Force Off override of the global state (highlighted button with red X).
Force Controls whether redundant codes are forced to be output for THIS
SPECIFIC Output Line. The state may be:
IMSpost Guide 97
GENERAL Menu and Options: Sequences
Button Description
M/P Outputs the specified values using one of the following:
Pivot
Face
Center
Tip
Hook Specifies whether or not to use HOOKS in the Solution calculation.
Does not use HOOKS (highlighted button with red X). This is
analogous to the NOHOOK solution statement option.
98 IMSpost Guide
GENERAL Menu and Options: Sequences
Button Description
Report Specifies whether or not errors are to be reported during the Solution
calculation.
Does not report errors (highlighted button with red X). This is
analogous to the NOREPORT solution statement option.
Macro Interaction
Sequences that are programmed via the Output Sequence dialog have all data stored in macro
language commands in the INIT_SEQUENCE macro.
For this example:
IMSpost Guide 99
GENERAL Menu and Options: New Command
New Command
This option initiates a utility that automatically creates a postprocessor macro. The logic for this
is limited to applying function (G/M) codes to the specified syntax. Function codes are associated
with minor word syntax, while Registers are associated with values.
1. In the Enter New Apt Command field, specify the syntax of the command. Anything
surrounded by brackets is considered optional. The # represents a value. For example:
The statement in the example above will offer the following combinations:
DOOR/SPACE,#,OPEN,#,#,#,#
DOOR/SPACE,#,CLOSE,#
DOOR/SPACE,#,SHUT,#,#
2. Click Apply.
3. Enter the associated function codes and control registers for each valid syntax combination.
In the example above, because the first and last values (#) are not optional, they will always
be output. They are represented in the Default cells with their associated controller register.
4. If you want the macro to output the codes with and without motion, click the “Output on the
next motion block” option. Then, in your macro, you can add logic for the with/without
motion check. For example:
Similarly, if you review the groups (CONTROLLER > Function Groups), you will see the
new group and members (functions):
6. You can click Test to test the command. To see the results of the test, click on the
secondary toolbar (this is the same as EXECUTE > Test Commands).
7. Click View to review the macro. For example:
You can save this as a file or simply close the window after reviewing the macro.
8. You can click View to generated output. The example generates the following:
9. When you have completed your entries, click OK.
Macro Manager
This option (also available with ) the IMS
macro file management utility. (Your license
must support this.) All macros for the active
postprocessor are listed. This enables you to
work with the macros associated with the
postprocessor file. Certain macros are
automatically added to the postprocessor file
when it is created. You can delete these (not
recommended), import macros from other
projects into the open project, add new macros,
and modify existing macros.
Each project, or postprocessor, consists of its
own set of macros. When you start a new
project, that project automatically includes a
default set of macros. The Macro Manager
dialog displays only those macros associated
with the project you have open.
When you initiate the Macro Manager, the
screen changes to provide option buttons and the
list of macros, as shown in the example on the
right.
The Debug feature includes several sets of options available for use. Options on the tool bar
above the Macro Manager (and under the secondary tool bar) control the debugging process:
Edit—Enables you to edit a macro after selecting it on the Macro Manager list.
Button Description
Delete—Deletes a macro that is selected on the Macro Manager list.
NOTE: It is not a good idea to delete a macro unless you are absolutely sure the
macro should not be supported within the postprocessor. The library files contain
macros that are called up with other macros. It is not a good idea to delete a macro
just because it does not look familiar.
Rather than deleting the macro, enter a BREAK statement as the first macro
instruction. For example:
SPINDL/*
BREAK
Later, you can “comment out” the BREAK statement and the macro will be
reactivated. For example:
SPINDL/*
*BREAK
Export—Opens a browser and enables you to export the selected macro(s) to another
postprocessor.
Import—Opens a browser and enables you to import a macro(s) from another
postprocessor.
Macro properties—Specifies the macro type.
Additional options are available on the EDIT menu. Note that some of the Edit options are
duplicated on the tool bars described above and are not repeated here:
Option Button Keys Description
Undo — Alt Reverses the previous action.
Backspace
Redo — Ctrl Y Restores the previous action that was reversed
(undone).
Cut Shift Cuts the current selection and places it on the
Delete Clipboard.
Copy Ctrl C Copies the current selection and places it on the
Clipboard.
Paste Ctrl V Pastes the cut or copied selection from the Clipboard.
Select All — Ctrl A Selects all information, such as all lines of code in a
macro.
Replace — Ctrl H Replaces currently selected text with the information
on the Clipboard.
Line Numbers — — Displays line numbers, when this option is checked.
New
Macros are executed by major words. When you click , the following dialog is displayed:
Enter a macro name and click OK. (Do not add the / code or any syntax.) For this example,
IMSpost automatically creates the following macro display:
The macro name SWITCH represents the command name that activates the macro of the same
name.
/* is a wildcard that signifies that IMSpost will trap all the SWITCH/ commands encountered in
the part file. As a default, IMSpost always adds the /* to the command name that is entered.
Each macro must end with a RETURN statement to signify the end of the macro logic and
instructs IMSpost to return and read the next CL/APT statement.
You could enter SWITCH/OFF for the macro name, but then your macro would only be called
for SWITCH/OFF commands.
With the new macro dialog open, you can insert your macro commands. For example, click
before the R in RETURN and press Enter to open a line between the macro command SWITCH/*
and RETURN statements.
You can close the view of the macro by clicking the X on the right of the macro name tab:
Edit
To edit an existing macro, select it from the Macro Manager list and then click . Or, double-
click the macro name on the list. The macro is displayed. The following example shows the
COOLNT macro.
All macros start with the word that activates the macro (in this case, COOLNT/*).
Any statement that begins with an asterisk (*) represents a comment. Comments must start with
an asterisk and cannot be combined with the instruction.
All macros must end with a RETURN command. This signifies the end of the macro and instructs
IMSpost to return and read the next CL/APT statement.
Import
Click . An Import browser is displayed. Select a library file (*.LIB extension). The Import
Macro dialog is displayed:
Field/Button Description
All Selects all macros in the list.
None Deselects all macros in the list.
View Views a selected macro.
Verify Reconfirms that the imported macro already exists in the open project.
The specific macro or macros you selected are copied out of the “import” project and into the
current project.
If you import a macro from another postprocessor and there is currently a macro with the same
name, IMSpost will indicate that you are about to overwrite an existing macro and provide the
option to cancel the procedure.
Macro Properties
Typically, macros are designed to determine and output machine or controller conditions. They
can also be designed to calculate a mathematical function. They can be assigned to do a
mathematical function and return the value to the macro that called it.
To specify how you want each macro will perform its operation, select the macro from the Macro
Manager. (Use the Ctrl key to select more than one macro.)
Field/Button Description
Include Provides the ability to load a macro (same name) from a master file. This
macro must exist in the file that is designated in the display area.
This instructs IMSpost to override the existing macro with the one specified
in the Include pathname display. This enables you to build and maintain a
library of custom macros that will be used with other postprocessors. The
advantage is that you can maintain a single library of macros. This master
file only needs to contain macros that will be shared with other
postprocessor files.
For the recipient postprocessors, be sure to check the Include option for all
macros contained in this master file. If it is checked, the existing macros
will be overridden by the master file. This is a powerful feature for
maintaining consistency among your postprocessor library. You only have
to update your master file and all your other posts will be updated when
they are executed.
NOTE: The Include checkbox gives you the advantage of ensuring that
your postprocessors always use your current custom macros. For example,
if you have additional custom logic you want to maintain in all of your
SPINDL macros, make sure this particular SPINDL macro exists in your
master file. This way when you update or create a new post, this SPINDL
will be imported from your designated master file.
Field/Button Description
Function Indicates that a macro is categorized as a function. That is, the macro can be
designed to return a mathematical value. When this option is selected, the
macro will compute and return the value to the macro that called it. Two
steps are necessary:
1. Define the function. This can be any valid programming logic that
IMSpost can interpret. The Function option must be checked for the
macro.
2. The macro function must be called from another macro. For example,
define the macro logic (this macro divides the first value by 2.5):
BBB/*
B = CLDATAN.1/2.5
RETURN(B)
To call the macro function:
LOADTL/*
* call macro function BBB/100
C = 4 + BBB(100)
Check Syntax Enables macro syntax checking. You can instruct the system on what the
allowable statements can be. Typically, when IMSpost reads a command in
the APT/CL file, it looks to find a macro with the same name. If any of the
parameters in the statement are not defined with the macro, usually the
statement is ignored. If you select the Check Syntax option, you can specify
what allowable commands (combinations) can be checked to match the
defined syntax. If IMSpost reads a command that does not exist, an error is
generated.
Postprocessor Specifies the macro logic is for a postprocessor operation. (Usually a
macro’s logic is either for a postprocessor or reverse-postprocessor
operation.)
A macro could be designed to do some type of a general file service that has
no relation to posting or reverse-posting. For this reason, both the
Postprocessor and Revpost checkboxes could be activated. Usually these
checkboxes are controlled by the type of project being created
(postprocessor or reverse-postprocessor).
Revpost Specifies the macro logic is for a reverse-postprocessor operation. (Usually
a macro’s logic is either for a postprocessor or reverse-postprocessor
operation.)
Yes Saves changes and exits the Confirm Macro Type dialog.
No Exits the Confirm Macro Type dialog without saving changes.
All Saves all changes (when you select more than one macro from the Macro
Manager) and exits the Confirm Macro Type dialog.
Search
To search for text on the Macro Manager list, click . The Macro Search dialog is displayed:
The CONTROLLER menu provides options to customize the controller. You can define features
that are specific to the CNC control, including:
Function codes used and their grouping
Letter address definitions (controller registers)
Block numbering and comment line format
Output tape codes required at beginning and end of file
Options on the CONTROLLER menu are:
Option Button Description
Block Number Specifies block number sequencing (Nxxxx).
Comment Enables you to enter operator comments and set parameters for the
Blocks comment block.
Register Defines tables for controller register formats. You can set the format
Format of controller letter addresses.
Function Defines controller function codes. All G/M codes in the
Codes postprocessor are listed.
Function — Lists all Mode/Group variables.
Groups
Subprograms — Provides options to support subroutines.
Tables — Enables you to create look-up tables.
Tape Format — Provides options for special characters needed on tape (such as %).
Import — Overrides the existing controller file with another controller file.
Controller
Apt Definition Sets the APT definition to convert.
Block Number
The Block Number option (also available with ) is use to customize the output of block
numbering or sequence numbering codes (Nxxxx) for your postprocessor.
NOTE: This option also is available with Sequence Numbers on the Checklist.
NOTE: The parameters set in this dialog are used in the INIT_CFG macro. The parameters set
are output as a SEQNO statement in the INIT_CFG macro. At any time during execution of the
postprocessor, you can add additional macro programming in other macros to control block
number output. Be careful, however, because it is possible to modify or disable the use of the
dialog parameters.
Field Description
Register Used Displays the code to be output for sequence numbering. You select from
the list of defined registers. For example, select N.
Start value Displays the integer value to be used as the starting block number. You
enter this number (for example, 100).
Increment value Displays the number to add to each sequence number for subsequent
sequence numbers. You enter this number (for example, 10).
Maximum value Displays the maximum value that can be used for block numbers. You
enter this number (for example, 999). When this block number is reached,
the next block number begins with the start value.
Block step Determines how many blocks to output before output of a sequence
number. The most common value is 1, which outputs sequence numbers
on each output block.
Block numbers Specifies whether block numbering is active or inactive for the
postprocessor.
Field Description
Output space after Indicates that you want to output space after the block number.
block number
The sequence numbering is saved in the INIT_CFG macro, using the macro language SEQNO
command. The dialog example above equates to:
N1 G40 G90 G80
N2 G1 Z3. Y2. X1. F100.
N3 Z6. Y5. X4.
N4 Z9. Y8. X7.
N5 Z3. Y2. X1.
N6 Z6. Y5. X4.
N7 Z9. Y8. X7.
N8 M30
The resulting SEQNO command is:
SEQNO(START=1.000000,INCR=1.000000,SPACE=1,ON,"N")
Another example is:
Comment Blocks
The Comment Blocks option (also available with ) define how your controller will output
comment blocks or operator messages.
NOTE: This option also is available with Comment Blocks on the Checklist.
Field Description
Prefix string Displays the string to be output preceding the comment block. For
example, enter:
(
Or:
MSG
Suffix string Displays the string to output at the end of the comment block, if there is
one. For example, enter:
)
Output comment Outputs comments. If this option is not selected, comment statements are
blocks not output no matter how the other fields in this dialog are set.
Output empty line Outputs a blank (empty) line before the comment block.
before comment
Output empty line Outputs a blank (empty) line after the comment block.
after comment
Field Description
Output with block Outputs the comment block with a sequence number.
number
Set block numbers Turns on block numbers after the comment block is output. If block
on after comment numbers are on, you should probably select this checkbox.
block
Convert to Outputs all comment strings in upper case. Otherwise, output is as in the
uppercase APT/CL file.
Register Format
The Register Format option (also available with ) defines tables for controller register
formats used in a postprocessor. You can enter all the letter address codes or just the ones you
plan to use.
NOTE: This option also is available with Register Format on the Checklist.
When you run a postprocessor, the output contains lines consisting of control registers and their
associated values, as shown here:
N6 G1 Y-95. F300
This line contains four control registers of different types and formats.
It is not enough just to output the letter address and its value. Certain limitations and specific
formats always apply. Different machines use different control registers to perform specific
functions. You can define the control registers your machine controller needs using the Register
Definition dialog.
Because all the registers parameters cannot be displayed on a single screen, the Register
Definition consists of two tabs: Basic and Advanced.
Each controller address has a respective field definition. The values in these fields can also be
modified via REGISTER variables. The values entered here apply to controller (not machine)
limits. Machine limits must be entered within the Machine Motion dialog.
The two tabs of information available on the Register Definition dialog are described below.
Basic
Fields on the Basic tab are:
Field/Button Description
Name Displays the output name of the controller register.
Units Out Displays the output units (INCH, MM, DEG, CONST). This parameter does
not affect the output format except in the case of rotary axis registers.
Units In Displays the input units (INCH, MM, DEG, CONST).
Initial Value Displays the initial value of the register.
Digits Specifies the number of digits output before and after the decimal point. For
example, 2.4 means output two places to the left and four places to the right
of the decimal.
Dec Indicates (when checked) that a decimal point is required.
Lead Indicates how the postprocessor will output leading zeros:
YES Outputs leading zeros.
NO Does not output leading zeros.
1 Outputs one lead zero.
2 Outputs two lead zeros
3 Outputs three lead zeros.
4 Outputs four lead zeros.
Trail Indicates how the postprocessor will output trailing zeros:
YES Outputs leading zeros.
NO Does not output leading zeros.
1 Outputs one lead zero.
2 Outputs two lead zeros
3 Outputs three lead zeros.
4 Outputs four lead zeros.
Sign Indicates (when checked) that a + sign is included before positive values.
Modal Indicates (when checked) that the register is modal.
Incr Indicates (when checked) that the register is incremental. Clear the checkbox
for absolute.
Incr. Name Displays the incremental name used in the incremental mode is active (Incr,
above, is checked).
Add/Copy Enters or copies a new register.
You can output just numbers with a specific format, and have a register name
appear blank. You can also require a specific output format for numbers, such
as integers only, two-place decimals only, and so forth.
Each register has its own unique format. If there is a need to use the same
register with a different format, enter the new register as F@DWELL or
F@CYCLE
If you require a register that starts with the character @ you must define the
new register as:
@@register
For example, @@F would output the @F register.
Field/Button Description
Add/Copy In the example below, the macro OUTPUT statement:
(continued) OUTPUT("L ", '@', 1.234, '@', 5.678, NEWLIN)
might output (depending, of course, on the definition of the @ format):
L 1.234 5.678
This type of output is typically only required for nonstandard postprocessors
that require macro customization.
Sometimes a controller may be using the same controller register for a
different function. For example, the X axis may have a 5.3 decimal format.
But for a dwell time the format could be completely different. The IMS
library posts handle this by also utilizing the @ character:
X@DWELL
IMSpost reads the register name, but only outputs the letter(s) that precede
the @ character.
Test Output Specifies a value used to determine how the postprocessor will output this
Value value. To test a register format:
1. Enter a value in the Test Output Value field.
2. Select a register to test (in the Name column).
3. Review the result shown to the right of the Test Output Value text box.
Advanced
Fields on the Advanced tab are:
Field/Button Description
Minimum Displays the minimum value for the output values. Provide a number if you
select the Limit Min checkbox. This value is designated for the controller
register and not machine axis limits. Machine axis limits are set within the
Machine feature.
Limit Min Indicates (when checked) that output values are limited to a defined
minimum.
Maximum Displays the maximum value for the output values. Provide a number if you
select the Limit Max checkbox. This value is designated for the controller
register and not machine axis limits. Machine axis limits are set within the
Machine feature.
Limit Max Indicates (when checked) that output values are limited to a defined
maximum. If you program a feedrate over the maximum and you want the
postprocessor to use the specified maximum feed, this maximum feed must be
represented by checking this option. For users with the macro utility, you can
also specify the following in the appropriate macro:
[Link] = 2500
[Link] = "Y"
Dec Char Displays the default character for decimal output.
Field/Button Description
DecInt Indicates how you want decimal characters output:
YES Outputs characters with integer values.
NO Does not output characters with integer values.
FORMAT Uses the defined format.
Before Displays the character or string to be output between the name and value.
After Displays the character or string to be output after the value.
Space Indicates (when checked) that a space is required between the register name
and value. (X 10. or X10.)
Table Displays the table, if any, associated with the register. To define a table, refer
to the Tables feature.
Zero Specifies the character output when the register value is 0. For example, some
controllers do not accept a 0, .0, or 0. as output.
Formula Displays a mathematical formula to be applied to the value of the register on
output. Specify the input value of the register as a question mark (?). For
example, to change the input value from radius to diameter, enter the
following for the X register:
?*2
Add/Copy Enters or copies a new register.
You can output just numbers with a specific format, and have a register name
appear blank. You can also require a specific output format for numbers, such
as integers only, two-place decimals only, and so forth.
Each register has its own unique format. If there is a need to use the same
register with a different format, enter the new register as F@DWELL or
F@CYCLE
If you require a register that starts with the character @ you must define the
new register as:
@@register
For example, @@F would output the @F register.
In the example below, the macro OUTPUT statement:
OUTPUT("L ", '@', 1.234, '@', 5.678, NEWLIN)
might output (depending, of course, on the definition of the @ format):
L 1.234 5.678
This type of output is typically only required for nonstandard postprocessors
that require macro customization.
Sometimes a controller may be using the same controller register for a
different function. For example, the X axis may have a 5.3 decimal format.
But for a dwell time the format could be completely different. The IMS
library posts handle this by also utilizing the @ character:
X@DWELL
IMSpost reads the register name, but only outputs the letter(s) that precede
the @ character.
Field/Button Description
Test Output Specifies a value used to determine how the postprocessor will output this
Value value. To test a register format:
1. Enter a value in the Test Output Value field.
2. Select a register to test (in the Name column).
3. Review the result shown to the right of the Test Output Value text box.
Deleting a Register
NOTE: The library posts probably contain more controller registers than you need. It is not a
good idea to delete them.
If you must delete a register:
1. Select one or more registers you want to delete. To select more than one, press and hold down
the SHIFT key as you select registers.
2. Press the Delete key on your keyboard. The registers are deleted from the list.
For example:
[Link] = 1250
[Link] = 2000
Remember, when setting a register to something other than a value, it must be surrounded in
double quotes. For example:
[Link] = "S2"
[Link] = "N"
Formats and formulas are also treated as text strings. For example:
[Link] = "?*2"
[Link] = "5.3"
Function Codes
This option (also available with ) defines the functions (G/M codes) for use in the
postprocessor.
NOTE: This option also is available with Function Codes (G/M) on the Checklist.
In the Function Definition dialog, you define the function codes you want to use in your
postprocessor. You can enter all the function codes or just the ones you want to use. When you
create a project, a basic set of functions is automatically associated with the project. These are
displayed in the Function Definition dialog. You can remove or replace them as you build a new
postprocessor file.
In general, advanced users employ function lists and the associated function groups as tools for
making macro programming easier and more efficient. To set up specific functions, select
CONTROLLER > Function Groups.
NOTE: The IMS macro language OUTPUT statement description describes how function group
variables are used in IMS macros.
Before using the Function Codes option, create a project or open an existing one.
1. In the text box to the right of the Add | Copy button, enter the name of the new function.
When adding more than one function code, separate each function with a comma. For
example, in the Add/Copy display area, enter:
G63,G64,G65,M41,M42
Make sure the Caps Lock is on. Most G and M function codes are usually in uppercase.
2. Click Add | Copy. The new function is added to the bottom of the list.
3. Modify the parameters, as described in the table below.
4. Click OK to save your work.
NOTE: If necessary, you can associate new function codes with Mode/Group variables. If the
function code requires the output of other registers, simple enter them in the Use field. You can
also specify how many G and M codes may be output per block (Maximum codes per block).
Field/Button Description
Name Identifies the functions associated with the postprocessor.
Mode/Group Displays the group or mode with which the function is associated.
A code associated with a MODE stays in effect until a different code
within the same mode cancels it. For example, an M3 code will stay in
effect until cancelled by an M4 or M5. A G1 code will stay in effect until
cancelled by a G0, G2, or G3.
Modal Indicates whether the function is modal or nonmodal.
Use Associates registers that are not based on machine axes. Separate these
with commas. These letter addresses are output with the corresponding
function code. For more information, refer to USE and One-Shot USE1
Parameters below.
Use Machine Axes Associates registers that are based on specific machine axes. For
example, a 5-axis machine might use X,Y,Z,A,B.
Component Links a specific component to a function (such as from MACHINE
FUNCTIONS in IMSmachine). Refer to MACHINE > Components.
Technology Specifies the technology type as All, Mill, or Turn. The
SYSTEM.TECHNOLOGY_TYPE variable applies and should be in the
system variable list (see Debug). For example:
Output Alone Specifies the function code may be output alone in a block. Do not select
this option if the function code should not be output by itself.
End Block Specifies the function is performed at the end of the block. Do not select
this option if the function is performed at the beginning of the block.
By Self Specifies the function code must be output by itself on a block.
Add | Copy Adds the function name specified in the text box to the list of functions.
To copy a function, select it and click Add | Copy. The program copies
that function definition and creates a new function with the same
parameters (which you can then edit).
Maximum codes Set the maximum codes per block for G-codes and M-codes.
per block
If you want to delete a function code, highlight it on the list and press the Delete key on your
keyboard.
Function Groups
The Function Groups option defines function groups and the functions that are members of those
groups.
Field/Button Description
Group Names Displays the groups currently associated with the postprocessor.
Group Members Displays the functions that are members of the group selected in the
Group Names list.
Initial Displays the default condition, if any, of the group. (This information is
noted under the Group Members area.)
Add Group Adds a group to those defined for the postprocessor. You are prompted to
provide a name for the group.
Delete Group Deletes the group selected in the Group Names list.
Add Member Adds a member to the group selected in the Group Names list. You are
prompted for the member name.
Delete Member Deletes the member selected in the Group Members list.
Initial/Clear Sets an initial value for the group. You must first select both a group and
a member in that group. Otherwise, the initial value is set to NONE. You
can also click this button to clear the initial value for a group.
Function Selects a function for a group/member combination. You must select both
a group and member before clicking this button.
Each group contains members. For example the MODE 'SPINDLE' would contain members of
CLW, CCLW, OFF, and ON. Functions can then be associated to these members.
If the function code(s) do not exist, you must use the Function Codes feature to add them.
Subprograms
The Subprograms option enables you to set up subprograms for the postprocessor.
Field Description
No controller Indicates that no controller subroutines should be output.
subprogram codes
Fanuc style Indicates that FANUC style subprograms should be output. This format
uses a function to call the subprogram and controller register (letter
addresses) to specify the subprogram number and number of repeats.
Seqno style Indicates that Seqno style subprograms should be output. This format
used a function and a starting and ending sequence number to mark the
subprogram.
Start of Specifies the Function code and Register (letter address) used to identify
subprogram code the start of the subprogram.
Select the Seqno Off options if the subroutine block should not be output
with a sequence number.
End of Specifies the Function code and Register (letter address) used to identify
subprogram code the end of the subprogram.
Select the Seqno Off options if the subroutine block should not be output
with a sequence number.
Field Description
Call subprogram Specifies the Function code and Register (letter address) used to call and
repeat the subprogram.
Select the Seqno Off options if the subroutine block should not be output
with a sequence number.
Output Message Specifies that the postprocessor should output a message regarding the
subroutine.
Incremental Mode Specifies that the postprocessor should force out Incremental mode.
Move to end Specifies that the postprocessor should output subroutines at end of the
machine file.
Activate Activates the subprogram option.
subprogram option
Tables
The Tables option enables you to set up controller-defined lookup tables. Use these tables to
establish a discrete set of acceptable values for spindle speed or cutter compensation.
You can create and delete tables as well as edit their definitions. The primary purpose of tables is
to attach them to registers. As described in this section, you create a table and then select
CONTROLLER > Register Format to choose the defined table. Once this table is complete, you
can add it to the Table column in the Register Definition.
To add a table:
1. Click New and then enter a table name for the table in the pop-up window. This name will be
displayed in the Table field.
2. Click in the Index column and enter the index value.
3. Click in the Value1 column and enter the associated value.
4. If you want to add an additional column of information, click Add Column. By default,
additional columns are named Value2, Value3, etc.
NOTE: The name of the table must be selected in the Table field on the Advanced tab of the
Register Definition (see Register Format). Use the Test Output feature as described for the
Register Definition.
Field/Button Description
Table Displays the name of the table whose definition is displayed in the fields
of the dialog. To view information for a table, select the table name from
the dropdown list.
New Adds a table to the Table dropdown list. You are prompted for the table’s
name (as described in the procedure above).
Delete Deletes a lookup table from the Table dropdown list. You are prompted
for the table name.
Add Column Adds a column for the table.
Delete Column Deletes the last (right-most) column from the table. Note that you cannot
delete the Value1 column.
Index Displays (and enables you to enter) an index for the table.
Value1 Displays (and enables you to enter) a value associated with the index.
You can add columns of values, as described for Add Column above.
This utility is used for creating look-up tables. For example, these S-codes would represent rpm
speeds:
S0 = 35 rpm S3 = 142 rpm S6 = 500 rpm S9 = 850 rpm
S1 = 60 rpm S4 = 250 rpm S7 = 660 rpm S10 = 1000 rpm
S2 = 124 rpm S5 = 330 rpm S8 = 775 rpm
IMSpost will then output the respective integer for the programmed rpm speed.
4. Build the table entries for RANGE1. Enter an index (such as 1) and a value for the index
(such as 10).
5. Enter another index of 2 and a value of 20. Click Add. Continue to add indices through 7 with
associated values through 70.
Tape Format
This option provides options to define the tape format for the postprocessor, including special
characters needed on tape (such as %).
Field Description
Column number for Specifies a fixed number of characters per outline line. Enter 0 if
output block alignment there is no limitation.
Output at the start of Outputs this character(s) at the beginning of each output block.
each block
Output at the end of Outputs this character(s) at the end of each output block.
each block
End of block characters Indicates character(s) that mark the end of an output block.
Start of file character Specifies the character output at the start of the file.
End of file character Specifies the character output at the end of the file.
KBytes Breaks up the NC code output file into files based on this maximum
KByte size. Enter 0 if no KByte break up is desired.
No. of blocks Breaks up the NC code output file into files based on this maximum
number of blocks. Enter 0 if no break up is desired.
Tool life Min Breaks up the NC code output file into smaller files based on this
tool time (minutes) used. Enter 0 if not break up is desired.
Field Description
Maximum characters per Specifies the maximum number of characters per output line. Enter
output line 0 if there is no limit.
Continuation character Specifies the character used to continue the current block on the
next output line.
Output spaces between Indicates that spaces are placed between codes in the output.(G0
codes X100. M5)
TIP: If your controller needs a special ASCII character at the beginning or end of the tape file,
you can enter its associated integer value from the ASCII table preceded by the carat (^)
character. For example, to output the ASCII character for “Line Feed” enter the following in the
respective display area:
^10
Import Controller
The Import Controller option overrides the existing controller file with another controller file.
Because IMSpost merges the controller data with the machines physical data, you have the ability
to override your postprocessor controller data with any other controller data file that resides on
your machine. For example, you can swap the Fanuc logic for a Heidenhain and still maintain the
axis configuration of your machine.
When the Import browser is displayed, highlight the *.lib file you want to load and click Open.
Or, double-click on the selected *.lib file.
When you use this option, all the dialogs within the postprocessor are updated accordingly. The
machine configuration will stay the same.
Apt Definition
This option (also available with ) opens the IMS Apt Definition dialog and enables you to
set the APT definition to convert. This is used for the Controller Emulator and not active in the
Postprocessor environment. Refer to the IMScontroller Emulator Guide for details.
Grammar
The Grammar option (also available with ) defines the grammar for macro syntax, registers,
functions, variables, and CE errors. This is only active for the Controller Emulator and not
applicable in the postprocessor environment. Refer to the IMScontroller Emulator Guide for
details.
Notes
IMSpost views a postprocessor as two separate items: a controller and a machine. This gives you
the capability of selecting a controller from your library and connecting it to the machine axis
configuration. IMSpost will automatically take you through these important steps.
The best way approach is to select a machine from the IMS library machine models. If you need
to modify an existing library model or create a machine from scratch, there are a few important
factors.
When defining your machine, it is important that you keep a consistent view while
constructing the entire machine.
Define your machine so all its axes are at their machine zero position. IMSpost uses the
standard right-hand coordinate system (for example, assume you are standing directly in
front of the machine).
Rather than using XYZ for linear axes, IMSpost uses the following descriptions:
HORIZONTAL defines the linear axis that moves from your left to your right.
INTO defines the linear axis that moves through you.
VERTICAL defines the linear axis that moves from the floor to the ceiling.
For rotary axes, IMSpost uses:
A as the name of the axis that rotates about the X axis.
B as the name of the axis that rotates about the Y axis.
C as the name of the axis that rotates about the Z axis.
The MACHINE menu includes the following options:
Option Description
Motion Displays all programmable machine axes. Use this dialog to define the
moving axes that your machine tool accepts or supports. You can name the
moving axes with the associated controller letter addresses (for example,
letter address X controls horizontal motion).
Components Specifies model components. Use this dialog to describe the physical
components of the machine (such as tables, heads, parts, and tools).
References Specifies machine offsets (pivot points). Use this dialog to describe offsets
between the components you have defined for the machine.
Multi-Axis Provides setup options for tool tracking.
Multi-axis Setup Sets specific formatting and conditions for multi-axis
programming.
Work Plane Sets formatting for a multi-axis machine with a controller
that supports different working planes.
Option Description
Import Imports machine options and overrides the existing machine model with:
Machine IMS project file From another postprocessor file. Use this option to
import a complete machine description (including
motion, components, and references) from another
project file.
IMS model file From an existing machine model. Use this option to
import a complete machine description from the
IMSmachine product. IMSmachine is automatically
installed when you install IMSpost and it is used to
graphically build a machine.
Pre-defined machines View and select predefined machine model.
Motion
The Motion option displays all programmable machine axes.
NOTE: This option also is available with Motion Axis on the Checklist.
Use the Machine Motion dialog to define the moving axes that your machine tool supports. You
can name the moving axes with the associated controller letter addresses (for example, letter
address X controls horizontal motion). Click in a cell to edit the information.
NOTE: Typically there is no need to add machine axes within this dialog. The predefined
machines models within IMSpost have been proven to be successful for many users.
To edit a motion axis:
1. Select the motion axis (row) that you want to modify.
2. Modify information, as described below.
To add an axis:
1. Enter the motion axis letter in the text box. When adding an axis, it is recommended to load a
new machine model that represents the new configuration. Adding an axis is commonly done
for machines that include co-linear axes (two machine axes that share the same direction), as
described below.
NOTE: The best way to add additional axes is to ensure you have the proper machine model
active. On the MACHINE menu, select the Import Machine option and then the Pre-defined
Machines option.
2. When adding a co-linear axis, indicate a Priority for the axis. Priority is used for machines
that support co-linear axes. For example, the W-axis would move the spindle head while the
Z axis would move the spindle quill. In any case, both axes must share the same direction
(vertical, horizontal, or into). Specify both axes in the order of their priority, as described for
co-linear axes (below).
3. Click Add.
4. Modify axis information. To do so, click in the field and select/enter the appropriate
information:
Field/Button Description
Component Specifies the machine component name that “moves” the associated
axis.
Type Indicates the axis type: Linear or Rotary.
Direction Indicates the axis direction:
(+) vertical
(-) horizontal
(+) into
(-) into
The + and – indicators associate a sign with the direction of
movement.
You can also program a 3-axis vector input (for example: 1,0,0)
instead of choosing one of the default axis names.
Minimum Available only if the motion type is Linear:
Defines the minimum axis travel limits for this machine axis. For
linear axes, these values are stored internally, but are not checked
unless explicitly coded in the appropriate macros.
The minimum and maximum values do not have an effect on rotary
axis output.
Maximum Available only if the motion type is Linear:
Specifies the maximum position value for the axis.
Once an axis is defined, you can click More…to enter additional definitions. A dialog similar to
the following is displayed. This dialog applies to a linear definition:
Field/Button Description
Name Specifies the motion axis name.
Register Specifies the letter address used to describe the moving axes defined
for the machine tool. The letter address must be defined in the Register
Format.
Component Specifies the machine component name that “moves” the associated
axis.
Channel Assigns a channel name if more than one machine with multi-channel
programming is used.
Type Indicates the axis type: Linear or Rotary.
+/- for rotary Rotary Only:
direction Indicates direction. For example, if this option is checked, +90 and -90
are the same position, but travel direction is CLW for +90 and CCLW
for -90.
If this option is not checked, +90 and -90 are different positions, 180
degrees apart. (This is the more standard condition.)
Field/Button Description
Short Way Rotary Only:
Instructs IMSpost that the controller will determine the direction that
requires the shortest route.
[Link] = 1 (on) or = 0 (off)
Output is from 0 to 360.
Direction Indicates the axis direction:
(+) vertical
(-) horizontal
(+) into
(-) into
The + and – indicate the direction of movement.
You can also program a 3-axis vector input (for example: 1,0,0)
instead of choosing one of the default axis names.
Minimum Defines the minimum axis travel limits for this machine axis. For
rotary axes, this value is always used in determining rotary axis
position. For linear axes, this value is stored internally but not checked
unless the Limit to Minimum option is selected (or it is explicitly
coded in the appropriate macros).
Limit to Minimum Linear Only:
Indicates that travel should be limited to the minimum value.
Maximum Defines the maximum axis travel limits for this machine axis. For
rotary axes, this value is always used in determining rotary axis
position. For linear axes, this value is stored internally but not checked
unless the Limit to Maximum option is selected (or it is explicitly
coded in the appropriate macros).
Limit to Maximum Linear Only:
Indicates that travel should be limited to the maximum value.
Home Position Specifies the “home” position for the axis. This is used only if the next
option (Move to home at tool change) is selected.
Move to home at tool Moves to the home coordinate at the tool change.
change For example, if your output shows Z motion first after a tool change
and you prefer to see XY before the Z axis motion, select this option
for the Z axis definition. Enter a value for the Z home position (in the
field above). The postprocessor will not output this point, but it will be
updated internally.
Maximum Feed Specifies the maximum axis feed (rapid positioning) for time
calculations.
Minimum increment Does not make movements that are smaller than this value.
Axis Step Outputs only axis motions to the step amount (round the values). A
step value of 2.5 will output values of 0, 2.5, 5.0, 7.5... or -2.5, -5.0, -
7.5...
Delta (co-linear axes) Linear Only:
Specifies the delta movement (if there is any) before a switch to
movement of the other machine axis parallel to this one. The machine
must be defined such that parallel linear axes exist.
Field/Button Description
Discrete position(s) Rotary Only:
Lists positions if the rotary axis is limited to certain fixed position. For
example:
[0, 90, 180, 270]
Acceleration Specifies the rate for acceleration speed (CE only). This is not
applicable to IMSpost.
Use Acc. Indicates that Acceleration should be used (CE only). This is not
applicable to IMSpost.
Deceleration Specifies the rate for slow down (CE only). This is not applicable to
IMSpost.
Use Dec. Indicates that Deceleration should be used (CE only). This is not
applicable to IMSpost.
Device ID (Catia) Shows the Catia device ID. Each motion axis has a device ID.
Lock axis for type Defines axis locking. If this is a linear axis, only the Linear option is
available. If this is rotary axis, both Linear and Rotary axis options are
available. This is because it is possible to use a rotary axis as a
substitute for linear motion. By default, the rotary position is not used
for position.
For example, given a 4-axis machine with XYZC axes, if you want to
have all motion in the XY plane to use X and C rather than X and Y,
set the Y-axis box to “Lock Linear” and be sure the “Lock Linear”
option is cleared (unchecked) for the C-axis.
Enable Auto Retract Available only if the motion type is Rotary:
Enables the Auto Retract feature if it is active (see MACHINE >
Multi-axis > Multi-axis Setup).
Enable Auto Retract Available only if the motion type is Rotary:
For Linear Move Repositions the rotary axis if a linear axis reaches a specified
minimum or maximum range.
Co-Linear Axes
Co-linear axes are used to support machines that have two machine axis that share the same
direction. A common example would be a horizontal machine with a programmable table or
saddle. The tool (Z) and the saddle (W) share the same axis direction. You need to instruct
IMSpost as to which axis has priority.
The following motion procedure describes a horizontal machine and how the W axis is added.
1. Enter the co-linear axis (W in this example) in the text box to the right of the Add button.
2. Indicate the axis that takes priority. In this example, enter Z,W to indicate that the Z-axis has
priority over the W-axis. Z will move first and, if any distance remains, W will move.
3. Click Add.
4. Click in the Direction column and select the direction of the axis. Note that both axes must
have the same direction (vertical, horizontal, or into).
5. Because Z axis is specified as the Priority axis, enter the distance the Z axis will travel. To do
so, click More… to the right of the Z-axis definition and enter the value (20 in the example) in the
Delta field.
This dictates that Z will take the first 20 mm (or inch) of each move. The remainder will be
done by the W. For example:
GOTO/10,10,100 Nxxx G1 X10. Y10. Z20. W80.
6. You also should include the W-axis parameter in your Function definition (as shown below).
To do so, open the CONTROLLER menu and select the Function Codes option. Enter the W-
axis parameter in the appropriate Use column field. The Use field instructs the postprocessor
as to what other registers should be output with the associated function code.
Components
The Components option displays various components that construct the active machine model.
Field/Button Description
Name Specifies the component name.
Type Indicates the components type:
Table, Head, Tool, Part, Static, Fixture, or Design
Mount Defines what the component is attached to.
Motion Describes the machine axis (if any) associated with the component.
Field/Button Description
Shape Indicates the component shape type:
Cube, Cylinder, Cone, Sphere, Torus, Extrude, Revolve, or Mesh
Cone or Cylinder must be used for tool shapes in order to define tool
orientation.
Direction For Tool Component Types Only:
Specifies the orientation direction of the component. Be sure to define all
component directions for these types of components.
Device ID (Catia) Identifies the device (Catia only).
Add Adds a component. Enter the component name in the text box and then
click Add.
To delete a machine component, select the component row and click Delete on your keyboard.
NOTE: It is recommended to select a predefined machine through the supplied existing models.
You can do this through FILE > New or on MACHINE > Import Machine > Pre-defined
machines.
References
The References option specifies machine offsets (pivot points). This feature is used with multi-
axis machines that require machine offsets or rotary axis “pivot points.”
NOTE: Entering machine offsets through this dialog ensures that the offsets are placed in the
proper area within IMSpost.
Field/Button Description
X (Horizontal) Specifies the reference offset in the horizontal machine direction.
Y (Into) Specifies the reference offset in the “into” machine direction.
Z (Vertical) Specifies a reference offset in the vertical machine direction.
Set Up Machine Defines the machine zero, as described in Defining Machine Z Zero.
Zero
Advanced Accesses Advanced User options, as described below.
FOR ADVANCED USERS: Each component has a point defined as its origin. When the
machine is “built,” it is set up in such a way that all component origins are attached at the same
point. This is not always the case with multi-axis or rotary axis machines. For example, it is
common to have a rotary table (for example, a-table) with an origin or pivot point below the xy-
table. The value from the a-table origin to the xy-table origin would be output in the vertical
column or the appropriate row in the reference table. You would proceed similarly with origins
that are not attached at the same point in order to accurately define your multi-axis machine.
Click the Advanced button and this dialog is displayed:
Field/Button Description
Horizontal Specifies the reference offset in the horizontal machine direction.
Into Specifies the reference offset in the “into” machine direction.
Vertical Specifies a reference offset in the vertical machine direction.
Horizontal If the from/to components are mounted in a rotated orientation:
Orientation Specifies the axis where the horizontal component of the “from” axis is
mounted on the “to” axis.
Into Orientation If the from/to components are mounted in a rotated orientation:
Specifies the axis where the “into” component of the “from” axis is
mounted on the “to” axis.
Field/Button Description
Save Saves the information on the dialog.
Reset Resets the information to the when the dialog was opened.
NOTE: It is highly recommended to enter machine offsets through the Machine References
feature. IMSpost will then place these values in the proper cells within the machine reference
section.
This selection also works in conjunction with how the postprocessor is tracking the tool.
Depending on what you selected and how you choose to track the tool, these two settings may
offset your tool axis. You specify the tool tracking by selecting MACHINE > Multi-axis > Multi-
axis- Setup. The area for “Output using” gives you four choices: Pivot, Face, Center, and Tip.
For example (assuming a reference pivot distance of 10 mm above spindle face):
GOTO/300,300,100
Multi-Axis
The Multi-axis feature is used to set specific formatting and conditions for multi-axis
programming. Several options are available:
Multi-axis Setup for postprocessors that contain one or more ROTARY machine axes.
Work Plane New to offer a complex transformation applying a matrix to the coordinate
system, primarily to put the Z-axis of the new frame along the tool axis (in order to use
drilling cycles, cutter compensation, etc.).
Transitions to manage the transition between operations.
General Strategy to define both the transformation applied to the coordinates (pivot point,
Rotating Tool Center Point (RTCP), and working plane) and the motion strategy
(Cartesian and polar).
In order to manage complex postprocessors, the Multi-Axis feature takes into account these steps:
Definition of the different behaviors that could be used during postprocessing
(transformation, strategy, etc.)
Activation
Application
This allows for the definition of multi-configurations and multi-strategies in the same
postprocessor just by defining what is expected and when. Many variables are initialized (and
may be changed during treatment), but are only taken into account when needed. Most of the new
variables are GLOBAL variables defined in the INIT macro and used at the start of each
operation.
Kinematics Strategy
In the case of multi-axis machines, there are often many solutions for the position of the machine
in order to put the tool tip in the right place compared to the part.
General Case: In the General Case, there are two solutions. For example, with AC machine, A-
90 C0 or A90 C180 could machine the part (adapting the linear axis position accordingly).
Depending on the range of the C axis, you could have more solution (modulo 360) but the
greatest risks on the machine come generally from the A rotation.
Different options could exist for the best General Case solution:
Use the closest one (minimizing the rotary motions). This reduces the cases of huge
rotary motions that, in the worst case, are dangerous for the part or the machine.
Force the “main rotary axis” to go in a direction (positive or negative). This keeps the
head or the table in a specific place compared to the operator. The disadvantages is the
generation of big rotary motions during the transition (instead of going from A-5 C0 to
A5 C0, the postprocessor will select the solution A-5 C180).
Force a linear motion to stay on a side of the part. (IMSpost does not provide an option to
reach this solution.) With a C table, when machining a cylinder (internal and external
side), it stays on the same side of the machine.
“Axial” Case: In the Axial Case, there are an infinite number of solutions. When the tool axis is
along a polar axis, all the position of this axis could allow for the kinematics solution.
Different options could exist for the best Axial Case solution:
Select the axis that will be used to machine the part. Either:
Keep using the linear axis and lock the polar axis, or
Use the polar axis and one linear axis normal to it.
Select the axis to lock outside of the operation and its position before milling.
Coordinates Transformations
Pivot Point: The postprocessor directly uses the machine coordinates, applying only the
translation due to the tool length management and the machining axis system.
RTCP: This transformation is based on the CAM approach. Ignoring the kinematics, the output
gives only the position of the tool tip compared to the part. The Lintol is another notion
automatically attached to this transformation. Depending on the controller configuration, the
controller can consider the problem of chordal error during the head or/and table rotation + linear
motion.
Working Plane: This transformation creates a local frame for an operation. The purpose of this
transformation is mainly to keep the Z of the local frame along the tool axis. This allows for the
use of cutter compensation and drilling cycles. A second way to use the local frame is to put a
main axis along a main direction of the shape to be machined. In this case, the tool axis is not
enough and the programmer must define it due to an axis system change in the CAM product.
Polar Controller Function: On machines similar to mill-turn when the tool axis is along the
turning spindle, the shop floor prefers to use a rotary rather than linear axis for the kinematics
solution only because of limited axis ranges. Nevertheless, except in the case of a drilling
operation, using the rotary axis generates cosmetic and program problems (such as huge programs
(Lintol), loss of cutter compensation, loss of linear quotation of the part in the ISO, etc.). To
compensate for this, some controllers offer a function that uses Cartesian output but translates in
polar motion in the machine (TRANSMIT of Siemens, G12.1 of Mazak, G21 of NUM).
Multi-axis Setup
This option is only necessary for postprocessors that contain one or more ROTARY machine axes.
Field Description
Use RTCP output Specifies that the output should be for a machine controller
supporting Rotating Tool Center Point (RTCP) output. This ignores
table rotation and takes care of table rotation compensation. For
example, this option takes care of the distance from the tip end of a
spindle to the pivot point. The use of Pivot or Face (see the Output
using… options described below) depends on the controller. You
defined if the distance is to the face of the spindle or to the pivot
point.
Multax on by default Enables the default startup condition of the postprocessor to multi-
axis postprocessing (as if MULTAX/ON has been programmed in the
APT/CL file).
Lintol on by default Enables the default startup condition of the postprocessor to linear
tolerance calculations for multi-axis postprocessing (as if
LINTOL/value has been programmed in the APT/CL file).
Field Description
Output using... Defines how to track the cutter. Select one:
Pivot (point of rotation on the head)
Face
Center
Tip
MSpost gives you the option of tracking the tool a number of ways.
Depending upon what you select in the “Output using” area, the
postprocessor will make its calculations based upon the tool data
passed within the APT/CL file.
The postprocessor normally gets its tool data from the LOADTL and
CUTTER statements. The tool length is defined with LOADTL and
the cutter diameter (or radius) is in the associated CUTTER
statement. This tool data updates these IMS system variables:
SYSTEM.TOOL_LENGTH Tool length
SYSTEM.CUTTER_RAD Cutter radius
SYSTEM.CUTTER_DIAM Cutter diameter
Within IMSpost, there is a CUT statement that instructs the system as
to what is being cut (PART) and how it is being cut (TOOL...). For
example, depending on what was selected in the “Output using” area;
the following four CUT statements could be generated:
CUT(PART,[Link]) Cut part based upon tools pivot point
(Machine References)
CUT(PART,[Link] Cut part with spindle face
CUT(PART,[Link]) Cut part with tools center
CUT(PART,[Link]) Cut part with tools endpoint
Solution Condition Indicates the solution chosen by the postprocessor. As a general rule,
IMSpost chooses the solution that represents the shortest movement
of the tool. You can enter a conditional expression in the Solution
Condition box to control the solution chosen by the postprocessor.
In multi-axis programming, depending on machine axis limits and
orientations, it is quite often possible to have more than one correct
output solution for any input point/vector value. When the Solution
Condition is true, the postprocessor will output the alternate position.
If a valid expression is entered, the postprocessor will make this
check for every 5-axis motion.
The system variable that contains this expression is:
SYSTEM.FORCE_WAY " expression "
For example:
SYSTEM.FORCE_WAY = "MACHINE.C > 45.0"
This example delete current solution expression:
SYSTEM.FORCE_WAY = ""
TIP: Use MACHINE type variables in the conditional expression,
rather than REGISTER variables. MACHINE variables are checked
during the calculation of the solution, whereas REGISTER variables
are not set until after the solution calculation has been completed.
For example, use:
Field Description
MACHINE.C > 45.0
rather than:
[Link] > 45.0)
Enable read ahead to Activates the routine that determines the best initial tool start-up
choose best solution orientation.
For 5-axis machines; this routine instructs IMSpost to look ahead
through a specified area of the part file and determine the best way to
initially position the tool. With this option selected, it could eliminate
or reduce the need for tool retractions and tool re-orientations. For
example; one start up tool orientation could be:
Nxxx X..Y..Z.. A45.0 C0.
and the alternate could be:
Nxxx X..Y..Z..A-45.0 C180.0
The global variable that controls this checkbox is:
GLOBAL.RAPID_BEST_SOLUTION
MULTAX/ON must be in effect here. If it is OFF, no SOLUTION
will be returned. MULTAX/ON could be set as a default condition in
this dialog.
Refer also to More Details About Best Solution, below.
Enable auto retract / Activates the retract/reorient feature and the options below. (Refer to
reorient for rotary axes the Enable Auto Retract option for MACHINE > Motion.)
Automatic retract and reorient is an optional feature of multi-axis
postprocessing using IMSpost. The retract/reorient condition occurs
when a rotary axis sees a new tool axis vector that exceeds the angle
specified in the “Auto retract angle” display area (described below),
or it reaches a machine travel limit while in the process of a cutting
move, and must retract the tool, unwind the rotary axis, move back to
the last position, and finish the cutting move.
With this feature enabled, IMSpost performs each of these moves
automatically when the condition occurs during postprocessing of a
multi-axis file. This motion can be modified within the
AUTO_RETRACT macro.
Auto retract angle Defines the delta angle that activates the auto retract feature. The
software will calculate the included angle between two (IJK) vectors,
and then compares it to the sum of angle changes of all rotary axes.
If the two deviate by more than the delta defined, an automatic
retraction will be initiated.
Clearance distance Defines the relative distance to retract (along the tool axis) in G0
mode before the rotary axis repositions (unwinds).
Feed in/out distance Defines the initial retraction distance in feed (G1) mode. Remaining
retraction will be done in G0 mode as specified in the Clearance
distance, above.
Rotating Tool Center Point (RTCP)
Rotational Tool Center Point (RTCP) programming mode, allows tool paths (calculated from the
center of a ball nose tool or the tool tip point for an end milling cutter) to be directly matched to
the center of rotation of the corresponding axis. This feature eliminates the need to re-post the
program for tool length changes or reestablish the zero position of the workpiece for every axis
rotation.
With RTCP turned on, new X, Y, and Z values are automatically calculated at the control so that
the center of the tool tip will follow the original tool path centerline. For the postprocessor in the
standard case, this means the X, Y, and Z linear values are not adjusted based on the rotary axis
positions, but rather this adjustment takes place at the machine controller.
The RTCP feature must be supported by the controller.
The IMSpost variable that controls this feature is:
SYSTEM.COORD_RTCP = 1 The “Enable auto retract/reorient for rotary axes” option is
checked (ON).
[Link] = 0 The “Enable auto retract/reorient for rotary axes” option is
not checked (OFF).
When the RTCP option is off, the postprocessor will adjust for the tool length by moving the
linear axes.
This system variable usually applies to table rotations only. Rotary head rotations are controlled
within IMSpost with the CUT statement and are dependent upon the options selected on the
Multi-axis Setup dialog. The CUT statement instructs IMSpost as to which part component will
be cut and which tool components will do the actual cutting. For example:
CUT(PART,[Link]) Cut part with tools defined pivot point (Machine References).
CUT(PART,[Link]) Cut part with spindle face.
CUT(PART,[Link]) Cut part with tools center point.
CUT(PART,[Link]) Cut part with tools tip.
IMSpost also tracks the tool based upon tool data being processed within the part file. Tool data
such as tool length, cutter radius, or diameter update IMSpost variables as these LOADTL and
CUTTER statements are read within the part file.
Each IMS model component contains a control point called its origin. This point is the local
coordinate system of that particular component. Cutter (tool) type components have four of these
local origin points:
ORIGIN tracks the spindle face (no tool length).
TIP uses the SYSTEM.TOOL_LENGTH
CENTER = SYSTEM.TOOL_LENGTH + SYSTEM.CUTTER_RAD
RTCP uses the specified pivot point (distance from spindle face to center of heads
rotation).
The tool origin that will be in effect is dependent upon the options selected on the Multi-axis
Setup dialog.
information for the diameter, radius, and length of the tool in IMSpost variables that are used in
calculating the contact points.
Field Description
Work Plane Type Defines the standard model (only based on main controllers). Other
Work Plane Function options on the dialog are entered based on the type of working plane
selected. Working plane syntax and behavior can vary significantly
from one controller to another. These options entered automatically,
propose samples of working plane syntaxes that are defined in the
main controllers (Fanuc, Heidenhain, and Siemens).
Work Plane On Indicates the function code when the working plane is on.
Work Plane Off Indicates the function code when the working plane is off.
Working Plane Activates (or deactivates) the WORKING_PLANE feature. You may
Available decide to define all the necessary information, but deactivate the
(bottom of the dialog) feature (uncheck this option) as a default.
Vector Properties
In order to create a working plane, the transformation is typically based on the rotation around 3
vectors. You can customize the direction of the vectors, the rotation type, and ranges according to
your requirement.
Field Description
Choice of Rotation Defines the vector based on one of three options:
Definition By Vector Defines the 3 vectors by the components.
By axis name Defines the 3 vectors based on the X, Y, and Z
axes (X is 0,0,1, etc.).
Automatic Internally checks the machine axis and proposes
the machine axis direction by default, if
possible.
Rotation Direction Defines the direction of the vectors of rotation.
Frame Transformation Refers to the trio of rotations about vectors that define the frame.
Independent Indicates that in a static frame, the vector of the
(Static Frame) rotation does not depend on the preceding frame
rotation.
Dependent Indicates that in a dependent frame, the vector
(Floating Frame) of the rotation is shifted based on the vector
rotation that preceded it.
After selecting the frame transformation, fill the table with the
relevant information.
Name Specifies the name of the axis.
Vector Indicates the associated direction vector.
Minimum Defines the minimum rotation angle.
Maximum Defines the maximum rotation angle.
Increment Specifies the tolerance value.
Transformation Options
Field Description
Apply only on Head Allows the transformation to apply the working plane only on the
Rotation head. For example, in the case of a mill-turn with a B-axis, you could
decide that the C-axis is not impacting the working plane which will
be defined only by taking into account the B rotation.
WPL Function Moves Provides the information that the working plane function moves the
Rotary Axes rotary axis according to the working plane (in order to put the tool
axis along the Z of the new frame). For example:
G53.1 after G68.2 of Fanuc, last parameter of the CYCLE800, TURN
or MOVE option of the PLANE SPATIAL.
WPL Function Uses Activates the RTCP transformation with the working plane syntax.
RTCP This option is mandatory in order to manage working plane with the
frame not only based on head rotation.
Axial operation (no Defines the axial operation.
transformation) Output even if Requires the working plane syntax (without
NULL rotation) even if the transformation is null.
Field Description
Use “axial” rotary Includes the “C” rotation if you have a C-axis
axis potion (C) and if the controller is correctly configured.
This forces the controller to take into account
this rotation (which is not always possible).
Transitions
After determining the strategy and transformation for each type of operation, a recurrent problem
is the management of the transition between operations. Most of the risks appear at this point and
the problem can be between operations or after a tool change.
To manage this transition, IMSPost proposes some default and safer behavior by adding a safety
retract. The Transitions feature proposes options to tell the postprocessor when to generate a
safety retract in the ISO code.
Field Description
Safety retract Enables you to select options to define events requiring safely retract
and provide the information that the tool could already be in a safe
place. Options include:
Safe position before any head rotation
Safe position before any table rotation
Safe position at the start of each operation
Tool change point is a safe position
Working plane function safety retract
Transition management
Transition Allows for more accuracy in the definition of the safety retract
management depending on the type of operation and the active strategy:
3-axis operations Indicates the transition management for 3-axis
operations is None, All, or only if the WPLANE
definition is new.
5-axis operations Indicates the transition management for 5-axis
operations is None, All, if RTCP is activated, or
only if the tool axis changes.
In some cases, the programing includes many
operations in the same place the programmer
would prefer to stay close to the part during a
transition without cancelling the RTCP:
If RTCP activation—For example, with the
Fanuc controller (depending of the controller
configuration), RTCP function (G43.4) cannot
be activated if the rotary axis is not reset.
Without safety retract, putting the rotary axis to
0 is very dangerous!
Only if tool axis change—To stay close to the
part, the programmer could define a common
vector between operations and so the
postprocessor will not generate retract. But in
the general case, without doing this, the
postprocessor will maintain a safe way of
working. It lets the programmer to do what he
wants and minimizes the risks.
General Strategy
This feature defines both the transformation applied to the coordinates (pivot point, Rotating Tool
Center Point (RTCP), and working plane) and the motion strategy (Cartesian and polar). In the
definition of a postprocessor, it is important to differentiate between the position of the tool in the
machine and the transformation to apply to the coordinates.
The General Strategy dialog is divided into three sections to define kinematics solution
preferences and coordinate transformations based on the main operation types:
5-axis operations
3-axis operations
Axial operations
5-Axis Operations
This section of the dialog defines the transformation applied to 5-axis operations.
Field Description
Use RTCP Designates the Rotating Tool Center Point (RTCP) as None,
Table+Head, or Head.
None The postprocessor will use a pivot point
strategy.
Head The postprocessor will use a strategy attached to
Table+Head a RTCP function applied either to the Head only
or Table+Head, depending on the controller.
Best solution Defines the preferred direction at the beginning of the operation only.
(first motion only) After that, the postprocessor will use the full range of the axis.
This best solution replaces the Solution Condition defined in the
Multi-Axis feature.
If a solution is not defined, the postprocessor uses the general
solution defined with the Multi-Axis feature.
3-Axis Operations
This section of the dialog defines the transformation applied to 3-axis operations. You can define
both drilling and milling operations in order to have a different behavior for these types of
machining operations.
Field Description
Transformation – Defines the operation as Pivot Point, Working Plane, or RTCP.
Milling Operation If you select Pivot Point, there is no transformation and the
Transformation – postprocessor uses the kinematics solution.
Drilling Operation If you select Working Plane, the postprocessor adds the working
plane transformation after the kinematics solution in order to put the
Z of the new frame along the tool axis. Refer to Work Plane New for
the definition of the transformation.
Best solution Replaces the Solution Condition defined in the Multi-Axis feature.
If a solution is not defined, the postprocessor uses the closest
solution.
Axial Operations
This section applies only for a machine having a rotary axis on the table.
Field Description
Table rotary axis/Tool Designates the table rotation axis that the post may use for linear
Direction positioning in the event axis rotation is parallel to the tool.
Strategy for Axial Defines the kinematics and transformation strategy for Milling and
Operation Drilling. Each can have a different strategy.
Controller Functions Specify the function codes on the controller that enact and cancel the
polar processing mode on the machine.
Field Description
Polar Definition Defines the polar strategy.
Lock Linear Axis Indicates the linear axis to lock
Locked Position Identifies the position (generally 0) to which the
linear axis is locked.
Axis Position Defines the direction (positive or negative) to
use for the axis position.
Linear Definition Defines the Cartesian strategy (linear)
Position of rotary Defines the position of the polar axis as one of
axis these options:
Auto—The postprocessor will use the current
position.
Predefined—The postprocessor will always use
this position.
ROTABL—The postprocessor will always use
this position, but the default position can be
modified.
Value if pre- Defines the value of a predefined position (if
defined Predefined is selected for the position of the
rotary axis).
Import Machine
This option imports machine options and overrides the existing machine model with:
IMS project file From another postprocessor file. This imports a machine description
from another project.
IMSmodel file From an existing machine model.
Pre-defined machines View and select predefined machine model.
IMSmodel File
You can import a machine model from an existing machine model from the /mchfiles folder.
After you select this option, an Open Model File browser is displayed.
1. Be sure you are looking at *.imsmdl files. Refer to the Files of Type box at the bottom of the
browser.
Pre-defined Machines
You can view and select pre-defined machine model. This enables you to maintain all your
controller data and change the machine. All the available library configurations are listed. For
example:
3. After loading the new machine model, you should clear any model offsets that may be in
effect. To clear these offsets:
a. Select MACHINE > References.
b. Click the Advanced button.
c. Click the Reset button to clear all the offsets.
d. Click the Save button.
4. If you still need to enter a new machine offset, select MACHINE > References and enter the
offset in the appropriate field.
Notes
REPORT menu options enable you to specify additional data to be output in a file. Typically this
is a file with the extenstion .lis. (This can be changed within FILE > Preferences). The report file
will include all data from the .nc file along with your specified commentary data to the right of
the machine code (Block Definition).
Each report file consists of a Block Definition, Header, and Footer. This .lis file will reside in the
same directory as your other output (.nc) files. The following example displays the Absolute
Machine Z, Machine Cut Time, and current spindle speed for each output block:
NOTE: When posting, you must activate the List File option on the Postprocess dialog
(EXECUTE > Postprocess). This file will have the same name as the output file unless you
change the name. If you do not check the List File option, the report output file will not be
created.
Two options on the REPORT menu are available to determine the characteristics of reports in
IMSpost. These options enable you to define the List Format and the Table Report. The REPORT
menu includes the following options:
Option Button Description
List Creates an optional *.lis output file (enter commentary data along with
the machine code). Use this dialog to define the format of the block-by-
block data output in the listing file.
When defining a List format, you define information you want to include
with the output list (.LIS) file created by the postprocessor. This .LIS file
shows all the data from your .NC file along with the associated
parameters specified with the List Format dialog.
Table Creates an optional tool data table and displays specified tool/cutter data.
The Table Report dialog controls the characteristics of tables that are
written to a separate file. An example of this type of report would be a
tool table. This report can be generated either in text or HTML format.
Your IMS license must include the IMSpost macro utility for this.
List
Use the List option (also available with ) to create an optional *.LIS output file that defines
the format of the block-by-block data output in the listing file.
Block Definition
The dialog for the Block Definition option is shown above. It includes the following:
Field/Button Description
Column Title Displays freeform text describing the header of this column of list data.
Place the cursor in the text area and enter text. Be descriptive as to what
will be output at the top of each page.
Attached Variable Specifies a variable name to be output in this column in the list file for
each block of data.
Field Format Describes the format (using #.#) of the field output for this column of
the list file.
Add Adds a new column to the list file block by block output.
Delete Removes a column from the list file block-by-block output. Click in a
field of the column you want to be removed and then click Delete.
NOTE: If you select EXECUTE > Postprocess, you will see a List File checkbox. By default, it
is normally not checked. You must check this box in order for IMSpost to create this additional
.LIS file. This file will reside in the same directory as the .NC files.
Program Header
The Program Header tab is used to define the format of the header to be placed at the start of the
output NC program in the listing file.
The blank text box enables you to enter text describing the header. Variable data fields are
represented by a string of ^ characters, which may also include a period (.) character for real
value variable fields. The text may be any number of lines, consisting of any number of fixed or
variable data fields.
1. Enter the text in the text box, such as shown in the example above.
2. Then, enter the length of the field. For example, if you enter 20 ^ characters after text, you
specify a variable length of 20 characters.
Be sure the length of these strings will be large enough to contain the variables, otherwise the
text within the variable could be truncated.
3. Click the Variables button and the following dialog is displayed, as shown below.
4. Specify the variables that are associated with the text. There should be a variable specified for
each string of ^ characters.
In the example below, note that two variables are required for the fourth line (DATE and
TIME).
5. Click OK to save your work.
Program Footer
The Program Footer tab is used to define the format of the footer to be placed at the end of the
NC program in the listing file.
The blank text box enables you to enter text describing the footer. Variable data fields are
represented by a string of ^ characters, which may also include a period (.) character for real
value variable fields. The text may be any number of lines, consisting of any number of fixed or
variable data fields.
1. Enter the text in the text box, such as shown in the example above.
2. Then, enter the length of the field. For example, if you enter 20 ^ characters after text, you
specify a variable length of 20 characters.
Be sure the length of these strings will be large enough to contain the variables, otherwise the
text within the variable could be truncated.
3. Click the Variables button and the following dialog is displayed:
The number of rows in on this table corresponds with the number of variable data fields you
entered. In the example above, there are three rows of variable data. You will specify a
variable for each string of ^ characters.
4. Click in a variable area and enter the value for that variable (such as [Link] in
the example above).
5. Enter values for each variable.
6. Click OK to save your work.
Page Header
The Page Header tab is used to define the format of the header to be placed at the start of each
page of the output NC program in the listing file.
The blank text box enables you to enter text describing the headerer. Variable data fields are
represented by a string of ^ characters, which may also include a period (.) character for real
value variable fields. The text may be any number of lines, consisting of any number of fixed or
variable data fields.
1. Enter the text in the text box, such as PARTNO: in the example above.
2. Then, enter the length of the field. For example, if your PARTNO will always contain a 4-
digit number, you would enter 4 ^ characters, as in the example above.
Be sure the length of these strings will be large enough to contain the variables, otherwise the
text within the variable could be truncated.
3. Click the Variables button and the following dialog is displayed, as shown below.
4. Enter the variable to be output.
NOTE: GLOBAL.PART_NAME is not an IMS library variable. You would have to define
this variable within your post.
If there is more than one variable entered, you can reposition their order by clicking the Up,
Down, and <<< keys. Or you can readjust the order by re-entering them in the display.
5. Click OK to save your work.
Page Footer
The Page Footer tab is used to define the format of the footer to be placed at the end of each page
of the output NC program in the listing file.
The blank text box enables you to enter text describing the footer. Variable data fields are
represented by a string of ^ characters, which may also include a period (.) character for real
value variable fields. The text may be any number of lines, consisting of any number of fixed or
variable data fields.
1. Enter the text in the text box, such as MACHINE: in the example above.
2. Then, enter the length of the field. For example, if you enter 15 ^ characters, as in the
example above, you specify a variable length of 15 characters.
Be sure the length of these strings will be large enough to contain the variables, otherwise the
text within the variable could be truncated.
3. Click the Variables button and the following dialog is displayed:
4. Enter the variable that contains the machine description (for example,
[Link]). This variable will also be displayed in the right column of the display
(Variable-1).
If there is more than one variable entered, you can reposition their order by clicking the Up,
Down, and <<< keys. Or you can readjust the order by re-entering them in the display.
5. Click OK to save your work.
Page Size
The Page Size option defines the number of rows and columns per page of the printed list file NC
program. These numbers should coincide with how you want pages processed through your
printer.
Field Description
# of lines per page Specifies the number of lines on a printed output page for the listing
file output.
# of characters per line Specifies the number of characters on a line on a printed output page
for the listing file output.
Table
The Table option (also available with ) creates an optional tool data table and displays
specified tool/cutter data. Use this option to define the format of any user-defined tables you
would like to generate as part of the postprocessing of an APT/CL file. A common use of this
function is to build tool list tables containing tool number, tool length, machine time, and so on.
However, these tables are completely definable in the postprocessor, and each postprocessor can
maintain any number of tables.
NOTE: Your IMS license must include the macro utility in order to support this feature.
Table Definition
The dialog for the Table Definition option is shown above. It includes the following:
Field/Button Description
Column Title Displays freeform text describing the header of this column of report
data. Place the cursor in the text area and enter text. Be descriptive as to
what will be output at the top of each page.
Attached Variable Specifies a variable name to be output in this column in the report file
for each block of data.
Field Format Describes the format (using #.#) of the field output for this column of
the report file.
New Table Creates a new table.
Delete Table Deleted the current table.
Add Column Adds a new column to the report file block by block output.
Delete Column Removes a column from the report file block-by-block output. Click in
a field of the column you want to be removed and then click Delete.
Text file Creates the report as a text file (.TXT).
Field/Button Description
HTML file Creates the report as an HTML file (.HTM).
XML file Creates the report as an XML file (.XML).
Program Header
The Program Header tab is used to define the format of the header to be placed at the start of the
output NC program in the report file. For example:
The blank text box enables you to enter text describing the header. Variable data fields are
represented by a string of ^ characters, which may also include a period (.) character for real
value variable fields. The text may be any number of lines, consisting of any number of fixed or
variable data fields.
1. Enter the text in the text box, such as shown in the example above.
2. Then, enter the length of the field. For example, if you enter 20 ^ characters after text, you
specify a variable length of 20 characters.
Be sure the length of these strings will be large enough to contain the variables, otherwise the
text within the variable could be truncated.
3. Click the Variables button and the following dialog is displayed, as shown below.
4. Specify the variables that are associated with the text. There should be a variable specified for
each string of ^ characters.
In the example below, note that two variables are required for the fourth line (DATE and
TIME).
5. Click OK to save your work.
Program Footer
The Program Footer tab is used to define the format of the footer to be placed at the end of the
NC program in the report file. For example:
The blank text box enables you to enter text describing the footer. Variable data fields are
represented by a string of ^ characters, which may also include a period (.) character for real
value variable fields. The text may be any number of lines, consisting of any number of fixed or
variable data fields.
1. Enter the text in the text box, such as shown in the example above.
2. Then, enter the length of the field. For example, if you enter 20 ^ characters after text, you
specify a variable length of 20 characters.
Be sure the length of these strings will be large enough to contain the variables, otherwise the
text within the variable could be truncated.
3. Click the Variables button and the following dialog is displayed:
The number of rows in on this table corresponds with the number of variable data fields you
entered. In the example above, there are three rows of variable data. You will specify a
variable for each string of ^ characters.
4. Click in a variable area and enter the value for that variable (such as [Link] in
the example above).
5. Enter values for each variable.
6. Click OK to save your work.
Page Footer
The Page Footer tab is used to define the format of the footer to be placed at the end of each page
of the output NC program in the report file. For example:
The blank text box enables you to enter text describing the footer. Variable data fields are
represented by a string of ^ characters, which may also include a period (.) character for real
value variable fields. The text may be any number of lines, consisting of any number of fixed or
variable data fields.
1. Enter the text in the text box, such as MACHINE: in the example above.
2. Then, enter the length of the field. For example, if you enter 15 ^ characters, as in the
example above, you specify a variable length of 15 characters.
Be sure the length of these strings will be large enough to contain the variables, otherwise the
text within the variable could be truncated.
3. Click the Variables button and the following dialog is displayed, as shown below.
4. Enter the variable that contains the machine description (for example,
[Link]). This variable will also be displayed in the right column of the display
(Variable-1).
If there is more than one variable entered, you can reposition their order by clicking the Up,
Down, and <<< keys. Or you can readjust the order by re-entering them in the display.
5. Click OK to save your work.
Page Header
The Page Header tab is used to define the format of the header to be placed at the start of each
page of the output NC program in the report file.
The blank text box enables you to enter text describing the header. Variable data fields are
represented by a string of ^ characters, which may also include a period (.) character for real
value variable fields. The text may be any number of lines, consisting of any number of fixed or
variable data fields.
1. Enter the text in the text box, such as PARTNO: in the example above.
2. Then, enter the length of the field. For example, if your PARTNO will always contain a 4-
digit number, you would enter 4 ^ characters, as in the example above.
Be sure the length of these strings will be large enough to contain the variables, otherwise the
text within the variable could be truncated.
3. Click the Variables button and the following dialog is displayed:
Notes
IMSpost library postprocessors normally include several “User” dialogs developed by IMS
engineers. The USER menu includes the options to create dialogs that will interact with your user
during postprocessor execution.
NOTE: You must have the IMSpost Macro programming option in order to control the activation
of these dialogs.
Options on the USER menu are:
Option Description
User Dialog Enables you to create custom dialogs.
Descriptive Comments EXAMPLE of a user dialog:
Activates tape comments. This is an IMS-developed dialog.
MULTI HOME EXAMPLE of a user dialog:
Enables you to active work coordinate systems. This is an IMS-
developed dialog.
Opstop EXAMPLE of a user dialog:
Activates output of M01 codes. This is an IMS-developed dialog.
User Dialog
The User Dialog option enables you to create custom dialogs. Once a dialog is created, it appears
on the USER menu (such as the example of Descriptive Comments, Opstop, and MULTI
HOME).
Field/Button Description
Select User Dialog Enables you to select an existing dialog to edit.
Field/Button Description
New Dialog Opens a blank dialog window. Enter a name in the pop-up window.
Delete Dialog Deletes the active dialog.
Add Entity Add an entity to the dialog. Then, you can specify:
Type Defines the entity type as one of the following:
Static Enters text to be read by user.
Checkbox Automatically creates a checkbox.
Edit Box Creates an area to accept a user response.
List Box Creates a list of items to select from.
Row Represents the horizontal starting position.
Col Represents the vertical starting position.
Size Defines the length of the field.
Macro Designates the macro name that contains the default
value (usually INIT/*) specified in the Value column.
Variable Defines the IMS macro variable to capture the result
of this field.
Var type Defines the IMS macro variable type as:
Double For any real value.
Integer For positive integers. The Checkbox type
is always an Integer.
String Accepts text strings. The Static type is
always a String.
Not Used Instructs the system that it is not necessary
to attach a type to the variable.
Value Defines the IMS macro variable value.
Label Specifies a label that depends on the entity Type:
Static Enter the static text.
Checkbox Usually left blank.
Edit Box Enter identifying text to be displayed to
the right of the checkbox.
List Box Enter the list box choices, separated by
commas.
Import Imports a dialog from another project (postprocessor) file.
Test Display the current dialog box. This is useful to check your design
while building a dialog. It also will show that you may need to
adjust the length of your fields.
Close Saves and exits the dialog.
IMSpost gives the postprocessor developer complete control as to when to display these dialogs.
At the beginning of postprocessing the part file (INIT_CFG macro).
In any existing macro.
Create a macro to display the user dialog.
By default, the IMS-supplied dialogs are not activated within the post. You must add a USER
macro command in order to activate them. For example:
USER(‘‘Descriptive Comments’’)
USER(‘‘Opstop’’)
NOTE: USER > MULTI HOME includes a checkbox to control the display of the dialog. If the
box is checked, a global variable is set to activate the dialog.
2. Click Add Entity to add an instruction to the dialog. Enter information for a Static entity as
shown:
4. Close the test results. Then, click Add Entity and enter information for an Edit Box entity as
shown below.
The information you enter will be saved in the variable name you specify within the Variable
column (GLOBAL.JOB_ID). As a default they should be declared in the INIT macro, but you
can use the browser and select another macro. Because this dialog is looking for an integer
response, the variable type is set to Integer.
TIP: Since these variables are going to be used in more than one macro, they must be defined
and declared as GLOBAL variables. Always declare your variables in the INIT macro.
6. Close the test results. Then, click Add Entity and enter information for a Checkbox entity as
shown:
A checkbox type entity is selected here because all that is need is a Yes (1) or No (0)
response. Notice in the Value column, a value of 1 is entered. This is the default to turn the
checkbox on. Variable types do not need to be selected for checkbox (the system assumes an
integer).
8. Close the test results. Then, click Add Entity and enter a Static entity with an instruction
prompt in the Label column:
10. Close the test results. Then, click Add Entity and enter a List Box entity. Enter all possible
selections using a comma (,) as a delimiter.
The order in which you enter selections in the Label column is the order in which they will be
displayed. Remember to specify the variable type and declare the variable
([Link]) that this selection will be stored in. As an option, you may enter any
available choice in the Value column as a default selection.
12. Close the test results. Then, click Close to save your work and exit the dialog.
Examples
The following are examples of user dialogs.
Descriptive Comments
This example of a user-defined dialog activates tape comments.
MULTI HOME
This example of a user-defined dialog enables the user to active work coordinate systems.
Opstop
This example of a user-defined dialog activates output of M01 codes.
Notes
The HELP menu provides options to displayed information about the IMSpost application or visit
the IMS Web site.
The HELP menu includes the following options:
Option Button Description
Help Topics Displays IMSpost help information.
Activate PP File
This option enables you to install specific postprocessor (PP) license codes, if applicable. It is
necessary only to install a custom PP file code if you received a project (postprocessor) file
developed by another user. An example of this is if you ordered a custom developed
postprocessor(s) from IMS or your dealer.
NOTE: If you have a license for any of the IMSpost development programs, your license will
allow you run any postprocessors you have created or modified without using this option.
Field/Button Description
Load PP files into Loads the selected postprocessor license file(s) into your current license.
my current license
Load PP files into a Loads the selected postprocessor license file(s) into a customer license.
customer license
Browse… Enables you to browse to and select the license file.
1. Get the postprocessor data file from IMS or your dealer. You should also receive a license
activation code for this specific postprocessor.
2. Select Help->Activate PP File.
3. Browse to or enter the name of the license file to be activated.
4. Click Finish and IMSpost will write the license code into the postprocessor project that is
currently active.
Diagnostics
The Diagnostics dialog enables you to troubleshoot your IMS software installation. Symptoms of
installation and license problems include, Demonstration version messages, postprocessing only
part of an APT/CL file, or license warning messages.
NOTE: The diagnostic troubleshoots installation and licensing problems only. It is not meant as a
tool for debugging the output of a particular postprocessor.
Field/Button Description
Environment Variables Confirms the set up of the IMS environment. The software will not
run correctly without the correct license file
(IMSDIR_LICENSE_FILE).
Hardware Info Confirm that the IMS software is correctly accessing either an
Ethernet address or an IMS supplied hardware key (dongle). This
area also indicates if a dealer license applies.
If an Ethernet address is shown, supply this as part of your license
request. If you are an existing IMS user and have an IMS-supplied
hardware key, send this key ID as part of your license request.
Field/Button Description
Output diagnostic report Enables you to select a name for a diagnostic report, which you
may want to create if the information above appears to be correct.
NOTE: If there appears to be a problem with your software or
license setup, an IMS support engineer or dealer representative
probably will request a copy of this file to analyze the problem.
Display diagnostic Displays the report file in your default editor. If this option is not
report file checked, the file is created file without displaying it.
Build Report Generates the diagnostic report.
1. Environment Variables :
IMSDIR_LICENSE_FILE = Z:\license_dell830_nodelocked.dat
IMSDIR_IMSVERIFY_DEBUG is not set
IMSDIR_CE_SYNC is not set
IMSDIR_MIK_AXS = 1
IMSDIR_MIK_CATMCH = g:\[Link]
IMSDIR_MIK_DEBUG = G:\mik_debug.txt
Company : Dan
Project Code : IMS
IMS dealer : TRUE
Linear : 99
Rotary : 99
4. Postprocessor ID Codes
File :
Creator :
User code :
PP ID code :
Post Version : 8.000000
Project Version : 50.000000
User Version : 1.000000
================================================================================
IMSflex license FEATURE report
================================================================================
================================================================================
IMSflex license file : Z:\license_dell830_nodelocked.dat
================================================================================
#######################################################################
##
## Intelligent Manufacturing Software, Inc.
##
#######################################################################
##
## Product license file for : Dan
##
## Creation date : Apr 12, 2011 (08:56)
##
##
## Company code : IMS
## Number of PP (3x): 0
## Number of PP (5x): 0
## Number of CE: 0
## Load option : 1 (Library enabled)
## Dealer option : 1
##
##
#####################################################################
# Features using nodelocked license
#####################################################################
FEATURE Revpost IMS 8.0 31-dec-2011 uncounted \
VENDOR_STRING=IMS-00100007FFFFF00-001e8c56298e \
HOSTID=001e8c56298e user_info=Dan ck=200 SIGN=5BD98628DDA8
FEATURE IMSpexec IMS 8.0 31-dec-2011 uncounted \
VENDOR_STRING=IMS-00100007FFFFF00-001e8c56298e \
HOSTID=001e8c56298e user_info=Dan ck=196 SIGN=610F01B4AD60
FEATURE IMSpostPro IMS 8.0 31-dec-2011 uncounted \
VENDOR_STRING=IMS-00100007FFFFF00-001e8c56298e \
HOSTID=001e8c56298e user_info=Dan ck=222 SIGN=F8393C601D9C
FEATURE RevEditor IMS 8.0 31-dec-2011 uncounted \
VENDOR_STRING=IMS-00100007FFFFF00-001e8c56298e \
HOSTID=001e8c56298e user_info=Dan ck=246 SIGN=B9DC8B147EA2
FEATURE IMSmachine IMS 4.0 31-dec-2011 uncounted \
VENDOR_STRING=IMS-00100007FFFFF00-001e8c56298e \
HOSTID=001e8c56298e user_info=Dan ck=152 SIGN=AF974ADA895C
FEATURE IMSverify5x IMS 4.0 31-dec-2011 uncounted \
VENDOR_STRING=IMS-00100007FFFFF00-001e8c56298e \
HOSTID=001e8c56298e user_info=Dan ck=196 SIGN=0AF9FA803BAC
Notes
Macros constitute the link between CLdata (cutter location data) input and the postprocessor’s
formatted output. You use macro programming to determine the internal logic of your project
during commonly modified postprocessing sequences to satisfy your hardware requirements and
your own machining preferences.
An IMS macro is a collection of statements that instructs the IMS knowledge base as to how to
respond to the given input. Each macro begins with the macro name (definition statement) and
ends with a RETURN statement. Any number of valid macro statements or expressions can
appear between the macro definition and the RETURN statement. The following example
illustrates a simple IMS macro:
TEST/*
[Link] = 2.5
[Link] = [Link]
OUTPUT(REGISTER.X, NEWLIN)
RETURN
The example has the required macro name TEST. The second statement is an example of the use
of an arithmetic expressions (setting the variable [Link] to the value 2.5). The fourth
statement is an example of the macro OUTPUT statement. The macro ends with the required
RETURN statement.
Category Description
LOCAL You can create and maintain local variables. However, you can use them only
within the macro in which you define them. You do not have to use special
reserved words to define a local variable; you just use the variable name (for
example, TEST1). After the system executes a macro, all local variables within
the macro are no longer defined. To use them again, you must redefine them in
another macro or macros.
CLDATA These variables are a type of system variable. The system sets their values for
one macro at a time, based on the input arguments or CLdata information
passed into the macro (from a CLD file). Two reserved words provide access
to this type of variable: CLDATAN and CLDATAM for Numbers and Minor
words, respectfully.
CLREAD These variables are a type of system variable. The system sets their values for
one macro at a time, based on the input arguments or CLdata information
accessed from a macro found in a CLREAD, read-ahead statement. Two
reserved words provide access to this type of variable: CLREADN and
CLDATAM for Numbers and Minor words, respectfully.
REGISTER These variables are related to the letter addresses that exist in the Register
Format Table. For example:
[Link] = "N" Set Z register as non-modal.
[Link] = 2000 Set F maximum = 2000
COMPONENT These are component-type variables. They are represented within the Machine
Components feature.
FUNCTION These variables are associated with the Function Codes feature. These
functions (G/M codes) represent responses to the various dialogs. These
function codes are usually associated with MODE variables.
[Link] = "G1" Reinstate G1 code name.
[Link] = "X,Y,Z,C" Registers to be output with G0 code.
[Link] = "M13" Change M3 code to M13.
MACHINE These variables are associated with the Machine feature. They enable you to
modify any of the machine axis parameters:
[Link] = 300 Update Z home position.
MACHINE.X = 1275 Update Machine X position.
SOLUTION These are variables associated with their respective SOLUTION routine.
Consult the individual SOLUTION macro statement for variable examples.
ARRAY These variables enable you to create subscripted variables. That is, the variable
declaration is modified by another variable:
INDX = INDX + 1
GLOBAL.FEED_TABLE = [Link][INDX]
All the above variables (except LOCAL) are treated as Global variables. That is, they may be
accessed throughout the Macro Manager.
Assignment Statements
Assignment statements are the most common statement used in macros. They have the format:
variable = expression
where the expression can be simple or complicated, as long as it produces a valid result.
IMS macros use two types of variables:
Local, used only within the residing macro
Global, available to any macro throughout the posts macro library. Global variables must
begin with the word GLOBAL.
You can subscript either type of variable.
All IMS variables (MODE, FUNCTION, REGISTER, MACHINE, etc.) are treated as global
variables. Examples are:
X = CLDATAN.1+ [Link] + [Link]
[Link] = "MIST"
PTR1 = LOCATE("G98")
A = A + 1
RPM = [Link][A]
TOOL = CLDATAN.1 + [Link]
[Link] = [Link]
DELTA = SQRT ( (X*X) + (Y*Y) )
[Link][N] = CLDATAN.1
TIP: Do not use periods (.), commas (,), single quotation marks, or double quotation marks in
local variable names. IMSpost uses these characters as mathematical operations, as delimiters,
and to distinguish variable names and text strings within the output generator. In general, it is not
a good idea to use any special characters in your variable definition, with the exception of the
underscore ( _ ):
OK: GLOBAL.FIRST_SPIN = 1
Not OK: [Link],SPIN = 1
In a macro language assignment statement, you can set or change a variable only for use in the
current macro. When execution of the current macro is completed, the value will then return to its
value before the one-shot assignment was executed. This “one-shot” change is achieved by
placing an exclamation mark (!) before the variable in the assignment statement. For example:
TEST/*
GLOBAL.A = 3.0 Set variable GLOBAL.A
!GLOBAL.A = 999.999 Set GLOBAL.A using “one-shot”
VALUE_1 = GLOBAL.A * (-1.0) Value of VALUE_1 is –999.999;
GLOBAL.A, while in the macro is 999.999
RETURN After the macro is completed, the value of
GLOBAL.A is 3.0
NOTE: Since these functions are reserved within IMSpost as special math functions, they should
not be used as local variable names.
OK: [Link] = CLDATAN.2
Not OK: MAX = CLDATAN.2
FINAL Macro
The FINAL/* macro is a special IMSpost macro. Its function is to reprocess the output of the
postprocessor before it is written to the output file. This “second pass” processing lets you add,
remove, or reposition blocks of data generated by the normal postprocessing phase (first pass).
There are IMSpost macro language statements that are specialized for use in a FINAL macro:
ADD
BOUND
COPY
DELETE
LOCATE
MOVE
UPDATE
The FINAL macro performs output for tool preselection. The listing of tools used is updated
during “pass one” processing. “Second pass” or FINAL loops to search for each M6. The NEXT
tool number from the list is then added to the block following the M6, preselecting the next tool.
NOTE: This macro illustrates the use of address pointers. With the addition of macro statements
such as CLREAD, these pointer-type commands are not used within the IMSpost environment.
However, they are very useful in the IMS Controller Emulator environment.
FINAL/*
[Link][[Link]] = [Link][1]
[Link] = 2
PTS = LOCATE(START)
PTE = LOCATE(END)
BOUND(PTS,PTE,FORWARD)
PTC = LOCATE(REGISTER.M6)
WHILE (PTC)
PTC = PTC + 1
[Link] = [Link][[Link]]
ADD(PTC, REGISTER.T)
[Link] = [Link] + 1
BOUND(PTC,PTE,FORWARD)
PTC = LOCATE(REGISTER.M6)
ENDWHILE
RETURN
ADD
Use the ADD macro command in a FINAL macro to add a string or register to an output block
marked with a pointer type variable. The syntax is:
ADD(PTR, "string")
ADD(PTR, REGISTER.?)
The current string or register (with the ? substituted by the actual register name) is added to the
block pointed to by PTR.
BOUND
Use the BOUND macro statement to set parameters used by the LOCATE statement. The syntax is:
BOUND(ptr1, ptr2, direction)
where ptr1 and ptr2 mark the beginning and end, respectively, of the search boundary for the
LOCATE command, and direction may be either of the keywords FORWARD or BACKWARD
to indicate the direction of search from the current location.
The direction argument is optional. If you omit it, the program assumes the value as FORWARD.
COPY
Use the COPY macro command in a FINAL macro to copy a block or a series or blocks. The
syntax used determines what action the COPY command will take. This command with two
arguments, copies the block pointed to by PTR1 after the block pointed to by PTR2:
COPY(PTR1, PTR2)
This command with three arguments copies the series of blocks from PTR1 to PTR2 after the
block pointed to by PTR3:
COPY(PTR1, PTR2, PTR3)
DELETE
Use the DELETE macro command in a FINAL macro to remove a string or register from an
output block or to remove a complete block or series of blocks. The action taken depends on the
syntax used.
To remove a string or register from an output block marked with a pointer type variable, enter:
DELETE(PTR, "string")
DELETE(PTR, REGISTER.?)
The current string or register (with the ? substituted by the actual register name) is removed from
the block pointed to by PTR.
To remove one entire block of code, enter:
DELETE(PTR1)
The entire block pointed to by PTR1 is removed from the output.
To remove a group of blocks, enter:
DELETE(PTR1, PTR2)
The series of blocks from PTR1 to PTR2 is removed from the output.
LOCATE
Use the LOCATE macro command to find blocks of data that contain a specified string or
register. When you find (or locate) such a block, a pointer variable is returned to mark that block
location. The syntax is:
PTR = LOCATE("string")
Or:
PTR = LOCATE(REGISTER."name")
If a block containing the string or register specified is not found, the return value is 0. If a block
containing the string of register specified is found, a pointer to the block is returned and all
internal data values are updated to the values at that block.
The LOCATE command searches blocks from the current position set in the BOUND statement.
The direction of search is also specified in the BOUND statement.
You can use the special arguments START and END to obtain a pointer marking the start or the
end of the file:
PTRS = LOCATE(START)
PTRE = LOCATE (END)
MOVE
Use the MOVE macro command in a FINAL macro to change the location of a block or series or
blocks. The syntax used determines what action the MOVE command will take.
This command with two arguments copies the block pointed to by PTR1 after the block pointed
to by PTR2. The original block PTR1 will then be deleted.
MOVE(PTR1, PTR2)
This command with three arguments copies the series of blocks from PTR1 to PTR2 after the
block pointed to by PTR3. The original series of blocks from PTR1 to PTR2 is then deleted.
MOVE(PTR1, PTR2, PTR3)
UPDATE
Use the UPDATE macro command in a FINAL macro to update all postprocessor data values up
to the block specified by the pointer argument. When moving around the list of output blocks
during FINAL macro processing, you may need to reset the data values to the values at a current
block. The syntax is:
UPDATE(PTR)
where PTR is a pointer variable pointing to the block to update to.
Macro Statements
The IMS macro facility supports the IMS knowledge-based system and includes macro
statements to support the NC production process. Supported statements include:
ADD
ASSIGN
BOUND
BREAK
CALL
CASE
CLREAD
COPY
CUT
DELETE
DISPLAY
FILE
GETAPT
GETAT
GETISO
HOOK
IF
LOCATE
MOVE
OPTIMIZE
OUTPUT
PRINT
PRIORITY
PUSH and POP
REPORT
RETURN
RUN
SEQNO
SETAT
SOLUTION
SORT
SPLIT
SPRINT
STREXT
STRLEN
STRSTR
TABLE
TOKEN
TOOL_ALONG
UPDATE
UCASE and LCASE
USER
WHILE
ASSIGN Statements
The ASSIGN statement enables you to assign an expression to a variable. The syntax is:
ASSIGN("variable",expression)
For example:
ORIGIN/100+50*2, (300+50)/2, 100/2
ASSIGN("A",CLDATA.1) A = 200
ASSIGN("B",CLDATA.2) B = 175
ASSIGN("C",CLDATA.3) C = 50
BREAK Statements
Use the BREAK statement to exit a macro before reaching the RETURN statement. For example:
TEST/*
IF(GLOBAL.FLAG_10)
BREAK
ENDIF
OUTPUT("FLAG_10 IS NOT SET",NEWLIN)
CALL Statements
You can execute one macro from within the body of another macro by using the CALL statement.
The CALL statement passes control to the first line of the specified macro. When the system
encounters a RETURN statement in the called macro, control returns to the calling macro at the
line immediately following the CALL statement. Examples are:
CALL(RAPID/)
CALL(GOTO/[Link], [Link], [Link])
CALL (PPRINT/"*** TOOL CHANGE OPERATION ***")
CALL (SPINDL/OFF)
CALL (RAPID/)
CALL (GOTO/10,0,[Link])
To specify the macro being called, use the list of formal parameters, NAME/*. There are four
formal parameter types that can be passed to the calling of other existing macros, as shown in the
example below.
All variables passed by a CALL statement are passed "by value." This means that changing the
variable passed into the called macro does not affect the original variable value in the calling
macro. In this example, the macro being called is TEST:
TEST/*
B = CLDATAN.1
A=7
-
-
RETURN
In this example, the calling macro is TEST_1:
TEST_1/*
A=5
CALL(TEST/A)
Note that here, after return from the call, A is still equal to 5, no matter what has been done in
the TEST macro.
RETURN
CASE Statements
Use the CASE statement to select statements to execute from among several alternatives. The
CASE statement syntax is:
CASE (expression, ..., expression, ..., expression)
value_1: statements
value_2: statements
...
value_n: statements
ENDCASE
The system evaluates each expression to obtain a result. The system then searches the results for a
value equal to a value in the list below. If the system finds an expression result equal to the first
listed value, then it executes the series of statements associated with that value. The system then
continues to search for a result equivalent to the next listed value. Unlike most standard CASE
statements in higher-level languages, the IMS CASE statement supports the search for the results
of multiple expressions.
CASE (CLDATAM)
"ON":[Link] = [Link]
"OFF":[Link] = "OFF"
"MIST":[Link] = "MIST"
[Link] = "MIST"
"FLOOD":[Link] = "FLOOD"
[Link] = "FLOOD"
ENDCASE
NOTE: The values in this example are written with double quotation marks because they are
character strings. Double quotation marks are not required for numbers or variable names.
CLREAD Statements
Use the CLREAD macro statement to look ahead in the APT-CL file and save information from
the minor words and/or CLdata values. This feature has many practical uses, including getting the
next tool number for tool pre-selection or reading ahead for subprogram processing. Another
feature of the CLREAD statement is that you can read ahead and then continue processing the
APT-CL file from the read-ahead point, so you can skip over sections of the APT-CL file if
desired.
The statement takes four arguments, and returns a value, as described below. The syntax is:
value = CLREAD("statement", occurrence #, stay/return, how many)
value Return value indicating the number of lines read, from the current line, until
search was successful. Value of 0 indicates statement was not found.
"statement" The formal parameters of the statement to read ahead for.
occurrence The number of times to locate this statement before returning success. To
find the next occurrence of the statement, occurrence is 1. To find the second
occurrence of the statement, occurrence is 2, and so on.
stay/return Set to 0, if you want to continue processing from the point after the statement
is found (in other words, jump). Set to 1 to return to normal processing order
after the statement is found. Set to 2 to continue looking for subsequent
statement(s) after the statement is found.
how many The number of APT-CL lines to search (if <=0, then search entire file).
Use the system variable [Link] to specify whether the statement that was looked ahead for
was found. If [Link] is 0, the search was successful. If [Link] is non-zero, the search
for the statement was not successful.
If the read ahead was successful, the formal parameters from the statement are stored in variables
of type CLREADN and CLREADM. These variables exactly correspond to the variables of type
CLDATAN and CLDATAM used when processing an APT command, and all formats of the
variable are analogous to CLDATAN and CLDATAM.
Example 1
This example show how to read ahead (in the LOADTL/* macro) for the following SPINDL
statement:
* ensure spindle is off
MODE("SPINDLE","OFF)
* read ahead 20 lines for SPINDL statement
RPM = CLREAD("SPINDL/*",1,1,20)
IF(RPM)
* activate read-ahead SPINDL statement
CALL(SYSTEM/APT_RLINE)
ELSE
* if not found, activate previous SPINDL
CALL(SPINDL/ON)
ENDIF
Example 2
For this example, the following macro lines will read ahead and get all the tool numbers in the
APT-CL file:
IVAL = 1
A = CLREAD("LOADTL/*",1,2,0)
WHILE (A > 0)
OUTPUT("TOOL # ", IVAL, " = ", CLREADN.1, NEWLIN)
IVAL = IVAL + 1
A = CLREAD("LOADTL/*",1,2,0)
ENDWHILE
CUT Statements
If there is more than one PART and/or TOOL component defined for your machine, you may
need to use the CUT statement. IMSpost uses the CUT statement to determine what is being cut,
and how it is being cut. This statement is useful for advanced machines with multiple,
simultaneous tools, or more than one part setup at a time. The syntax is:
CUT( [PART component], [TOOL component].TIP)
For example, CUT ( PART2, [Link] ) means that the part named PART2 is machined by
the tool components tool tip named VTOOL.
For multi-axis machines, the TOOL component has four origin configurations associated with it.
These are dependent upon what was selected with the Multi-axis Setup feature.
CUT(PART,[Link]) Cut PART component with tools (rotary head) defined pivot
point.
CUT(PART,[Link]) Cut PART component with spindle face.
CUT(PART,[Link]) Cut PART component with tools center point.
CUT(PART,[Link]) Cut PART component with tools tip.
FILE Statements
The FILE macro statement is used to perform reading and writing to an external file. The syntax
is:
FILE(action, filename [, instring])
action READ, WRITE, CLOSE, APPEND (add a data string to the end of a specified
file), OPEN (open a specified file), COPY (copy the file name into another
name), DELETE (delete a specified filename), or TABLE.
The action TABLE outputs data to a predefined table within IMSpost (see the
Report feature). An example could be an external text file that contains all
pertinent tool data:
FILE(TABLE,"[Link]",TOOL TABLE
This statement would take the data that was predefined through the Report
feature and add it to a file named [Link].
filename Name of the file.
instring Name of the input string. Do not use this with CLOSE. Use the table name
with the TABLE action.
For reading (READ action) or writing (WRITE action) from or to a file, be sure to use the full
pathname for the requested file. It is not necessary to explicitly open a file before reading or
writing, as is necessary with some other programming languages. However, it is necessary to
close (CLOSE action) the file.
Use the variable [Link] to test for end-of-file. After executing a FILE command with the
READ or WRITE action, the SYSTEM variable [Link] will be set to 0 if the command
executed successfully. The [Link] variable will be set to 1 if an error, or end-of-file
condition occurs. For example, to extract data from a temp file and add it to another:
[Link] = 0
* check to see if file still contains data
WHILE([Link] = 0)
FILE(READ,[Link],GET_CODE)
IF([Link] = 0)
FILE(APPEND,GLOBAL.FILE_A,GET_CODE)
ENDIF
ENDWHILE
[Link] = GLOBAL.FILE_A
* close and delete temp file
FILE(CLOSE,GLOBAL.FILE_A)
FILE(DELETE,GLOBAL.FILE_A)
It is not necessary to OPEN a file before you read or write to it. However, it is necessary to
CLOSE the file before you DELETE it.
GETAPT Statements
This statement returns the current APT/CL statements. For example:
[Link] = GETAPT Returns current APT/CL record and saves it in variable
[Link]
NOTE: This is the same as the system variable SYSTEM.APT_LINE
GETAT Statements
GETAT is used to extract a character from the specified position:
A = GETAT("TOOL=5",4)
The first argument is the string to be used, and the 2nd argument is the character position to
extract. In this case, A = L
GETISO statements
This command enables you to retrieve previous output data from the buffer.
SYSTEM.SAVE_ISO_LINES = #
where # represents how many blocks of output to retrieve. The following logic could be contained
within an existing macro:
* retrieve and output the last 10 lines of ISO code
I = 1
WHILE( I <= SYSTEM.SAVE_ISO_LINES )
A[I] = GETISO(I)
OUTPUT(A[I],NEWLIN)
I = I + 1
ENDWHILE
HOOK Statements
Hooking is an advanced programming feature that is implemented in the IMSpost macro
language using the HOOK command. Hooking defines execution of some command (a macro)
when a certain set of conditions is true at a certain time.
There is a lot going on with a HOOK statement. Do not expect to step through it within the macro
debugger. The best way to see if your HOOK is being activated is to set a breakpoint at the macro
it is calling. The syntax is:
HOOK (NAME=name1, MACRO=name2, EXPRESSION = expr, PLACE = place, FLAG)
Each HOOK statement has its own unique name. This gives you the option of turning the HOOK
ON or OFF throughout your program. The macro activated by the HOOK statement must be
predefined.
The FLAG expression is optional. This enables you to define specific instances when you want
the HOOK macro called. This expression must be surrounded in double quotes. For example:
HOOK(NAME=CLAMPS,MACRO="CLAMP/*",EXPRESSION="[Link]",
PLACE=AGOTO,ON"
Example
TEST/*
HOOK (NAME=MYHOOK, MACRO="AUXFUN/120", EXPRESSION="GLOBAL.A=5",
PLACE=BEFORE, ON)
RETURN
INIT/*
GLOBAL.A = 5
RETURN
IF Statements
The first form of the IF statement uses the syntax:
IF (condition)
statement
...
...
...
statement
ENDIF
where “condition” is any expression that results in a Boolean value (true or false) and “statement”
is any valid IMS macro statement.
To execute the IF statement, the system first evaluates the condition. If the condition is not equal
to zero, the system executes the following statements until it encounters ENDIF. If the condition
equals zero, the system does not execute the statements and it passes control to the next statement
after ENDIF. For example:
IF ([Link] > 1)
[Link] = 500.0
OUTPUT([Link], NEWLIN)
ENDIF
Another form of the IF statement uses the syntax:
IF (condition)
statement
...
statement
ELSE
statement
...
statement
ENDIF
In this case, if the condition is not equal to zero, the system executes each statement until it
encounters ELSE. If the condition equals zero, the system executes all statements after the ELSE
until it encounters ENDIF. In each case, the system passes control to the statement following
ENDIF after it has executed either series of statements. For example:
IF (CLDATAN.1 = 180)
DIRECTION = "CCLW"
ELSE
DIRECTION = "CLW"
ENDIF
You can nest IF statements. Be sure to associate the IF/ELSE/ENDIF statements correctly when
you construct nested IF statements.
You can also combine IF statements by using the words AND and OR:
IF(([Link] = 'OFF') OR ([Link] = 'OFF'))
IF (([Link]) AND ([Link]) AND ([Link] <>
'INITIAL'))
TIP: Use the Auto Indent feature within the IMS macro editor.
OPTIMIZE Statements
The OPTIMIZE statements are automatically created within IMSpost. These statements control
the LINE-FIT, ARC-FIT, and NURBS algorithm features. Depending upon what was selected
through the respective dialogs, these OPTIMIZE commands will be created and reside in the
INIT macro.
Each OPTIMIZE statement will remain in effect until modified or cancelled.
These parameters are activated with the Motion feature. Please refer to the Arc Fit, Line Fit, and
Nurbs tabs.
For example, to activate the Line Fit routine:
OPTIMIZE(LINE,1)
To cancel the Line Fit routine:
OPTIMIZE(LINE,0)
To activate Arc Fit routine in the XY plane only:
OPTIMIZE(CIRCLE,1,ACTIVE,1,TANGENT,0,SCREW,0,XYPLAN,1,YZPLAN,0,
ZXPLAN,0,ALLPLAN,0)
OUTPUT Statements
The OUTPUT statement is the link between the IMS knowledge base and the output data files.
The system writes data generated by the OUTPUT statement to a file whose name is stored in the
system variable [Link].
The OUTPUT statement accepts arguments in one of four forms. Each has a specific meaning and
should be used for a specific purpose. A description of each form follows:
A string in double quotes causes the system to write the string to the file without
interpretation. Without interpretation means that the system writes the data as is and does
not check for machine code data that can update the knowledge base. Use this type of
output for PPRINT or INSERT macros or to output logical functions to the tape.
A string in single quotes causes the system to check the string for controller register data
and values and to update the knowledge base to reflect the new data. The system may not
use this data as is. The setting of the sort command or the addition of sequence numbers
can affect the data.
If the parser does not recognize any part of the string as a controller register or value, the system
processes the string without interpretation as if it were in double quotation marks.
You can use variables in the OUTPUT statement to provide the macros with a greater
level of flexibility. To avoid unpredictable results, use only variables that you have
previously defined. You can use global variables, user-defined variables, and system
variables, including MODE, FUNCTION, COMPONENT, MACHINE, CLREAD,
CLDATA, REGISTER, SYSTEM, and SOLUTION.
You must specify a NEWLIN argument to terminate an OUTPUT statement and send it
to the knowledge base for processing. NEWLIN ends the current line of output and sends
all remaining data to the knowledge base for processing.
FOR ADVANCED USERS: You can use the keywords WRITE and READ in an OUTPUT
statement to process information in a macro and save it in a buffer for later use.
WRITE at the end of an OUTPUT command terminates the string and stores the
information in the output buffer.
READ tells the knowledge base to write the data stored in the buffer to the knowledge
base for OUTPUT processing.
For an example of the usage of WRITE and READ, the standard MILL postprocessor
makes extensive use of this functionality in macros in which output is “saved until the
next motion block” (COOLNT, SPINDL, LOADTL, and so on). The buffer is then output
in the GOTO macro (OUTPUT(READ)).
NOTE: You can program any combination of these four argument forms in any number of
OUTPUT statements. When outputting any combination of machine code, variables, or text, each
item must be separated by a comma delimiter.
Examples of the OUTPUT statement are:
OUTPUT("(***THIS IS AN OPERATOR MESSAGE ***)", NEWLIN)
OUTPUT('G01 X5.0 Y5.0', NEWLIN)
OUTPUT([Link], GLOBAL.X * 2.0, 'M06', NEWLIN)
OUTPUT('Y', [Link])
The IMS macros distributed with this product contain additional examples of the OUTPUT
statement.
Using a MODE variable in the OUTPUT statement is the same as using a function. It also
generates the USE connected to the related function. The benefit of using MODE is that the
macro is not CONTROLLER dependent because it is not using the direct function name but a
virtual name defined by the user. After mode output, MODE will always have the current output
as the current mode.
Example Part 1
Assume the last output is G1 X1. Assume the following variable values:
[Link] = 2.4.
[Link] = "Y"
[Link] = "Y"
[Link] = "X"
[Link] = "G1"
[Link]= "LINEAR"
OUTPUT([Link],NEWLIN) X2.4
OUTPUT([Link],NEWLIN) G1 X2.4
OUTPUT([Link],NEWLIN) X2.4
Example Part 2
Assume last output is G0 X1. Assume the following variable values:
[Link] = 1.0
[Link] = "N"
[Link] = "N"
[Link] = "X"
[Link] = "G0"
[Link]= "POSITION"
OUTPUT([Link],NEWLIN) G1 X1.0
OUTPUT([Link],NEWLIN) G0 X1.0
OUTPUT([Link],NEWLIN) X1.0
SEQNO(OFF)
OUTPUT('O', PRNUM, NEWLIN)
SEQNO(ON)
...
RETURN
TIP: You can also add a default response by adding it to the DISPLY line. In the following
example, the system assumes 1000 if the user does not respond:
DISPLY(PRNUM,1000)
The next example uses the system variable SYSTEM.DISPLAY_RETURN to adjust the user
response time. If there is no response after 10 seconds, the system continues.
SYSTEM.DISPLAY_RETURN = 10
If you need your programmer to input various sections of data, see USER > User Dialog.
PRIORITY Statements
Use the PRIORITY macro command, which is a machine-controlling command, for machines
with parallel linear axes. The syntax is:
PRIORITY(axis1, axis2, …, axisn)
For axis motion in which it is possible to obtain a postprocessor solution using more than one axis
(for example, U and X or Z and W), the postprocessor chooses the axes in order of priority
specified in this statement.
You can also set this priority within the Machine Motion feature.
REPORT Statements
REPORT statements enable you to write out to external error (.log) files. You can create and add
postprocessor errors to the [Link] file. For additional data, see FILE > Error Definition.
RETURN Statements
The RETURN statement is a required part of every macro, although it has no effect on output or
execution. For the IMS knowledge base to recognize the end of a macro, use a RETURN
statement as the final statement, including comments, in a macro. Refer to the IMS macros
provided with the product for examples of the RETURN statement.
RETURN statements can also return a value to the macro that called it. The following example
returns 7 to the calling macro:
RETURN 7
ROUND Statements
The ROUND statement enables you to round-off and truncate a value. The syntax is:
A = ROUND (54.6678,3)
The first argument (54.6678) is the value to be rounded. The first argument may also be any valid
variable.
The second argument (3) specifies how many places to round the value to. If this argument is
zero, the value will be rounded off to an integer.
In the following example, A = 54.669:
A = ROUND (54.6678,3)
The first argument could also represented as a defined variable. In this example, B = 54.3 and
C = 124:
[Link] = 54.332
B = ROUND ([Link],1)
C = ROUND(123.5,0)
RUN Statements
Use the RUN macro command to execute other programs from an IMS macro. The RUN
command issues an operating system call to begin execution of the program specified. The IMS
macro continues processing after the RUN command is executed—it does not wait until
completion of the external program. The syntax is:
RUN("program")
where program is the name of the external program to run. For example, from the Windows
version of IMSpost, you would use the following command to open Notepad:
RUN("notepad")
To open an external file with Notepad:
GLOBAL.PART_PATH = "notepad " + "c:\MILL\MAZAK\[Link]"
RUN ( GLOBAL.PART_PATH )
SEQNO Statements
Use the SEQNO statement to override the default conditions for sequence number output. In this
example, the SEQNO statement sets the sequence number to five and increases the number by
five:
INIT_CFG/*
SEQNO(START=5,INCR=5,ON,"N")
SORT(N,G,X,Y,Z,R,I,J,K,F,S,T,M)
OUTPUT('G90 G70 G80 G00', NEWLIN
RETURN
TIP: For macro users, you can control the sequence with:
SEQNO(ON) Same as CALL(SEQNO/ON).
SEQNO(OFF) Same as CALL(SEQNO/OFF).
SEQNO("O") Changes the sequence letter address to O (such as O1535 G0 Z1200).
The letter O must exist in the Register Table.
SETAT Statements
This statement enables you to substitute a character in a string with another. For example;
MY_STRING = "ABCDEFG"
SETAT (MY_STRING,3,"L")
The first argument is the text string. The second argument (3) is the placement of the character to
be replaced. The third argument ("L") contains the replacement character. So, the results of
MY_STRING will be "ABLDEFG".
With the SETAT statement, it is also possible to substitute text with an ASCII character. For
example:
MY_STRING = "ABC"
SETAT(MY_STRING,3,12)
MY_STRING = "AB + ascii representation of integer 12 (page break)
SOLUTION Statements
The SOLUTION statement gives you a simple mechanism for converting part coordinates to the
machine coordinates in point vector format. The SOLUTION statement also strips these
coordinates of machine offsets and tool offsets, providing you with the original GOTO or
CIRCLE data.
The SOLUTION statement syntax takes several different formats:
Format 1 (Basic GOTO motion)
Format 2 (GOTO motion with linearization)
Format 3 (Circle records)
Format 4 (Converts circles to lines)
Format 5 (Calculates perpendicular vector to line or arc)
X,Y,Z Usually the given part coordinate, given in the APT GOTO statement.
I,J,K Usually the vector of the tool, relative to the part, given in multiaxis
(>3) moves.
"MOVE" (optional) Moves the machine to the required coordinate.
"REGISTER" (optional) Updates the related registers with the new values.
"NOREPORT" (optional) Instructs IMSpost to not report any warnings or errors as a
result of this SOLUTION.
"NOHOOK" (optional) Cancels any pending HOOK logic for this SOLUTION. This
is a one-shot statement. After this SOLUTION is generated, IMSpost
For each axis defined in the machine definition for the postprocessor (where “name” is the axis
name), the following applies:
SOLUTION.name_CURRENT Current position of this axis before moved by this solution.
SOLUTION.name_VALUE New suggested value to move to.
SOLUTION.name_INCREMENT Incremental move (from last position).
SOLUTION.name_CHANGE Need to move Yes/No (different from last position).
For example, if you have a machine with two linear axes X,Y, then:
SOLUTION.X_CURRENT Current position of this axis before moved by this solution.
SOLUTION.X_VALUE New suggested value to move to.
SOLUTION.X_INCREMENT Increment move.
SOLUTION.X_CHANGE Need to move: Yes/No.
SOLUTION.Y_CURRENT Current position of this axis before moved by this solution.
SOLUTION.Y_VALUE New suggested value to move to.
SOLUTION.Y_INCREMENT Increment move.
SOLUTION.Y_CHANGE Need to move: Yes/No.
SOLUTION.LINEAR_AXIS Number of linear axes that move for this solution.
SOLUTION.ROTARY_AXIS Number of rotary axes that move for this solution.
SOLUTION.LINTOL_LINEAR Maximum distance from the straight line within this
solution.
SOLUTION.LINTOL_ROTARY Maximum angle distance from the plane within this
solution.
SOLUTION.LINEAR_MOVE Length of the linear move.
SOLUTION.ROTARY_MOVE Length of rotary move in system units (INCH/MM).
SOLUTION.TOTAL_MOVE Length of total move.
Returning a solution for GOTO or CIRCLE involves complicated math calculations. You do not
need to have any math knowledge to use these powerful statements. In some instances, however,
you may want to have more influence on the result of the solution. The following example
demonstrates how you can influence the result of the SOLUTION statement by using two
SYSTEM matrices and a LOCAL axis coordinate system.
For the matrix examples, assume that you call the solution with the following arguments:
Xi,Yi,Zi,Ii,Ji,Ki
If the variable, SYSTEM.MATRIX1 0, the input variables will be multiplied by matrix 1.
If the variable, SYSTEM.MATRIX2 0, the input variables will be multiplied by matrix 2.
The variables [Link][1], [Link][2], and [Link][3], are added
to Xi,Yi,Zi, respectively.
The matrices are three rows by four columns and are defined using SYSTEM variables as:
SYSTEM.MATRIXA1[1] SYSTEM.MATRIXA1[2] SYSTEM.MATRIX1A[3] SYSTEM.MATRIX1A[4]
SYSTEM.MATRIXB1[1] SYSTEM.MATRIXB1[2] SYSTEM.MATRIX1B[3] SYSTEM.MATRIX1B[4]
SYSTEM.MATRIXC1[1] SYSTEM.MATRIXC1[2] SYSTEM.MATRIX1C[3] SYSTEM.MATRIX1C[4]
As can be seen, by default the system variables have no effect on the SOLUTION at all. They are
simply a mechanism for you to provide advance calculation to the input variables, prior to the
SOLUTION calculations being performed.
The REGISTER and MOVE parameters instruct IMSpost to move the machine and update the
controllers registers to the new values calculated by the SOLUTION statement. You can use the
SOLUTION statement, without these two parameters, and no motion or controller registers will
be updated. You can then utilize these new SOLUTION variables in your logic and specify
another SOLUTION statement that includes the REGISTER and MOVE parameters.
The solution in IMSpost goes through a series of stages in order to take the incoming APT
coordinate to the expected outgoing Axis Position solution. At any point you can look at the
steps/calculations of the solution record by going to the Watch window in the IMSpost debugging
tools.
APT
The APT coordinates come into the solution based on the coordinates that were passed to the
GOTO solution either in the GOTO macro or in a user-written macro where the
SOLUTION(GOTO/…) statement appears.
Matrices
There are two 3x4 system matrices that can be applied to the APT coordinates before the internal
solution is done. These matrices can be used to perform any rotation or translation of the APT
that might be needed. Inside the OUTPUT window, they are referred to as MATRIX1 and
MATRIX2, and outside of this context they can be accessed and changed in the system variables
SYSTEM.MAT1 and SYSTEM.MAT2. The number that appears before the matrix indicates the
value of SYSTEM.MATRIX1 (or SYSTEM.MATRIX2), which indicates how the matrix is
applied to the APT data. Refer to Macro Language Variables, starting on page 238 of this guide,
for more information.
Rotation Solution
The post lists each rotary solution that would satisfy the IJK vector. Each rotary solution consists
of information (as shown above) listing out what axes were active during this solution, the lock
variable settings for each axis, and the position the axes move to satisfy the solution.
Setup Move
For each machine axis there is a Setup Move variable. The value of this variable represents the
movement required to move the machine from its default position in the post to a position where
the “machine zero” coincides with the part zero. The “machine zero” is in reference to the setting
on the References dialog box addressed during post customization. If Face is selected, the Setup
Move reflects the axis move required to bring the tool mounting point coincident with the part
mounting point. If Pivot is selected, the pivot point is brought coincident with the part mounting
point. At any time, the setup move for an individual axis can be found in the variable
MACHINE.[?].SETUP_MOVE.
RTCP
If RTCP Table is selected, the solution is not dependent on rotary orientation. For this reason, the
RTCP setting will reset the XYZ back to the same values as they were directly preceding the
ROTARY solution. This setting is connected to the check box “Use RTCP Output,” which is
found on the Multi-Axis Setup dialog. This setting is not dependent/connected to the RTCP cut
setting, which is prompted by having the “Output Using” set to RTCP in the CUT(…).
Working Planes
The working plane matrix is the final step applied to the solution data before it is in its final form.
The working plan matrix is applied when the working plan is set to ON and can either be
calculated automatically by the post or the matrix can be specified by the user.
You will call the LINTOL solution when working in MULTAX/ON mode (4 or 5 axes motion),
and a LINTOL/n (linearization) statement is encountered in the program. The LINTOL may also
be activated within the postprocessor definition (see the Multi-Axis feature).
LINTOL/n is a means to break single moves into much smaller moves in such a way that the tool
tip will move in a straight line relative to the part and the tool axis will move in a plane defined
by the cross product of the start and the end tool vectors. This solution makes use of the
SYSTEM variables:
[Link] Controls multi-axis linearization routine. The SOLUTION
first checks whether [Link] = 1 (if 0, no
linearization check is made).
SYSTEM.LINTOL_LINEAR Specifies the linear deviation (if 0.0, no check is made).
This is linearization for the linear axes only.
SYSTEM.LINTOL_ROTARY Specifies the angular deviation (if 0.0, no check is made).
This is the multi-axis angular deviation for rotary motion.
SYSTEM.MAX_STEP Controls linearization of line segments:
= 0 Line segments not affected by limit set in
SYSTEM.MAX_LINTOL_STEP
= 1 Line segments not complete; limit set in
SYSTEM.MAX_LINTOL_STEP
SYSTEM.MAX_LINTOL_STEP Amount of lintol blocks ( 0 = no limit).
NOTE: For 5-axis motion, the last 2 SOLUTION variables will be passed into the
AUTO_RETRACT/* macro. There you can make a decision as to what motion path to take (it
gives you the opportunity to force the opposite motion).
In addition, for each quadrant component of the arc (up to 5), the same information for each
quadrant arc is supplied in array format. For each quadrant, the start point is the end point of the
previous quadrant.
[Link][1..n]
SYSTEM.START_ANGLE[1..n]
SYSTEM.END_ANGLE[1..n]
SYSTEM.DELTA_ANGLE[1..n]
SYSTEM.X_START[1..n]
SYSTEM.Y_START[1..n]
SYSTEM.X_END[1..n]
SYSTEM.Y_END[1..n]
SYSTEM.X_CNT_TO_START[1..n]
SYSTEM.Y_CNT_TO_START[1..n]
SYSTEM.X_CNT_TO_END[1..n]
SYSTEM.Y_CNT_TO_END[1..n]
SYSTEM.X_CFG_CENTER[1..n]
SYSTEM.Y_CFG_CENTER[1..n]
The X_CFG_CENTER & Y_CFG_CENTER solution variables are set dependent on the
[Link] variable (this variable is changed if you choose a different option in the
CIRCLE DIALOG BOX) where [Link] could be:
0: Absolute coordinate of center.
1: Distance from start to center.
2: Distance from center to start.
3: Unsigned distance from center to start.
4: Radius
5: Radius, Center
6: Intermediate Point (Controller Emulator)
10: Linearize circular output.
This SOLUTION form works together with the CIRCLE solution and can be called only after
calling SOLUTION(CIRCLE/). This is because the CIR2LIN solution uses the CIRCLE solution
return record as its input arguments.
The purpose of this solution is to provide an easy way to convert arc movement to linear
interpolated movements, for controllers that do not support circular interpolation (usually G2,
G3). This would be the case if you selected the “Break into linear moves” with the Circle feature.
The first call of this solution after a CIRCLE solution changes the number of break moves for this
arc in SOLUTION.#_OF_RECORD. Subsequent calls decreases the
SOLUTION.#_OF_RECORD until all moves are completed—in other words, the end of the arc
is reached.
SORT Statements
The SORT statement is a statement created especially for the IMS knowledge-based applications.
Use it within the INIT_CFG/ macro to set the order in which registers, preparatory functions (G-
codes), and auxiliary functions (M-codes) are processed when the macros are executed during
postprocessing.
NOTE: If you utilize the Sort Output feature in the IMS environment, these statements are
generated automatically. The SORT command enables you to change the sorting of and letter
addresses or function codes with any particular macro.
To set the order of processing for controller registers, specify the register list in the order you
want and separate each register name with a comma. For example:
SORT(N,G,X,Y,R,Z,I,J,K,F,S,T,M)
To set the order of processing for preparatory functions, specify the option GFUNC as the first
argument to the SORT command followed by the G-values listed in the order you want, separated
by commas:
SORT(GFUNC,90,91,17,18,20,21,92,93,94,95,40,41,1,2,3,4)
To set the order of processing for auxiliary functions, specify the option MFUNC as the first
argument to the SORT command followed by the M-values listed in the order you want,
separated by commas:
SORT(MFUNC,1,2,3,4,11,12,8,9,30)
The system processes any registers or values that are not specified in the list in the order in which
they are processed by the knowledge base, but only after it processes all the registers or values
specified in the SORT.
Example 1
Sort order and resulting sort statement in macro INIT_CFG/* is:
SORT(/N,N,O,G,X,Y,Z,I,J,K,R,Q,P,H,D,S,L,T,M,F)
Example 2
Sort order and resulting sort statement in macro INIT_CFG/* is:
SORT(/N,N,O,G,Z,Y,X,I,J,K,R,Q,P,H,D,S,L,T,M,F)
Example 3
You can also use this statement to sort the order of selected G-codes. This can be useful when
multiple G-codes are output per block.
SORT(GFUNC,90,91,94,95,98,99,17,18,19,40,41,42,0,1,2,3,4,80,81,82,83,
83,87,89)
The same can be done with M functions (only necessary if multiple M-codes per block):
SORT(MFUNC,3,4,5,7,8,9,13,14)
SPLIT Statements
Use this statement to split a string into substrings. This command is often used together with the
FILE command to “split” input strings read from an external data source. However, the command
can be used on any string. The syntax is:
SPLIT(delim, instring, sub1, sub2, . . . , subn)
where:
delim is a separator for splitting. This must be enclosed in double quotes.
instring is the name of the input string.
sub1,sub2,....,subn output substrings.
You can have more substring arguments supplied than the number of substrings present in the
input string. A good rule to follow is to be sure to have enough substring variables for the longest
input string you intend to interpret.
An example is:
ISUB = 1
[Link] = 0
WHILE ([Link] = 0)
FILE(READ, "[Link]", TEXTLINE)
SPLIT(",",TEXTLINE,DVALUE,EVALUE)
[Link][ISUB] = DVALUE
[Link][ISUB] = EVALUE
ISUB = ISUB + 1
ENDWHILE
SPRINT Statements
The SPRINT statement allows for specific formats when outputting values (variables) with text
strings. For users experienced with the C programming language, this statement is similar to
PRINTF
The syntax is:
NAME_10 = SPRINT("%s %3.0f %u",T1,GLOBAL.CENTER_DRIVE,T2)
Each conversion character must be preceded by a percent sign (%). The SPRINT statement
contains the arguments and formats, and the variable names to be output. These two fields are
separated by a comma delimiter. Available arguments are:
d Convert to decimal
o Convert to unsigned octal
x Convert to unsigned hexadecimal
u Convert to unsigned decimal (integer)
c Single character
s Designates a text string
f Convert as a real number
Looking at the above syntax example, consider the following:
T1 = "( TOOL DRIVE ="
GLOBAL.CENTER_DRIVE = 525.775
T2 = " )"
NAME_10 = SPRINT("%s %3.3f %s",T1,GLOBAL.CENTER_DRIVE,T2)
OUTPUT(NAME_10,NEWLIN) --> ( TOOL DRIVE = 525.775 )
Each argument/format field must be separated by a space, and the entire string of formats must be
enclosed with double quotes. A comma must then be inserted to separate the argument field from
the variable name field. If necessary, you can also tab the fields.
The following table shows the different ways of printing the textsting “hello, world” (12
characters). Colons are used here to display the field length.
NOTE: The SPRINT statement is sensitive. Step through the debugger to ensure it is specified
correctly. If the debug icon is not displayed after reading it, it is OK.
STREXT Statements
Use the STREXT statement to extract a specified piece of text from a text string. For example:
VV = "ABCDEF"
A = STREXT(VV,3,4) A = "CD"
The STREXT statement also is useful for extracting the remainder of a text string. For example:
MY_TXT = "PARTNO_TEST15_JOBID#78A"
GET_TEXT = STREXT(MY_TXT,8) GET_TEXT = "TEST15_JOBID#78A"
NOTE: When specifying the locations of the text string, you cannot use variables. You must
specify the location with an integer.
STRLEN Statements
This statement will return the length of the string (number of characters). For example:
TEST = "THE COW JUMPED OVER THE MOON"
AA = STRLEN(TEST)
* AA = 28 (spaces are also included).
STRSTR Statements
This statement enables you to extract text from a text string. For example:
MY_TXT = "ABCDEFGH1234567"
B = STRSTR(MY_TXT,"FGH")
The above statement searches the MY_TXT texstring for the string FGH. When found, it extracts
it and everything behind it.
NOTE: If the second substring is not found, the variable will be empty.
TABLE Statements
Use the TABLE command to insert a line, with the current table variable values, into the
specified table. Each time a TABLE statement is read, it will add the specified data to the specific
table name.
Typically, a tool list table is created with the Report feature. All the proper variables and formats
are specified there. The TABLE command would exist at the bottom of the LOADTL macro, thus
entering the predefined data into the table.
The syntax is:
TABLE(table)
where:
table is the name of a predefined table to generate a new line. For example:
TABLE(TOOL TABLE)
At the end of the program, the postprocessor should write out all this table data to a file. This
would be done within the FINI_CFG macro:
FILE(TABLE,"[Link]",TOOL TABLE)
where:
[Link] is the file in HTML format.
TOOL TABLE is the name of the table that was predefined with the Report feature.
TOKEN Statements
Use this statement to extract pieces of text separated with delimeters. One or more delimeters
may be specifed with this.
MY_PART = "LOAD%TOOL:10,MANUAL"
A = TOKEN(MY_PART,"%:,")
where specified delimiters are %:,
You could extract all the text from the special characters by utilizing logic similar to this in a
macro:
A = TOKEN(MY_PART,"%:,")
WHILE(A)
OUTPUT(A,NEWLIN)
A=TOKEN("%:,"
ENDWHILE
The results will be:
N1 LOAD
N2 TOOL
N3 10
N4 MANUAL
TOOL_ALONG Statements
This statement will return the current tool direction for the specified axes. For example, if you
have 3-axis machine (XYZ) and the Machine Z is specified as (+) vertical in the Motion dialog:
A = TOOL_ALONG("X","Y","Z")
IMSpost would return:
A = +Z
This statement is used within the CYCLMOTN macro to see if the current tool-axis is along one
of the major axes. This statement can be useful when programming machines with rotary heads.
USER STATEMENTS
Use the USER statement to display a custom dialog. The dialog name must be the exact name as
the description used in USER > User Dialog. For example:
USER("TOOL DATA BOX")
Typically, if you want your dialog to be displayed for every job, enter this statement in the INIT/*
or INIT_CFG/* macros (not both).
There are some dialogs already connected with the library posts. These are available under the
User menu.
Once dialogs are written correctly, you can also import them into other projects.
WHILE Statements
The WHILE statement is the looping statement for IMS macros. A WHILE loop executes as long
as a given condition exists. Execution ends when the condition no longer exists. Because the test
is at the top of the loop, it is possible for the loop not to run. The loop statements do not execute if
the condition never exists. This eliminates the need for an explicit test to bypass the loop.
The syntax of the WHILE statement is:
WHILE (condition)
statement
...
statement
ENDWHILE
The condition can be any expression that results in a Boolean value. Each statement in the loop
can be any valid IMS macro statement. The system evaluates the condition. If the condition is
equal to zero, the system exits the loop and passes control to the statement after ENDWHILE. If
the condition does not equal zero, the system executes the series of statements that follow
WHILE and passes control to the top of the loop where it evaluates the condition again.
The system executes the loop statements only when the WHILE condition is true (the condition
does not equal zero). The system exits the loop when the WHILE condition is false (the condition
equals zero).
An example is:
I = 1
WHILE (I < CLDATAN.0)
OUTPUT("M", CLDATAN.[I],NEWLIN)
I = I + 1
ENDWHILE
NOTE: You can nest WHILE statements. Statements under control of a WHILE statement can
themselves be WHILE statements.
Notes
CLDATA Variables
The variables of the format CLDATAM and CLDATAN are the way an IMSpost macro receives
the input parameters from either an input file or an IMSpost test command.
CLDATAM variables are used to store input parameter “minor words.” CLDATAN variables are
used to store input values. The different formats of these variables are as follows:
Variable Description
CLDATAN.0 Parameter 0 is the count of CLDATAN input values.
CLDATAN.1… Parameter(s) 1 to n are the actual input values.
[Link].0 [Link].0 is the count of values left of minor.
[Link].1… [Link].1 to n are the actual values left of minor.
[Link].0 [Link].0 is the count of values right of minor.
[Link].1 [Link].1 to n are the actual value right of minor.
CLDATAN.[#]
[Link].[#] Values 1…n can be written using the array format.
[Link].[#]
CLDATAM.0 Parameter 0 is the count of CLDATAM input values.
CLDATAM.1… Parameter(s) 1 to n are the actual input minor words.
[Link].0 [Link].0 is the count of minor words left of minor.
[Link].1… [Link].1 to n are the actual minor words left of minor.
[Link].0 [Link].0 is the count of minor words right of minor.
[Link].1. [Link].1 to n are the actual minor words right of
CLDATAM.[#] minor.
[Link].[#] Minor words 1…n can be written using the array format.
[Link].[#]
You can also use the CLDATA.# format to extract/output a parameter within the CLDATA
statement. For example:
CYCLE/DEEP,FEDTO,-125,INCR,12.5,MMPM,2000,RAPTO,10
where CLDATA.0 is the count total number of values and parameters. In this case, there are 5
parameters and 4 values:
CLDATA.1 = DEEP
CLDATA.2 = FEDTO
CLDATA.3 = -.125
CLDATA.4 = INCR
CLDATA.5 = 12.5
CLDATA.6 = MMPM
CLDATA.7 = 2000
CLDATA.8 = RAPTO
CLDATA.9 = 10
An example is:
LOADTL/1.0, LENGTH, 5.0, OSETNO, 3.0
When the LOADTL macro is initiated by the above statement, the CLDATA variables would be:
CLDATA.0 = 5 3 values + 2 minor words.
CLDATAN.0 = 3
CLDATAN.1 = 1.0
CLDATAN.2 = 5.0
CLDATAN.3 = 3.0
CLDATAM.0 = 2
CLDATAM.1 = "LENGTH"
CLDATAM.2 = "OSETNO"
CLREAD Variables
The variables of the format CLREADM and CLREADN are the way an IMSpost macro receives
the input parameters from a “read ahead” of the input stream (from either an input file or IMSpost
test command). Reading ahead is done using the IMS macro CLREAD statement. If the
CLREAD macro statement successfully finds the statement it is searching for, the CLREADM
and CLREADN variables will have the input parameters of that statement.
CLREADM variables are used to store input parameter “minor words.” CLREADN variables are
used to store input values. The different formats of these variables are as follows:
Variable Description
CLREADN.0 Parameter 0 is the count of CLREADN input values.
CLREADN.1… Parameter(s) 1 to n are the actual input values.
[Link].0 [Link].0 is the count of values left of minor.
[Link].1… [Link].1 to n are the actual values left of minor.
[Link].0 [Link].0 is the count of values right of minor.
[Link].1… [Link].1 to n are the actual values right of minor.
CLREADN.[#]
[Link].[#] Values 1…n can be written using the array format.
[Link].[#]
CLREADM.0 Parameter 0 is the count of CLREADM input values.
CLREADM.1… Parameter(s) 1 to n are the actual input minor words.
[Link].0 [Link].0 is the count of minor words left of minor.
Variable Description
[Link].1… [Link].1 to n are the actual minor words left of minor.
[Link].0 [Link].0 is the count of minor words right of minor.
[Link].1… [Link].1 to n are the actual minor words right of
CLREADM.[#] minor.
[Link].[#] Minor words 1...n can be written using the array format.
[Link].[#]
Field Description
Name Component ID (from the component tree).
Type Table, Head, Part, Tool, Static, and Fixture.
Mount How the component is attached to another.
Motion Does component drive a machine axis? If so, enter axis.
Shape Components shape. This can be a cube cone or cylinder.
Field Description
Direction Direction in which the cylinder or cone is pointed.
COMPONENT Variables
COMPONENT variables tell IMSpost “what” is being cut (PART) and “how” it is being cut
(TOOL). Typically there is no reason to change these variables. It does, however, give you the
ability to reorient the part, cut multiple parts, or change the tool axis direction (cutting with a
right-angle attachment). This information is specified within the CUT macro statement.
Variable Description
[Link] Specifies the units type for the entire model ("INCH" or
"MM"). For example:
[Link] = "MM"
[Link] Specifies the priority of the machine co-linear axes. For
example:
[Link] = "Z,W"
[Link] Specifies the units (name) type ("INCH" or "MM"). For
example:
[Link] = "MM"
[Link] Specifies the components type. The choices are "TABLE",
"HEAD", "PART", "TOOL", "STATIC", and "FIXTURE" For
example:
[Link] = "TOOL"
[Link] Specifies what component it is attached to. For example:
[Link] = "HEAD"
[Link] Specifies what machine register is affected. For example:
[Link] = "Z"
[Link] Specifies the component shape as "CUBE", "CYLINDER", or
"CONE". For example:
[Link] = "CUBE"
Variable Description
[Link] = 1
[Link] Controls the maximum machine limit check (0 = Off,
1 = On). For example:
[Link] = 1
[Link] Enters the maximum feedrate for the specified axis.
For example:
[Link] = 2000
[Link] Specifies the increment used with the co-linear axis
only. For example:
[Link] = 20.0
[Link] Specifies the origin from which the component
originates. For example:
[Link] = "[Link]"
[Link] Enters the offset distance along the specified
direction. For example:
[Link] = 7.05
[Link] = 11.8578
[Link] = 0
COOLANT Variables
The macro variables used by this dialog, with default settings and description, are as follows:
Variable Description
GLOBAL.COOLANT_BLOCK = 0 Outputs coolant on a block itself.
= 1 Outputs with the next motion block.
GLOBAL.COOLANT_DEF = 'MIST' Default coolant condition.
[Link] : M7 MODE/GROUP and FUNCTION attached to the
MIST coolant.
[Link] : M8 MODE/GROUP and FUNCTION attached to the
FLOOD coolant.
[Link] : M9 MODE/GROUP and FUNCTION attached to the
coolant is off.
COOLNT/OFF M9 [Link]="OFF"
CYCLE Variables
The macro variables used by this dialog, with default settings and description, are as follows:
Variable Description
GLOBAL.CYCLE_USER1 = "" User defined cycle type name.
GLOBAL.CYCLE_USER2 = "" User defined cycle type name.
GLOBAL.CYCLE_USER3 = "" User defined cycle type name.
GLOBAL.CYCLE_USER4 = "" User defined cycle type name.
GLOBAL.CYCLE_OTHER = "" Additional code to be output on cycle block.
GLOBAL.CYCLE_CFORM = 0 Clearance plane format:
0: Absolute position
1: Incremental position from cycle plane
2: Absolute or incremental (based on current mode
of the postprocessor)
3: Incremental value, with reversed sign
GLOBAL.CYCLE_DFORM = 0 Depth format:
0: Absolute position
1: Incremental position from cycle plane
2: Absolute or incremental (based on current mode
of the postprocessor)
3: Incremental value, with reversed sign
GLOBAL.CYCLE_BLOCK = 0 0: Cycle off in block itself
1: Cycle off on next motion block
GLOBAL.CYCLE_REG4 = "P" Register used for cycle dwell value.
GLOBAL.CYCLE_REG3 = "R" Register used for clearance plane value.
GLOBAL.CYCLE_REG2 = "Q" Register used for peck increments; used in DEEP and
BRKCHP cycles.
Variable Description
GLOBAL.CYCLE_REG1 = "Z" Register used for cycle depth value.
[Link]="G80" MODE/GROUP + FUNCTION attached to cycle off.
[Link]="G81" MODE/GROUP+ FUNCTION attached to cycle drill.
[Link]="G82" MODE/GROUP+ FUNCTION attached to cycle drill
with dwell (spot drill).
[Link]="G83" MODE/GROUP+ FUNCTION attached to deep
drilling cycle.
[Link]="G84" MODE/GROUP+ FUNCTION attached to tapping
cycle.
[Link]="G85" MODE/GROUP+ FUNCTION attached to reaming
cycle.
[Link]="G86" MODE/GROUP+ FUNCTION attached to boring
cycle.
[Link]="G87 MODE/GROUP+ FUNCTION attached to back
boring cycle.
[Link]="G88" MODE/GROUP+ FUNCTION attached to manual
boring cycle.
[Link]="G89" MODE/GROUP+ FUNCTION attached to bore stop
cycle.
[Link]="G73" MODE/GROUP+ FUNCTION attached to
breakchipping cycle.
[Link]="G74" MODE/GROUP+ FUNCTION attached to left-hand
(reverse) tapping cycle.
[Link] MODE/GROUP+ FUNCTION attached to user
defined cycle.
Variable Description
GLOBAL.FEED_MM_REV = 3.3 Digit format for MM/REVOLUTION format.
GLOBAL.FEED_INCH_REV = 2.4 Digit format for INCH/REVOLUTION format.
GLOBAL.FEED_INV_TIME = 4.2 Digit format for inverse time feed programming.
GLOBAL.FEED_PROG = 100.000000 Default feed rate value.
[Link] (G94) MODE/GROUP+ FUNCTION attached to per
minute feed mode.
[Link] (G95) MODE/GROUP+FUNCTION attached to per
revolution feed mode.
[Link] (G93) MODE/GROUP attached to inverse time feed mode.
FUNCTION Variables
Functions (M and G codes) are the codes that activate machining modes or specify controller
options.
Each function that is supported within the postprocessor has the following variables associated
with them. IMSpost will always use what is defined in the Function Table. These Function
Variables give you a way to override these settings.
Variable Description
[Link] Name of the G/M code. For example:
[Link] = "M13"
This variable is useful for changing the name of a function
[Link] For code modality enter "Y" for modal; enter "N" for non-
modal. For example:
[Link] = "Y"
[Link] MODE variable that could be associated with the code.
[Link] Enter controller letter addresses that will always be output with
this function code. For example:
[Link] = "X,Y,Z,B,F"
[Link].USE1 Enter controller letter addresses that will be output (one-shot)
with this function code. For example:
FUNCTION.G1.USE1 = "X,Y,Z,B,F"
[Link] Enter 1 if code is output by itself. If code is output with other
codes, enter 0.
Variable Description
[Link] Enter 1 if the controller acts on code immediately.
[Link] Enter 1 if code is output by itself, or enter 0 if output with other
code.
NOTE: The END and BLOCK definitions control their respective checkboxes in the Function
Definition Table. These two variables are normally in effect if the maximum number for G or M
codes per block is exceeded. If it is, these checkboxes could determine which codes are output
first when the G/M code buffer is full.
Function codes that are entered via the postprocessor dialogs, are automatically associated with
IMS library Mode/Group (see CONTROLLER > Function Codes or CONTROLLER > Function
Groups).
Function codes may also be changed. Note that once they are changed, they remain in effect until
changed back to its original or default definition.
[Link] = "M13"
Geometry Functions
IMSpost utilizes some of these functions to shorten the length of existing macros that include
various calculations. Some of these library macros include CATMAT/*, PNT2VEC/*,
ORIGIN/*, and UCS/*.
ARC
ARC is a variable that contains a start point, center point, direction vector, and end point. The
syntax is:
ARC (STARTPOINT, CENTERPOINT, DIRECTION, ENDPOINT)
For example:
A = ARC (11,20,100, 10,20,100, 0,0,1 10,21,100)
The result of this is a 90-degree arc, starting at zero (0.0) on X-axis and ending at 90 degrees on
Y-axis:
Start point is at 11,20,100
Center point is at 10,20,100
Arc plane XY plane, direction of the arc counterclockwise (CCLW) is 0,0,1
End point is at 10,21,100
Each of the points in the ARC statement may use a POINT variable, and the direction may use a
VECTOR variable. As an example, the same ARC defined above may be created using the
following sequence of commands:
PS = POINT(11,20,0)
PC = POINT(10,20,100)
PE = POINT(10,21,100)
V = VECTOR(1,0,0)
A = ARC(PS,PC,V,PE)
In order to access specific elements of an ARC data variable, use the following syntax (assume A
is an ARC):
BACKMAT
BACKMAT returns the reverse for the specified matrix. Available syntax is:
BACKMAT(MATRIX)
BACKMAT(A[1],A[2],A[3],A[4], B[1],B[2],B[3],B[4],
C[1],C[2],C[3],C[4])
BACKMAT(A[1],A[2],A[3], B[1],B[2],B[3], C[1],C[2],C[3])
BACKMAT(VECTOR, VECTOR, VECTOR)
BACKMAT(VECTOR, A[4],VECTOR, B[4],VECTOR,C[4])
BACKMAT(POINT, A[4],POINT, B[4],POINT,C[4])
For example:
M1 = MATRIX(0,0,1,0,1,0,-1,0,0)
M2 = BACKMAT(M1)
M2 = MATRIX(0,0,-1,0,0,-1,0,0,1,0,0,0)
ISIDENT
ISIDENT is an “identity-type” matrix (1 = true, 0 = false). Available syntax is:
ISIDENT(MATRIX)
ISIDENT(VECTOR,X,VECTOR,Y,VECTOR,Z)
ISIDENT(A[1],A[2],A[3],A[4],
B[1],B[2],B[3],B[4],C[1],C[2],C[3],C[4])
LINE_PNT_TAN_CIR(POINT,CIRCLE)
LINE_PNT_TAN_CIR(X,Y,Z,XC,YC,ZC,I,J,K,R)
M1 = MATRIX(1,0,0,0,0,1,0,0,0,0,1,0
A = ISEDENT(M1) --> A = 1
LINE_ANGLE_LINE
LINE_ANGLE_LINE returns definition of a line passing through a point at an angle with a given
line. Available syntax is:
LINE_ANGLE_LINE (LINE,POINT,ANGLE)
LINE_ANGLE_LINE (POINT,POINT,POINT,ANGLE)
LINE_ANGLE_LINE (X1,Y1,Z1,X2,Y2,Z2,X,Y,Z,ANGLE)
For example:
L1 = LINE)ANGLE_LINE(-3,4,0,3,4,0,4,3,0,90) L1 = LINE(4,3,0,4,5,0)
LINE_DIST_PARREL
LINE_DIST_PARREL returns points of a line parallel to a given line at a given distance from it.
Available syntax is:
LINE_DIST_PARREL(LINE,DISTANCE)
LINE_DIST_PARREL(POINT,POINT,DISTANCE)
LINE_DIST_PARREL(X1,Y1,Z1,X2,Y2,Z2)
LINE_DIST_PARREL(LINE,DISTANCE)
LINE_DIST_PARREL(POINT,POINT,DISTANCE)
LINE_DIST_PARREL(X1,Y1,Z1,X2,Y2,Z2)
For example:
L1 = LINE_DIST_PARREL(5,0,3,10,3,2) L1 = LINE(5,-2,3,10,-2,3)
LINE_PARREL
This function gives the second point, which together with the specified point, defines a line
parallel to the given line. Available syntax is:
LINE_PARREL(LINE,POINT)
LINE_PARREL(POINT,POINT,POINT)
LINE_PARREL(X1,Y1,Z1,X2,Y2,Z2,X,Y,Z)
For example:
L1 = LINE_PARRLEL(5,0,3,10,0,3,7,4,3) L1 = LINE(4,3,0,4,5,0)
MATIDNT
MATIDNT returns the identity matrix.
M1 = MATIDNT() M1 = MATRIX(1,0,0,0,0,0,1,0,0,0,0,0,1,0)
MATPNTVEC
MATPNTVEC returns matrix from a given point and two vectors. Available syntax is:
MATPNTVEC(POINT,VECTOR,VECTOR)
MATPNTVEC(X,Y,Z,I1,J1,K1,I2,J2,K2)
For example:
M1 = MATPNTVEC(1,2,3,1,0,0,0,1,0)
M1 = MATRIX(1,0,0,1,0,1,0,2,0,0,1,3)
MATROT
MATROT defines the matrix according to two specified vectors and an angle. Available syntax is:
MATROT(VECTOR,VECTOR,ANGLE)
MATROT(POINT,POINT,ANGLE)
MATROT(I1,J1,K1,I2,J2,K2,ANGLE)
MATROT(LINE,ANGLE)
For example:
V1 = VECTOR(1,0,0)
V2 = VECTOR(0,1,0)
ANG = 90
M1 = MATROT(V1,V2,ANG) M1 = MATRIX(-0.448074,0,0.893997,1,0,
1,0,0,-0.893997,0,-0.448074,0)
PNT_LINE_CIR_INTRSC
PNT_LINE_CIR_INTRSC returns the intersection points where the line intersects a circle.
Available syntax is:
PNT_LINE_CIR_INTRSC(LINE,CIRCLE)
PNT_LINE_CIR_INTRSC(POINT,POINT,CIRCLE)
PNT_LINE_CIR_INTRSC(X1,Y1,Z1,X2,Y2,Z2,XC,YC,ZC,I,J,K,R)
For example:
L1 = LINE(-7,4,0,9,4,0)
C1 = CIRCLE(0,0,0,0,0,1,5)
PSC = PNT_LINE_CIR_INTRSC(L1,C1) PSC = LINE(3,4,0,-3,4,0)
PNT_LINE_INTRSC
PNT_LINE_INTRSC reads the coordinates from each of the two specified lines and returns the
coordinates of the lines intersection point. Available syntax is:
PNT_LINE_INTRSC(LINE,LINE)
PNT_LINE_INTRSC(POINT,POINT,POINT,POINT)
PNT_LINE_INTRSC(X11,Y11,Z11,X12,Y12,Z12,X21,Y21,Z21,X22,Y22,Z22)
For example:
L1 = LINE(-3,5,0,9,5,0)
L2 = LINE(2,4,0,2,7,0)
P = POINT_LINE_INTRSC(L1,L2) P = POINT(2,5,0)
PNT_LINE_PROFILE_INTRSC
PNT_LINE_PROFILE_INTRSC finds the intersection between a line and a plane. Available syntax
is:
PNT_LINE_PROFILE_INTRSC(PLANE,LINE)
For example:
T = PNT_LINE_PROFILE_INTRSC(P,L)
If an intersection exists, the resulting value T is a variable of type POINT.
PNTONPLN
PNTONPLN checks to see if a given point exists on the specified plane. Available syntax is:
PNTONPLN(POINT,PLANE)
PNTONPLN(X,Y,Z,A,B,C,D)
For example:
B = PNTONPLV(2,4,0,0,0,1,0) B=1
VECPERVEC Returns the vector that is perpendicular to the
specified vector.
Available syntax is:
VECPERVEC(VECTOR)
VECPERVEC(I,J,K)
For example:
V1 = VECPERVEC(1,0,0) V1 = VECTOR(0,1,0)
PROFILE
PROFILE is a variable that consists of a list of points and/or arcs in any order. A PROFILE type
is a unique type of IMS macro language variable. While all other variable types have a fixed size,
the profile type may grow in size dynamically as more elements (point/arc) are added to it. each
new element that is added to a profile is connected to the last element of the profile geometrically
with a straight line. So a two point profile, for example, is a representation of a line.
All points and arcs must be on the same plane.
A profile is always 2-dimensional.
A profile can be created in different ways:
P = PROFILE(T) T is a variable of type POINT. P is now a profile with one element.
P = PROFILE(A) A is a variable of type ARC. P is now a profile with two elements:
The first element is a point (start point of the arc A).
The second element is a arc (center, direction, end) from arc A.
To add a new element to a profile, you may simply use the + operation. For example :
T1 = POINT(1,2,0)
T2 = POINT(-3,4.5,0)
P = PROFILE(T1)
P = P + T2
PROFILE_GET_MAX
PROFILE_GET_MAX reads the maximum axis coordinate values in a profile. Available syntax is:
PROFILE_GET_MAX(PLANE)
For example:
T = PROFILE_GET_MAX(P)
T is a return of variable of type POINT where:
T.X is the maximum X values of all the elements in the profile P.
T.Y is the maximum Y values of all the elements in the profile P.
T.Z is the maximum Z values of all the elements in the profile P.
* PROFILE_GET_MAX searches though the entire profile geometry, not only through the edges
of each element, to find the maximum elements for each axis.
PROFILE_GET_MIN
PROFILE_GET_MIN reads the minimum axis coordinate values in a profile. Available syntax is:
PROFILE_GET_MIN(PLANE)
For example:
T = PROFILE_GET_MIN(P)
T is a return of variable of type POINT where:
T.X is the minimum X values of all the elements in the profile P.
T.Y is the minimum Y values of all the elements in the profile P.
T.Z is the minimum Z values of all the elements in the profile P.
* PROFILE_GET_MIN searches though the entire profile geometry, not only through the edges
of each element, to find the minimum elements for each axis.
PROFILE_OFFSET
PROFILE_OFFSET returns a new profiile built with an offset to a given profile. Available syntax
is:
PROFILE_OFFSET(P, OFFSET, SIDE, STARTPOINT, ENDPOINT)
P Input profile.
OFFSET Input amount to offset the profile.
SIDE “LEFT” or “RIGHT” (analogous to ‘side’ in G41/G42).
STARTPOINT Approach the profile’s first element.
ENDPOINT Retract from the profile’s last element.
For example:
P1 = PROFILE_OFFSET(P,0.2,"LEFT",PS,PE)
Return (P1) A PROFILE WITH OFFSET 0.2 FROM THE GIVEN PROFILE (P)
The offset profile is built assuming you want to be on the left of the original profile, looking from
the first element of the profile to the second element.
VECANG
VECANG returns the angle between two specified vectors.
ANG = VECANG(0,0,1,1,0,1) ANG = 45
ANG = VECANG(VECTOR,VECTOR) Returns angle of 2 predefined vectors.
ANG = VECANG(V10,V12
VECANG (POINT,POINT) Returns angle of 2 predefined points.
ANG = VECANG(P12,P13)
VECLEN
VECLEN returns the vectors length.
L = VECLEN(1,1,1 L = 1.732051
VECLEN (VECTOR)
L1 = VECLEN(V2) Return length of predefined vector.
VECLEN (I,J,K)
L2 = VECLEN(1,1,0)
VECLEN (POINT)
VECLEN(P3)
VECLEN (X1,Y1,Z1,X2,Y2,Z2)
L = VECLEN(1,1,1) L = 1.732051
In case of vector input of 6 variables (or a LINE type or a 2 POINT type), the result will be the
length of subtraction.
VECLEN (POINT,POINT)
L4 = VECLEN(P6,P8)
VECLEN (LINE)
L5 = VECLEN(L12)
VECPROD
VECPROD generates the vectors product.
VECPROD(I1,J1,K1,I2,J2,K2)
V1 = VECPROD(1,1,0,0,0,1) V1 = VECTOR(0.707107,-.207107,0
VECPROD(VECTOR,VECTOR)
V1 = VECTOR(1,1,0
V2 = VECTOR(0,0,1)
V5 = VECPROD(V1,V2) V5 = VECPROD(1,1,0,0,0,1)
V5 = VECTOR(0.707107,-.207107,0)
Geometry Operations
You can combining math operations (+,-,*,/) with predefined geometry definitions.
Combination Description
ARC + ARC Adding two arcs. Both arcs must be on same plane and in the same
direction. The start point of second arc must be the same as the end
point of the first arc, otherwise the result will be in error or
unpredictable.
The resulting arc start point is the start point of the first given arc,
and the end point is the end point of the second given arc.
For example
C1 = ARC(11,20,100, 10,20,100, 0,0,1, 10,21,100)
C2 = ARC(10,21,100, 10,20,100, 0,0,1, 10,19,100)
C3 = C1 + C2
C3 (result data) is:
Start point 11.000000,20.000000,100.000000
Center point 10.000000,20.000000,100.000000
Direction 0.000000,0.000000,1.000000
End point 10.000000,19.000000,100.000000
ARC * MATRIX Multiplying an arc by a given matrix. For example:
P = POINT(0,0,0)
V = VECTOR(0,0,1)
M = MATROT(P,V,90) (A rotation matrix of 90 degrees in XY
plane)
C1 = ARC(11,20,100, 10,20,100, 0,0,1, 10,21,100)
C2 = C1 * M
C2 (result data) is:
Start point -20.000000,11.000000,100.000000,-20.000000
Center point -20.000000,10.000000,100.000000
Direction 0.000000,0.000000,1.000000
End point 21.000000,10.000000,100.000000
CIRCLE * MATRIX Multiplying a circle by a predefined matrix.
C1=CIRCLE(5,0,0,0,0,1,5)
M1=MATRIX(-1,0,0,1,1,0,0,2,0,0,1,3)
C2=C1*M1
then:
Combination Description
C2=CIRCLE(1,7,3,0,0,1,5)
LINE * REAL Multiplying a predefined line by a real number.
L1 = LINE(10,12,10,200,150,10)
L2 = L1*2.0
then:
L2 = LINE(20,24,20,400,300,20)
LINE / REAL Dividing a predefined line by a real number.
L1 = LINE(10,12,10,200,150,10)
L2 = L1/2.0
then:
L2 = LINE(5,6,5,100,75,10)
MATRIX * MATRIX Multiplying two predefined matrices.
M1 = MATRIX(0,0,1,3,1,0,1,5,0,1,0,5)
M2 = MATRIX(0,0,1,0,0,1,0,0,0,0,1,0)
M3 = M1 * M2
then:
M3 = MATRIX(
MATRIX / MATRIX Dividing two predefined matrices.
MATRIX * REAL Multiplying a predefined matrix by a real number.
M1 = MATRIX(0,0,1,3,1,0,1,5,0,1,0,5)
M2 = M1*2.0
then:
M2 = MATRIX(0,0,2,6,2,0,2,10,0,2,0,10)
POINT + POINT Adding two predefined points.
P1 = POINT(100,100,20)
P2 = POINT(10,20,15)
and if:
P3 = P1 + P2
then:
P3 = POINT(110,120,35)
POINT - POINT Subtracting two predefined points.
P1 = POINT(100,100,20)
P2 = POINT(10,20,15)
and if:
P3 = P1 - P2
then:
P3 = POINT(90,80,5)
POINT * REAL Multiplying a predefined point with a real number.
P1 = POINT(100,100,20)
P2 = P1*2.0
then:
P2 = POINT(200,200,40)
POINT / REAL Dividing a predefined point with a real number.
P1 = POINT(100,100,20)
P2 = P1/2.0
then:
P2 = POINT(50,50,10)
Combination Description
POINT + VECTOR Adding a predefined point to a predefined vector.
P1 = POINT(100,100,20)
V1 = VECTOR(0,0,1)
P2 = P1 + V1
then:
P2 = POINT(100,100,21)
VECTOR * REAL Multiplying a predefined vector by a real number.
V1 = VECTOR(1,2,3)
V3 = V1 * 2.0
then:
V3 = VECTOR(2,4,6)
VECTOR - VECTOR Subtracting two predefined vectors.
V1 = VECTOR(1,2,3)
V2 = VECTOR(1,0,0)
V3 = V1 - V2
then:
V3 = VECTOR(0,2,3)
VECTOR * VECTOR Multiplying two predefined vectors.
V1 = VECTOR(1,2,3)
V2 = VECTOR(1,0,0)
V3 = V1 * V2
then:
V3 = VECTOR(1,0,0)
Geometry Assignments
IMSpost utilizes some of these functions to shorten the length of existing macros that include
various calculations. Some of these library macros include CATMAT/*, PNT2VEC/*,
ORIGIN/*, and UCS/*. IMS offers various ways of defining and extracting geometry data:
Assignment Description
BACKMAT Returns the reverse of the specified matrix. Syntax
includes:
BACKMAT(MATRIX)
BACKMAT(A[1],A[2],A[3],A[4],B[1],B[2],B[3],
B[4] ,C[1],C[2],C[3],C[4]
BACKMAT(A[1],A[2],A[3],B[1],B[2],B[3],,C[1],
C[2],C[3]
BACKMAT(VECTOR,VECTOR,VECTOR)
BACKMAT(VECTOR,A[4],VECTOR,B[4],
VECTOR,C[4]
BACKMAT(POINT,A[4],POINT,B[4],POINT,C[4]
For example:
M1 = MATRIX(0,0,1,0,1,0,-1,0,0)
M2 = BACKMAT(M1)
returns:
M2 = MATRIX(0,0,-1,0,0,-1,0,0,1,0,0,0)
Assignment Description
C#.[X,Y,Z,I,J,K,R] Extract circle data.
C1 = CIRCLE(3,4,0,0,0,1,5)
C1.X = 3 C1.Y = 4 C1.Z = 0
C1.I = 0 C1.J = 0 C1.K = 1
C1.R = 5
CIRCLE(CIRCLE) Predefined circle. If:
C1 = CIRCLE(0,0,0,0,0,1,5)
and:
C2 = CIRCLE(C1)
then:
C2 = C1
CIRCLE(POINT,POINT,POINT) Determine circle with three predefined points. If:
P1=POINT(3,4,0)
P2=POINT(5,0,0)
P3 = POINT(0,5,0)
and:
C1 = CIRCLE(P1,P2,P3)
then:
C1 = 0,0,0,0,0,-1,5
CIRCLE(POINT,POINT,R) Determine circle with 2 predefined points.
P1 = POINT(3,4,0)
P2 = POINT(5,0,0)
C1 = CIRCLE(P1,P2,5)
then:
C1 = 3,4,0,1,0,0,5
CIRCLE(POINT,VECTOR,R) Determine circle with predefined point, vector, and
specify radius.
P1 = POINT(3,4,0)
V1 = VECTOR(0,0,1)
RAD = 5.0
C3 = CIRCLE(P1,V1,RAD)
CIRCLE(X,Y,Z,I,J,K,R) Specify circle with circle endpoint, circle center, and
radius.
C1 = CIRCLE(0,0,0,0,0,1,5)
ISIDENT If specified matrix is an “identity” type matrix
=1 for YES
= 0 for NO
M1 = MATRIX(1,0,0,0,0,1,0,0,0,0,1,0)
A = ISIDENT(M1)
A = 1
L#.[X[I]/Y[I]/Z[I] Access starting/ending line coordinates, where [I] can
be 1 or 2.
L1 = LINE(1,2,3,4,5,6)
L1.X[1] = 1 L1.X[2] = 4
L1.Y[1] = 2 L1.Y[2] = 5
L1.Z[1] = 3 L1.Z[2] = 6
Assignment Description
LINE(LINE) Predefined LINE. If:
L1 = LINE(1,2,3,4,5,6)
and:
L2 = LINE(L1)
then:
L2 = L1
LINE([Link]) Determine LINE definition from 2 predefined points.
If:
P1=POINT(1,2,3)
and:
P2=POINT(4,5,6)
then:
L1 = LINE(P1,P2)
L1 = 1,2,3,4,5,6
LINE(X1,Y1,Z1,X2,Y2,Z2) Specify starting and ending points.
L1 = LINE(1,2,3,4,5,6)
LINE_ANGLE_LINE Returns definition of a line passing through a point at
an angle with a given line.
L1 = LINE_ANGLE_LINE(-3,4,0,3,4,0,4,3,0,90)
returns:
L1 = LINE(4,3,0,4,5,0)
LINE_DIST_PARREL Returns the points of a line parallel to a given line at a
given distance.
L1 = LINE_DIST_PARREL(5,0,3,10,0,3,2)
returns:
L1 = LINE(5,-2,3,10,-2,3)
LINE_PARREL Returns a second point which, together with a given
point, defines a line parallel to a given line.
L1 = LINE_PARRLEL(5,0,3,10,0,3,7,4,3)
returns:
L1 = LINE(4,3,0,4,5,0)
LINE_PNT_TAN_CIR Returns a line passing through a pt and tangent to a
circle. The syntax is:
LINE_PNT_TAN_CIR(POINT,CIRCLE)
LINE_PNT_TAN_CIR(X,Y,Z,XC,YC,ZC,I,J,K,R)
For example:
P1 = POINT(7,5,0)
C1 = CIRCLE(0,0,0,0,0,1,5)
L1 = LINE_PNT_TAN_CIR(P1,C1)
returns:
L1 = LINE(5.571429,7,0,7,5,0)
M#.[A[1...4] Accessing matrix values.
M#.[B[1...4] M1=MATRIX(1,2,3,1,4,5,6,2,7,8,9,3)
M#.[C[1...4] M1.A[1] = 1 M1.A[2] = 2
M1.A[3] = 3 M1.A[4[ = 1
M1.B[1] = 4 M1.B[2] = 5
M1.B[3] = 6 M1.B[4] = 2
Assignment Description
M1.C[1] = 7 M1.C[2] = 8
M1.C[3] = 9 M1.C[4] = 3
MATIDNT Returns the identity matrix.
M1 = MATIDNT()
returns:
M1 = MATRIX(1,0,0,0,0,10,0,0,0,1,0)
MATPNTVEC Returns matrix from a given point and two vectors.
Available syntax includes:
M1 = MATPNTVEC(1,2,3,1,0,0,0,1,0)
returns:
M1 = MATRIX(1,0,0,1,0,1,0,2,0,0,1,3)
MATRIX(A1,A2,A3,A4,B1,B2, Specify all 12 values.
B3,B4,C1,C2,C3,C4 M1 = MATRIXI(0,0,1,3,1,0,1,5,0,1,0,5
MATRIX(A1,A2,A3,B1,B2,B3, Omit 4th, 8th, and 12th values in the matrix. IMSpost
C1,C2,C3) will assume zero.
M1 = MATRIX(0,0,1,1,0,1,0,1,0)
is converted to
M1 = MATRIX(0,0,1,0,1,0,1,0,0,1,0,0)
MATRIX(MATRIX) Predefined matrix. If:
M1 = MATRIX(1,0,0,1,0,1,1,2,1,0,0,3)
and:
M2 = MATRIX(M1)
then:
M2 = MATRIX(1,0,0,1,0,1,1,2,1,0,0,3)
MATRIX(POINT,CONST,POINT, CONST specifies the translation origin point. If:
CONST,POINT,CONST P1 = POINT(1,2,3)
P2 = POINT(4,5,6)
P3 = POINT(7,8,9)
and:
M1 = MATRIX(P1,1,P2,2,P3,3)
then:
M1 = MATRIX(1,2,3,1,4,5,6,2,7,8,9,3)
MATRIX(VECTOR,CONST,VECTOR, CONST specifies the translation origin point. If:
CONST,VECTOR,CONST V1 = VECTOR,1,0,0)
V2 = VECTOR(0,1,1)
V3 = VECTOR((1,0,0)
and:
M1 = MATRIX(V1,1,V2,2,V3,3)
then:
M1 = MATRIX(1,0,0,1,0,1,1,2,1,0,0,3)
MATRIX(VECTOR,VECTOR,VECTOR) Use three predefined vectors to construct matrix.
IMSpost assumes zero for 4th, 8th and 12th values. If:
V1 = VECTOR(1,0,0)
V2 = VECTOR(0,1,1)
V3 = VECTOR(1,0,0)
and:
M1 = MATRIX(V1,V2,V3)
Assignment Description
then:
M1 = MATRIX(1,0,0,0,0,1,1,0,1,0,0,0)
MATROT Specifies matrix with two vectors and rotated at a
specified angle. Available syntax is:
MATROT(VECTOR,VECTOR,ANGLE)
MATROT(POINT,POINT,ANGLE)
MATROT(I1,J1,K1,I2,J2,K2,ANGLE)
For example:
V1 = VECTOR(1,0,0)
V2 = VECTOR(0,1,0)
ANG = 90
M1 = MATROT(V1,V2,ANG)
returns:
M1 = MATRIX(-0.448074,0,0.893997,1,0,1,0,0,
-.893997,0,-0.448074,0)
PL#.[A/B/C/D] Extract plane data,
PL1 = PLANE(1,0,0,5)
PL1.A = 1 PL1.B = 0
PL1.C = 0 PL1.D = 5
PLANE(I,J,K,CONST) CONST specifies the translation origin point.
PL1 = PLANE(0,0,1,3)
PLANE(PLANE) Use predefined plane definition. If:
PL1 = PLANE(0,0,1,5)
and:
PL2 = PLANE(PL1)
then:
PL2 = PL1
PLANE(POINT,CONST) Use a predefined point (IMSpost will transform the
point data into a vector). CONST specifies the
translation origin point. If:
P1 = point(3,4,0)
and:
PL1 = PLANE(P1,5)
then:
PL1 = 0.6,0.8,0,5
Point data is converted to vector data.
PLANE(POINT,POINT,POINT) Use three predefined points to calculate a plane. If:
P1 = POINT(3,4,0)
P2 = POINT(5,0,0)
P3 = POINT(0,5,0)
and:
PL1 = PLANE(P1,P2,P3)
then:
PL1 = 0,0,-1,5
PLANE(VECTOR,CONST) CONST specifies the translation origin point. If:
V1 = VECTOR(1,0,0)
and:
Assignment Description
PL1 = PLANE(V1,5)
then:
PL1 =1,0,0,5)
PLANE(VECTOR,VECTOR,POINT) Use two predefined vectors and a point. If:
V1 = VECTOR(0,1,0)
V2 = VECTOR(0,1,1)
P1 = POINT(0,5,0)
and:
PL1 = PLANE(V1,V2,P1)
then:
PL1 = 1,0,0,0
PNT_LINE_CIR_INTRSC Returns intersection points of a line passing through a
circle. Available syntax includes:
PNT_LINE_CIR_INTRSC(LINE,CIRCLE)
PNT_LINE_CIR_INTRSC(POINT,POINT,CIRCLE)
PNT_LINE_CIR_INTRSC(X1,Y1,Z1,X2,Y2,Z2,
XC,YC,ZC,I,J,K,R)
For example:
LI = LINE(-7,4,0,9,4,0)
C1 = CIRCLE(0,0,0,0,0,1,5)
PSC = PNT_LINE_CIR_INTRSC(L1,C1)
returns:
PSC = LINE(3,4,0,-3,4,0)
PNT_LINE_INTRSC Returns intersection point of two lines. Syntax is:
PNT_LINE_INTRSC(LINE,LINE)
PNT_LINE_INTRSC(POINT,POINT,POINT,POINT)
PNT_LINE_INTRSC(X11,Y11,Z11,X12,Y12,Z12,
X21,Y21,Z21,X22,Y22,Z22)
For example:
L1 = LINE(-3,5,0,9,5,0)
L2 = LINE(2,4,0,2,7,0)
P = PNT_LINE_INTRSC(L1,L2)
returns:
P = POINT(2,5,0)
PNTONPLN Checks to see if specified point is on a specified plane.
Syntax is:
PNTONPLN(POINT,PLANE)
PNTONPLN(X,Y,Z,A,B,C,D)
For example:
I = PNTONPLN(2,4,0,0,0,1,0)
I = 1 for true condition; I = 0 for false condition
P# .[X,Y,Z] Access point data.
If P1 = (POINT(10,20,400)
P1.[X,Y,Z]
results as:
P1.X = 10; P1.Y = 20; P1.Z=400
POINT(POINT) Predefined point.
Assignment Description
P2 = POINT(P1)
POINT(P2) = POINT(P1)
POINT(VECTOR) Point = vector.
V1 = VECTOR(0,0,1)
P1 = V1 : P1 = 0,0,1
POINT(X,Y,Z) Specify point.
P1 = POINT(10,20,400)
X=10; Y=20; Z=400
V#.[X,Y,Z] Access vector coordinates (IMSpost will first
normalize the vector before returning values). If:
V1 = VECTOR(1,0,1)
then:
V1.X = 0.707107
V1.Y = 0
V1.Z = 0.707107
VECANG Returns the angle between two specified vectors.
Syntax includes:
VECANG(VECTOR,VECTOR)
VECANG(POINT,POINT)
VECANG(I1,J1,K1,I2,J2,K2)
For example:
A = VECANG(0,0,1,1,0,1)
returns:
A = 45
VECLEN Returns length of vector. Available syntax includes:
VECLEN(VECTOR)
VECLEN(I,J,K)
VECLEN(POINT)
VECLEN(X1,Y1,Z1,X2,Y2,Z2)
VECLEN(POINT,POINT)
VECLEN(LINE)
For example;
L = VECLEN(1,1,1)
returns:
L = 1.732051
NOTE: If the specified vector consists of 6 variables,
a LINE type or a 2 POINT type, the result will be the
length of subtraction
VECPERVEC Returns vector that is perpendicular to specified
vector. Syntax is:
VECPERVEC(VECTOR)
VECPERVEC(I,J,K)
For example:
V1 = VECPERVEC(1,0,0)
returns:
V1 = VECTOR(0,1,0)
Assignment Description
VECPROD Returns vectors product. For example:
V1 = VECPROD(1,1,0,0,0,1)
returns:
V1 = VECTOR(0.707107,-0.707107,0)
VECTOR(I,J,K) If:
V1 = VECTOR(1,0,1)
IMSpost will normalize the vector to:
V1 = 0.707107,0,0.707107
VECTOR(LINE) Take the difference between two points and normalize
the vector.
L1 = LINE(3,0,9,2,5,6)
V1 = VECTOR(L1)
returns:
V1 = 0.169031,0.845154,-0.507093
VECTOR(POINT) Specify as a predefined point. If:
P1 = POINT(1,0,1)
and:
V1 = VECTOR(P1)
IMSpost will normalize the vector to:
V1 = 0.707,0,0.707
VECTOR(POINT,POINT) Take the difference between two points and normalize
the vector.
P1 = POINT(3,0,9)
P2 = POINT(2,5,6)
V1 = VECTOR(P1,P2)
returns:
V1 = 0.169031,0.845154,-0.507093
VECTOR(VECTOR) Predefined vector. If:
V1 = VECTOR(0,0,1)
and:
V2 = VECTOR(V1)
then:
V2 = V1
VECTOR(X1,Y1,Z1,X2,Y2,Z2) Take the difference between two points, and normalize
the vector. If:
V1 = VECTOR(3,0,9,2,5,6)
returns:
V1 = -.845145,0.169031,0.507093
MACHINE Variables
Each programmable axis of the machine has a set of variables associated with it. Most of these
variables are set within the Machine Motion feature.
Variable Description
[Link] = "LINEAR" for linear axis
= "ROTARY" for rotary axis. This variable cannot be
Variable Description
changed within the macro language. It can only be read.
[Link] = 1 Check against minimum limit
= 0 Do not check
[Link] = 1 Check against maximum limit
= 0 Do not check
[Link] Maximum allowable federate. For example:
MACHINE.Z = 3000
[Link] Axis output as incremental:
=0 for No
=1 for Yes
[Link] Contains specified horsepower.
[Link] Minimum limit. For example:
[Link] = -20.0
[Link] Maximum limit. For example:
[Link] = 3000.0
[Link]. Current absolute machine position. For example:
MACHINE.X = 0.0
[Link] =0 Output to error file
[Link] =0 Do not move axis to home position during tool changes
= 1 Move axis to home position for tool changes
[Link] = 0 Do not use RTCP mode for rotary motion
= 1 Use RTCP mode for rotary motion
[Link] =0 Enable axis
=1 Lock axis (for all motion)
[Link] =0 Enable movement along linear axis
=1 Disable movement along linear axis
[Link] =0 Enable movement along rotary axis
=1 Disable movement along rotary axis
[Link] Specify absolute machine home position (used in tool
changes). For example:
[Link] = 4500
[Link] Instructs IMSpost that the controller will determine the
shortest direction. For example:
[Link] = 1
[Link] Normally used for indexing tables. For example, if the
indexer can only move in increments of 2.5:
[Link] = 2.5
[Link] Specify minimum increments necessary for movement
(default = 0).
[Link] Current absolute machine position. For example:
[Link] = 0.0
[Link] Delta motion for axis. For example:
[Link] = 5
Variable Description
[Link] Current absolute machine position. For example:
[Link] = 500.5
MODE Variables
MODE (or Group) variables are used by IMSpost to categorize certain functions. For example,
the functions M3,M4, and M5 would be assigned to [Link], and functions like G0,
G1, G2, and G3 would be assigned to [Link]. This idea is very similar to the way
these codes work within your controller. M3 would stay in effect until cancelled by an M4 or M5.
IMSpost uses MODE variables to update controller and machining conditions to the post.
A standard IMS library postprocessor comes with a variety of default MODE variables, but you
can easily modify these or create your own.
Here is a list of the standard MODE variables. The function that is associated with them is
dependent upon which library postprocessor was selected and what is entered in its respective
dialog.
[Link] = "POSITION" (G0)
[Link] = "LINEAR" (G1)
[Link] = "CLW" (G2)
[Link] = "CCLW" (G3)
[Link] = "CYCLE" ; See [Link] below
REGISTER Variables
Each register that is defined in the Register Format Table, contains the following descriptions:
Variable Description
[Link] Name of letter address. For example:
[Link]="X"
[Link] Current value in register. For example:
[Link] = 2000
[Link] MM or INCH
[Link] Unit (mm or inch) for input. For example:
[Link] = "MM"
[Link] Unit (mm or inch) for output. For example:
[Link] = "MM"
[Link] Number format definition. For example:
[Link] = 4.0
[Link] Number of whole numbers in format.
[Link] Number of decimal places in format.
[Link] Minimum allowable value (this is a controller number and
not a machine limitation). See MACHINE Variables.
[Link] Maximum allowable value (this is a controller number and
not a machine limitation). See MACHINE Variables.
[Link] How to output leading zeros:
"N" for No, "Y" for Yes, or 1 through 4 to specify a
minimum of leading zeros to output.
[Link] Contains data on how to output leading zeros:
"N" for No, "Y" for Yes, or 1 through 4 to specify a
minimum of trailing zeros to output.
[Link] Character to be used for decimal point. For example:
[Link]="."
[Link] Unique formula for register. For example:
Variable Description
[Link] = "?+100"
(T-code = tool number + 100)
[Link] Output + sign:
"N" for No or "Y" for Yes
[Link] How to output value of zero. For example:
[Link]="0.0"
[Link] Use minimum limits set within controller register (these are
not the same as machine limits). See MACHINE Variables.
"N" for No or "Y" for Yes
[Link] Use maximum limits set within controller register (these
are not the same as machine limits). See MACHINE
Variables.
"N" for No or "Y" for Yes
[Link] = "N" for output axis as absolute
= "Y" for output axis as incremental
[Link] Name of table that register is associated with.
[Link] Is register modal:
"N" for No or "Y" for Yes
[Link] Last or previous value in register.
[Link] Did register change?
0 = No or 1 = Yes
[Link] Delta difference from current and last values.
[Link] Absolute value for register.
[Link] Initial value of register at start-up.
[Link] Specify characters to be output before registers value.
[Link] Specify characters to be output after registers value.
[Link] Specify character to output for decimal point. For example:
[Link] = "."
[Link] Output a decimal point with an integer:
"F" for register format, "Y" for Yes, or "N" for No
[Link] Output space between letter and value:
0 = No or 1 = Yes
[Link] Report to log file if value out of limits:
0 = No or 1 = Yes
[Link] Force out the current value:
0 = No or 1 = Yes
[Link] Set minimum resolution. Enter number of decimal places.
[Link] Contains name change of register when in incremental
mode. For example:
[Link]="/X"
[Link] = "S3"
[Link] = "O"
[Link] = "R-"
When a register is changed, it will remain in effect until changed back to its original definition.
SPINDLE Variables
The macro variables used by this dialog, with default settings and description, are as follows:
Variable Description
GLOBAL.SPINDLE_BLOCK = 1 0 = Output on a block itself
1 = Output codes with next motion
GLOBAL.SPINDLE_REG = "S" Register used for spindle speed value.
GLOBAL.SPINDLE_DIR = 'CLW' Current spindle direction.
GLOBAL.SPINDLE_RPM = 100.000 Default spindle speed at startup.
GLOBAL.SPINDLE_DEF = 'CLW' Default spindle direction at startup.
[Link] : M3 MODE/GROUP+ FUNCTION attached to spindle
clockwise rotation.
[Link] : M4 MODE/GROUP+ FUNCTION attached to spindle
anti-clockwise rotation.
[Link] : M5 MODE/GROUP+ FUNCTION attached to spindle is
off.
SYSTEM Variables
SYSTEM variables are:
Variable Description
[Link] Number of digits of accuracy for internal calculations.
SYSTEM.ADD_APT_TO_ISO Character(s) to add to beginning of APT statement when
outputting APT statements to output file. Works with:
SYSTEM.OUT_APT_TO_ISO = 1
SYSTEM.ADD_APT_TO_ISO_END Character(s) to add to the end of APT statement when
outputting APT statements to output file. Works with:
SYSTEM.OUT_APT_TO_ISO = 1
SYSTEM.ADD_LENGTH Machine axis that tool length is added to (Z).
SYSTEM.ADD_LENGTHX Machine axis that tool length is added to (X).
SYSTEM.ADD_LENGTHY Machine axis that tool length is added to (Y).
[Link] APT card in IBM360/370 CLFILE.
SYSTEM.APT_LINE The current APT line command read from the file or from
the test dialog.
SYSTEM.APT_RLINE In case of using CLREAD, this variable holds the last
statement read by the CLREAD command.
SYSTEM.ARCFIT_EXACT ARC-FIT ends point must be on arc.
SYSTEM.ARCFIT_MAXRAD ARC-FIT maximum radius.
Variable Description
SYSTEM.ARCFIT_MINANG ARC-FIT minimum angle.
SYSTEM.ARCFIT_MINRAD ARC-FIT minimum radius.
SYSTEM.ARCFIT_POINTS ARC-FIT minimum number of points (must be greater
than 3).
SYSTEM.ARCFIT_TOLRAD ARC-FIT maximum tolerance allowed from arc radius.
SYSTEM.ARCFIT_TOLPLN ARC-FIT maximum tolerance allowed of each point from
arc plane.
SYSTEM.AUTO_RETRACT 0 = Disable AUTO_RETRACT
1 = Enable AUTO_RETRACT
SYSTEM_AUTO_RETRACT_ANGLE When using the AUTO_RETRACT feature (see Machine
Multi-Axis), this variable holds the maximum deviation
allowed from the angle between the last vector specified
in the last GOTO/x, y, z, i, j, k and the current GOTO/x,
y, z, i, j, k where the i, j, k defined the vectors.
This variable can be either real number or a string which
represents a percentage.
For a real number, it specifies the deviation from the
angle between the two vectors.
For a string, the value should be preceded by a
percentage sign. For example, to specify the maximum
deviation in percentage from the given angle:
SYSTEM.AUTO_RETRACT_ANGLE = "%12"
SYTEM.AUTO_RETRACT_OUT Delta retraction distance. Refer to the Auto retract option
on the Multi-axis dialog. See MACHINE > Multi-axis >
Multi-axis Setup.
SYSTEM.AUTO_RETRACT_SAFE When using the AUTO_RETRACT feature (see Machine
Multi-Axis), this variable holds the clearance distance.
[Link][n] n = 1 thru 15 for a list of motion axis names.
SYSTEM.BEST_SOLUTION =1 Activate (one-shot). This is the best start-up position
for a 5-axis machine
SYSTEM.BEST_START_COMMAND APT word to be used for the beginning boundary for the
best-solution look-ahead process.
SYSTEM.BEST_START_REPEAT Number of times to locate the start boundary (default =
1).
SYSTEM.BEST_END_COMMAND APT word to be used for the ending boundary for the
best-solution look-ahead process.
SYSTEM.BEST_END_REPEAT Number of times to locate the end boundary (default = 1).
SYSTEM.BLOCK_BEGLINE Holding the variable from the Tape Format Output at the
start of each block.
SYSTEM.BLOCK_ADD Holding the variable from the Tape Format Output at the
end of each block.
SYSTEM.BREAK_LINE_A Linear break; angle to the next position.
SYSTEM.BREAK_LINE_COUNT Number of points in linear break.
Variable Description
SYSTEM.BREAK_LINE_COND[1] Condition expression for Line 1 in the Linear Equation
Formula.
SYSTEM.BREAK_LINE_COND[2] Condition expression for Line 2 in the Linear Equation
Formula.
SYSTEM.BREAK_LINE_COND[3] Condition expression for Line 3 in the Linear Equation
Formula.
SYSTEM.BREAK_LINE_COND[4] Condition expression for Line 4 in the Linear Equation
Formula.
SYSTEM.BREAK_LINE_COND[5] Condition expression for Line 5 in the Linear Equation
Formula.
SYSTEM.BREAK_LINE_CUR_F Linear break; feed value.
SYSTEM.BREAK_LINE_CUR_S Linear break; spindle rpm value.
SYSTEM.BREAK_LINE_EXP[1] Linear break; break expression one.
SYSTEM.BREAK_LINE_EXP[2] Linear break; break expression two.
SYSTEM.BREAK_LINE_EXP[3] Linear break; break expression three.
SYSTEM.BREAK_LINE_FED[4] Linear break; break expression four.
SYSTEM.BREAK_LINE_FED[5] Linear break; feed expression five.
SYSTEM.BREAK_LINE_L1 Linear break; length of line to the current point.
SYSTEM.BREAK_LINE_L2 Linear break; length of line from the current to the next
point.
SYSTEM.BREAK_LINE_MUL[1] Linear break; reps for the first break expression.
SYSTEM.BREAK_LINE_MUL[2] Linear break; reps for the second break expression.
SYSTEM.BREAK_LINE_MUL[3] Linear break; reps for the third break expression.
SYSTEM.BREAK_LINE_MUL[4] Linear break; reps for the fourth break expression.
SYSTEM.BREAK_LINE_MUL[5 Linear break; reps for the fifth break expression.
SYSTEM.BREAK_LINE_SPD[1] Linear break; spindle speed expression one.
SYSTEM.BREAK_LINE_SPD[2] Linear break; spindle speed expression two.
SYSTEM.BREAK_LINE_SPD[3] Linear break; spindle speed expression three.
SYSTEM.BREAK_LINE_SPD[4] Linear break; spindle speed expression four.
SYSTEM.BREAK_LINE_SPD[5] Linear break; spindle speed expression five.
SYSTEM.BREAK_LINE_X[0] Linear break; X last position.
SYSTEM.BREAK_LINE_X[1] Linear break; X current position.
SYSTEM.BREAK_LINE_X[2] Linear break; X next position.
SYSTEM.BREAK_LINE_Y[0] Linear break; Y last position.
SYSTEM.BREAK_LINE_Y[1] Linear break; Y current position.
SYSTEM.BREAK_LINE_Y[2] Linear break; Y next position.
SYSTEM.BREAK_LINE_Z[0] Linear break; Z last position.
SYSTEM.BREAK_LINE_Z[1] Linear break; Z current position.
SYSTEM.BREAK_LINE_Z[2] Linear break; Z next position.
[Link] This flag is set to 1 if there is output pending in the
output buffer.
Variable Description
SYSTEM.BUFFER_APT Read and store the APT file in the buffer before
execution.
0 = No or 1 = Yes
[Link] Number representing the type of circular interpolation
selected with the Circle feature.
=1 Absolute center and endpoint
=2 Distance from start to center and endpoint
=3 Unsigned distance from start to end and endpoint
=4 Radius and endpoint
=5 Center, radius, and end angle
=6 Circles not allowed (postprocessor simulates circle
with linear motion
SYSTEM.CIRCLE_ANGLE Letter address that represents the angle of the endpoint
(IMS Controller Emulator only).
SYSTEM.CIRCLE_CENTER_X Enter letter address for circle center along X axis (I).
SYSTEM.CIRCLE_CENTER_Y Enter letter address for circle center along Y axis (J).
SYSTEM.CIRCLE_CENTER_Z Enter letter address for circle center along Z axis (K).
SYSTEM.CIRCLE_MAX_CHORD Holds the variable from the Circle feature. Maximum
chord length limits the linear break of a circle to a line
such that one segment (chord) will not exceed this value.
If 0.0, ignore this limitation.
SYSTEM.CONTROLLER_RTCP Controls use of RTCP option (if RTCP is not in the CUT
statement).
SYSTEM.COORD_RTCP Holds the variable from the Machine Multi-Axis feature.
Use the RTCP output checkbox.
=0 Rotation tables effect the calculation of the linear
moves
=1 Does not affect the calculation of the linear moves
SYSTEM.CIRCLE_RADIUS Enter letter address.
SYSTEM.CIRCLE_SIGN Output negative sign for circle center (can be NO or
YES).
SYSTEM.CIRCLE_TOLER Tolerance for linear approximation.
SYSTEM.CIRCLE_ANGLE Holds the name of the register specifying the ANGLE OF
THE END POINT IN arcs command for the IMS
Controller Emulator. This is used only for:
[Link] = 5
SYSTEM.CIRCLE_RADIUS Holds the name of the register specifying the RADIUS of
arcs command for the IMS Controller Emulator.
SYSTEM.CIRCLE_CENTER_X Holds the name of the register specifying the CENTER
usually along the X axis of arcs command for the IMS
Controller Emulator.
SYSTEM.CIRCLE_CENTER_Y Holds the name of the register specifying the CENTER
usually along the Y axis of arcs command for the IMS
Controller Emulator,
Variable Description
SYSTEM.CIRCLE_CENTER_Z Holds the name of the register specifying the CENTER
usually along the Z axis of arcs command for the IMS
Controller Emulator.
SYSTEM_CIRCKIND Specify the circular interpolation method ( for the IMS
Controller Emulator only).
= 1 Absolute center and end point
= 2 Distance from start to center and end point
= 3 Unsigned distance from start to end and end point
(quadrant boundary)
= 4 Radius and end point
= 5 Center, radius, and end angle
= 6 Circles not allowed (created with linear moves)
[Link] Variable containing current circular interpolation output
format (0 – 6,10).
[Link] Input file type processing. CAM system represented by
integer.
[Link] CLDATA card in IBM360/370 format.
[Link] Part (APT/CL) name and path name where the part file
resides.
SYSTEM.CODE_SPACE Output space between codes: 0 for No or 1 for Yes
[Link] Check validity of IF statements in posts macros:
= 0 and IF statements are not valid, IMS system will
accept statements.
=1 and IF statements are not valid, IMS system will
ignore IF statements and all statements associated
with its true condition.
SYSTEM.CON_DELMEMORY Value in kilobytes required for the start and end strings
added for file breakup.
SYSTEM.CON_MEMORY Value in kilobytes of the number of bytes that can be
output into a file before a new file is started.
SYSTEM.CON_NOBLOCKS Size of file based on the number of blocks.
SYSTEM.CON_TOOLLIFE Size of file based upon the tool life.
SYSTEM.CONTROLLER_AUTO_ If not 0, the controller keeps the tool tip on a straight line
LINTOL when the rotary axis moves.
SYSTEM.CONTROLLER_AUTO_ Step angle used for keeping the tool tip on a straight line
LINTOL_STEP with rotary motion.
SYSTEM.CONTROLLER_RTCP Controls use of RTCP option, when RTCP does not exist
in the CUT statement.
SYSTEM.COORD_RTCP Controls Rotating Tool Center Point within the
postprocessor (must be supported within the controller):
= 0 Rotation tables effect the calculation of the linear
moves.
= 1 Does not affect the calculation of the linear moves.
Variable Description
SYSTEM.CURVE_TOLER Specify curve tolerance (default = 0). If greater than 0,
system performance could be slower for 5-axis
machining based on this value.
[Link] Enter current cutter compensation mode.
[Link] CUTCOM length status: "OFF" or "ON"
SYSTEM.CUTCOM_LENGTH Enter length value.
SYSTEM.CUTCOM_LENGTHX Contains the value used in tool length compensation
along X.
SYSTEM.CUTCOM_LENGTHY Contains the value used in tool length compensation
along Y.
SYSTEM.CUTCOM_OFFSET Defines the radius of the tool for contact point
calculation.
SYSTEM.CUTCOM_X_NAME Name of register representing X-axis coordinate in 3D
cutter compensation.
SYSTEM.CUTCOM_Y_NAME Name of register representing Y-axis coordinate in 3D
cutter compensation.
SYSTEM.CUTCOM_Z_NAME Name of register representing Z-axis coordinate in 3D
cutter compensation.
SYSTEM.CUTTER_DIAM Contact point diameter for the corner radius cutter.
SYSTEM.CUTTER_LEN Contact point length for the corner radius cutter.
SYSTEM.CUTTER_RAD Contact point radius for the corner radius cutter.
[Link] Flag used for checking to determine if a series of linear
points form a circular motion. If 1, then the check is
done; if 0 (default), check is not done.
[Link] Current date.
[Link] Number of digits of accuracy to be used for internal
calculations of XYZ only (default is 4).
SYSTEM.DIGITS_IJK Minimum factor to be used when truncating IJK vectors.
For example:
SYSTEM.DIGITS_IJK = 4
This instructs IMSpost to truncate IJK vectors to the 4th
decimal place (default = 0, no truncation factor).
SYSTEM.DISPLAY_RETURN Return from display dialog (default is 30 seconds).
SYSTEM.END_FILE When ISO output is written to multiple output files,
output this string at the end of each new output file.
[Link] Number of errors reported to the log file.
[Link] Current feed rate used for machine time calculations.
SYSTEM.FEED_LAST Last feedrate used for the acceleration/deceleration
application.
[Link] Current feed mode.
SYSTEM.FEEDRATE_NAME Register name for feed value.
SYSTEM.FILE_LINES_COUNT Contains number of lines written to the ISO file.
Variable Description
SYSTEM.FILE_SIZE Holds the current size of the ISO output file (bytes). For
example:
SYSTEM.FILE_SIZE/1024 = kbytes
SYSTEM.FORCE4AXES For 4-axis milling machine only:
If not 0, IMSpost will force the tool vector (I,J,K) to be
on the plane of the rotary axis.
SYSTEM.FORCE_WAY Holds the variable from the Machine Multi-Axis setup
solution condition.
SYSTEM.GET_ISO_LINES Defines the number of previous ISO blocks to retrieve
from the output buffer.
[Link] Show moves in the graphic module:
0 for No or 1 for Yes
SYSTEM.GRAPHIC_STEP Longest move step when showing the moves.
SYSTEM.GRAPHIC_WAIT Delay time in seconds when showing the moves in the
graphic module.
SYSTEM.GOTO_SOLUTION Force GOTO solution to choose the solution number:
0 = no force, 1 = force first, 2 = force second
This is used to force a specific SOLUTION for multi-axis
motion.
[Link] Helical interpolation allowed: 0 for No or 1 for Yes
SYSTEM.INV_TIME_FORMULA Contains the formula to be used for inverse/time feed
number calculation.
SYSTEM.ISO_APT_COMP = 0 Do not calculate the coordinate for the machine with
regard the cutter compensation. (G41,G42 & D
value — IMS Controller Emulator only).
= 1 Calculate the coordinate for the machine with regard
to cutter compensation (G41,G42 & D value).
SYSTEM.I Last given I value in GOTO and CIRCLE solutions.
[Link] Input/Output status variable (0 or 1).
SYSTEM.J Last given J value in GOTO or CIRCLE solutions.
SYSTEM.K Last given K value in GOTO or CIRCLE solutions.
SYSTEM.LINEFIT_TOLER Maximum tolerance allowed of each point from the line.
SYSTEM.LINTOL_TYPE For continuous multi-axes machine when LINTOL/ON is
used for keeping small deviation from a straight line cut.
0 Create segments of moves by dividing the given APT
vector to smaller change in vectors.
1 Create segments of moves by dividing the machine
angles (AXIS A, B, C, etc) to smaller change in
angles. This method will result with equal change of
the angles axis in each segment.
SYSTEM.LINTOL_TOOL_LENGTH Not supported at this time. Reserved for future use.
[Link] Multi-axis LINTOL condition: 0 = Off or 1 = On
SYSTEM.LINTOL_DIRECTION Force GOTO solution to use the same solution as in the
Variable Description
previous LINTOL solution.
SYSTEM.LINTOL_LINEAR Multi-axis linearization value (linear axes).
SYSTEM.LINTOL_ROTARY Multi-axis angular deviation value (rotary axes).
SYSTEM.LINTOL_TOOL_LENGTH Tool length for linearization tolerance calculation.
SYSTEM.LINTOL_ROTARY Multi-axis angular deviation value (rotary axes).
SYSTEM.LIN_ROT_INV_TIME = 1 Activate inverse time feed formula for motion that
contains both linear and rotary motion.
SYSTEM.LIN_INV_TIME = 1 Activate inverse time feed formula if motion
contains linear motion only.
[Link] Output statement should write to list file:
0 = No or 1 = Yes
[Link][n] Local coordinate system offset values (n = 1 – 15).
[Link] Name of list output file.
SYSTEM.MAT1F[n] System matrix variable ( n = 1 – 15).
SYSTEM.MAT2F[n] System matrix variable ( n = 1 – 15).
SYSTEM.MATRIX1 Specifies the type of matrix calculation for MATRIX1:
= 0 Matrix1 is off
= 1 Multiply XYZIJK (point and vector) by MATRIX1
before calculating the solution
= 2 Multiply XYZ (point) by MATRIX1 before
calculating the solution
= 3 Multiply IJK (vector) by MATRIX1 before
calculating the solution
= -1 Multiply XYZIJK (point and vector) by the inverse
of MATRIX1 before calculating the solution
= -2 Multiply XYZ (point) by the inverse of MATRIX1
before calculating the solution
= -3 Multiply IJK (vector) by the inverse of MATRIX1
before calculating the solution
SYSTEM.MATRIX2 Specifies type of matrix calculation for MATRIX2:
= 0 Matrix2 is off
= 1 Multiply XYZIJK (point and vector) by MATRIX2
before calculating the solution
= 2 Multiply XYZ (point) by MATRIX2 before
calculating the solution
= 3 Multiply IJK (vector) by MATRIX2 before
calculating the solution
= -1 Multiply XYZIJK (point and vector) by the inverse
of MATRIX2 before calculating the solution
= -2 Multiply XYZ (point) by the inverse of MATRIX2
before calculating the solution
= -3 Multiply IJK (vector) by the inverse of MATRIX2
before calculating the solution
SYSTEM.MATRIX1A[n] Specify the MATRIX1 value for row A, column n; where
n can be 1 through 4.
Variable Description
SYSTEM.MATRIX1B[n] Specify the MATRIX1 value for row B, column n; where
n can be 1 through 4.
SYSTEM.MATRIX1C[n] Specify MATRIX1 value for row C, column n; where n
can be 1 through 4.
SYSTEM.MATRIX2A[n] Specify MATRIX2 value for row A column n; where n
can be 1 through 4.
SYSTEM.MATRIX2B[n] Specify MATRIX2 value for row B column n; where n
can be 1 through 4.
SYSTEM.MATRIX2C[n] Specify MATRIX2 value for row C column n; where n
can be 1 through 4.
[Link] Enter maximum arc angle per block (90, 360).
SYSTEM.MAX_CSS Maximum constant surface speed.
[Link] For IMS Controller Emulator only:
Enables you to split one move into a series of smaller
moves.
SYSTEM.MAX_GCODE Maximum number of G-codes in one block (0 for no
limit).
SYSTEM.MAX_MCODE Maximum number of M-codes in one block (0 for no
limit).
[Link][n] n can be 1 thru15 representing each of the programmable
machine axes.
[Link] For IMS Controller Emulator only:
Each time a machine motion is detected, this variable will
be set to non-zero.
[Link] Machine time (includes tool changes, dwells, and
positioning).
SYSTEM.MTIME_CUT Machine cut time.
SYSTEM.MTOOL_TIME Tool cut time.
[Link] Multax processing flag.
[Link] For IMS Controller Emulator only:
This variable is one of the most important variables in the
IMS Controller Emulator. The system will automatically
set it to non-zero if there is a machine axis in the current
block (G1 XYZ). However, if in the current block there is
a function defined in the grammar section of the
functions that a motion is not allowed (such as G4 X),
then the [Link] variable will remain ZERO.
This variable is updated for every block parsed by the
IMS Controller Emulator.
[Link] Component along the X axis normal to the surface (for
calculating the tip point from contact).
SYSTEM.NORMALX_LAST Previous component along X axis normal to the surface
(for calculating tip point and 3D cutter compensation).
[Link] Component along the Y axis normal to the surface (for
calculating the tip point from contact).
Variable Description
SYSTEM.NORMALY_LAST Previous component along the Y axis normal to the
surface (for calculating the tip point and 3D cutter
compensation.)
[Link] Component along the Z axis normal to the surface (for
calculating the tip point from contact).
SYSTEM.NORMALZ_LAST Previous component along the Z axis normal to the
surface (for calculating the tip point and 3D cutter
compensation).
[Link] Specify minimum number of points for converting
GOTO points to an arc.
SYSTEM.NURBS_ANGLE Angular value used to break up splines.
SYSTEM.NURBS_DEVIATION Angular deviation value to start the new curve based on
angle sharpness.
SYSTEM.NURBS_ORDER Nurbs maximum order between 2-4.
SYSTEM.NURBS_TOLER Nurbs tolerance.
SYSTEM.NURBS_TOLER_ANG Nurbs tolerance band for IJK vectors.
SYSTEM.NURBS_TYPE Enter nurbs type (0, 1, 2, 3, 4):
= 0 Nurbs/spline not supported by this controller. All
NURBS commands will convert to segments of a
line in the tolerance specified in the Motion Nurbs
feature.
= 1 Controller support nurbs format control points,
notes, and weight (Fanuc, Siemens).
= 2 Controller support spline format with polynominals
from left to right.
= 3 Controller support spline format with polynominals
from right to left (Heidenhain style).
= 4 Controller support Bezier format.
[Link][n] n n can be 1 thru15 representing an offset for each of the
programmable machine axes.
SYSTEM.OUT_APT_TO_ISO = 1 Output APT statement to machine code file
= 0 Do not output (default).
[Link] Operating system (WIN, VMS, or UNIX).
[Link] Not in use at this time.
SYSTEM.OVERLAP_ANGLE = 1 Allow overlap angle of rotary axes limits.
[Link] Output listing page number.
[Link] Current plane in effect (XY).
SYSTEM.PLANE_X Register name applied to XY plane (X).
SYSTEM.PLANE_Y Register name applied to YZ plane (Y).
SYSTEM.PLANE_Z Register name applied to ZX plane (Z).
[Link] (Special for Prelude Mfg.) Generate debug commands as
APT statements.
Variable Description
[Link] For IMS Controller Emulator only:
Use polar coordinates.
[Link] For IMS Controller Emulator only:
Polar coordinate angle.
[Link] For IMS Controller Emulator only:
Polar coordinate radius.
SYSTEM.POLAR_CENTER_X For IMS Controller Emulator only (not IMSpost).
SYSTEM.POLAR_CENTER_Y For IMS Controller Emulator only (not IMSpost).
SYSTEM.POLAR_CENTER_XNAME Register name applied to X center of polar coordinate.
SYSTEM.POLAR_CENTER_YNAME Register name applied to Y center of polar coordinate.
[Link] Name of project file.
SYSTEM.RAD_CSS Maximum CSS radius.
SYSTEM.RAPID_INV_TIME How to control rapid in inverse time mode:
= 1 Postprocessor will output G0 code in G93 mode
= 0 Postprocessor will switch back to G94 mode for
rapid motion and switch back to G93 if necessary.
SYSTEM.ROT_INV_TIME = 1 Activate inverse time formula if motion only
contains rotary motion.
[Link] Used in 5-axis tool length calculations: 0 = Off or 1 = On.
SYSTEM.SAVE_ISO_LINES Specify number of ISO blocks to retrieve from the output
buffer.
[Link] Write OUTPUT commands to the terminal (not active).
[Link] Contains the last sequence number.
SYSTEM.SEQNO_INCR Sequence number increment value.
SYSTEM.SEQNO_ON Controls sequence block output:
0 = SEQNO is Off
1 = SEQNO is On
SYSTEM.SHORT_WAY_METHOD For multi-axes machine in MULTAX mode. There are
two options to define how IMSpost chooses the preferred
solution (in the SOLUTION/GOTO command as well as
in the internal code):
= 0 Check the length of the move the tools tip is doing
and choose the shortest one.
= 1 Check the angles the rotary axes rotates and choose
the shortest one.
[Link] For IMS Controller Emulator only:
The current spindle speed.
SYSTEM.SOL_NUMBER_LIMIT Processed from the SOLUTION(LINTOL) statement. If
SYSTEM.SOL_NUMBER_FINAL the Auto Retract sequence is in effect, these variables are
passed to the AUTO_RETRACT/* macro where a proper
motion route is determined.
SYSTEM.SOLUTION_NUMBER Force multi-axis SOLUTION type in LINTOL
processing.
Variable Description
[Link] Current spindle speed. This is used for machine time
calculations.
SYSTEM.SPINDLE_NAME Register name for spindle speed value.
SYSTEM.START_END_RAD Maximum deviation allowed between start/end to the
circle center (0.0 to ignore).
SYSTEM.STR_FILE When ISO output is written to multiple output files,
output this string at the start of each new output file.
[Link] Flag to set whether linear motion should be handled by
special internal processing rather than by the GOTO
macro:
1 = On (internal processing)
0 = Off (use GOTO macro)
SYSTEM.TABLE_FILES Number of exterior table files to read in ( default = 0).
[Link] Output statement should write to NC file: “ON" or "OFF"
[Link] Path and name of the ISO output file.
SYSTEM.TAPE_LENGTH Length of tape characters.
[Link] Current time.
SYSTEM.TIME_CALCULATION = 0 Do not update system machine time
([Link])
= 1 Update system machine time
SYSTEM.TIP_CONTACT Tool tip/contact options:
0 for input tip = output tip
1 for input contact = output contact
2 for input contact = output tip
SYSTEM.TOOL_LENGTH Variable containing the tool length value that will be used
when necessary in MULTAX calculations.
SYSTEM.TOOL_LENGTHX Contains tool length value that may be used in various
MULTAX calculations.
SYSTEM.TOOL_LENGTHY Contains tool length value that may be used in various
MULTAX calculations.
SYSTEM.TOOL_LENGTHZ Contains tool length value that may be used in various
MULTAX calculations.
SYSTEM.TOOL_WITH Instructs the postprocessor as to how to calculate the tool
axis:
= 1 Tool Tip
= 2 Tool Center
= 3 Spindle Face (as if the tool length is zero length)
= 4 RTCP point (for now, the same as option 3)
[Link] Software version.
[Link] Number of warnings reported to the log file.
SYSTEM.X Last given X value in GOTO or CIRCLE solutions.
SYSTEM.X_ARC_CENTER Current circle center along X.
SYSTEM.X_ARC_CENTER_LAST Previous circle center along X.
Variable Description
SYSTEM.X_ARC_DIR Current arc direction along X.
SYSTEM.X_ARC_DIR_LAST Previous arc direction along X.
SYSTEM.X_LAST Previous X value calculated from GOTO or CIRCLE
SOLUTION record.
SYSTEM.Y Last given Y value in GOTO and CIRCLE solutions.
SYSTEM.Y_ARC_CENTER Current circle center along Y.
SYSTEM.Y_ARC_CENTER_LAST Previous circle center along Y.
SYSTEM.Y_ARC_DIR Current arc direction along Y.
SYSTEM.Y_ARC_DIR_LAST Previous arc direction along Y.
SYSTEM.Y_LAST Previous Y value calculated from GOTO or CIRCLE
SOLUTION record.
SYSTEM.Z Last given Z value in GOTO or CIRCLE solutions.
SYSTEM.Z_ARC_CENTER Current circle center along Z.
SYSTEM.Z_ARC_CENTER_LAST Previous circle center along Z.
SYSTEM.Z_ARC_DIR Current arc direction along Z.
SYSTEM.Z_ARC_DIR_LAST Previous arc direction along Z.
SYSTEM.Z_LAST Previous value calculated from GOTO or CIRCLE
SOLUTION record.
GLOBAL.TOOLCHG_TIME
Overview
Working planes are an advanced functionality on many modern controllers that allow for using
certain codes that were previously reserved only for orientation along a major plane
(G17,G18,G19) even when the tool is not oriented along one of these planes. These types of
codes include cutter compensation, canned cycles, and circles. They work by providing the
controller with the mathematic definition of another plane on which paths and cycles can be
defined and cut.
Usually CAM systems generate the tool path file (APT, CLD) in one physical coordinate system.
This physical coordinate system usually represents the part coordinate system with respect to the
machine coordinate system. However, this single coordinate system only has three planes
associated with it (XY, YZ, XZ). If the head of the machine is tilted, the path may not lie along
any of these planes. In order to cut the material with certain controller modes, you need to work
normal to a plane; so if it is not one of the major planes, you need to define one.
This allows the controller to see all points as if the coordinate system lies on that particular plane.
It is effectively the same as if all programming was done on the XY-plane as defined in the
controller. With this technique, the controller first applies the compensation to the given points
and then converts the points back to the physical coordinate system using the pre-definition of the
plane. For the definition of the plane, the controller uses a sequence of rotations about vectors that
relate the physical coordinate system to a specific plane.
NC File
In the NC file, the working plane is defined by calling a specific code to signify that working
plane mode has been turned on. In addition, listed in the working plane are the angles of rotation
and the vectors about which the angles are rotating. The offset of the origin also can be listed. The
specific call can vary between types of controller and even between generations.
Ex. (Makino Tilted Working Plane) G68.2 X0. Y5. Z0. I90. J45. K0.
This call notes that working planes have been turned on and a new coordinate system in which
the controller will work has an origin that is 5 units from the origin of the original coordinate
system. In addition, the coordinate system is defined by a rotation of 90 degrees about one vector
and then 45 degrees about another.
Manual Implementation
Rather than having the post calculate the working plane matrix, it is possible to specify the
working plane matrix that you want the post to apply to all the calculations. This can be done by
passing the WPLANE function the matrix that you want to apply.
WPLANE(MATRIX,SYSTEM.WPLANE_MAT.A[1],SYSTEM.WPLANE_MAT.A[2],SYSTEM.WPLANE_MAT.
A[3],SOLUTION.X_VALUE,SYSTEM.WPLANE_MAT.B[1],SYSTEM.WPLANE_MAT.B[2],SYSTEM.
WPLANE_MAT.B[3],SOLUTION.Y_VALUE,SYSTEM.WPLANE_MAT.C[1],SYSTEM.WPLANE_MAT.C[2],
SYSTEM.WPLANE_MAT.C[3],SOLUTION.Z_VALUE,ONCE,1)
This line takes the current working plane matrix and switches and populates back the same matrix
with the exception that the third column is populated by the current Solution X,Y, and Z.
If you do not already know the matrix you want to apply, it is possible to calculate it based on a
working plane Solution statement.
Notes