Category Archives: Beginners

CNC Programming Safely Using Decimal Point

CNC Training Call David: 07834 858 407

CNC Training Centre Reviews

30 five star ratings on Google (just saying)

CNC Programming Safely (Decimal Points)

CNC Programming Safely is very important. This post explains about the role of the decimal point.

Decimal points who needs em eh?

On Fanuc controls and Haas controls depending on the setting of a parameter if you input something like X20 it can be taken in two ways.

(1) X20 is taken as a movement in X of 20mm this is like a calculator and some controls will convert this to 20.000 for you.

(2) X20 is taken as 20 microns which would be .020

The difference between 20mm and .02mm is massive would you agree?

CNC Programming Safely

This also works on feed rates so you could be waiting a long time. Or the other way around you end up with a pile of broken tools.

The most dangerous one is with offsets this will definitely cause a collision.

I remember those things in comic books where you have to find the difference between two pictures. The difference with a CNC Machine is it can cost you your job if you don’t spot the missing decimal point.

Even at five years old I couldn’t really be arsed. I remember swearing for the first time and thinking “fuck this, pass the water pistol”

Sorry this is not true, obviously I was swearing long before my fifth birthday.

Please contact me with the answers to the quiz above (that way I’ll know never to offer you a job)

Decimal Points

Now you could go diving for your manuals and check your parameters and settings. I don’t actually recommend that right now.

Think of people like me and all those applications engineers who work here there and everywhere.

It maybe that in your company you have machines set in different ways and that’s gonna be real confusing.

It is obviously a good idea to have all your machines working in a similar manner if possible.

CNC Programming Safely

So in order to do your CNC Programming Safely I recommend that you make a rule when you are inputting code.

Always include a decimal point regardless of the control settings.

That way whatever your machine setup you will still get the right movements and offset adjustments.

Never Use a Decimal Point (CNC Programming Safely)

M codes
S Codes
G codes although there are exceptions such as G54.1
H numbers
T codes
L
N numbers
O (Programme numbers)
P  address

And if you do you will get an alarm. There are exceptions to these rules but you would need to check your programming manual.

Use a Decimal Point (CNC Programming Safely)

B   address
C   address
D  address
E   address
F   code
I   address
J   address
K  address
Q  address
R  address
U  address
V  address
W address
X  address
Y  address
Z  address

I have trained people who insist on programming X0.0 and that is ok if it helps you to remember the decimal point. Even though on X0 it would make no difference but rules are rules.
Just remember that if you change companies it will be very hard to break the habit if you are not inputting decimal points.

It’s a bit like keep putting your hands down your trousers. When your at home it’s a minor bollocking from the wife.

Try it in public and you’ll end up on the sex offenders register.

Those using CAD/CAM systems it is quite easy to change your post processor to always output decimal points too.

Here is the Fanuc parameter that you can alter.

Click Me

Services offered at CNC Training Centre

Edgecam training.

Classroom programmer training.

Onsite CNC Machine Training.

CNC Training on all controls and machines.

Mazak Training Fanuc Training

Don’t forget we offer training on all types of Mazak Machines and all Fanuc Controls 6m to 31i Oi old to young.


Leading Trailing Zeros CNC Programming Basics

CNC Training Call David: 07834 858 407

 

CNC Training Centre Reviews

30 five star ratings on Google (Just saying)

Leading Trailing Zeros

You do not need leading or trailing zeros in a CNC program (see below):

O0001(G81 DEMO)
G21 G90 G40
T01 M06 (20.0 MM DIA X 90 POINT SPOT DRILL)
G90 G00 G54 X12.64 Y88.00 S2546 M03
G43 H01 Z15.00 M08
G0 Z100.00
Z1.00
G01 Z-0.1
Without leading Zero is exactly the same. (Trust me it won’t self destruct or start world war 3)
O1(G81 DEMO)
G21 G90 G40
T1 M6 (20.0 MM DIA X 90 POINT SPOT DRILL)
G90 G0 G54 X12.64 Y88. S2546 M3
G43 H1 Z15. M8
G0 Z100.
Z1.
G1 Z-.1

Try to keep your code consistent. As I mentioned before try to make all programs look the same.

Create an SOP (Standard Operating Procedure) which will cover all programming layout options. Haas controls will insert their own leading and trailing zeros so you won’t have a choice there.

Leading Trailing Zeros and Memory

Leading Trailing Zeros, if you are short of memory (not as in forgetful) this can save loads of space, and you might be surprised how small the memory is on some CNC machines, some have the memory of a fish.

Leading Trailing Zeros

CNC Programming

The main thing is that you are happy with the layout of your program.

If you are not consistent with your approach it can cause a lot of problems.

Please remember that when you are typing code into the machine it will take you considerably longer to type G01 X0.200 Y0.200 F100.00 than G1 X.2 Y.2. It could wear out your fingers or give you multi RSI.

A Haas control will automatically add leading zeros but just try to ignore it. Maybe Mr Haas likes to see them.

Main thing is you don’t need to type them in.

Take a look at this article.

Another way to save space on a Mazak control is to delete all the spaces (ISO G code programs only)

Contact David :07834 858 407

Services offered at CNC Training Centre

CNC Programming Course

Onsite CNC Machine Training.

Training on all controls and machines.

Mazak Training Fanuc Training

Don’t forget we offer training on all types of Mazak Machines and all Fanuc Controls 6m to 31i Oi old to young.


Background Edit Fanuc

CNC Training Call David: 07834 858 407

 

CNC Training Centre Reviews

30 five star ratings on Google (Just saying)

