Modal and non modal G codes

CNC Training Call David: 07834 858 407

30 Five Star Reviews

CNC Training Centre Reviews

Contact CNC Training Centre

 

Modal and non modal G codes

Modal and non modal G codes

Let Me explain

We all know that programming can be complicated. So let me explain to you how it all works. This article explains the real meaning of Modal and non modal G codes.

Modal means that once a command is issued it stays in the control.

How Can you Actually Use This?

If you issue a G0 or G00 command the machine is in rapid and you do not need to re-state it.

Rapid means all motors are flat out, like a teenager in a Ferrari.

Every move from then on will be a rapid move unless you tell it otherwise. The G code that changes it must be in the same group. For example G0 G1 G2 and G3 are all in the same group a bit like The Beatles used to be.

The other day I was talking to  a “young person” who hadn’t even heard of the Beatles. I mean fuckin hell, am I really really old or are they doomed to be forgotten?

“Read More”

CNC Machine Training Classes

Category : Training

CNC Training Call David: 07834 858 407

30 Five Star Reviews

CNC Training Centre Reviews

Contact CNC Training Centre

CNC Machine Training Classes now running at the CNC Training Centre

Beginners

Setter Operator Beginners Turning

Setter Operator Beginners Milling

These two courses are designed for beginners who want to learn how to set and operate a CNC machine and are for students with very little engineering experience.

 Learn to Programme

Learn To Programme Turning

Learn To Programme Milling

If you already work on a CNC Machine but you want to learn to programme then the two courses above are for you.

Absolute Beginners

I have added these courses which are for students with very little engineering experience. They cover the basics of milling and turning in preparation for learning to programme.

Beginners turning

Beginners Milling

 

They are two day courses but pack a lot in, covering tooling and measuring instruments. I am drawing from my vast experience in industry, on the coal face as it were, and knowing the very basics skills that are needed by a CNC operator before he begins to learn about programming.

The New CNC Training Classes and Courses focus very much on the basics giving a solid understanding of the nuts and bolts of CNC programming on an ISO Fanuc Haas type control.

The Story

I am going to ramble on, because I always do, but it made me think of when I worked with my dad many years ago. My dad was a brilliant old school engineer and he worked for Alfred Herberts from boy to man, apart from a brief period in the RAF.

New CNC Training ClassesHe got made redundant and had his pension robbed when AH finally went bust. I was running an engineering company so it seemed obvious to have him working for me.

I learnt so much from my dad about the basic principles of machining (this is the link to the training courses) albeit tenuous. His claim to fame was that he worked the first Cri Dan machine. This was an amazing innovative machine that could hold it’s own, until fairly recently, against a CNC lathe for high-speed threading. There are still a few about now.

New CNC Training ClassesMy dad often joked that he could offhand grind a 1/16 of an inch drill and read a steel rule to a thousandth of an inch which I am sure was bullshit although I would never dare to say. I remember we were trying to turn and bore some motor bodies on a Mori Seiki lathe and we could not get them round. Anyway he told me to weld up some jaws so that they would fully envelop the part.

CNC Machine Training ClassesCNC Machine Training Classes

Basically it had nowhere to go it was like a big collet and it worked. But there was another lesson to learn. Our inexperienced inspector was trying to measure roundness with a micrometer which I am sure you all know cannot be done.

CNC Machine Training Classes

 

An argument ensued and profanities were exchanged. We ended up buying a Talyrond roundness checker which is the correct tool for the job.

New CNC Training Classes

 

As it happens the same thing cropped up in a customer’s only a few months back. I caught them trying to measure roundness with a micrometer. Back to basics again.

These days I have a much better way to prove my point than shouting and swearing and it’s cheap 50 pence to be precise.

 

I threw them a 50p piece (UK Currency) or even a 20p for the real cheapskates. “Is that round” was my question. They laughed

.

“Here is a micrometer now check it for roundness”.

Mmm it’s dead round when you check it with a micrometer.

The smart arses amongst you will know that a 50p piece is an “equilateral curve heptagon“. And it measures the same across any two points you care to choose. It proves that you can’t measure roundness with a micrometer.

I won’t be teaching you about roundness on these courses ,that would be silly you already know, but if you are interested in learning basic CNC Programming for a Lathe or Milling Machine look no further.

The New CNC Training Classes focus very much on the basics giving a solid understanding of the nuts and bolts of CNC programming on an ISO Fanuc Haas type control.

See all The Courses

Or fill out the contact form below


Tool Length Offsets Beginners CNC

