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:

Tool comment at Sequence Number


Recommended Posts

I get this output from my post:

(CLEAN TOP)

 

 

N9

G91 G30 Z0 M5

G91 G30 X0 Y0

T9 M6 (3.15 VALENITE SHELLMILL)

(RAPID = Z.25)

(MAX DEPTH = Z0.)

G0 G90 G54

X12.6376 Y2.975 S5500 M3

G43 H9 Z.25 /M8 T21

Z.1

G1 Z0. F50.

X-12.6374

Y0.

X12.6376

Y-2.975

X-12.6374

G0 Z.25 M9

G0 G40 G80 Z2.

M9

G91 G30 Z0 M5

G91 G30 X0 Y0

M1

(DRILL THRU)

 

N21

G91 G30 Z0 M5

G91 G30 X0 Y0

T21 M6 (X DRILL)

(RAPID = Z.25)

(MAX DEPTH = Z-.8)

G0 G90 G54

X8.8125 Y-1.8019 S3000 M3

G43 H21 Z.25 /M8 T11

G98 G83 Z-.8 R.1 Q.1 F20.

X0.

X-8.8125

Y1.5032

X0.

X8.8125

G0 G40 G80 Z2.

M9

G91 G30 Z0 M5

G91 G30 X0 Y0

M1

 

How do I get the tool comments to output at the end of the Sequence Number

example:

 

N9 (CLEAN TOP), N21(DRILL THRU), etc.

Thanks alot

Link to comment
Share on other sites
  • 3 weeks later...

I got this problem before and i fixed here how it works. My way may be more complicated then ROY, I'm just trying help if you think it works for you.

 

------------------

# --------------------------------------------------------------------------

# Tool Comment / Manual Entry Section

# --------------------------------------------------------------------------

ptoolcomment #Comment for tool

spaces$=0

tnote = t$

toffnote = tloffno$

tlngnote = tlngno$

tldianote = tldia$

scomm_str, pstrtool, " ", *tnote, " ", *toffnote, " ", *tlngnote, " ", *tldianote, scomm_end, e$

spaces$ = sav_spc

 

pstrtool #Comment for tool

if strtool$ <> sblank,

[

strtool$ = ucase(strtool$)

*strtool$, " "

]

 

pcomment$ #Comment from manual entry (must call pcomment2 if booleans)

pcomment2

 

pcomment2 #Comment from manual entry

#1005 - As Comment

#1006 - As Code

#1007 - As Comment with output line, change at point

#1026 - As Code with output line, change at point

#1008 - Operation comment

 

#1051 - Machine Name

#1052 - Group Comment

#1053 - Group Name

#1054 - File Descriptor

 

spaces$ = 0

scomm$ = ucase (scomm$)

if sof & gcode$ = 1052, scomm_str, scomm$, scomm_end, e$

if sof & gcode$ = 1053, scomm_str, "P/NAME= ", scomm$, scomm_end, e$

#if gcode$ = 1005, n$, pspc, scomm_str, scomm$, scomm_end, e$

if gcode$ = 1006, n$, pspc, scomm$, e$

#if gcode$ = 1007, scomm_str, scomm$, scomm_end

#if gcode$ = 1026, scomm$

#if gcode$ = 1008 & header = zero, n$, pspc, scomm_str, scomm$, scomm_end, e$

if gcode$ = 1008, scomm_sav = ucase(scomm$)

spaces$ = sav_spc

 

pcomment3 #Comment from manual entry

if toolchng,

[

spaces$=0

if swcsplname <> snull, pbld, n$, pspc, scomm_str, swcsplname, scomm_end, e$

if swcsplcomm <> snull, pbld, n$, pspc, scomm_str, swcsplcomm, scomm_end, e$

if rot_on_x & stoolplname <> snull, pbld, n$, pspc, scomm_str, "TOOLPLANE NAME - ", stoolplname, scomm_end, e$

if rot_on_x & stoolplcomm <> snull, pbld, n$, pspc, scomm_str, "TOOLPLANE COMMENT - ", stoolplcomm, scomm_end, e$

if rot_on_x & sconstplname <> snull, pbld, n$, pspc, scomm_str, "CPLANE NAME - ", sconstplname, scomm_end, e$

if rot_on_x & sconstplcomm <> snull, pbld, n$, pspc, scomm_str, "CPLANE COMMENT - ", sconstplcomm, scomm_end, e$

if stpgrpname <> snull, pbld, n$, pspc, scomm_str, stpgrpname, scomm_end, e$

#if opcode$ <> 3 & opcode$ <> 16, pbld, n$, pspc, scomm_str, "COMPENSATION TYPE - ", *scomp_type, scomm_end, e$

spaces$=sav_spc

]

if toolchng0 & op_id$ <> last_op_id,

[

spaces$=0

if swcsplname <> snull, pbld, n$, pspc, scomm_str, swcsplname, scomm_end, e$

if swcsplcomm <> snull, pbld, n$, pspc, scomm_str, swcsplcomm, scomm_end, e$

if rot_on_x & stoolplname <> snull, pbld, n$, pspc, scomm_str, "TOOLPLANE NAME - ", stoolplname, scomm_end, e$

if rot_on_x & stoolplcomm <> snull, pbld, n$, pspc, scomm_str, "TOOLPLANE COMMENT - ", stoolplcomm, scomm_end, e$

if rot_on_x & sconstplname <> snull, pbld, n$, pspc, scomm_str, "CPLANE NAME - ", sconstplname, scomm_end, e$

if rot_on_x & sconstplcomm <> snull, pbld, n$, pspc, scomm_str, "CPLANE COMMENT - ", sconstplcomm, scomm_end, e$

if stpgrpname <> snull, pbld, n$, pspc, scomm_str, stpgrpname, scomm_end, e$

if comp_type <> prv_comp_type & opcode$ <> 3 & opcode$ <> 16, pbld, n$, pspc, scomm_str, "COMPENSATION TYPE - ", *scomp_type, scomm_end, e$

spaces$ = sav_spc

]

 

 

 

# --------------------------------------------------------------------------

# Start of File and Toolchange Setup

# --------------------------------------------------------------------------

psof0$ #Start of file for tool zero

psof$

 

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

ptlchg_errorcheck #Check for common toolchange errors

 

"(*)", e$,

comment$, e$

#spaces$=0, scomm_str, *stpgrpname, scomm_end, spaces$=sav_spc, e$

ptravel

pwritbuf5

pcuttype

toolchng = one

if ntools$ = one,

[

#skip single tool outputs, stagetool must be on

#stagetool = m_one

!next_tool$

]

tooltotal = rbuf(4,0) #Reads total tool and null tool changes

 

while wc8 < 9999,

[

init = 1

init = wbuf(8,wc8)

]

if toolcountn <= tooltotal, nexttool = rbuf(4,toolcountn)

else, nexttool = first_tool$

 

if tool_table = 2, ppredstck

if tool_table = 3, pmetastck

 

absinc$ = sav_absinc

sav_mi9 = mi9$

sav_workofs = workofs$

if sav_workofs < 0, sav_workofs = 0

ptlchg_com

sof = 0

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...