Getting Started with PostHASTE

background image

Getting Started

with the PostHASTE

Postprocessor

Gibbs and Associates

323 Science Drive

Moorpark, CA 93021

October 2003

background image

ProprietaryNotice

This document contains propriety information of Gibbs and Associates and is to be used only pursuant to and
in conjunction with the license granted to the licensee with respect to the accompanying Gibbs and Associates
licensed software. Except as expressly permitted in the license, no part of this document may be reproduced,
transmitted, transcribed, stored in a retrieval system, or translated into any language or computer language, in
any form or by any means, electronic, magnetic, optical, chemical, manual or otherwise, without the prior
expressed written permission from Gibbs and Associates or a duly authorized representative thereof.

It is strongly advised that users carefully review the license in order to understand the rights and obligations
related to this licensed software and the accompanying documentation.

Use of the computer software and the user documentation has been provided pursuant to a Gibbs and Associ-
ates licensing agreement.

© 2003 Gibbs and Associates. All rights reserved. The Gibbs logo, GibbsCAM, GibbsCAM logo, Virtual
Gibbs, Gibbs SFP, MTM, Hole Wizard, SolidSurfacer, and “Powerfully Simple. Simply Powerful.”are
either trademark(s) or registered trademark(s) of Gibbs and Associates in the United States and/or other
countries. Windows is a registered trademark of Microsoft Corporation in the United States and other
countries. All other brand or product names are trademarks or registered trademarks of their respective
owners.

Acknowledgements:

Written by Paul Andrews

Thanks to Bill Gibbs and Wil Gaffga for their input and assistance.

Printed in the United States of America

Modified: October 24, 2003 1:30 pm

background image

Table of Contents

i

Ta b l e o f C o n t e n t s

GETTING STARTED WITH THE POSTHASTE POSTPROCESSOR 1

What this manual contains. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2

For more information… . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2

INSTALLING & RUNNING POSTHASTE 3

What is PostHASTE? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .4
Installation. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .4
To run PostHaste… . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .4
Using PostHaste for the first time & Setup . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .5

Setting up AutoOpen . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .6
Caution - Running PostHaste “again” . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .7

FORMATTING BASICS 8

How PostHaste works . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .9
Overall structure of the template file . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .9

Complete 4 axis mill format template.*. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .10
Details regarding the various template sections . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .11
Comments in the format . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .16

EXAMPLE: MODIFYING THE TOOLCHANGE SEQUENCE 17

GO FOR IT! 19

OVERALL SYSTEM CONFIGURATION 21

The PostHaste.CFG or Post.INI file . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .22

RECOMMENDED FORMAT FILE EXTENSIONS 24

background image

GETTING

STARTED WITH

THE POSTHASTE

POSTPROCESSOR

background image

Getting Started with the PostHASTE Postprocessor

2

CHAPTER 1

:

G e t t i n g S t a r t e d w i t h t h e

P o s t H A S T E P o s t p r o c e s s o r

WHAT THIS MANUAL CONTAINS

This manual will help you…

Install and run PostHASTE for the first time and configure it for your own use, and

Learn the basic concepts of making formatting changes.

This manual will guide you through your first time use of PostHASTE which may require a small amount of ‘setup’. (And
we do mean small. It typically takes less than 3 minutes.)

In this manual, we will only be dealing with post formats for 3 and 4 axis milling (.pM3 and .pM4 files) and 2 axis turning
(.pT2 files).

FOR MORE INFORMATION…

If you need to learn more details about modifying postprocessor

format templates

, then (after making sure that you first

understand the basic formatting concepts explained in this manual) please refer to the PostHASTE Formatting Reference
Manual.

T

I

P

For installation instructions, first see the document called The
Great 3-Minute Post-Processor Installation.

background image

INSTALLING &

RUNNING

POSTHASTE

background image

Installing & Running PostHaste

4

CHAPTER 2

:

I n s t a l l i n g & R u n n i n g

P o s t H a s t e

WHAT IS POSTHASTE?

PostHASTE (sometimes referred to as “the post” for short) is a software system that translates your CAM system’s tool
motion output (CL files) into ‘NC program’ (text or ‘ASCII’) files to drive NC or CNC machines. PostHaste can create
programs in any of these formats:

EIA standard:

EIA programs are the most common type of machine control files; they typically use G, X, Y, Z, T and/or M

codes (among others) for various machine movements and functions.

‘Conversational’:

Conversational programs are usually somewhat similar to EIA programs, but typically have words or phrases

(such as ‘LINE’ or ‘ARC’) in place of the standard letter codes.

Tab-sequential (or “columnar”):

These types of programs are not very common anymore, but are sometimes needed for older

