cancel
Showing results for 
Search instead for 
Did you mean: 

Machine tool run time....

Pioneer
Pioneer

Hello,

 

I am trying to output the length of time per machine tool.  I believe I want to use the mom_sys_tool_time command but I keep getting errors saying that the variable doesn't exist even if I declare it in the beginning of my custom command.  I've had trouble with _sys variables before so I think I might be misusing it.  Does anybody have any experience with this?

 

Thanks

5 REPLIES

Re: Machine tool run time....

Esteemed Contributor
Esteemed Contributor

mom_toolpath_time is the entire time for the current operation including rapid moves.

mom_toolpath_cutting_time contains only the cutting time of the current operation.

 

You will have to sum up the times for each tool manually.

Stefan Pendl, Systemmanager CAx, HAIDLMAIR GmbH
Production: NX10.0.3, VERICUT 8.0, FBM, MRL 3.1.4 | TcUA 10.1 MP7 Patch 0 (10.1.7.0) | TcVis 10.1
Development: VB.NET, Tcl/Tk    Testing: NX11.0 EAP, NX12.0 EAP

How to Get the Most from Your Signature in the Community

Re: Machine tool run time....

Pioneer
Pioneer

When I look in the MOM Variables Browser I don't see either of those variables listed.  Should I expect them to?  I'm in NX 10.

Re: Machine tool run time....

Esteemed Contributor
Esteemed Contributor

The variables browser is not up-to-date, it is just an average to get a feeling for the naming.

 

The best you can do is to run the review tool when generating shop documentation or post-processing a small sample tool path.

Stefan Pendl, Systemmanager CAx, HAIDLMAIR GmbH
Production: NX10.0.3, VERICUT 8.0, FBM, MRL 3.1.4 | TcUA 10.1 MP7 Patch 0 (10.1.7.0) | TcVis 10.1
Development: VB.NET, Tcl/Tk    Testing: NX11.0 EAP, NX12.0 EAP

How to Get the Most from Your Signature in the Community

Re: Machine tool run time....


JarvisIntern wrote:

Hello,

 

I am trying to output the length of time per machine tool.

 

Thanks


Here is an old custom command from Hank Holt that should give you a good start.

Save it as pb_cmd_machine_times.tcl, and import in to your post.

 

#===============================================================================
# Exported Custom Commands created by holt
# on Wed Feb 05 16:11:49 2003 Central Daylight Time
#===============================================================================

#=============================================================
proc PB_CMD_start_time { } {
#=============================================================
global accumulated_time
set accumulated_time 0
}

#=============================================================
proc PB_CMD_path_time { } {
#=============================================================
# 
# add the custom command PB_CMD_start_time to
# the Start_of_Program event, then add
# this custom command to the End_of_Operation event
# This will calculate the time for each path and output it

global mom_machine_time accumulated_time mom_operation_name
global mom_sys_control_in mom_sys_control_out ci co

# call in the control in & out codes

set ci " "
set co " "
if {[info exists mom_sys_control_in] == 1 }  { set ci $mom_sys_control_in }
if {[info exists mom_sys_control_out] == 1 }  { set co $mom_sys_control_out }

set op_time [expr $mom_machine_time - $accumulated_time]
MOM_set_seq_off
MOM_output_literal "$co==========================================$ci"
MOM_output_literal "$co OPERATION: $mom_operation_name   TIME: [format "%3.1f" $op_time] MIN.$ci"
MOM_output_literal "$co==========================================$ci"
MOM_set_seq_on
set accumulated_time $mom_machine_time

}

#=============================================================
proc PB_CMD_machine_time { } {
#=============================================================

global mom_machine_time ci co
MOM_set_seq_off
MOM_output_literal "$co ========================================== $ci"
MOM_output_literal "$co TOTAL TIME: [format "%3.1f" $mom_machine_time] $ci"
MOM_output_literal "$co ========================================== $ci"
MOM_set_seq_on

}
Mark Rief
Retired Siemens

Re: Machine tool run time....

Pioneer
Pioneer

Thanks to all,

 

All of this has been very useful.

 

 

Learn online





Solution Information