Jump to content

Welcome to eMastercam

Register now to participate in the forums, access the download area, buy Mastercam training materials, post processors and more. This message will be removed once you have signed in.

Use your display name or email address to sign in:

post help


Guest
 Share

Recommended Posts

i am having a problem in my nc file where it is posting a G92 twice at the beginning of my program and i don't know how to get rid of it.it also post a G92 after wire comp cancel.that is ok

but not necessary.it puts the G92 correctly when it goes to a new start position which is what i want.can someone take a look at this in the section i posted and tell me what would fix it.

this is a fanuc version x wire post.

 

 

% pheader$ pheader$ 0. 50.

O1500(T) pheader$ pheader$ 0. 50.

(DATE=DD-MM-YY - 13-11-06 TIME=HH:MM - 12:38) pheader$ pheader$ 0. 50.

(MCX FILE - T) pheader$ pheader$ 0. 50.

(NC FILE - C:MCAMX2WIRENCT.NC) pheader$ pheader$ 0. 50.

O1500 psof$ psof$ 1. 52.

G0 G20 G90 psof$ psof$ 1. 52.

M31 psof$ psof$ 1. 52.

G77 P1 psof$ psof$ 1. 52.

M15 P1 psof$ psof$ 1. 52.

G92 X-3.24474 Y2.92359 psof$ ptlch_nstrt 1. 52.

G92 psof$ ptlch_nstrt 1. 52.

M60 psof$ p__49:1241 1. 52.

M37 psof$ psof$ 1. 52.

S1 D1 psof$ pconchg$ 1. 52.

G41 G1 X-2.6577 plin$ plinout 2. 54.

G3 X-3.83178 I-.58704 pcir$ pcirout 3. 56.

X-2.6577 I.58704 pcir$ pcirout 3. 56.

G40 G1 X-3.24474 plin$ plinout 4. 58.

G92 ptlchg$ ptlch_nstrt 4. 104.

M38 ptlchg$ ptlchg$ 4. 104.

S2 D2 ptlchg$ pconchg$ 4. 104.

G41 G1 X-2.6577 plin$ plinout 4. 106.

G3 X-3.83178 I-.58704 pcir$ pcirout 4. 108.

X-2.6577 I.58704 pcir$ pcirout 4. 108.

G40 G1 X-3.24474 plin$ plinout 4. 110.

G92 ptlchg$ ptlch_nstrt 4. 156.

M38 ptlchg$ ptlchg$ 4. 156.

S3 D3 ptlchg$ pconchg$ 4. 156.

G41 G1 X-2.6577 plin$ plinout 4. 158.

G3 X-3.83178 I-.58704 pcir$ pcirout 4. 160.

X-2.6577 I.58704 pcir$ pcirout 4. 160.

G40 G1 X-3.24474 plin$ plinout 4. 162.

G92 ptlchg$ ptlch_nstrt 4. 208.

M38 ptlchg$ ptlchg$ 4. 208.

S4 D4 ptlchg$ pconchg$ 4. 208.

G41 G1 X-2.6577 plin$ plinout 4. 210.

G3 X-3.83178 I-.58704 pcir$ pcirout 4. 212.

X-2.6577 I.58704 pcir$ pcirout 4. 212.

G40 G1 X-3.24474 plin$ plinout 4. 214.

M50 plin$ p__53:1306 4. 214.

G0 X.6423 Y2.80177 ptlchg$ ptlch_nstrt 4. 260.

G92 ptlchg$ ptlch_nstrt 4. 260.

 

 

ptlch_nstrt #Tool change, do not use start position

pcom_moveb

if op_id$ <> prv_op_id$, [

xr$ = xabs, yr$ =yabs

n$,sg20code,xr$, yr$, e$

]

 

if contour_typ$ = 1,

pcantxt1, pbld, n$, pwcs, sg20code, sgabsinc, pxout, pyout, ptaperwb,

strcantext, e$

 

 

if contour_typ$ = 2,

pcantxt1, pbld, n$, pwcs, sg20code, sgabsinc, pxout, pyout, ptaperwt,

strcantext, e$

 

if contour_typ$ = 3,

pcantxt1, pbld, n$, pwcs, sg20code, sgabsinc, pxout, pyout, plandup,

