S-code – spindle speed value

S-code – spindle speed value


T-code – tool number


P-code – additional work offset number

As the ta ble illustrates, the only ex cep tion in the ta ble is the #4130 vari able – it has no cor re –

drilling Machine

spond ing value in the As sign ment List 1 for lo cal vari ables It was added by Fanuc later, when the

CNC tech nol ogy ad vanced, to ac com mo date the ex tended work off set set, also known as the ad di –

tional work off sets – G541 P1 to G541 P48 Vari ables that would ‘fit nat u rally’ in the ta ble, but are miss ing, for ex am ple #4118, are quite le git i mate to use, pro vid ing they are sup ported by

the con trol sys tem for the par tic u lar CNC ma chine tool (not ex actly a likely sce nario)

There are two sys tem vari able num bers that may seem out of or der – they are #4114 (the let ter

N, the ad dress for the se quence num bers), and #4115 (the let ter O, the ad dress for the pro gram

num ber) In the As sign ment List 1, there are no #14 cnc equipment and #15 lo cal vari ables listed These as sign –

ments are phys i cally ex cluded in the list, but notching machine they are im plied by their on-pres ence

Copyright 2005, Industrial Press Inc, New York, NY –

FANUC CNC Custom Macros


Chapter 12

Fanuc 10/11/15

The list ing of sys tem vari ables for the higher group of Fanuc con trols uses both sets of vari ables

– for the pre ced angle shearing machine ing block, and for the ex e cut ing block


Variable Number

Program Address

(Code Letter)

Preceding Executing





B-code – indexing axis position



D-code – cutter radius offset number



E-code – feedrate value (if available)



F-code – feedrate value



H-code – tool length offset number



M-code – miscellaneous function



N-code – sequence number



O-code – program number



S-code – spindle speed value



T-code – tool number



P-code – Additional work offset number

As in the table for the modal G-codes listed earlier

his is sim i lar to the con cept of ead-only and the ead-and-write

type of vari ables in many gen eral com mer cial pro gram ming lan guages, cov ered in the last chap –

ter The listing of the ‘other’ eleven modal ad dresses that can be used in macro pro gram ming, is

pre sented here:


These modal codes are in ad di tion to the modal G-codes On the next two pages are the list ings

drilling Machine

of the sys tem vari ables re lat ing to the ‘other’ modal ad dresses, for the two com mon types of

Fanuc con trols Ob serve angle machine the method of how these vari ables are num bered, again, there is a log i cal

method to it, and a lit tle dif fer ent one from the one used for modal G-codes Also note the last two

dig its of each sys tem vari able num ber They cor re spond to the Lo cal Vari ables As sign ment List 1

For ex am ple, the let ter B is as signed to the lo cal cnc equipment vari able #2, hence the #4102 sys tem vari able,

the let ter D is as signed to the lo cal vari able notching machine #7, hence the #4107 sys tem vari able, and so on

Very valu able ob ser va tion that can come handy

Copyright 2005, Industrial Press Inc, New York, NY – FANUC CNC Custom Macros



Fanuc 0/16/18/21

As in the table for the modal G-codes listed earlier, the lower level con trols use only sys tem

vari ables ap ply ing to the pre ced ing block The sys tem vari ables re lated to the ex e cut ing block are not avail able for this group of Fanuc con trols (FS-0/16/18/21)

The fol low ing ta ble shows the other modal in for ma tion (eleven com mon ad dresses) fre quently

used in a macro pro gram with their cor re spond ing sys tem vari ables



Program Address


(Code Letter)


B-code – indexing axis position


D-code – cutter radius offset number


E-code – feedrate value (if available)


F-code – feedrate value


H-code – tool length offset number


M-code – miscellaneous function


N-code – sequence number


O-code – program numbe

Basic language in its original form is now a his tory

Basic language in its original form is now a his tory, many of its rules and

struc tural forms still do ex ist Ba sic lan guage has de vel oped into the cur rent Vi sual Ba sic, very mod ern, and struc tured, high level lan guage One of the rem nants busbar bending machine of the old Ba sic is the func tion