(e.g. ‘Bandit’) or less expensive (such as Emco-Maier) machines. These programs have the various numerical values
arranged in columns (instead of using a letter); the location (or spacing) of the numbers within each line determines the
significance of the value. For example the first column may be an X position, the second column the Y position, and so on.

INSTALLATION

If you haven’t already, we recommend that you install PostHaste as instructed in the document called The Great 3-Minute
Post-Processor Installation. That will take you through setting up PostHaste for your initial use. (However, if you had
trouble setting up the AutoOpen feature, there are more details on that in the section below.)

TO RUN POSTHASTE…

Actually running PostHaste (generating an NC program file) is very simple.

Although the dialogs are very simple,

you may want to refer to the section below for important information regarding:

- folders and

- setting up the PostHaste’s AutoOpen feature (which will open your finished NC program in the editor of your choice once
the posting is complete).

T

I

P

Throughout this manual,

Mandatory steps that you must perform are written in bold underlined text.

Bold

text is used to emphasize

important information

.

background image

Installing & Running PostHaste

5

USING POSTHASTE FOR THE FIRST TIME & SETUP

To run PostHaste, just double-click the PostHaste icon wherever you see it (in the GS folder, from the Start
menu, or on your Desktop).

This will activate PostHaste, and

may

also bring up

other “information” dialogs like this…

…if this happens,

then answer the questions

appropriately

. (These are dialogs that the post

automatically presents to you in order to get
information required to create the finished NC
program.)

Then, one of two things will happen:

- You will either see your finished NC program appear in an editor window,

OR…

- You will see this AutoOpen message:

If you DO see your NC program in an editor

(that is, you do NOT see the above message),
then your system is already set to
automatically open your program files –
Congratulations!

You do NOT need to go

through the

Setting up AutoOpen

section

following.

background image

Installing & Running PostHaste

6

S

ETTING

UP

A

UTO

O

PEN

The dialog above appears if Windows does not know what application should be used to open your finished NC program.

This should only happen the very first time you create an NC program with PostHaste

– if you follow these instructions

to set up the AutoOpen feature:

After you

press OK on the above dialog

, a window like the one below will appear that contains your finished NC

program:

Just

double-click your NC program

in the above window,

and you will be presented with this dialog to let you choose
the application you want to use for editing your NC
program files:

Fill in the “Description” field

(you may put in any

description you like), then

use the scroll bar to find the

application you want to use

to view or edit your NC

programs. (You may use your favorite editor, WordPad -
whatever you like!), then

double-click on the application

.

Your program will then appear in that editor – and you’re done!

Important note re AutoOpen and Windows' File Associations

By setting up your system’s Windows'

File associations

, you can

set the

AutoOpen

feature to open a file with any application you

choose ( - a communications package, for instance, to send a NC
program to one of your machines).

If, at a later time, you want to change your system's
Windows'

File associations

, you can do this by…

1.

Open

Windows Explorer

2.

Click the

Folder Options

choice in

the

View

menu

.

background image

Installing & Running PostHaste

7

(In Windows 2000 and XP, the

Folder Options

choice is in

the

Tools

menu

.)

The

Open With

dialog shown above should appear.

3.

Find and select the file extension you wish to change and hit the REMOVE button.

4.

Close the dialog.

5.

In

Windows Explorer

again, just double-click the desired file and you will be taken once again to the

Open With

dialog,

where you may choose any application you like.

C

AUTION

- R

UNNING

P

OST

H

ASTE

AGAIN

If you’ve run PostHaste, then you’ve seen the main PostHaste window as shown below.

The four buttons along the bottom are pretty self explanatory, but

you

do

have to be careful about one thing – the

Post

Again

button

.

!

If you hit

Post Again

while your editing window is still open from the previous run, then the

code in your editor may NOT be updated to reflect any changes that you made the second
time you ran the post.

We highly recommend that you close your editor before “posting again”.

That way, when

the post ‘AutoOpens’ the file, it will indeed be your new code – not the code ‘left over’ in the
editing window from a previous run.

background image

FORMATTING

BASICS

background image

Formatting Basics

9

CHAPTER 3

:

Fo r m a t t i n g B a s i c s

This section will familiarize you with the basics of working with PostHaste formatting template files.

HOW POSTHASTE WORKS

PostHaste gets all of the configuration information for each machine from a

format template file

(which we usually refer as

the format or the template).

All you have to do to change a machine program format is to modify the contents of the corresponding template file. This
can be done easily with any word processor or text editor – just like editing an NC program.

As a matter of fact, the formatting templates look very much like NC programs. We designed the post this way to be as easy
as possible for NC programmers to modify.

OVERALL STRUCTURE OF THE TEMPLATE FILE