strcantext, e$

if contour_typ$ = 4,

pcantxt1, pbld, n$, pwcs, sg20code, sgabsinc, pxout, pyout, planddown,

strcantext, e$

if contour_typ$ = 0,

pcantxt1, pbld, n$, pwcs, sg20code, sgabsinc, pxout, pyout, pzout,

strcantext, e$

if G92_flag = 0,pbld,"G92",e$

postlchng = zero

G92_flag = zero

pcantxt

pbld, n$, stank, e$

pcom_movea

Link to comment
Share on other sites

this is the first one i come to in the post.

 

 

psof$ #Start of file for non-zero tool number

!op_id$

pcuttype

g20code$ = zero

cc_pos$ = zero

prv_xia = vequ(startx$)

prv_uia = vequ(startx$)

*progno$,e$

comment$

pbld, n$, *sg20code, *smetric, *sgabsinc, [if feed_out, "G94"], e$

pbld, n$, "M31", e$

pbld, n$, "G77 P1", e$

if cuttype = 0,pbld,n$,"M15 P1",e$

else,pbld,n$,"M15 P11",e$

if strtflag = one, ptlch_strt

else,

[

prv_g20code$ = -1

prv_xabs = c9k

prv_yabs = c9k

ptlch_nstrt

]

if skimpass$ > -1,pbld,n$,"M37",e$

else,pbld,n$,"M38",e$

# if skimpass < 0, pbld, n, "M38", e

 

pbld, n$, pconchg$, e$

motst$ = one

sof = zero

Link to comment
Share on other sites

terry,

 

it does.but if i don't have that line it won't put a g92 after i go to a new start pos.

 

steve, if i try to find that with the 1 attached to it,it says it does not exist.i am using a generic fanuc wire post version 10.

Link to comment
Share on other sites

terry,

i set it up like this in my post and now it looks good except that when i'm doing taper it does not put the correct i and j values at the initial g92.on my wire parameter pages i have the height of the part set at 2.0.the land height is set at 1.75 and the xy plane is set to 0.it should read G92 X0. Y0. J1.75 I-1.75.it has something to do with this section of the old post that defines the contour type.if i put this in it post out

G92 X0. Y0. J2.0 I0.

G92 X0. Y0. J1.75 I-1.75

what do think i should do?

i am just trying to get an updated post that works for all wirepaths.i have posts that work but some of them are version 7 or 8 post.

 

if contour_typ$ = 1,

pcantxt1, pbld, n$, pwcs, sg20code, sgabsinc, pxout, pyout, ptaperwb,

strcantext, e$

 

 

if contour_typ$ = 2,

pcantxt1, pbld, n$, pwcs, sg20code, sgabsinc, pxout, pyout, ptaperwt,

strcantext, e$

 

if contour_typ$ = 3,

pcantxt1, pbld, n$, pwcs, sg20code, sgabsinc, pxout, pyout, plandup,

strcantext, e$

if contour_typ$ = 4,

pcantxt1, pbld, n$, pwcs, sg20code, sgabsinc, pxout, pyout, planddown,

strcantext, e$

if contour_typ$ = 0,

pcantxt1, pbld, n$, pwcs, sg20code, sgabsinc, pxout, pyout, pzout,

strcantext, e$

 

 

ptlch_strt #Tool change, use start position

 

pstart_pos

pcom_moveb

pcantxt

pcantxt1, pbld, n$, pwcs, pfxout, pfyout, pzout, pstrtij, strcantext, e$

pcom_movea

prstore_pos

ptlch_nstrt

 

ptlch_nstrt #Tool change, do not use start position

pcom_moveb

if op_id$ <> prv_op_id$, [

xr$ = xabs, yr$ =yabs

n$,sg20code,xr$, yr$, e$

]

 

 

 

if sof, #Program start