GOTOn, and GOSUB, both con sid ered to day a very poor way of lan guage based pro gram struc –

ture How ever, the other branch ing func tions (IF, IF-THEN, and WHILE) are avail able to con –

drilling Machine

trol the flow of the macro pro gram

In ei ther form, the de ci sion is al ways based on the re sult of a given con di tion, or given sit u a –

tion De pend ing on this re sult, at least two other op tions must be avail able for fur ther con sid er –

ations As an ex am ple, the ev ery day Eng lish equiv a lent of – f I have money, I will buy a car

has two parts The con di tion here is ‘if I have money’ – ‘to have money’ There are two logical out –

comes – they are ‘I will buy a car’ and cnc equipment ‘I will not buy a car’ , one or the other, but never both f I

have money, I will buy a car, but notching machine I do not have money, so I will not buy a car Sim ple logic, and very pow er ful when ap plied to mac ros

The sim plic ity of the above ex am ple is very strong when trans ferred into the realm of a macro

pro gram ming Of course, the macro con di tions and macro op tions will al ways be dif fer ent, but

the logic, the eval u a tion, the think ing pro cess, and the de ci sion will not

For ex am ple, one ob jec tive of a macro could be to check if the cut ting tool trav els within the

lim its of the ma chine For each axis to be tested, a very spe cific con di tion will be created – f the

length of travel is greater than the given dis tance, then , and the macro will have to con tain the

de ci sion in it own format If the con di tion spec i fied is true, the CNC op er a tor may be no ti fied

with an alarm mes sage or at least a pro gram com ment If the con di tion is false (not true), the

macro will pro ceed with the pro gram flow

with out in ter rup tion The op er a tor may not even be

with out in ter rup tion The op er a tor may not even be

aware of the eval u a tion and Drilling Machine for Plate de ci sion tak ing place This chap ter cov ers var i ous as pects of con di –

tional test ing, branch ing, and loop ing, de pend ing on the com plex ity of the given con di tion and the

pur pose of such eval u a tion

drilling Machine

The first and the sin gle ma jor func tion in all the above ex am ples is the IF func tion


Copyright 2005, Industrial Press Inc, New York, NY –

FANUC CNC Custom Macros


Chapter 13

IF Function


The IF func tion has sev eral names – it is called the de ci sion func tion, the di ver gence func tion, or most com monly, the con di tional func tion The for mat of th IF func tion is:


where n is the block num ber to branch to, but only if the eval u ated con di tion (the re turned value) is TRUE If the con di tion is true, all state ments be tween the IF-block and GOTOn-block will be by passed If the eval u ated con di tion is not TRUE, it is FALSE, and the pro gram will con –

tinue pro cess ing the next block fol low ing the block con tain ing the IF func tion We can sche mat i –

cally rep re Dished Head Punching Machine sent the last ex am ple in a sim ple flow chart in Fig ure 19



Schematic flowchart representation


of the


IF conditional branching








The flowchart only shows the de ci sion mak ing and the re sults, not any com plete pro gram The

di ag o nal box iden ti fies the con di tion to be eval u ated (for ex am ple, ma chine travel lim its), and the

two rect an gu lar boxes iden tify two – and only two – pos si ble out comes (YES or NO) Each out –

come re sults in an ac tion to be taken:


If the travel Angle Punching IS too long, gen er ate alarm condition and stop pro cess ing


If the travel IS NOT too long, run the rest of the pro gram nor mally

The IF func tion is one of the macro state ments that con trol the or der of pro gram pro cess ing

Conditional Branching

Branching from one block of

What is missing are all system variables that have some thing to do

n that may be valu able from this chap ter re lates to the list It is not what is in –

cluded, but what is miss ing Modal com mands used in the macro pro gram ming have been dis –

cussed ex ten sively, along with the re lated sys tem vari ables An other sub ject dis cussed was the

ma jor group of the modal G-code ad dresses, and eleven other modal ad dresses What is miss ing?

What is missing are all system variables that have some thing to do with a tool po si tion, such as