As you take a look at the template on the next page, you will notice that…

…the first line in the template starts with the word NAME.

(All templates must start with a NAME line to identify the controller & machine name.)

…all of the formatting information that PostHASTE requires is placed in the format template file in these 3 basic areas:

1.

The address (letter) formats

2.

Commands & Switches

3.

The “Sequences”

Take a look at the sample template on the next page and get familiar with these areas – you will notice that they are quite
different from each other and quite easily distinguishable from each other.

!

The next page shows a

complete

4 axis milling format template. We

highly

recommend that

you

make a printout (or hard copy) of the template on the following page and keep it

handy so you can easily refer to it

while you’re learning about PostHaste.

background image

Formatting Basics

10

C

OMPLETE

4

AXIS

MILL

FORMAT

TEMPLATE

.*

Again, we highly recommend that you make a hard copy of this page and keep it for reference.

* Note: 3 axis formats are exactly the same except that they don’t have the code shown in italics (most notably, the Index
sequence and RotAngle variable).

name Haas 4 axis Vertical machining center

- Section 1 - Letter formatting -

O >4 (O can be up to 4 digits.)
N >4
G >2 (G can be up to 2 digits.)

X ->3.>4 (All these letters are formatted
Y ->3.>4 to allow a minus sign, then up
Z ->3.>4 to 3 digits before the decimal,
I ->3.>4 and up to 4 digits after.)
J ->3.>4
Q ->3.>4
R ->3.>4
P ->3.>4
A ->4.>4 Limit -8000 8000 (For Rotary axis.)
F >3.1
K ->3.>4
H >2
D >2
T >2
M >2
S >4

- Section 2 – Commands & Switches -

ModalGs 0 1 2 3 73 74 76 80 81 82 83 84 85
Sequence#s N 0 1 1 Char, Freq, Inc., First

HCode X (Axis letters.)
VCode Y
Dcode Z
FeedCode F

Feed G1 (Motion G codes.)
Rapid G0
Cw G2
Ccw G3

CtrCode I J (Circle info… )
CtrIncremental? Y
ByQuadrants? N

Comment ( ) (Comment start / end. )
Spindle 3 4 5 (M codes: Cw, Ccw, Off )
Coolant 8 9 7 (M codes: On, Off, Mist.)
DComp 41 42 40 (G codes: Left, Right, Off )

RotaryFeed F[InvTime] Rotary feed rate
FeedType G 95 94 93 IPR, IPM, InvTime

- Section 3 - The NC code sequences -

(First, the sequences for program startup, tool
changes, rotary rapid [index] moves, cutter diameter
compensation and program end…)

