Cancel
Showing results for 
Search instead for 
Did you mean: 

G-code simulation with G65 Fanuc Macro B Subprogram

Experimenter
Experimenter

Hello all,  

 

In our shop we use subprograms to handle certain operations such as threadmilling.  We feed a Fanuc Subprogram parameters such as thread lead, thread major, etc etc and the macro figures the rest out.  This way we can reduce the amount of code in our programs.

 

Here is an example of our macro to cut a certain thread

G65P9502A1C.45 D1 M1. U.005 R3.51 Z3.31 F.003

 

I have the subprogram in the right directory but I can not get the variable M1. to get passed to the subprogram.  M is variable #13 for passthru on Fanuc Macro B.  It appears all other variables pass thru to the subprogram without any issues.  I am assuming the CSE is seeing the M and assuming its a M code and not a fanuc macro pass variable.  

 

When I change my code to 

G65P9502A1C.45 D1 H1. U.005 R3.51 Z3.31 F.003

 

and change the corresponding fanuc macro subprograms from #13 to #11, everything works as it should.  Is there a way to "fix" the OOTB Fanuc CSE to read macro passthough variable "M" #13 correctly?  

 

Also, is there some kind of tool bar I can open up to see the current macro variables?  I want to double check the computations without having to rig up the output to an Xmovement to see if the numbers are right.  

5 REPLIES 5

Re: G-code simulation with G65 Fanuc Macro B Subprogram

Siemens Phenom Siemens Phenom
Siemens Phenom

Your observation is correct. At this point in time M is not supported to become a parameter in the OOTB Fanuc.CCF. I do not know why yet, but this is the description of G65:

 

Calls macro defined in address P. The subprogram filename is determined using GMe_GetSubprogFilename(P).Uses GMe_MoveVariableBlock and GMe_ResetVariableBlock to store the current local variables onto the stackSaves parameters using argument specification I (ABC...) on stack #100200, #100300 depending on stack level. They will be moved to #0-#33 in the first line of the macro (O Metacode). GMe_SetMacroArgument is used In argument specification I the M parameter is not yet supported.
Argument specification II is not yet supported.

 

You can either open an ER or get in contact with service or partner to customize that.

Thomas Schulz
Siemens PLM
Manufacturing Engineering Software

Re: G-code simulation with G65 Fanuc Macro B Subprogram

Pioneer
Pioneer

I'm running into the same issue ... can't pass parameters in under the word "M". Has a solution to this been found?

 

Thanks,

John

Re: G-code simulation with G65 Fanuc Macro B Subprogram

Siemens Phenom Siemens Phenom
Siemens Phenom

Hi,

 

I looked into the NX1202 FanucFamily.CCF file and there is M as parameter within the G65 metacode implementation. The mentioned limitation for the M parameter within the description has also been removed. I´ve not checked prior versions. 

 

2019-01-18 07_41_38-Machine Configurator - [D__Programs_NX_NX12_MACH_resource_library_machine_instal.png

 

hope that helps

 

Thomas

Re: G-code simulation with G65 Fanuc Macro B Subprogram

Solution Partner Phenom Solution Partner Phenom
Solution Partner Phenom

Also, is there some kind of tool bar I can open up to see the current macro variables? I want to double check the computations without having to rig up the output to an Xmovement to see if the numbers are right.

 

Not sure if this got answered but I just wanted to be sure you know you can monitor variables in the Execution View inside ISV. Down at the bottom there is a Variables group.

LMGi
www.TLMGi.com

Re: G-code simulation with G65 Fanuc Macro B Subprogram

Pioneer
Pioneer

Thomas,

 

I've found a workaround for my application in NX11. Glad to know that it's been fixed for versions 12 and beyond.

 

-John

Learn online





Solution Information