end point co or di nates in a block, work co or di nates, angle machine ma chine co or di nates, var i ous tool off set po si –

tions, co or di nates re lated to the skip func tion, and so on – even de vi a tion amount of the servo po –

drilling Machine

si tion, etc

In the chap ters that fol low this one, more sys tem vari ables will be cov ered, most listed ear lier in

a de scrip tive form They in clude those re lated to alarms, tim ers, and var i ous axis po si tion in for –

ma tion The next chap ter cov ers an other part of the most im por tant automatic punching machine macro pro gram ming tools –

conditional testing, branch ing and loop ing

Copyright 2005, Industrial Press Inc, New Dished Head Punching Machine York, NY –

FANUC CNC Custom Macros



About half way through the hand book, now co mes a real pow er house of mac ros At this level of

macro de vel op ment, strong ba sic knowl edge of macro com mand struc ture, off sets, mem o ries, as

well as understanding vari ables, etc, is essential A vari able is as signed a value, macro is pro –

cessed with that value in ef fect, macro ex its This straight for ward ap proach is convenient, and

very com mon, but it can not and does not stand alone It needs some ad di tional forms of data ma –

nip u la tion, forms based on some kind of de ci sion mak ing pro cess

Decision Making in Macros

The struc ture of a typ i cal Fanuc macro pro gram is based on the old est and sim plest of all com –

puter lan guages – Ba sic锟? The Ba sic lan guage proved to be sim ple, yet pow er ful, lan guage for its

Development and Challenges of Hydraulic Foot – driven Robots

1. Electro-hydraulic servo control technology overview
As a bridge connecting modern microelectronic technology, computer technology and hydraulic technology, electro-hydraulic servo control technology has become an important constituent of modern control technology, with good linearity, small dead zone, high sensitivity, dynamic performance, fast response and high precision. Significant advantages. Electro-hydraulic servo control system consists of hydraulic control unit, servo cylinder, power oil Angle Steel Punching Machine three major components. Application of the system summed up in a total of the following ways: valve-cylinder servo system, valve-controlled motor servo system and pump-controlled motor servo system.

laser cutter laser cutting machine

