![]() | |
| Home Page | Mark Forums Read | Today's Posts | My Replies | Classifieds | Reviews | Photo Gallery | Web Links | Share Files | Advertise With Us | Ad List |
| |||||||
| Fanuc Discuss Fanuc controllers here! |
| This forum is sponsored by: |
![]() |
| | LinkBack | Thread Tools | Search this Thread | Display Modes |
|
#1
| ||||
| ||||
Hi, I thought this needed to be posted. There are so many questions having to do with Macro B, which some machines don't have, but perhaps they DO have Macro A, which nobody ever talks about. I'd like to see if someone tests for Macro B and it doesn't work (MDI ---> #500 = 1 EOB, Cycle start) Tests also for Macro A (MDI --> G65 H01 P#500 Q1 EOB, cycle start) and finds it does work. Macro A is cumbersome, but could be a live option for some. From a 0M Operator's Manual, Macro A usage: G65 H01 Pn Qn (Definition or substitution) Macro B == #P = #Q G65 H02 Pn Qn Rn (Addition) Macro B == #P = #Q + #R G65 H03 Pn Qn Rn (Subtraction) Macro B == #P = #Q - #R G65 H04 Pn Qn Rn (Multiplication) Macro B == #P = #Q X #R G65 H05 Pn Qn Rn (Division) Macro B == #P = #Q / #R G65 H11 Pn Qn Rn (Logical sum) Macro B == #P = #Q OR #R G65 H12 Pn Qn Rn (Logical product) Macro B == #P = #Q AND #R G65 H13 Pn Qn Rn (Exclusive OR) Macro B == #P = #Q XOR #R G65 H21 Pn Qn (square root) Macro B == #P = SIN[#Q] G65 H22 Pn Qn (Absolute Value) Macro B == #P = ABS[#Q] G65 H23 Pn Qn Rn (Remainder) Macro B == ??? G65 H24 Pn Qn (BCD to Binary) Macro B == #P = BIN[#Q] G65 H25 Pn Qn (Binary to BCD) Macro B == #P = BCD[#Q] G65 H26 Pn Qn Rn (Combined multiplication / division) Macro B == #P = [#P X #Q] / #R G65 H27 Pn Qn Rn (Combined square root) Macro B == #P = SQRT[[#Q X #Q] + [#R X #R]] G65 H28 Pn Qn Rn (Combined square root) Macro B == SQRT[[#Q X #Q] - [#R X #R]] G65 H31 Pn Qn Rn(Sine) Macro B == #P = #Q X SIN[#R] G65 H32 Pn Qn Rn (Cosine) Macro B == #P = #Q X COS[#R] G65 H33 Pn Qn Rn(Tangent) Macro B == #P = #Q X TAN[#R] G65 H34 Pn Qn Rn (Arctangent) Macro B == #P = #Q X ATAN[#R] G65 H80 Pn (Divergence) Macro B == GOTO #P G65 H81 Pn Qn Rn (Conditional Divergence 1) Macro B == IF #Q EQ #R GOTO #P G65 H82 Pn Qn Rn (Conditional Divergence 2) Macro B ==IF #Q NE #R GOTO #P G65 H83 Pn Qn Rn (Conditional Divergence 3) Macro B ==IF #Q GT #R GOTO #P G65 H84 Pn Qn Rn (Conditional Divergence 4) Macro B ==IF #Q LT #R GOTO #P G65 H85 Pn Qn Rn (Conditional Divergence 5) Macro B ==IF #Q GE #R GOTO #P G65 H86 Pn Qn Rn(Conditional Divergence 6) Macro B ==IF #Q LE #R GOTO #P G65 H99 Pn (Alarm Occurrence, generates a P/S Alarm with number code 500+Pn) Macro B == #3000 = 1 (ALARM NOTE) Last edited by beege; 03-23-2011 at 10:24 AM. |
|
#2
| ||||
| ||||
| Do you have A right now and need of Macro B or just pointing out the differences? Al.
__________________ CNC, Mechatronics Integration and Machine Design. “Logic will get you from A to B. Imagination will take you everywhere.” Albert E. |
|
#6
| ||||
| ||||
| Thanks Beege I just bought a lathe that had 4 Macro A progs in it now I have a better understanding of whats going on, they're for the tool sensor arm, which no longer exists on the machine. I do know Macro B & have written many a program. |
|
#7
| ||||
| ||||
| dont macroB require a full key MDI? not all machines have them- none of the Zeroes we ordered ever did except one for a customer that wanted macro B... almost all of the stuff Ive written here has been macro-A, not that bad...I also typed up a list like yours for the setup guys though- why Fanuc describes them in xyz instead of the required pqr format is beyond me- reading the manual just confuses folks. Macro B is a lot more readable, no doubt, but its still pretty powerful. I just ran into another issue with unpublished variables a few weeks ago,- wrote a macro to increment thru the variables to put a weird number in the one I wanted, found it that way...almost every register in the control is available in the macro table, but they dont tell you where they are- at least not where Ive found... Important to note if writing Macro, the controls buffer 3 lines at a time- if one step effects a change in a variable of the next step, it will not work right...put two extra EOBs in there to fill the buffer and all works fine (till someone deletes the extra EOBs!!!) Tim |
|
#8
| |||
| |||
| There are quite a few machines that used Macro B code in their tool change routines and don't have the full key pad. For machines configured in this way, you can write the Macro programs using a PC and upload to the control. Regards, Bill |
|
#12
| |||
| |||
| Lots of thanks.........................
|
![]() |
| Tags |
| fanuc, g65, macro, macro a |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | Search this Thread |
| Display Modes | |
| |
Similar Threads | ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Macro Help | AndyF | Haas Mills | 4 | 07-16-2010 09:26 AM |
| "difference between Custom Macro A and Custom Macro B" | arulthambi | Parametric Programing | 4 | 10-05-2009 03:34 PM |
| Need Help!- Macro A or Macro B On fanuc o-md | macrosat | Fanuc | 1 | 07-29-2009 06:49 AM |
| Testing program for Macro (Fanuc Macro B) | NickDP | Fanuc | 2 | 03-27-2009 03:15 PM |
| Convert Fanuc Macro to Fadal Macro | bfoster59 | Fadal | 1 | 11-08-2007 11:41 PM |