StartCode
O[Program#]
G91
G28 X2 Y-2 Z-2
G90
End

1stToolChange
N[Block] T[Tool] M6
G0 G40 G80 G[Work] X[H] Y[V] A[RotAngle]
G43 Z[D] H[Lcomp] M[Direct] S[Speed]
M[Cool]
End

ToolChange (Secondary tool changes.)
M9
G28 G49 Z0 S100
N[Block] T[Tool] M6
G0 G40 G80 G[Work] X[H] Y[V] A[RotAngle]
G43 Z[D] H[Lcomp] M[Direct] S[Speed]
M[Cool]
End

Index X (How to rapid w/ rotary motion.)
G0 Z[ILevel]
G[Work] X[H] Y[V] A[RotAngle]
Z[D]
End

Infeed (Apply cuttercomp)
G1 Z[D] F[Plunge]
G[Side] X[H] Y[V] D[DComp] F[FRate]
end

Outfeed (Remove cuttercomp)
G1 G40 X[H] Y[V]
Z[D]
End

EndCode
G0 G28 G49 Z0 S100
G28 G91 X0 Y0 A0 T[Tool1] M6
G90 M30
End

(Now, the sequences for the drilling cycles…)

Drill - Feed in, rapid out.
G81 X[H] Y[V] Z[D] R[RLevel] F[FRate]
end cancel

Peck - Peck Drill (full tretract)
G83 X[H] Y[V] Z[D] Q[Step] R[RLevel] F[FRate]
end cancel

ChipBreak - Peck Drill (partial tretract)
G73 X[H] Y[V] Z[D] Q[Step] R[RLevel] F[FRate]
end cancel

Tap - Tapping.
G84 X[H] Y[V] Z[D] R[RLevel] F[FRate]
end cancel

LTap - L. handed tapping.
G74 X[H] Y[V] Z[D] R[RLevel] F[FRate]
end cancel

Ream - Feed in, feed out.
G85 X[H] Y[V] Z[D] R[RLevel] F[FRate]
end cancel

Bore - Feed in, stop, orient, rapid out.
G86 X[H] Y[V] Z[D] R[RLevel] F[FRate]
end cancel

Back - Back bore cycle.
G87 X[H] Y[V] Z[D] R[RLevel] F[FRate]
end cancel

Cancel (Code used to cancel the drill cycles.)
G80
end

background image

Formatting Basics

11

D

ETAILS

REGARDING

THE

VARIOUS

TEMPLATE

SECTIONS

This section briefly describes what these do. Please take a look at the sample template (you did make a hard copy of the
previous page, right?) while you read the following; doing this will greatly help you get a good idea of how the template file
works.

The Name line

When you edit a template file, you will
notice that the word NAME is the first
thing in the format. The NAME line starts
the description of each machine format.
Without a NAME line, you don’t have a
format. Sorry - that’s just the way it is.

NOTE: Some template files have more
than one machine format in them. This is
why the Name line is so important – the
Name line is what separates different
formats within the same template file. If
you happen to run a template that as more
than one format in it, then PostHaste will
present a list like this so that you can
choose which machine (within the same
template) that you want to generate code for.

After the required NAME line, the remainder of each format can be broken into 3 sections (as described in brief below).
These 3 sections look basically the same from one machine format to the next, so the easiest way to create a new NC code
format is to copy an existing machine format template, then alter it to fit your needs.

The Letter formatting section

This section of the format lists the letters that can be used in your format - in the order that they will appear in the lines
of machine program code
- and the exact formatting of the numerical values that accompany each letter. Here’s an excerpt
from the letter format section of a Fanuc template:

% 00

‘Letter alone’: No digits before the decimal, no decimal, and no digits after the decimal

O >4

‘O’ can have up to 4 digits, no decimal…

N >4

… and the same for ‘N’.

G >2

G can have up to 2 digits (again, no decimal).

X ->3.>4

X can have minus sign, up to 3 digits before, up to 4 after decimal.

Y ->3.>4

(And the same for Y.)

The sample above shows only the most basic type of numeric formatting: that is, specifying…

!

When formatting a template that has more than one machine in it, you must be very
careful to make sure that you are editing the section of the template file that actually
applies to the machine format you want to edit
. So be careful to always make sure that
you are editing the section under the proper Name
line!

!

When reading letter formatting lines, read the ‘arrow’ character ‘>’ as meaning ‘up to’.

background image

Formatting Basics

12

the number of digits possible before and after the decimal

(by the numbers that you see on each line), and

whether or not there will be an actual decimal point (.):

(notice the X and Y lines have a decimal point, the others do not.)

whether or not a minus sign is allowed (notice the ‘-‘ on the X and Y lines)

There are many more things that you can do with letter formats – you can learn about these in the PostHaste Formatting
Reference Manual
.

The Commands & Switches section

After the letter formats, there is typically a page or two full of Commands and Switches such as…

ModalGs 0 1 2 3 73 74 76 80 81 82 83 84 85 List of modal G code values
Sequence#s N 0 1 1

Char, Freq, Increment, Start

First#? N

Output Line # on first line?

Last#? N

Line # on first line?

HCode X

‘Horizontal’ axis letter

VCode Y

‘Vertical’ axis letter

Dcode Z

Depth’ axis letter

FeedCode F This is the letter that accompanies feed rates.

But, what’s a Switch?

Any word that you see in the templates followed by a question mark (such as First#? and Last#? above) are called
switches because they refer to various code conditions that can be turned ‘on or off ’ (like a switch) simply by placing a
Y or N after the switch.

…The various commands and switches tell the post basic information that is used commonly in many areas of the final
machine program. Armed with a little common sense, you should get a pretty good idea of what these do as you look
through them. (Again, please refer to the PostHaste Formatting Reference Manual to learn more about all of the available
commands.)

In the mean time, however, there are a few that we should probably introduce you to…

!

…but there is one more thing that is very important that may not be obvious: whether or not there are mandatory
leading and/or trailing zeroes
. This is controlled by the ‘arrow’ (>) character:

As mentioned above, the arrow character means ‘up to’, so leaving out the arrow ‘forces’ there to be mandatory
leading or trailing zeroes
. For example some older machines may require…

X ->34

This will format X to have no decimal and trailing zeros: an X value of -1.5 will appear as X-15000

…and for a really old machine that requires leading and trailing zeroes AND a plus or minus sign use…

X +-34

… so an X value of 1.5 will appear as X+0015000

background image

Formatting Basics

13

Arc formatting commands & switches

We have found that the commands related to arc formatting are the ones that people have to deal with quite commonly, so
we’ll explain a bit about them here. (They are shown in here with their most common settings:)

Cw G2
Ccw G3
ByQuadrants? N

Break arcs at quadrant boundaries?

CtrCode I J

Can be ‘I J’ or ‘R’ or ‘I J R’

CtrIncremental? Y

Are I and J incremental from arc start point?\

These commands (along with properly formatted X, Y, I and J letters) are all that is usually needed for PostHaste to know
how you want the arc codes to appear – at least on most relatively modern machines.

For most folks, though, the above commands are all that’s needed. Here is some information on the ones that may not be
completely obvious…

ByQuadrants?

Some machines can only handle arc motions that are 90 degrees or less. If that is the case on your machine, then follow
ByQuadrants? with the letter Y (or ‘yes’). This will cause PostHaste to break all arcs at quadrant boundaries.

Note: ‘ByQuadrants? Y’ should also be used if you are using the ‘CtrCode R’ setting in your format (as the R method of arc
center calculation becomes ambiguous if arcs over 180 degrees are allowed). Which brings us to a discussion of CtrCode.

CtrCode

CtrCode designates the letters used to indicate the center point of an arc. It can be followed by one, two, or three letters – the
most common settings are shown here:

CtrCode I J

Use 2 letters to show that you want the arc center designated by its X and Y axis locations

CtrCode R

1 letter causes only the arc radius to be programmed. (Note: ‘ByQuadrants? Y’ must be used for this to work!)

CtrCode I J R

Yes, there are machines that require both center XY values and a radius. (Go figure…) For those, use 3 letters.

CtrIncremental?

Set this to N if the center of arcs need to be indicated with absolute values (measured from the program origin rather than
the start point of the arc).

The Sequences

The sequences constitute the true ‘template’ portion of the format; the sequences specify exactly where all of the words
(such as G1, M6 and X-3.25) appear in the final program.

!

However, there are many machines whose arcs do not follow ‘relatively modern’ standards, so you may need more
artillery for those. In that case, then see the CwCode and CcwCode sequences in the PostHaste Formatting Reference
Manual
. (These sequences let you custom-build arc motion blocks – line by line and word by word.)

!

Please note that for turning formats (.pT2 files) CtrCode should typically be…

CtrCode I K

2 letters indicating H (horizontal) and D (depth) axis letters (Corresponding to X and Z)

background image

Formatting Basics

14

As you have seen in the complete format sample in section “Complete 4 axis mill format template.*” on page 10 (that you
printed out?) – the sequences look similar to an NC program, and they exactly describe the placement of all of the code
that is required to perform all of the individual machine functions.

There are sequences to describe every portion of a finished machine program (and more!).

The most commonly edited sequences

The ones you will probably edit the most commonly are listed in the following table. Take a minute or two to look at the
sequences in the hardcopy of the sample that you made (from the section Complete 4 axis mill format template.*
) and
cross reference it to the table below so that you understand how the sequences listed below describe all of the
separate functions listed in the right hand column:.

Sequences used for drilling cycles

After the sequences mentioned above, the most commonly edited sequences are probably the drilling (or ‘point to point’
cycle) sequences. They are…

There are a lot of options on drilling cycles, so we’re not going to go into them in any detail here; but, as usual, you can get
detailed information on these (and all other) sequences in the PostHaste Formatting Reference Manual.

These sequences ...

...contain the code required ...

StartCode

- for the very start your NC program

1stToolChange

- to get the first tool into the spindle (if required),
- turn on the spindle and coolant, and
- position (rapid) the tool to the first XY location in the job, then
- rapid down to the ‘initial clearance plane’
(Note: This sequence generally gets executed immediately after StartCode)

ToolChange

- to change from one tool to another (e.g. turn coolant off and retract Z)
- and then perform all of the same functions as 1stToolChange (for every tool after the first one.)

EndCode

…at the very end of the program

Sequence name:

What it does:

Typical G codes:

Drill

‘Straight’ drilling (Feed in, Rapid out, with or without Dwell)*

G81 and/or G82*

Ream

‘Feed in, Feed out’

G85

Peck

Peck Drilling – ‘full out’ retract between pecks

G83

ChipBreak

‘partial retract’ peck drilling

G73

Tap

Tapping

G84

LTap

Left-handed tapping

G74

Bore

‘Find boring’: Feed in, stop, orient, rapid out

G76

Back

Back-boring cycle

G87

Cancel

Cancels all drilling cycles

G80

background image

Formatting Basics

15

Things to watch out for when working with sequences:

Of course, you have already noticed that in the PostHaste template, the ‘number’ can also be a [variable]

…which, of course, brings us to the next topic.

Using [Variables]

In almost all of the sequences, you see variables such as [Program#] or [H] or [Tool]. This is because of the fact that in
almost all of the sequences, changing numerical values must be assigned to the various letters. Since numerical values that
get assigned to any given letter vary from program to program (and from place to place within a program), they are called
variables.**

Now, don’t let the word variable scare you; variable simply means: “A word that takes the place of a number”. Let us
explain it this way:

There is a reason for (or description of ) every value of an NC program that you create; we are simply showing the
“reason” instead of the value itself. For instance: an X value on a mill generally indicates a HORIZONTAL POSITION; so
we simply abbreviate it as the letter H... “H” is the variable that indicates “horizontal position”. Therefore, to indicate that
you want the X to appear followed by the current horizontal position, then simply put X[H] where you want that to appear
in your sequence.

The different letters in your NC program generally have a specific “reason for existence”, so we simply match the “reason”
to the letter. Another example: the letter T usually indicates a “tool number”, so we’ve created a variable called “TOOL” to
specify the tool number. You will see it used in the ToolChange sequence like this: T[Tool]

See... that wasn’t so scary, now was it?

For a complete list of variables and what they do, see the PostHaste Formatting Reference Manual - Appendix A.

That appendix lists all of the variable names (and the values to which they refer) that we can use instead of numbers when
describing the sequences. Because there are so many types of values that can be used in an NC program there are several

!

Please note that, just like a standard NC program, each ‘word’ is always a letter followed by a number.

Please note that this is true - even if you want to output just a single character with no number – as is usually the case
with the percent sign (usually found in StartCode). Since a number must always follow every letter in every
sequence - like this…

%0

…then to prevent the zero from actually appearing in the code, we format the letter (in this case the %) up in
the letter format section of the template to ‘suppress’ the numeric output like this:

% 00

(No digits before the decimal, no decimal, and no digits after the decimal)

A single space must separate all words. Make sure not to accidentally use 2 spaces – this turns the rest of the
line into a comment! (See the section “Comments in the format” on page 16 re use of comments.)

* Most formatting templates in the library do NOT support Dwell or G82 on Drill cycles – but it can easily be added;
This is one of the simple ‘copy and paste’ changes that we have supplied for you in the QuickClips.txt file.
You should take a moment to get familiar with the capabilities we have provided in the QuickClips.txt file; take a look (open it with any editor) – you
may find some very useful items there.
** Variables is a term that we’ve borrowed from the world of computer programming. Please forgive us; we’ll try not to do this type of thing too often

background image

Formatting Basics

16

pages of variables listed there. It’s rather a long list (which you certainly do not need to memorize!), but you may want to
“skim” it, just to get an idea of what’s available. That appendix is intended to be used for reference when you need it.

C

OMMENTS

IN

THE

FORMAT

You’ve probably already noticed that there are ‘comments’ in the templates.

There are 2 ways that you can enter comments into PostHaste templates:

1.

For short (one line or less than one line) comments…
… simply type 2 or more spaces (then type your comment after the spaces), or

2.

For longer (multiple line) comments where it becomes inconvenient to use leading spaces, you may instead use the
Notes: and EndNotes commands; put Notes: on the line before your comments and EndNotes on a line after them.
(Make sure that you don’t forget the colon [:] at the end of the word Notes:. If you omit the colon, it won’t work!)

Here’s a sample section from a template that shows both types of comments (we’ve underlined the coments to make them
easier to see…)

Name Fanuc 6M, Shizuoka B6V

Notes:
Format formed by Fred Farkle for
Farmer Frank’s Fabulous Fat Free French Friers
Feb. First, ’55.
(All of these lines are comments because of the
NOTES: line above and the ENDNOTES line below.)
EndNotes

This line is a comment because of the leading spaces.

O >4 Program number
N >4 Line numbers

You can have as many Notes:/EndNotes comment sections as you’d like in your template.
Notes:/EndNotes and ‘indented’ comments may also be used inside sequences.

!

We HIGHLY recommend that you make liberal use of comments! Comments take only a few seconds to write,
but could save you hours of time and frustration later when you need to make changes to your format! This is
especially true when you’re doing something unusual, and ALWAYS (!) when you’re using ‘user variables’ such as
[Val1], [Val2], etc. (Read about user variables in the PostHaste Formatting Reference Manual.)

!

NOTE: Since PostHaste will ignore anything on the line that has 2 or more adjacent spaces before it…
be careful not to accidentally “comment out” part of the actual formatting information by mistakenly entering 2
spaces in place of 1!

background image

EXAMPLE:

MODIFYING THE

TOOLCHANGE

SEQUENCE

background image

Example: Modifying the ToolChange sequence

18

CHAPTER 4

:

E x a m p l e : M o d i f y i n g t h e

To o l C h a n g e s e q u e n c e

To get a feel for how to make changes, let’s make two changes that people commonly do in their tool change sequences
(1stToolChange and ToolChange): we’ll move a few codes to different locations as shown in this sample (codes in bold are
being moved):

So… we simply make the corresponding changes in the 1stToolChange sequence:

Please notice the ‘one for one’ correspondence between the template lines (in the table immediately above) and the actual
code output (in the first table).

The changes we want to make:

What the code looks like now:

…and how we want it to look:

We want the M6 on its own line - after the Tool #…

N1 T1 M6
G0 G40 G80 G54 X1.6 Y3.45
G42 Z0.1 H1 M3 S2500

N1 T1
M6
G0 G40 G80 G54 X1.6 Y3.45 M8

Our coolant pump is old – we need the M8 earlier.

M8

G42 Z0.1 H2 M3 S2500

What we do to make the change:

The original sequence:

…We simply make it look like this:

Click the mouse just before the M6 and press enter (to move the M6 down
to its own line)

1stToolChange
N[Block] T[Tool] M6
G0 G40 G80 G[Work] X[H] Y[V]
G43 Z[D] H[Lcomp] M[Direct]
S[Speed]

1stToolChange
N[Block] T[Tool]
M6
G0 G40 G80 G[Work] X[H] Y[V] M[Cool]

‘Cut’ the M[Cool] here and ‘paste’ it onto the G0 line.

M[Cool]
End

G43 Z[D] H[Lcomp] M[Direct] S[Speed]
End

background image

GO FOR IT!

background image

Go for it!

20

CHAPTER 5

:

G o f o r i t !

With just what you have read so far in this manual and some common sense, you can now probably configure PostHASTE
for most of your code requirements - because we designed the template to be rather self-explanatory. In other words: you
may not have to read the formatting reference manual in order to get the job done.

So go ahead - open up a template (with any text editor) and have at it!

!

Don’t forget to first make a backup copy of any templates that you work on!

background image

OVERALL SYSTEM

CONFIGURATION

background image

Overall System Configuration

22

APPENDIX A

:

O v e r a l l S y s t e m

C o n f i g u r a t i o n

THE POSTHASTE.CFG OR POST.INI FILE

The PostHaste.CFG file (or, for you SurfCam users, the Post.INI file) allows you to configure some overall operational
characteristics of PostHaste. It is similar in layout to the commands and switches section of the format template, in that
each valid line in the .cfg file starts with a single command word, followed by one or more parameters. The valid commands
are shown in the charts below.

This first chart lists the most commonly used commands:

Command

What it does

Notes

Format

Indicates the file name extensions for the format template file(s) and
tells PostHaste in which folder to find them.

The FORMAT line is REQUIRED.

InDrive

Similar to Format, the InDrive line designates the default folder and file
extension for incoming CL files.

OutDrive …

Similar to the above, but designates the folder and the file extension
for the finished NC program file.

If this line is omitted, then the final program file will be created in the
same folder as the incoming CL file and have the .NCC extension.
(Also see the note re AutoOpen? below.)

Ignore …

Use this to tell PostHaste to completely ignore certain CL records.
Example:
Ignore INDIRV
Note: Ignore commands are processed AFTER Convert commands.

You may place many Ignore commands in the .cfg file.
NOTE: You can also use this command in your format
template(s)!
IGNORE commands in your template affects only the
machine in the template. IGNORE commands in the CFG file affect ALL
machines.

Convert …

Allows you to “convert” incoming CL records by effectively performing a
“search and replace” on all lines as they are read from the CL file -
BEFORE they are processed by the format template. Example:
Convert ‘MOVARC’ to ‘CIRCLE’
Note: Convert commands are processed BEFORE Ignore commands.

You may have many CONVERT lines in the .cfg file.
This same command is also available in the format template, but is most
commonly used in the .cfg file because in most cases, you want ALL of
your posts to do the same “conversions” of CL data. Putting the Convert
command(s) here in the .cfg file - once - keeps you from having to
repeat the same Convert commands in all of your different format
templates.

background image

Overall System Configuration

23

This second chart lists the commands that are not changed or used as often as those in the chart above. Once you set them,
you will probably never need to change them.

Command

What it does

Notes

Logging? N

The “N” (no) tells the post to NOT create a PostHaste.LOG file.
(Inhibiting the .log file may help the post run slightly faster.)

If this line is omitted (or if you use “Y”), then the post WILL create a
PostHaste.LOG file (the equivalent of “Logging? Y”).
PostHaste generates a POSTHASTE.LOG file (in the same folder as your
PostHASTE.exe file). This file is a "debugging" aid that helps you see exactly
what incoming CL data caused each line of NC code to be output. This file is
essentially a "merging" of the incoming CL data and the outgoing NC code.
By looking at this file (in any text editor), you can see exactly which CL
records produced each line of NC program. (The incoming CL lines are
numbered for your convenience.)
NOTE: This file is overwritten each time you run the post, so if you want to
save it, you will either have to rename it or move it to another folder.

CloseWindow? Y

“Y” tells PostHaste to automatically close the main PostHaste
dialog window as soon as it has completed posting the current file.

If this line is omitted (or if you use “N”), then the main PostHaste window will
remain on the screen, allowing you to choose another posting or editing task
by pressing any of the task buttons (e.g. the Post Again or Edit Template or
Exit buttons).

AutoOpen? N

The “N” (no) tells the post to NOT open the NC program file after it
has been created. See section 1.1.1 for more information on
PostHaste’s AutoOpen feature.

For the AutoOpen feature to work properly, the OutDrive line (see
above) must be a complete
path name (including the drive letter).

AptDrillAbs?

Follow this with “Y” (yes) if the CYCLE records in the CL files you
use store the CLEAR, RAPTO and FEDTO values as ABSOLUTE
values. (NOTE: This is NOT the ISO standard for APT CL files, but
some systems do it this way [such as Hurco], so this “switch” allows
PostHaste to process those types of CL files properly.)

If this line is omitted, PostHaste will interpret the CLEAR FEDTO values as
“incremental from the hole top” (the equivalent of “AptDrillAbs? Y”) - which
is the ISO standard for APT CL files.
(Note: In the ISO standard, RAPTO [the “R level”] is measured incrementally,
DOWN from the calculated CLEAR level.)

EOL

If the incoming CL file is NOT stored in “PC standard End Of Line”
format (CR and LF characters after each line), then indicate the
ASCII value of the that is used as the ‘End of Line’ (EOL) character.

UNIX systems use the LF (linefeed) character by itself, which is ASCII
character number 10. So, for example, you would use this line:
EOL 10

FontSize

Add a FontSize command like the one below if the characters in the
PostHASTE main window and prompts are too small or too large.
FontSize –13
(Note: This is the 'default' size that is used if you do not have a
FontSize command. )
We have noticed that you can use either positive or negative values
here; make the number 'farther from zero' to make the fonts
larger.

PostHaste sends the FontSize number directly to Windows through a Windows
API call; in other words, the font size is controlled directly by Windows.
We suspect that 'minus' font sizes indicates 'points' (72 points per inch), and
positive values indicate 'pixel height' (in other words, -13 creates larger text
than 13) … but we're not sure of the details on this.
You can change the font size 'on the fly': While PostHaste is running, just edit
your .cfg file and change the number. Then save the .cfg file. You will
immediately see the effect of the changes you make when you hit the post
again button.

FontName

If you don't like the default font ('MS Sans Serif'), you can enter
another one in quotes here like this:
FontName 'Terminal'
Make sure that you use a valid font name that is installed on your
system, and that you do NOT misspell the font name!

Using FontName to indicate another font ('Terminal' or some other) is usually
required for asian ('double-byte') or other language fonts to display the
proper character set.

background image

RECOMMENDED

FORMAT FILE

EXTENSIONS

background image

Recommended Format File Extensions

25

APPENDIX B

:

R e c o m m e n d e d Fo r m a t F i l e

E x t e n s i o n s

The file name extensions in the table below can be used in the Format line of your PostHaste.cfg file. The numbers in the
file name extensions indicates the number of axes supported by the template.

Machine type

Format template file name Extensions

Milling

.pM3 to .pM5 (for 5 axis)

Turning

.pT2 to .pT4

Mill/Turn (mUltifunction machines)

.pU2 to .pU5

Flame or Plasma

.pF2 ...

Laser

.pL2 ...

Punch Press

.pP2

Water jet

.pW2 ...

Wire EDM

.pE2 ...


Document Outline


Wyszukiwarka

Podobne podstrony:
1 3 Getting started with Data Studio Lab
Packt Publishing Getting Started with Backbone Marionette (2014)
Getting Started with Arduino
GETTING STARTED WITH MAT000
Getting Started with MediaFire
Getting Started with Data Warehouse and Business Intelligence
Getting Started with Arduino Table of Contents
1 3 Getting started with Data Studio Lab
Packt Publishing Getting Started with Backbone Marionette (2014)
Borland Delphi Magazine Getting Started With Sql Part 2
Getting Started With Asterisk
Getting Started with QuadriSpace
Getting Started with PECS
6624 Getting started with the Power BI for Android app WSG 2
6623 Getting started with the Power BI mobile app for Windows 10 WSG 2
getting started with pyparsing
6628 Getting started with Power BI PG 2

więcej podobnych podstron