[

if strtflag = zero, # Start Pt. = Thread Pt.

[

# Initial 'G92' at program start

pcantxt1, pbld, n$, pwcs, `sg20code, sgabsinc, pfxout, pfyout,

pzout, pstrtij, strcantext, e$

# Rapid to this G92 position (same X,Y position as G92)

#pbld, n$, *sg20code, pfxout, pfyout, e$

]

else, # Start Pt. <> Thread Pt.

[

#Rapid from Start Pt. -> Thread Pt. (at start of file)

pcantxt1, pbld, n$, *sg20code, pfxout, pfyout, strcantext, e$

if re_G92, # Re-G92XY at after positioning to Thread Pt.?

pbld, n$, pwcs, pfxout, pfyout, pzout, e$

]

]

else, # After initial program start

[

if xinc | yinc, # Reposition motion?

[

# Rapid to new cut (Cut Pt. -> new Thread Pt.)

pcantxt1, pbld, n$, pwcs, `sg20code, sgabsinc, pxout, pyout, pzout,

pstrtij, strcantext, e$

if re_G92, # Re-G92XY at each thread point (after SOF)?

[

sof = one # Needed to force 'G92' output in all to 'pwcs'

pbld, n$, pwcs, pfxout, pfyout, pzout, e$

sof = zero

]

]

]

 

postlchng = zero

pcantxt

pbld, n$, stank, e$

sof = zero

pcom_movea

 

 

% pheader$ pheader$ 0. 50.

O1500(T) pheader$ pheader$ 0. 50.

(DATE=DD-MM-YY - 14-11-06 TIME=HH:MM - 07:31) pheader$ pheader$ 0. 50.

(MCX FILE - T) pheader$ pheader$ 0. 50.

(NC FILE - C:MCAMX2WIRENCT.NC) pheader$ pheader$ 0. 50.

O1500 psof$ psof$ 1. 52.

G0 G20 G90 psof$ psof$ 1. 52.

M31 psof$ psof$ 1. 52.

G77 P1 psof$ psof$ 1. 52.

M15 P1 psof$ psof$ 1. 52.

G92 X0. Y0. I2. J0. psof$ p__7:655 1. 52.

M60 psof$ p__55:1257 1. 52.

M37 psof$ psof$ 1. 52.

S1 D1 psof$ pconchg$ 1. 52.

G41 G1 G51 X.5 T5. plin$ plinout 2. 54.

G3 X-.5 I-.5 pcir$ pcirout 3. 56.

X.5 I.5 pcir$ pcirout 3. 56.

G40 G1 G50 X0. T0. plin$ plinout 4. 58.

M38 ptlchg$ ptlchg$ 4. 104.

S2 D2 ptlchg$ pconchg$ 4. 104.

G41 G1 X.5 plin$ plinout 4. 106.

G3 X-.5 I-.5 pcir$ pcirout 4. 108.

X.5 I.5 pcir$ pcirout 4. 108.

G40 G1 X0. plin$ plinout 4. 110.

M38 ptlchg$ ptlchg$ 4. 156.

S3 D3 ptlchg$ pconchg$ 4. 156.

G41 G1 X.5 plin$ plinout 4. 158.

G3 X-.5 I-.5 pcir$ pcirout 4. 160.

X.5 I.5 pcir$ pcirout 4. 160.

G40 G1 X0. plin$ plinout 4. 162.

M38 ptlchg$ ptlchg$ 4. 208.

S4 D4 ptlchg$ pconchg$ 4. 208.

G41 G1 X.5 plin$ plinout 4. 210.

G3 X-.5 I-.5 pcir$ pcirout 4. 212.

X.5 I.5 pcir$ pcirout 4. 212.

G40 G1 X0. plin$ plinout 4. 214.

M50 plin$ p__59:1322 4. 214.

M29 peof$ peof$ 4. 218.

M30 peof$ peof$ 4. 218.

% peof$ peof$ 4. 218.

Link to comment
Share on other sites

if contour_typ$ = 1,

pcantxt1, pbld, n$, pwcs, sg20code, sgabsinc, pxout, pyout, ptaperwb,

strcantext, e$

 

 

I am assuming your i and j values must come from the ptaperwb post blocks. (or others depending on contour type). You got some wire guys here to help you out, so I will get out of the way now.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.

Join us!

eMastercam - your online source for all things Mastercam.

Together, we are the strongest Mastercam community on the web with over 56,000 members, and our online store offers a wide selection of training materials for all applications and skill levels.

Follow us

×
×
  • Create New...