cancel
Showing results for 
Search instead for 
Did you mean: 

Post error when trying to add spindle range

Pioneer
Pioneer

I am having trouble getting my lathe post to output the spindle range. I filled in the first three rows of the range table (I only need M41 M42 and M43) and added a M_range block to my spindle line. When I try and post I get an error saying that - MOM was given an invalid expression in a block template  $mom_sys_spindle_range_code ($mom_spindle_range)   This happens both when I try RPM and SFM. Any advice would be appreciated.

NX 10.0.2 PB 10.0.2
5 REPLIES

Re: Post error when trying to add spindle range

Legend
Legend

have you turned on range status and specified range in  feeds and speeds of the operation?

Cattura1.PNG

you can avoid the error if you specify range output as optional (if the range is not specified range address will not be output)

Cattura2.PNG

ciao

Luciano

 

Re: Post error when trying to add spindle range

Pioneer
Pioneer

Thanks for the info! It works the way you suggested but I would really like for the post to figure out which range to use. We have a lot of different machines with different ranges.

NX 10.0.2 PB 10.0.2

Re: Post error when trying to add spindle range

Legend
Legend

you can try to calculate and set mom_spindle_range variable value based on operation's RPM in a  custom command before spindle line output

About turning operations (if it's your case), it is more complicated with SFM as you cannot know the spindle speed in advance, because it's related to turning diameter.

In this case maybe you can base range calculation on max spindle rpm  ( again you have to specify a value for Maximum Rpm ,that is always a good practice if you are going to machine little diameters on big parts)

Cattura3.PNG

ciao

 

Re: Post error when trying to add spindle range

Attached is a custom command (rename to .tcl and import) which selects the range code based on the RPM and the spindle table. It's old, so it may need updating, but you should get the idea. This is the area of interest:

 

   for {set i 1} {$i <= $mom_number_of_ranges} {incr i} {
      if {$speed > $mom_sys_spindle_param($i,min) && $speed <= $mom_sys_spindle_param($i,max) } {
         set mom_spindle_range $i
         return
      }
   }

 

 

Mark Rief
Retired Siemens

Re: Post error when trying to add spindle range

Pioneer
Pioneer

Mark,

 

That worked great. Thanks!!

NX 10.0.2 PB 10.0.2

Learn online





Solution Information