Electro-hydraulic servo control system has the following advantages:
(1) The power-to-weight ratio and the moment-to-inertia ratio (or force-mass ratio) of the hydraulic components are large, and the forces (or moments) and power delivered are large, making it possible to form small, light, fast, Action of the servo system to control high-power or large load.
(2) hydraulic actuator response speed, servo control in the use of hydraulic actuators can increase the loop gain, the band widened.
(3) anti-load rigidity, so high control accuracy.
In addition, there are components of good lubricity, long life, easy to achieve stepless speed regulation, overload protection and easy.
Electro-hydraulic servo control system has the following disadvantages:
(1) as the working medium is oil, prone to leakage Angle Drilling machine, pollution of the environment.
(2) hydraulic servo components, high precision, and therefore expensive.
(3) susceptible to oil pollution.
2. Foot-type robot overview
At present, the common walking robot is applied in two-legged, four-legged and six-legged type. The robot is the most representative in the United States and Japan. Among them, the bigdog robot in the United States Climbing up to 52kg and climbing up to 35 °. Its leg joints resemble the joint structure of the animal’s legs and are equipped with vibration-absorbing and energy-cycling components. At the same time, the legs are connected with a number of sensors, The movement is controlled by the servo motor. The robot has strong maneuverability and reaction ability. The balancing ability is very good. However, because the gasoline generator needs to carry the fuel tank, it is affected by the environment and poor reliability. In addition, Servo control system, so when walking the engine will issue a strange noise. In addition, Japan Chiba University to low-speed walking, not afraid of slope-based comet-tv robot and Japan chukyo universuty to low-speed walking, climbing-based TTTAN XI robot is a typical representative of foot-type robot.
In summary, the foot-type robot has great advantages such as high efficiency in land-propulsion, stability, strong terrain adaptability, best solution in the conventional mobile-inaccessible area, and thus become the future battlefield, industrial production and exploration Mining an important means of one.
The application of electro – hydraulic servo control technology in foot – type robot
In the process of motion, the foot-type robot, as a rigid body mainly made by machinery, produces a considerable impact load with the ground due to the impact, and the size and direction of the load always show irregular changes, the BigDog robot in the United States For example, the hydraulic drive system consists of a variable piston pump driven by a gasoline engine at the same time on the implementation of 16 hydraulic actuators hydraulic output to achieve the purpose of power output, hydraulic transmission has two characteristics: hydraulic system Busbar Processing Machine oil The pressure depends on the size of the external load, the speed of the implementation of components depends on the flow of hydraulic systems, these two points just with the foot-type robot body of the load and the corresponding rotation. The engine controls the rotation speed of the piston according to the load and rotational speed carried by each joint of the robot body, thus controlling the hydraulic output of the piston pump, adapting to the dynamic demand of the robot movement and has the ability of predicting. The faster the movement speed of the robot, The more severe the change, the greater the corresponding hydraulic output, and vice versa, in order to achieve a strong enough to adapt to the foot-type robot terrain changes.
The foot-type robot makes full use of the characteristics of the hydraulic transmission in the dynamics, and transfers the analysis and calculation of the dynamics to the control of the hydraulic system. The force and torque output of the hydraulic system mainly depend on the load of the terminal actuator. Size and changes, adjust the engine speed to achieve the total hydraulic pressure on the hydraulic control, and then through the electro-hydraulic servo valve control into a single actuator of the oil pressure, flow and flow rate and other parameters to achieve the output load according to the corresponding balance Of the force and torque, including acceleration and deceleration of the situation.
However, the foot-type robot with motor control needs to predict the load of each joint in the next period and set the output of the motor, but this output can not achieve the fast output and load balance of the hydraulic output. Motor output or greater than the terminal load, or less than the terminal load, only in a few cases the two just balance, which is the common motor-driven foot-type robot in the walk, the body will appear the majority of shaking reasons, Unbalanced, and hydraulically actuated foot-type robots, unless subjected to sudden drilling equipment manufacturers external forces, in most cases can be in a dynamic balance, the key is the adaptability of its hydraulic system play a decisive role, when the hydraulic-driven foot When the robot accelerates, the output torque needs to be greater than the current load, which is the use of the servo valve control flow rate function, when an actuator where the limb load suddenly increases, can also use the servo valve pressurization function, To achieve in the actuator oil pressure is greater than the performance of the total road oil pressure.

laser cutting machine

The kinematic efficiency of the foot-type robot depends on three aspects: internal friction caused by the motion mode, the transmission efficiency of the mechanical structure and the internal friction caused by the control. The internal friction of the movement mode includes the barying of the center of gravity, the swing of the leg relative to the fuselage and so on. The mechanical part mainly includes each active joint and the hydraulic actuator internal and output end movement conversion mechanism. Thereby requiring energy-efficient driving, compliant adaptation, and adaptable terrain switching control. Although the electro-hydraulic servo control technology can meet the requirements of the latter two, the low efficiency of the hydraulic system becomes the soft rib of the further development of cnc punch machine the foot-type robot, which leads directly to the low efficiency, large volume and high input power of the foot-type robot. As well as the significant shortcomings of poor endurance. In addition, due to the hydraulic system has a lot of noise, but also directly lead to the foot-type robot in the work of the noise is not conducive to the implementation of tasks on the battlefield and the implementation of exploration, which is currently foot-type robot is not widely used important reason one.
In summary, the foot-type robot drive requires high power density ratio and for strong terrain adaptability, it also needs position and force rapid response and precise control and switching, so the electro-hydraulic control system has become a foot-driven robot The best not to replace the program.
Development and Challenges of Hydraulic-driven Foot-type Robots
1. Research on foot-type robot
With the deep research and development of foot-type robot, the performance of foot-type robot in speed, stability, flexibility and adaptability to the ground will continue to improve, the autonomy and intelligence will be gradually realized, comprehensive analysis, The future development, foot-type robot has the following trends:
(1) to achieve high-energy, high-efficiency legs
Animal tendon muscles are highly efficient energy storage and energy saving components to solve the problem of high speed and stable walking and energy efficiency, and foot-type robot robot joints and rigid joints are rigid, not only can not be stored, and because of the touchdown Impact, to consume a lot of energy, and high power and has a buffer energy storage measures of the leg body is a hot issue for future research.
(2) foot-type mobile technology and wheel technology
The combination of foot-type movement and wheel-type technology can not only control the efficiency of movement through wheel-type control, but also use leg mechanism to achieve obstacle avoidance and obstacle avoidance. At present, the combination of wheel and foot Research, in the future research work in wheel, foot combined research will be further increased.
(3) miniaturization of walking robots
Micro-walking robot has a broad application prospects, it can be widely used in various scientific exploration, industrial operations, such as in a small space such as pipe walking, operation and maintenance.
(4) to enhance the foot-type robot load capacity
At present, the research of foot-type robot is mainly focused on small-scale and light-weight, easy to control and so on. It has a certain gap from the low energy consumption and high load requirement. In practical field work, the usability is poor, The research of foot-type robot with low energy consumption of walking mechanism is also an important direction for future research.
(5) robot bionic to further deepen
Foot-type robot can not only be limited to the imitation of institutions, but also should imitate the biological functions, such as the bat’s hearing, dog’s sense of smell, dragonfly’s vision.
In summary, although the foot-type robot technology has made great progress, but constraints of further development of foot-based robot theory has not been fundamentally solved, many of the robot also failed to simple biological movement speed and stability , The key technology of the foot-type robot still needs to be further developed energetically.
Electro-hydraulic servo control foot-type robot technology challenges
Because the electro-hydraulic servo system is a serious uncertain nonlinear system, the environment and characters are complex, and there are many parameters such as external disturbance and cross-coupling interference. In addition, electro-hydraulic servo system has high requirements on frequency band and tracking accuracy. In the application of foot-type robot, because it is in the high-precision fast tracking conditions, the nonlinear effect of electro-hydraulic servo system can not be ignored, so it can be said that electro-hydraulic servo system is a typical unknown uncertain nonlinear system, This kind of system has large disturbance, wide working range, many time-varying parameters and difficult to be modeled accurately. These characteristics will have serious influence on the stability CNC H-Beam Drilling Machine, dynamic characteristics and precision of the system. Especially, the control precision is affected by the load characteristics. It is predicted that the application of computer control in the electro-hydraulic servo system makes the realization of the complex control strategy possible, thus improving the robustness and control precision of the system and playing an active role in solving many engineering problems. In the environment of robot, due to the large disturbance and serious uncertainty of environment, the adaptive algorithm is required to be complicated and difficult to be realized. In addition, its processing ability to nonlinear factors is unsatisfactory. In recent years, , The development of control subjects also contributed to the intelligent control of electro-hydraulic servo control system.
In summary, the hydraulically driven foot-type robot has a wide application prospect and research value because of its many significant advantages, but because of the hydraulic system itself, there are some major flaws also limit the further development of hydraulic drive robots, Therefore, it is necessary to study and solve the problems of electro-hydraulic servo control technology such as low efficiency, high noise and nonlinearity. Only by breaking these technical difficulties, can the development of foot-type robot take a higher level .

Stainless steel wire rope protection measures

In order to avoid the use of stainless steel wire rope and placed in the unnecessary damage angle steel machine, you need to do some of the corresponding stainless steel wire rope protection measures. So what are the specific protective measures? Today by the Chiron to explain for everyone. First, the transport, the application of transport (such as cars, battery vehicles, etc.), clean, isolated protective measures to prevent dust, oil, rust pollution of stainless steel wire rope. Do not drag, to avoid bumps, scratches. Second, when lifting, should use special spreader, such as lifting belt, special chuck, is strictly prohibited to use sharp, rough lifting equipment, so as not to scratch the surface of stainless steel wire rope.