CNC Training Call David: 07834 858 407

30 Five Star Reviews

CNC Training Centre Reviews

Contact CNC Training Centre

 

This article will explain all you need to know about tool length offsets and setting tool length offsets Fanuc

Ok so you managed to write a CNC Programme for your CNC Milling Machine, well done.

A CNC program is a set of instructions telling your CNC Machine exactly how to machine your component.

It contains all the necessary tool paths XY position and Z depths.

It also contains on off signals to do things like starting the spindle (M3 clockwise M4 counterclockwise).

The progam will have all the feeds and speeds for your tools. You may have performed a simulation using the graphics on your machine.

 

tool length offsets

Lots of software like Edgecam can perform full collision detection. You have a model of every tool and it’s holder. There is full model of the machine and all the work-holding.

tool length offsets

Edgecam will even tell you if the flute length of the tool is too short!

Ok so that is all great so far but when we put this program in the machine to run there are three things the machine doesn’t know.

Can you guess what they are?

No it doesn’t know jackpot winning lottery numbers (that would be four things it didn’t know).

  1. It doesn’t know where the part is in the machine coordinate system.

  2. It doesn’t know how long the tools are (tool length offsets).

  3. It doesn’t know the diameter of the tools.

Vital information wouldn’t you say?

So first of all we use the Work Offsets to tell the machine where the part is.

Read this for more CNC Help if you want to learn how Work Offsets are used.

Please don’t worry if you don’t know how to do this after all this is beginners help with tool length offsets .

Your mates don’t know your reading it, you can tell them you already knew all this shit.

tool length offsets

So in the picture above we would touch the spindle nose onto the Z datum of our work-piece. This would tell the machine where the part is in the Z axis.

 

tool length offsets

 

This distance is input into our work offset table (in this case G54).

If we now program G0 G54 Z0 the spindle would rapid down to this position (G54 is where the values are stored).

We wouldn’t do this by the way cos the machine would crash.

tool length offsets

Now The Tool Length

What we now need to do is take into account the length of the tool.

We would measure each tool length and store it in our tool length offsets file.

tool length offsets
This is how they look on a Haas Machine

This tool length offsets file stays in the machine and is independent of your CNC Programs. So now any program can access this file.

So how does it do that?

It uses G43 and G43 says “ok get me a tool length offset”

G0 G43 Z3. H1

Which tool offset?? Well that’s the H number.

So the line above says to the machine rapid to Z3. Oh and by the way allow for the length of Tool 1 before you get there.

That’s the H1

So it gets the tool length from the tool length offsets file. It then does all the maths for you.

Actually it’s just a bit of simple arithmetic. Your (G54) work offset) minus your tool length.

Your tool will arrive 3mm above your component.

So whatever tool you called into the spindle with your M6 command you need to use the corresponding H number.

M6 T5                                                  (Get tool 5 in the spindle)
G90 G0 G54 X0 Y0 S1500 M3    (Rapid to X0 Y0 and start the spindle)
G43 Z3. H5                        (Rapid to Z3. but allow for the length of tool 5)

How do you measure the tools?

tool length offsets

Well some people use a bit of paper!!!

And some buy one of these little babies.

“It’s just a light on a fuckin stick” I hear you say. But it’s so much more. I comes on at an exact distance above your part. And because it’s all spring loaded, if the tool carries on a bit it don’t bust anything.

Only cheap but do a great job.

setting tool length offsets fanuc

And if your a very good boy you might get one of these for Christmas.

tool length offsets

Auto tool measurement (yes it’s all done for you)

In the cases above we are storing the actual tool length in the offset file.

Now let’s take a look at that tool file again.

tool length offsets

Some of my readers are very astute but before you start writing me an email or commenting on this article. “oh David it looks like you fucked up again”

I know……

Why are the tool lengths (Under Geometry) minus figures?

That’s because as always there are several ways to do this. What some people do (and I am not one of them) is……

They bring each tool down from zero return and touch on the part. This figure is then recorded in the tool length offsets file. And yes it’s a minus figure. Of course the G54 work offset would be zero in the case of Z.

tool length offsets

 

Now I am not prepared to argue with you about this (your doctor told me not to). It’s just bad.

Maybe you might want to read this?

That figure has no relation to the actual tool length and you need to reset every tool for every Job!!

I’m saying no more I’ll just wait for the comments.

There is Only One Way

Actually there is something else to consider. (I know I
said I’m saying no more).

