Available:*
Library | Item Barcode | Call Number | Material Type | Item Category 1 | Status |
---|---|---|---|---|---|
Searching... | 30000010267235 | TJ1189 S56 2010 | Open Access Book | Book | Searching... |
On Order
Summary
Summary
Publisher's Note: Products purchased from Third Party sellers are not guaranteed by the publisher for quality, authenticity, or access to any online entitlements included with the product.
Master CNC macro programming
CNC Programming Using Fanuc Custom Macro B shows you how to implement powerful, advanced CNC macro programming techniques that result in unparalleled accuracy, flexible automation, and enhanced productivity. Step-by-step instructions begin with basic principles and gradually proceed in complexity. Specific descriptions and programming examples follow Fanuc's Custom Macro B language with reference to Fanuc 0i series controls. By the end of the book, you will be able to develop highly efficient programs that exploit the full potential of CNC machines.
COVERAGE INCLUDES:
Variables and expressions Types of variables--local, global, macro, and system variables Macro functions, including trigonometric, rounding, logical, and conversion functions Branches and loops Subprograms Macro call Complex motion generation Parametric programming Custom canned cycles Probing Communication with external devices Programmable data entryAuthor Notes
S. K. Sinha earned his Ph.D. in mechanical engineering from the Indian Institute of Technology in 1993. He has 18 years of teaching experience in CNC programming and has been working in the CNC area for the past 10 years.
Table of Contents
Preface | p. xi |
Acknowledgments | p. xiii |
1 Introduction | p. 1 |
1.1 Part Programming Techniques | p. 2 |
Conventional Part Programming | p. 2 |
Conversational Part Programming | p. 3 |
Part Programming Using CAM Software | p. 3 |
Macro Programming | p. 4 |
Comparison of the Four Methods | p. 4 |
1.2 Certain Applications of Macro Programming | p. 4 |
Complex Motions | p. 5 |
Families of Parts | p. 5 |
Custom Canned Cycles | p. 6 |
"Intelligent" Programs | p. 7 |
Probing | p. 7 |
Machine Status Information/Manipulation | p. 8 |
Communication with External Devices | p. 8 |
1.3 Does My Machine Have Macro Capability? | p. 9 |
1.4 Aim of the Present Text | p. 11 |
1.5 How to Use This Text | p. 11 |
2 Variables and Expressions | p. 13 |
2.1 Macro Variables | p. 13 |
2.2 Macro Expressions | p. 13 |
2.3 Assigning a Value to a Variable | p. 16 |
2.4 Display of Variables | p. 18 |
2.5 Real versus Integer Values | p. 19 |
2.6 Undefined Variables | p. 22 |
Null Variables in Word Addresses | p. 22 |
Null Variables in Arithmetic Operations | p. 23 |
Null Variables in Conditional Expressions | p. 23 |
2.7 A Simple Use of Macro Programming Features | p. 24 |
2.8 Retaining Programs in MDI Mode | p. 24 |
3 Types of Variables | p. 27 |
3.1 Local and Global Variables | p. 27 |
3.2 Effect of System Reset on Macro Variables | p. 28 |
3.3 Levels of Local Variables | p. 29 |
3.4 Range of Values Stored in Variables | p. 33 |
3.5 System Variables | p. 35 |
System Variables versus System Parameters | p. 35 |
System Variables on Fanuc 0i Series Controls | p. 36 |
Displaying System Variables | p. 36 |
Interface Signals | p. 37 |
System Variables for Input Interface Signals | p. 40 |
System Variables for Output Interface Signals | p. 40 |
Geometry and Wear Offset Values | p. 40 |
Workpiece Coordinate System Shift Amount | p. 43 |
Macro Alarms | p. 44 |
Time Information | p. 45 |
Automatic Operation Control | p. 45 |
Execution Pause | p. 48 |
Mirror Image Information | p. 48 |
Number of Machined Parts | p. 48 |
Modal Information | p. 49 |
Current Tool Position | p. 52 |
Work Offset Values | p. 55 |
4 Macro Functions | p. 57 |
4.1 Types of Macro Functions | p. 57 |
Priority of Operations in Arithmetic Expressions | p. 57 |
Priority of Operations in Boolean Expressions | p. 58 |
Effect of Order of Calculations | p. 58 |
Nesting of Brackets | p. 59 |
4.2 Arithmetic Operations | p. 59 |
Division versus Block-Skip Function | p. 60 |
4.3 Trigonometric Functions | p. 60 |
4.4 Rounding Functions | p. 63 |
ROUND, FIX, and FUP | p. 64 |
4.5 Miscellaneous Functions | p. 67 |
SQRT | p. 67 |
ABS | p. 67 |
LN | p. 68 |
EXP | p. 68 |
Arbitrary Exponent of a Number | p. 69 |
4.6 Logical Functions | p. 69 |
Bitwise Functions | p. 69 |
Boolean Functions | p. 71 |
Bitwise versus Boolean Operations | p. 72 |
Enabling Boolean Operations | p. 73 |
An Application Example of Bitwise Operation | p. 73 |
4.7 Conversion Functions | p. 75 |
5 Branches and Loops | p. 79 |
5.1 Unconditional Branching | p. 79 |
5.2 Conditional Branching | p. 80 |
5.3 Conditional Execution of a Single Macro Statement | p. 93 |
5.4 Execution in a Loop | p. 94 |
5.5 Arithmetic Operations on Macro Variable Numbers | p. 103 |
Methods of Zero Shift | p. 106 |
Machine Coordinate System | p. 107 |
External Workpiece Coordinate System | p. 107 |
G54-G59, G54.1 P1-P48 Workpiece Coordinate Systems | p. 108 |
Zero Shift by Manipulating Offset Distances | p. 109 |
Zero Shift through System Variables | p. 109 |
Work Offset Display on a Milling Machine | p. 110 |
System Variables for Various Work Offset Values | p. 111 |
Zero Shift through a Program | p. 111 |
5.6 Nested WHILE Statement | p. 115 |
6 Review of Subprograms | p. 121 |
6.1 Introduction | p. 121 |
What Is a Subprogram? | p. 121 |
Why Is It Used? | p. 121 |
Subprograms versus Subroutines of a Conventional Computer Language | p. 122 |
6.2 Subprogram Call | p. 122 |
6.3 Multiple Call of a Subprogram | p. 125 |
6.4 Subprogram Nesting | p. 132 |
7 Macro Call | p. 137 |
7.1 Introduction | p. 137 |
7.2 Macro versus Subprogram | p. 137 |
7.3 Macro Call | p. 138 |
Simple Call (G65) | p. 138 |
Modal Call (G66) | p. 141 |
Call with User-Defined G-Code | p. 145 |
Call with User-Defined M-Code | p. 147 |
7.4 Subprogram Call without Using M98/M198 | p. 148 |
Subprogram Call Using an M-Code | p. 148 |
Subprogram Call Using a T-Code | p. 150 |
7.5 Argument Specification | p. 151 |
Argument Specification I | p. 152 |
Argument Specification II | p. 153 |
Mixed Argument Specification | p. 154 |
An Example of a G-Code Macro Call with Arguments | p. 155 |
7.6 Processing of Macro Statements | p. 163 |
What Is Buffering? | p. 163 |
How Many Blocks Are Buffered? | p. 163 |
When Are the Buffered Blocks Processed? | p. 163 |
Processing When the Next Block is Not Buffered | p. 163 |
Processing in Radius Compensation Cancel (G40) Mode | p. 164 |
Processing in Radius Compensation Mode (Case 1) | p. 164 |
Processing in Radius Compensation Mode (Case 2) | p. 164 |
Effect of Buffering of Macro Statements on Program Execution | p. 165 |
8 Complex Motion Generation | p. 167 |
8.1 Introduction | p. 167 |
8.2 Arc with Uniformly Varying Radius | p. 167 |
8.3 Helical Interpolation with Variable Radius | p. 175 |
8.4 Parabolic Turning | p. 181 |
Roughing Operation | p. 184 |
Step-Removal Operation | p. 184 |
8.5 Turning a Sine Curve | p. 188 |
9 Parametric Programming | p. 193 |
9.1 Introduction | p. 193 |
9.2 Locator Pin | p. 194 |
9.3 Bolt Holes on a Flange | p. 200 |
10 Custom Canned Cycles | p. 207 |
10.1 Introduction | p. 207 |
10.2 Deep-Hole Peck Drilling on a Lathe | p. 207 |
10.3 Drilling with Reducing Peck Lengths on a Milling Machine | p. 215 |
11 Probing | p. 223 |
11.1 Introduction | p. 223 |
11.2 Skip Function on a CNC Machine | p. 224 |
11.3 Probing a Pocket | p. 224 |
11.4 Finding Center of a Hole | p. 228 |
11.5 Finding Angle of an Edge | p. 231 |
11.6 Adjusting Wear Offset | p. 233 |
12 Communication with External Devices | p. 237 |
12.1 Introduction | p. 237 |
12.2 Switching Principle | p. 237 |
12.3 Input Types and Wiring | p. 239 |
12.4 Connector Pin Assignment | p. 240 |
12.5 Discrete Sensors for Sourcing/Sinking PLC Inputs | p. 244 |
12.6 Output Types and Wiring | p. 246 |
13 Programmable Data Input | p. 251 |
13.1 Introduction | p. 251 |
13.2 Data Input for WCS Offset Distances | p. 252 |
13.3 Data Input for Additional WCS Offset Distances | p. 253 |
13.4 Data Input for Compensation Values on a Milling Machine | p. 254 |
13.5 Data Input for Compensation Values on a Lathe | p. 255 |
13.6 Data Input for Parameter Values | p. 258 |
A Limitation of G10 L50 Method | p. 262 |
Appendix A List of Complex Macros | p. 263 |
Appendix B List of Parameters | p. 265 |
Index | p. 267 |