Background edit, I only really get to hear about background edit when people get stuck in it. It’s a bit like being accidentally locked in a toilet you feel a bit of a twat and very embarrassed in equal measures.

This button is your closest friend

Now I made it real big because one day it will save your life.

You know when you play Monopoly and you get one of those cards that says “GET OUT OF JAIL FREE”

If you get sent to jail you just present this card and your sentence is immediately quashed it’s a bit like having Donald Trump as a mate.

It doesn’t work for shop lifting by the way I tried it as a child when I nicked a tin of Spam from the Coop. Fortunately in those days the police were never involved as they knew your parents would beat you to within an inch of your life at the slightest hint of petty larceny.

Anyway press this button background edit all your woes will cease.

And if that doesn’t work this one is the nuclear option.

background edit

The first one is for the program you’re actually background editing. Don’t forget you can have more than one program that you are background editing, more on this later.

Anyway this button stops them all, a clean sheet as it were.

Oh Dear

The reason people get into such a mess with this is because you can actually get into background editing by accident it’s easy.

If you are in a folder and you press INPUT then whatever program your cursor is on immediately comes up for background editing.

If you do this a few times then you can have several programs on the screen to edit.

 

You can switch between these programs and edit any one. You can copy and paste between them which makes writing programs from templates really easy.

Use the FORWARD and BACKWARD softkeys to switch between programs

To escape this lot you need the help of this key

background edit

This will end it all.

Background Edit is Amazing

Yes background edit is really useful, maybe amazing is stretching it a bit, but it does have many uses. Editing a few programs together is the bit I like.

If you want to edit whilst you are running a program then that’s also useful.

Background edit Warning

Don’t hit the fuckin reset button!!!!

Obviously this will stop everything so why would you do it?

Well maybe you are one of those very naughty boys who uses it to get to the head of the program when editing.

When in background edit it’s easy to press reset except this time you just stopped everything because your program is running.

Change Your Habits

Use rewind, some controls have a rewind button

use this to get to the head of the program.

On other controls it’s LINE SEARCH then press TOP or BOTTOM

This will take you directly to the head of your program or the end of your program.

Nothing is stopped and no one is harmed.

background edit

 

Why I Hate Background Edit

It’s an absolute pain in the bollocks mainly because it is so easy to accidentally get into background edit and not even realise.

You keep pressing the MDI button and the screen just wont change. If you have Guide i then you will get a warning when you switch over and you can’t do anything until you end it.

To be honest I don’t hate it at all. You just need to be aware that you need to come out of it to do various other things.

Another Useful Feature

If you want to use a program for reference. In other words you want to look at what’s in it but you need to be careful not to alter it.

Press BG EDIT then type in your program number

Press REF EXEC

Your program will appear in green meaning it is “read only” so you can’t accidentally alter it.

What’s Running in The Background?

You can also call your running program in background edit. This will also appear in green and be read only.

 

 


Ten Things You Might Not Know About The Fanuc Sub Program

CNC Training Call David: 07834 858 407

 

CNC Training Centre Reviews

30 five star ratings on Google (Just saying)

Sub Program Fanuc

Here are ten things you might not know about Fanuc sub programs,

Fanuc CNC controls are the most common controls in the world so it might be useful to have a good understanding of how sub programs are called and used.

(1) You Can Call a Sub Program By Name.

Yes you heard it here the program can be called by it’s name or it’s number. When calling by name don’t use the P.

Just put the name of the program in these things <> with an M98 and your away.

M98<ALBERT>

The only problem with this is that the syntax needs to be spot on so if you have got complicated names for your your sub routines then you might be in the shit.

I always call mine names like ALBERT that are easy to remember.

(2) You can use internal sub routines on a Fanuc Control.

Some people call these local sub programs. It just means it’s tagged on the end of your program which makes them nice n easy to look after. A bit like a pet Goldfish or a pet fly.

I bought mine from the local pet store. I asked the assistant if he sold pet flies and he said no. I said “well there are loads in the window”.

Anyway he sold me one (£15) his name is Paul

 

This is not him this is Steve.

Internal Sub-Routines

By typing M98 Q500 your control will look for N500 within your current program. This is great because you can add the sub programs to the end of your main program. Don’t forget to leave big gaps so you can clearly see where and what they are. Oh and mind your P’s and Q’s.

M98 P500 (Call O500 externally)

M98Q500 (Call N500 in main program.

Oh and read this too.

Sub Program

Just one other thing. Watch your n numbers it’s easy to get them mixed up. Try and use a convention.

“Read More”

Fanuc Editing Copy and Paste

CNC Training Call David: 07834 858 407

 

CNC Training Centre Reviews

30 five star ratings on Google (Just saying)

Fanuc Editing Oi Model D. This does vary on the age of your control this article is for a newer control (Fanuc Oi Model D).

Read this article if you want to see Fanuc Editing 18i (older control) or this one for older Oi control  copy and paste.

Now I’ll warn you that it’s not a simple process but if you get into the habit of using it you’ll never leave home without it.

I am definitely not going to rant on and on about why all these simple procedures were not introduced years and years ago. Why has the editing on CNC controls generally been so shit over the years?

I am also not going to rant and and whinge about how fuckin complicated it all is.

I mean bloody hell all I want is to take this shit here and join it to the end of this shit here.

I’m not asking  for an “X Factor Audition Here” (Simon if you are reading this my contact details are above) I only write this crap to try and make some money, my really passion is singing and exotic dancing in my underwear. I really want this Simon, just one chance is all I need.

“Read More”

Careers in CNC

View all current vacancies in CNC

Click here

Call David: 07834 858 407