In the lifting and placement, should avoid shock bumps caused by stainless steel wire rope scratches steel cutting machine. Third, there should be a special storage rack, storage rack should be wood or surface coating of carbon steel bracket or pad to rubber pads cnc plate drilling machine, with carbon steel and other metal material isolation. Storage of stainless steel wire rope and other materials to be relatively isolated storage area hydraulic angle cutting machine, there should be protective measures to avoid dust, oil, rust on the stainless steel wire rope pollution. Above these protective measures we all remember it? To ensure the normal life of stainless steel wire rope, stainless steel wire rope to ensure safe and reliable work, the relevant protection measures is necessary, you must bear in mind.

Punch industry in the future more humane

Punch industry in the future more humane With the world from the industrial economy to the era of knowledge-based economy changes, production-oriented enterprises on the urgent need for automated punch will be highlighted, but at the same time the development of the domestic press is relatively backward and aggravated the contradiction between supply and demand, and ultimately lead to a vicious circle. Although China’s punch industry is not standing still, but only as soon as possible to scientific and technological innovation, close to the user, independent research and development operations instead of blindly introducing and copying the traditional model in order to make China’s punch industry and the healthy development of the market and catch up with the world advanced Level saw machine. Dongguan IPM Precision Machinery Co., Ltd. to meet the global development of the punch industry for the majority of the new and old customers with a quality and cheap punch. In this case, Commodity of human nature, has gradually become a shopping standard when people choose. Comfort, reliability, value, safety and efficiency of the evaluation, the punch industry after decades of development history, the continuous development of human resources, humanistic design is in the design process to fully consider the human physiological and psychological factors, more attention to product convenience, comfort, Production, updating, replacement.

In this case, Punch mechanical properties: Using high-strength cast iron, the stress elimination, to ensure long-term accuracy Three-column guide post designed to minimize dynamic friction, with forced lubrication and oil cooling system to minimize heat distortion The use of hydraulic locking system, the mold is more simple and direct The use of high-performance damping system to extend the service life of presses, to avoid interference with the external environment Using the world’s most advanced digital frequency technology to ensure product quality The top dead center stops the device and protects the mold effectively Using the microcomputer controller copper busbar bending machine, punch angle, speed and fault location and other information, all in a separate console display Reprovision detection of the final material, mistakenly sent, blowing materials, shaped scissors, more humane In this case, IPM has a highly sophisticated technical personnel, with high-quality work team, in time for our customers to provide comprehensive after-sales service Hydraulic punching machines. The company has always been to ‘people-oriented, technology leadership, integrity management, a well-known brand’ for the purpose, as always, to provide reliable products, perfect service and common development and create success. Article source punch manufacturers: www.ipmmc.com

The latest sheet metal presses

The latest sheet metal presses, Taiwan Punch, Huizhou general punch The latest sheet metal punch by the high steel frame design beam fabrication, the use of high-quality steel welding system Ring Drilling Machine, through the elimination of internal stress process. Improve the accuracy of the whole machine stability and reliability, Taiwan Punch precision molds up to 0 Angle Drilling machine.1mm, safe, convenient and reliable, Huizhou general press transmission center and the machine as a whole center to ensure accurate and stable stamping.

In order to ensure the relative smoothness of the machine operation, it adopts two sliders and balancer design methods, which can be equipped with various automatic equipments to automate production, reduce the cost and improve the efficiency. For more information on presses, please visit www.ipmmc.com

The latest Shenzhen punch CNC Flange Drilling Machine

The latest Shenzhen punch CNC Flange Drilling Machine, punch Taiwan, ordinary punch The latest Shenzhen punch by high steel frame design steel hole punch, the use of high-quality steel welding system, through the elimination of internal stress process. Improve the accuracy of the whole machine stability and reliability, Taiwan punch precision molds up to 0.1mm, safe, convenient and reliable.

Ordinary punch press transmission center and the center of the machine as a whole bevel tools, to ensure accurate and stable stamping. To ensure the relative stability of the machine running, the use of stacked into two slider, balancer device design.

« Older Entries