585,729 active members*
4,429 visitors online*
Register for free
Login
Results 1 to 3 of 3
  1. #1
    Join Date
    Nov 2010
    Posts
    65

    Custom Macro A alarm 76

    Hi all!

    Not sure where I should post my question about Custom Macro A so here is a link to the thread I wrote. Please help!

    http://www.cnczone.com/forums/fanuc/...tml#post857224

  2. #2
    Join Date
    Sep 2010
    Posts
    1230
    Quote Originally Posted by Lene Madsen View Post
    Hi all!

    Not sure where I should post my question about Custom Macro A so here is a link to the thread I wrote. Please help!

    http://www.cnczone.com/forums/fanuc/...tml#post857224
    Your format for Macro A is correct to define a variable at program level.

    G65 H01 P#121 Q4000 should load the value of Q into variable #121

    However, if your example program snippet is exactly as it appears in the control, I note that you have a "," instead of a period (decimal point); you've done this in both your main and sub program examples(see below). If this is the case then this may be upsetting the control. I'm not sure whether the control will even accept a "," as in all my years of being involved with NC and CNC machines, I've never made that mistake nor tried to use "," in a program, even in a comment. If you have used a ",", I would have expected a different error.

    G17 G40 G54 G21 G90 ;
    M6 T1;
    G00 X0 Y0 Z0,5 S400 M13;

    G81 X#108 Y#106 R0,1 Z-13,1 F50

    If this is not the case, and you are using periods, the way to find a problem with Macro code that is defying logic, is to put the one line of code you suspect to be the problem in a program by itself. Construct a program as follows to see if you get the same error when you run it.

    The only thing the following program does is load the value of 4000 into #121

    O1000
    G65 H01 P#121 Q4000
    M00
    M30
    %

    Run this program and when it stops at the compulsory stop M00, look up variable 121 in the Macro variable register to make sure that the value 4000 has been stored. If this works, continue to add code one block at a time, and always include the M00 before the end of the program so that you can check that the correct values are appearing in corresponding variable in the Macro variable register.

    Regards,

    Bill

  3. #3
    Join Date
    Nov 2010
    Posts
    65
    Hi angelw

    Thank you for your reply. The "," written here is only in this post (this is how we write decimals in Europe, sorry for the confusion), in the machine I have used the appropriate "."

Similar Threads

  1. Custom Macro A alarm 76
    By Lene Madsen in forum Fanuc
    Replies: 6
    Last Post: 12-06-2010, 12:07 PM
  2. "difference between Custom Macro A and Custom Macro B"
    By arulthambi in forum Parametric Programing
    Replies: 4
    Last Post: 10-05-2009, 09:34 PM
  3. Custom macro!!!!
    By chrisryn in forum G-Code Programing
    Replies: 4
    Last Post: 05-28-2008, 04:13 AM
  4. Custom Macro B On A 18t.
    By JIMMYZ in forum Fanuc
    Replies: 3
    Last Post: 10-19-2006, 04:08 AM
  5. custom macro
    By The Metal in forum Daewoo/Doosan
    Replies: 2
    Last Post: 09-28-2006, 01:26 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •