What's new
What's new

Haas -- FANUC Macro compatibility?

ChipSplitter

Titanium
Joined
May 23, 2019
Location
Maybe
I'm hoping to improve myself by learning macro programming. If I learn a little more, I'll know just enough to be dangerous....:D

My question is, how cross-compatible is a FANUC macro manual with a Haas machine? I understand some of the variables might(?) do different things, but the structure is the same, right?



This is the book I was thinking about getting. https://www.amazon.com/Fanuc-Custom...t=&hvlocphy=9017167&hvtargid=pla-458001799679
 
I think before I spent $60 I would go to the Renishaw site and download their inspection plus pdf docs. If that is not enough, then maybe buy the book...
 
I know that I carry on about it but I have this one https://www.amazon.com/S-K-Sinha/dp...3GVH915CMXA&psc=1&refRID=T14J80N7Y3GVH915CMXA

It was pricey for me but really helped and still helps. Even in the Authors foreword he says that it is meant to be read textbook style... So to run from basics to more advanced macros. I still use it to back track every now and again.
The author even sent me extra variables that were not in my edition once I purchased it and I just stuck them in the back.
 
I know that I carry on about it but I have this one CNC Programming using Fanuc Custom Macro B: Sinha, S.K: 9780071713320: Amazon.com: Books

It was pricey for me but really helped and still helps. Even in the Authors foreword he says that it is meant to be read textbook style... So to run from basics to more advanced macros. I still use it to back track every now and again.
The author even sent me extra variables that were not in my edition once I purchased it and I just stuck them in the back.

Thank you NAST555 for your nice words about the book.

In the new reprint of the book, several appendices have been added, including one for macro variables. It is really helpful to have a complete list at one place, with reference page numbers for their description. Some typos also have been corrected.

If you are purchasing the book, look for appendices C, D and E at the back. If not found, ask for the newer version, or PM me to mail you the extra material.

Smid's book is good, but, for i-series controls, mine is better. Ask somebody who has seen both the books,
 
Bump, bump, bump.

Thanks for the book recommendations.....:D

But I still don't know the answer to my original question.

Pinging Wheelie, litlerob1, Mike1974, TMP, or anyone else that knows Haas macros. :Ithankyou:
 
Bump, bump, bump.

Thanks for the book recommendations.....:D

But I still don't know the answer to my original question.

Pinging Wheelie, litlerob1, Mike1974, TMP, or anyone else that knows Haas macros. :Ithankyou:
Hello ChipSplitter,
For the most part, the Fanuc and Haas User Macro language can be considered the same. Local, Common Volatile and Common Nonvolatile Variables are the same. Many of the System Variables considered to be standard are the same.

There are a lot of Fanuc System Variables available that are not listed in the Fanuc Manual. The reason for this is that Fanuc supply their controls to many different MTBs and its the responsibility of the MTB as to whether additional System Variables are supplied or not. As Haas is both the supplier of the Software and the MTB, many additional System Variables are available.

One major difference between the Fanuc and Haas System is that Haas supply a "G" Code to set, or limit the number of Look Ahead Blocks. By specifying G103 with a P address in the range of 1 to 15, the number of Look Ahead Blocks is limited to the number specified by the P address. If P0 is specified, or G103 is included in a Block with the P address omitted, then Look Ahead Limiting will be disabled. The Fanuc System doesn't have this feature and a Work Around must be employed when the Look Ahead must be stopped.

Being able to stop the Look Ahead Block is very important in some circumstances. For example, if you needed to get the Current Machine Position at the end of a move, then you may think that the following would suffice:

G90 G54 X0.0 Y0.0
G43 Z10.0 H01
#1=#5023
------
------
------
------

If in the above example the Workshift for Z in G54 is -210.123 and the Tool Length Offset registered for H01 is 85.60, then the Machine Position in Z at the Absolute Z10.0 position will be -114.523. Accordingly, one may expect that #1 will take on this value when it reads the System Variable #5023. Not so. In fact, the result of the above code is likely to be a value of circa -0.10 being registered in Local Variable #1. To get the desired result, the above code would have to be rewritten as follows:

G90 G54 X0.0 Y0.0
G43 Z10.0 H01
G53 (or G31)
#1=#5023

The above code will stop the Look Ahead before #1=#5023 is executed and ensures that the G43 Z10.0 H01 is completed before #5023 is read.

Regards,

Bill
 
Hello ChipSplitter,
For the most part, the Fanuc and Haas User Macro language can be considered the same. Local, Common Volatile and Common Nonvolatile Variables are the same. Many of the System Variables considered to be standard are the same.

There are a lot of Fanuc System Variables available that are not listed in the Fanuc Manual. The reason for this is that Fanuc supply their controls to many different MTBs and its the responsibility of the MTB as to whether additional System Variables are supplied or not. As Haas is both the supplier of the Software and the MTB, many additional System Variables are available.

One major difference between the Fanuc and Haas System is that Haas supply a "G" Code to set, or limit the number of Look Ahead Blocks. By specifying G103 with a P address in the range of 1 to 15, the number of Look Ahead Blocks is limited to the number specified by the P address. If P0 is specified, or G103 is included in a Block with the P address omitted, then Look Ahead Limiting will be disabled. The Fanuc System doesn't have this feature and a Work Around must be employed when the Look Ahead must be stopped.

Being able to stop the Look Ahead Block is very important in some circumstances. For example, if you needed to get the Current Machine Position at the end of a move, then you may think that the following would suffice:

G90 G54 X0.0 Y0.0
G43 Z10.0 H01
#1=#5023
------
------
------
------

If in the above example the Workshift for Z in G54 is -210.123 and the Tool Length Offset registered for H01 is 85.60, then the Machine Position in Z at the Absolute Z10.0 position will be -124.523. Accordingly, one may expect that #1 will take on this value when it reads the System Variable #5023. Not so. In fact, the result of the above code is likely to be a value of circa -0.10 being registered in Local Variable #1. To get the desired result, the above code would have to be rewritten as follows:

G90 G54 X0.0 Y0.0
G43 Z10.0 H01
G53 (or G31)
#1=#5023

The above code will stop the Look Ahead before #1=#5023 is executed and ensures that the G43 Z10.0 H01 is completed before #5023 is read.

Regards,

Bill


Thank you Bill. That makes sense.
 
Thank you Bill. That makes sense.
Hello ChipSplitter,
A correction to my previous Post is required.
"at the Absolute Z10.0 position will be -124.523", should be "at the Absolute Z10.0 position will be -114.523"; I omitted to take into account the Z10.0, the machine Position would be -124.523 if the Absolute Coordinate were to be Z0.0

Regards,

Bill
 
Hello ChipSplitter,
For the most part, the Fanuc and Haas User Macro language can be considered the same. Local, Common Volatile and Common Nonvolatile Variables are the same. Many of the System Variables considered to be standard are the same.

There are a lot of Fanuc System Variables available that are not listed in the Fanuc Manual. The reason for this is that Fanuc supply their controls to many different MTBs and its the responsibility of the MTB as to whether additional System Variables are supplied or not. As Haas is both the supplier of the Software and the MTB, many additional System Variables are available.

One major difference between the Fanuc and Haas System is that Haas supply a "G" Code to set, or limit the number of Look Ahead Blocks. By specifying G103 with a P address in the range of 1 to 15, the number of Look Ahead Blocks is limited to the number specified by the P address. If P0 is specified, or G103 is included in a Block with the P address omitted, then Look Ahead Limiting will be disabled. The Fanuc System doesn't have this feature and a Work Around must be employed when the Look Ahead must be stopped.

Being able to stop the Look Ahead Block is very important in some circumstances. For example, if you needed to get the Current Machine Position at the end of a move, then you may think that the following would suffice:

G90 G54 X0.0 Y0.0
G43 Z10.0 H01
#1=#5023
------
------
------
------

If in the above example the Workshift for Z in G54 is -210.123 and the Tool Length Offset registered for H01 is 85.60, then the Machine Position in Z at the Absolute Z10.0 position will be -114.523. Accordingly, one may expect that #1 will take on this value when it reads the System Variable #5023. Not so. In fact, the result of the above code is likely to be a value of circa -0.10 being registered in Local Variable #1. To get the desired result, the above code would have to be rewritten as follows:

G90 G54 X0.0 Y0.0
G43 Z10.0 H01
G53 (or G31)
#1=#5023

The above code will stop the Look Ahead before #1=#5023 is executed and ensures that the G43 Z10.0 H01 is completed before #5023 is read.

Regards,

Bill

Nowhere in the Fanuc manuals it is mentioned that G31 will stop look ahead.
It is the finding of Bill. Such a simple solution.
He has been generous enough to share such a useful information with all of us.
We all are grateful to him.
 
Nowhere in the Fanuc manuals it is mentioned that G31 will stop look ahead.
It is the finding of Bill. Such a simple solution.
He has been generous enough to share such a useful information with all of us.
We all are grateful to him.
Hello sinha.
Similarly, nowhere in the Fanuc manual is it mentioned that G53 will stop Look Ahead. These are workarounds that individuals have stumbled across in the passing of time. In quite early controls, it was sufficient to use a Dwell and even a number of consecutive EOBs, but these two solutions have failed in later controls. G31 is the popular choice of many of the MTBs I work with.

When using G31 in the manner it was designed, it will always complete before advancing to the next Block, by either receiving the Skip Signal and Skipping to the next Block, or not receiving the Skip Signal before its specified destination is reached and merely advancing to the next Block. Notwithstanding that G53 is considered by many to be the typical code to use to interrupt Look Ahead, its not required when using G31 in its normal manner. Accordingly, G31 executed with, or without Coordinate Addresses with stop Look Ahead.

I prefer to use G31 over G53 as, in my opinion and experience, G53 is in more general use for the purpose it was designed for than G31 and therefore, G31 is more conspicuous when I'm proof reading a CNC program. Also, I have one clients control where G53 did not work to halt Look Ahead and where G31 did. However, PROBE and I don't see eye to eye on this and have agreed to disagree.

Regards,

Bill
 








 
Back
Top