Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations MintJulep on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

postbuilder, manual tool change, outputting a M00 at end. 1

Status
Not open for further replies.

Jaydenn

Mechanical
Jan 13, 2005
281
Hi.

For starters,I am new to postbuilder and VERY new to tcl programming.
I am embarking on the "learn as you go" method of making a post.

I have managed to figure everything out I need to except one simple, but important item.

The post does not output an M00 at the end of an operation that uses a tool flagged as "manual tool change"

How can I get the post to do that??

My instinct says I need to write a custom command that querys the MOM_tool_change_type variable and outputs based on that.

Am I on the right track?
Can someone help me with the syntax to get an "if" statement to work?

Thanks,
JAY
 
Replies continue below

Recommended for you

When posting a question please let us know what version of NX you are using and in this case what version of Post Builder.

Where are you defining the Manual option?
I set it on the tool.
There is a event marker in Post Builder for a Manual Tool Change and it outputs a M00 at the tool change.
To get a M00 at the end of the operation you will need a custom command.

Create a custom command with the following text and place it at the end of path event in post builder.

global mom_tool_change_type

if { $mom_tool_change_type == "MANUAL" } {MOM_output_literal "M00"}







John Joyce
Tata Technologies iKS
1675 Larimer St.
Denver, CO
www.myigetit.com
 
 http://files.engineering.com/getfile.aspx?folder=a8799180-82f8-46b0-9a36-6ac0cc041a32&file=end_of_path.gif
If you are going to get into any customization of Post Builder I would recommend learning some Tcl. There are a lot of Tcl dedicate web sites and even a Tcl/Tk for dummies book, I have one. It is not that hard to learn and then you can become real dangerous.

John Joyce
Tata Technologies iKS
1675 Larimer St.
Denver, CO
 
I am using NX 5 and PB 5.0.3

Thanks for getting me started.
However, this solution alone, does not work.
I have about 10 seperate operations using the manual tool...
The output file has a "M00" at the end of each operation. I only need the output at the end of ALL the ops included in that tool sequence.

How can I achieve that?

J
 
I guess what I need to say is;

If the next operation has a tool change...Output M00

If the next operation does NOT have a tool change...Output nothing.


J
 
OK i get it
try this

global mom_tool_change_type
global mom_next_oper_has_tool_change


if { $mom_tool_change_type == "MANUAL" && $mom_next_oper_has_tool_change =="YES" } {MOM_output_literal "M00"}


John Joyce
Tata Technologies iKS
1675 Larimer St.
Denver, CO
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor