Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

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

post link issue

Status
Not open for further replies.

davidtan20

Aerospace
Aug 15, 2011
27
0
0
CA
Hi post experts,

I had an issue when I was trying to link mill-turn posts together with nx8.0

I made 3 mill-turn posts turning & zhead & xhead, I tested them seperately all ok.

1) I made mill-turn-zhead as the main post and used linked feature connected turning and mill-turn-xhead, and named them
zhead\turn\xhead
2) I also defined "user defined events" head event by machining method ==> object ==> start event ==>active head zhead\turn\xhead

give me following message when I post all the programs I made with the linked post:

"mom_sys_add_cutting_time" no such variable
while executing
"expr $mom_cutting_time + $mom_sys_add_cutting_time"
( procedure "MOM_end_of_path" Line 7 )

I thought perhaps because I have modified posts. then I tried making those three posts without changing anydthing at all except
make sure Initial Spindle Axies and Maching Mode are right, but same error. I am an inch away from well-done, please help me out.

thanks so much
davidtan20


 
Replies continue below

Recommended for you

Can you show the actual code that is in the proc at the end of path that seems to be causing the error?
It appears thet the math expression is missing some [ brackets ]



John Joyce
N.C. Programming Supervisor
Barnes Aerospace, Windsor CT
NX6.0.5.3
 
Hi joycejo,

first thank you very much.
at beginning I thought same thing, and I even looked rest of tcl calculation and found same expression,
I even tried
set a 5
set b 6
expr $a + $b
11
anyway the following is proc:


#=============================================================
proc MOM_end_of_path { } {
#=============================================================
global mom_sys_add_cutting_time mom_sys_add_non_cutting_time
global mom_cutting_time mom_machine_time

# Accumulated time should be in minutes.
set mom_cutting_time [expr $mom_cutting_time + $mom_sys_add_cutting_time]
set mom_machine_time [expr $mom_machine_time + $mom_sys_add_cutting_time + $mom_sys_add_non_cutting_time]
MOM_reload_variable mom_cutting_time
MOM_reload_variable mom_machine_time

if [llength [info commands PB_CMD_kin_end_of_path] ] {
PB_CMD_kin_end_of_path
}

PB_CMD_Coolant_control
global mom_sys_in_operation
set mom_sys_in_operation 0

thank you so much
 
My guess is that your variable is not initialized in the post or not used (set) in that particular operation. Where is mom sys add cutting time a variable you created or one from NX? Linking post is kind of wierd as it jumps back and forth between the main and the linked posts. Can't remember all about it as I don't do this anymore. You could do an info exist on it and that would kill the error.
 

Hi shags72,

Thank you so much for your answering.
I have checked all the TCL files, found out that all the variable of mom_sys_add_cutting_time are defined at
the beginning of procs, one is in proc MOM_end_of_path { } {, other one is in proc MOM_start_path { } {.
I don't know what is the next, since this variable is initialized.

thank you
 
Okay, well tell me what you have. What is the main post? Where is the ccmd at? Main or linked post and in what event area. What kind of operation is being processed when it fails. Does it fail imediately or does it get to a certain op and then die?mom_sys_add_cutting_time I haven't heard of so I am thinking it might be a new var added since I quit writing. Attach your logfile. Like I said the way the post runs with links can be confusing but I will try and help as best I can remember.
 
Hi shags72,

1) I made mill-turn-zhead as the main post and linked to lathe and mill-turn-xhead, and named them zhead\turn\xhead
2) I also defined "user defined events" head event by machining method ==> object ==> start event ==>active head zhead\turn\xhead

give me following message right way when I post all the programs I made with the linked post:

"mom_sys_add_cutting_time" no such variable
while executing
"expr $mom_cutting_time + $mom_sys_add_cutting_time"
( procedure "MOM_end_of_path" Line 7 )

I tried making those three posts without changing anydthing at all except make sure Initial Spindle Axies and Maching Mode are right, but same error came out.
when I posted programs of mill-turn-zhead, the linked post works ok, but not turning and mill-turn-xhead.

thank you
 
What is the operation type for the operation that you are getting the error on? This will give you an indication on which post the error is in. Also can you get the logfile from nx and post it?
 
Hi shags72,

I have posted them seperately, each result are totally ok but not linked post, from my understanding linked-post not even goes through in the very beginning.
my programs are ordered by lathe => z-milling => x-milling, the programs for lathe would not go through the main post z-head, message says happened on z-head (main post) TLC file.

thank you


 
Status
Not open for further replies.
Back
Top