Showing results for 
Search instead for 
Do you mean 
Reply

Last move indentification

[ Edited ]

helo,

 

it is possible to identify the very last move in the operation (event 188 in this case)?

 

I need to put some code just before MOM_end_of_path event is triggerred.

Bez názvu.png

 

(return and gohome moves sometimes exists sometimes not )

 

 

thank you for ideas

 

---------------------------------------------
#♫ PB, 5ax, itnc, nx, vericut ♫ #
12 REPLIES

Re: Last move indentification

Post Builder or Post Configurator?

 

In PB, what if you add a custom command as the very first thing in "end of path" event - does that always come out in the desire place? (if not, why?)

Ken Akerboom Sr CAx Systems Engr, Moog, Inc.
Production: NX10.0.3.5 MP5 + patch/TC11.2
I'd rather be e-steemed than e-diseaseled


Re: Last move indentification

PB

---------------------------------------------
#♫ PB, 5ax, itnc, nx, vericut ♫ #

Re: Last move indentification

In PostConfigurator you create a proc MOM_end_of_path_LIB_ENTRY an insert your code in the start section.

proc MOM_end_of_path_LIB_ENTRY {{option default}} {
switch $option {
"start" {
#Insert your code here
}
"end" {
}
}
}

regards

Re: Last move indentification

[ Edited ]

look , sometimes I have to set some variable X=1 before MOM_insert - ude is outputed in end event in the operation.

If I set this variable X=1 on the start of end of path event ,  MOM_insert is already outputed before - so to late for setting the X.

Only place where I can set this X variable is just before MOM_insert is outputed -  is some move event (last).

That is why I want to set it before end of path event  is triggered.

 

ps: I cant set it in every move, because I need X=0 during machining.

 

 

---------------------------------------------
#♫ PB, 5ax, itnc, nx, vericut ♫ #

Re: Last move indentification

Instead of using MOM_insert, create a UDE and save variable to use in the proc called in end of path.

 

Using Insert can create problems if posting programs to multiple machines.

A custom UDE allows different or no output for machines controlled by the individual post.

Re: Last move indentification

Hello,

yes youre right, I can save variable from ude and output it in the end of operation.

But if you want to use such ude for example during operation - like local return (turning) or add ude in editing paths,  it wont work.

I am not familiar for making one ude for end event and one for local return. you know what I mean.

---------------------------------------------
#♫ PB, 5ax, itnc, nx, vericut ♫ #

Re: Last move indentification

A program example might help.

 

If a UDE is used in the Start of op and in Local return with one value and in the End of op with another value.

custom commands on the various move events and end of path event can control when and what to output.

 

or one UDE with Start, Local and End Values then output the value in the corresponding event.

 

 

Re: Last move indentification

example:

1.

you have ude MOM_example for outputing message/variable.

Add this ude into start event and end event in operation - it outputs what you want, but no where you want.

So you save message/variable and output somewhere where you want it.

OK. works. 

 

2. You want output message in local return during operation. It call this MOM during operation.

But this ude doesnt output message, only save it for later output. :/

 

I am switching  if ude should output or only save variable.

And I want to switch before end of path is triggered.

And I have to do that in last move.

Because till that moment I output messages normally (local return during paths), but after then I want  to save it and output later.

 

 

 

 

---------------------------------------------
#♫ PB, 5ax, itnc, nx, vericut ♫ #

Re: Last move indentification

Hello Juraj

 

With PostConfigurator you can use Pretreatment to get this variable before you execute MOM_insert in the real run.

First create a proc like

      xxx  --> any name

      your_variable  --> the variable what you want to remember

 

proc LIB_SPF_pt_additional_variables_xxx {} {

      LIB_SPF_pretreatment_add_var MOM_end_of_path your_variable 0

}

 

In the real post run you can ask this variable with the following command

 

set var [LIB_SPF_get_pretreatment your_variable 0]

 

 

regards

Heinrich

 

 

 

 

 

Learn online





Solution Information