By setting your tool length the correct way (my way), the stored offset is the actual tool length and you can do a rough check with your steel ruler before proving your program.

Auto tool length measurement will always give actual tool length and so will a tool pre-setter. That means you can swap tools between machines.

A Few Other Things About Tool Length Offsets

If you have a Mazak. Mmmmm if you have a Mazak.

Well it’s easy. Mazak machines have active offsets so the minute you do a tool change and get your tool in the spindle the tool lengths offsets are active. They also nearly always have an auto tool measurement system

.

Sorry if you are a Mazak user and you are thinking “this dozy bastard has made me read all this gratuitous shit for nothing”

Now’s the time to leave. Go on off you go.

Ok so what.

Mazaks also do this…….

When you write a G code type program for a Mazak you don’t need a G43 and you don’t need the H

M6 T5                                                  (Get tool 5 in the spindle)
G90 G0 G54 X0 Y0 S1500 M3    (Rapid to X0 Y0 and start the spindle)
Z3.                        (Rapid to Z3. but allow for the length of tool 5)

Forget the G43 H5 shit…. soooo easy.

Those Mazak guys just don’t believe in stating the obvious and wasting your precious finger tips typing in a load of bollocks that the machine should know anyway.

Just remember you can change this by parameter if you want it to work the same way as your Fanuc or your Haas. Oh and you don’t care about increasing your carbon footprint with those extra finger presses.

That way you can put programs from your Fanuc into your Mazak and vice versa.

One other thing

 

Haas have a little trick up their sleeve.

You can alter the settings on a Haas machine so that if your H and your T are not the same you get an alarm.

M6 T5                                                 
G90 G0 G54 X0 Y0 S1500 M3   
G43 Z3. H1                       

Remember our program. If you changed the tool number but forgot to change the H you would be using the length of T1 for T5

 

 

Yes you just bent your machine.

Of course if it’s a Haas you just get an alarm.

Learn all this and more

 


Hurco Training, Getting the Most from Your Hurco Machines?

CNC Training Call David: 07834 858 407

CNC Training Centre Reviews

Contact CNC Training Centre

Unleash the full potential of your shop with onsite Hurco training

Investing in Hurco machinery is a smart business decision, but to truly maximise your return, your team needs the right expertise. While Hurco’s WinMax control is celebrated for its intuitive conversational programming, unlocking its full power and advanced features requires specialised training.

Old and Young All Welcome

I recently worked on a 15 year old Hurco and it’s striking how advanced this control always was. When you are from a G code background you are almost looking for the catch because it is so simple.
The CNC Training Centre can come onsite and conduct your Hurco Training. Unlock the hidden features. Technology is often underused and proper training will unlock these extra powers.
Hurco Training
Our expert-led, onsite Hurco training brings knowledge directly to your shop floor, offering advantages that standard classroom training may not provide.

The power of onsite Hurco training

Onsite training allows your team to learn on the specific Hurco machines they use daily. This approach ensures that operators understand the capabilities of your equipment without needing to adjust to different machines.
Training is customised to your team’s skill level and your applications.
Covering conversational programming, integrating G-code or CAM software.
Advanced techniques like 5-axis programming or solid model import.

Training Brought To You

Bringing the training to your location minimises disruption and costs associated with off-site training.
Trainees can apply new skills immediately using your parts and applications, receiving relevant feedback. This leads to fewer errors, reduced waste, and improved production quality.
Training teams together fosters consistent knowledge and best practices, enhancing teamwork and productivity.

Invest in your profitability

Proper training is a strategic investment that improves machine utilisation and productivity.
Onsite Hurco training gives your team the skills to optimise your machinery, speeding up the process from design to finished part.
Contact us today to discuss a customised onsite training plan and maximise the potential of your Hurco machines.

CNC Training Call David: 07834 858 407

CNC Training Centre Reviews
Contact CNC Training Centre

 


Edgecam Associativity How it Works

CNC Training Call David: 07834 858 407

30 Five Star Reviews

CNC Training Centre Reviews

Contact CNC Training Centre

This tutorial is about Edgecam Associativity it’s not really a tutorial.

Edgecam Associativity

It’s about the concept of Edgecam Associativity in solid modelling. It shows how you can create a model in your solid modelling system which can be transferred straight through to your programming system.

Edgecam Training

Don’t watch the video about Edgecam Associativity yet, it took me ages to write all this.

https://youtu.be/9yxwhVEAsYI

“Read More”

Careers in CNC

View all current vacancies in CNC

Click here

Call David: 07834 858 407