What's new
What's new

CAM vs Hand Coding

Joined
Aug 26, 2021
Location
Victoria, BC, Canada
Hey all, I've been lurking for a while but this is my first post here.

So my question for everyone is this: Approximately how much of your programming is CAM, and how much is hand coded? EDIT: Lets throw conversational into the mix too.

A little context: I help teach introductory CNC machining to 2nd year mechanical engineering students, who are familiar with CAD (Solidworks mostly), so they pick up CAM relatively easily. Part of the curriculum is teaching them G code, which for me (and probably everyone here) is an obvious thing to learn if you're going to do any CNC machining, but they can't wrap their heads around why they should know how to actually write a program; in their minds, it's kind of like learning how to use a slide rule. So, in order to get more buy in from the students, I want to get some input from people out in industry as to how much hand coding they actually do.

Thanks everyone!
 
CAM 100 %. I couldn't gcode my my way out of a paper bad. 😄

But can you read a program and spot an error? Seems crazy to not know how to do something even thought there is an easier way to do it. Why would a student single block some code if the blocks do not mean anything? The point is to understand what you are doing and reading the code is important. I can't write complex code but I can program a 2 axis lathe all day and can read code for a VMC with no issues. Maybe a screw machine and others would get complicated to write and read but still it is important.
 
Thanks guys. To be clear, we don't expect them to write anything too complicated, something along the lines of a 2D contour with radiused corners and a few drilled holes. The point of it is to teach them how to actually understand g code so they can edit and find mistakes in their CAM generated programs.
 
It's also worth understanding what the machine understands. It's kind of like speaking a foreign language. If you walk into a McDonald's in France, you should know a big mac with cheese is a royale. Machines don't understand pointing and hand-waving :)
 
Thanks guys. To be clear, we don't expect them to write anything too complicated, something along the lines of a 2D contour with radiused corners and a few drilled holes. The point of it is to teach them how to actually understand g code so they can edit and find mistakes in their CAM generated programs.

This is perfect.
Teaching them the basics of how to actually read G code, kudos! :cheers:


I program all of our milling programs with Mastercam. There are very rare instances where we would hand code programs. And those are simple things like milling soft jaws to hold round parts, doing a quick drill and tap, or an easy keyway/slot that has to be done yesterday.
As for lathes, 99.999% of the lathe programs are programed at the machine using conversation.
 
Typically I have guys on the floor do simple programs in G code and we do complex ones in CAM. I know many shops are %100 CAM but I just don't believe in that. I will not teach someone CAM that hasn't proven to me a basic knowledge of G code.

1) It's faster to hammer some code into the control to drill and tap some holes vs drawing the part, adding tool paths, posting the program, and transferring it to the machine.

2) The more in depth knowledge you have of the machinery you're working on the more competent you will be.

3) The old school techniques of this industry should not be forgotten. The new comers should know how we got to where we are today. Often an old method of doing something is just as effective or at will least get you out of a jam, even if it doesn't fit the mold of the latest buzz word nonsense.

4) If I had to learn it the hard way so do they.
 
But can you read a program and spot an error? Seems crazy to not know how to do something even thought there is an easier way to do it. Why would a student single block some code if the blocks do not mean anything? The point is to understand what you are doing and reading the code is important. I can't write complex code but I can program a 2 axis lathe all day and can read code for a VMC with no issues. Maybe a screw machine and others would get complicated to write and read but still it is important.

Run single block to look at distance to go to see if you are going to hit anything.
 
On basic stuff, a lot of hand programming. I'm very proficient with cycles and macros as well as machine special functions so I can get a maximum of productivity with a minimum of code. I use CAD/CAM for paths that require more than simple math to figure out, or highly repetitive paths. Conversational is reserved for training those who want to know it.
 
Run single block to look at distance to go to see if you are going to hit anything.

Big difference in distance to go if you are in G00 or G01. Same principle applies if you have a code that reads G01 F10. and it rapids across the part because there is a G95 from a tapping cycle that didn't get fixed with a G94 afterwards.
 
Personally, I don't care what my printer firmware driver is sending over the wire, as long as the print comes out right
 
Why learn to multiply or divide if one has a calculator or cell phone?
Heck why even plus or minus or the ability to make change for a dollar now?
One crawls before walking, learns to walk before running.

On the side of ignoring the basics I wonder how many current computer and cell phone programmers can do it in hex?
How many CAM jockeys know just how different a G00 and G01 move is?
Bob
 
CAM 100 %. I couldn't gcode my my way out of a paper bad. ��

I don't think I'll ever be able to understand this one. Not knowing or understanding what the code will do for you is just wild to me.
 
I don't think I'll ever be able to understand this one. Not knowing or understanding what the code will do for you is just wild to me.

I can't remember a canned cycle format to save my life anymore.

I know that the #'s are right when I look at it. So off we go.
Start here, peck there, finish down there. All those #'s are
good, good to go.

Personally I think the thing you really need to know about G-Code, is
understanding basic cartesian coordinates.

The G's that you need to remember. G0 fast.. G1 slow.. G2 left G3 right.
M3 M4 M5 M8 M9...

G90 and G91 are incredibly important if you are finger banging.. But that goes
back to understanding coordinates, and not necessarily G-Code.

I know what my safety block does, but I don't remember what each code is. I don't.
A student doesn't need to remember all that crap either. I understand that part
of teaching is taking the subject past what they will actually need, so that the
retained information ends up being the stuff they actually need.

I think a good homework assignment right at the beginning of a G-Code class would
be have the kids dig through the G and M codes, and write their own safety block.
No grades. Either you did it, or you didn't. Explanation
with each code of course (show your work).

Having them trig out an off axis corner radius path... That goes back to geometry,
trig and coordinates. I don't think that is necessary to be taught in a programming
class, either you know that math or you don't. Show them how to CAD it out and pull
points, that makes sense.. I know how to do the math, but pulling points is easier.
 
On the lathe, 100% hand coding. On the VMC’s and HMC’c about 50-50. But your students have to learn the basics.
 
Probably better things to teach them about machining then the basics of Gcode. Very rarely do they need to know gcode unless that have a drive to become a manufacturing engineer or machining on the side. Would be worth far more to have them construct parts from bad drawings to understand why certain features callouts will cause machine shops issues or much higher cost. IE perfectly square holes, holes close to a welded vertical brace or such. This would be similar to teaching a machinist class about PLC programming instead of saying it just works with the code in it.

The shop class I took for my ME degree helped to understand design for manufacturing. I only learned gcode for home machining for a side business.
 
A little context: I help teach introductory CNC machining to 2nd year mechanical engineering students, who are familiar with CAD (Solidworks mostly), so they pick up CAM relatively easily. Part of the curriculum is teaching them G code, which for me (and probably everyone here) is an obvious thing to learn if you're going to do any CNC machining, but they can't wrap their heads around why they should know how to actually write a program; in their minds, it's kind of like learning how to use a slide rule.

Maybe the pace of the course is too slow. How much time are they spending coding basic 2D shapes into G1/G2/G3 toolpaths?

In the real world, it's not about being able to write toolpaths by hand. It's about always knowing what the machine is about to do and spotting problems at a glance. When you're standing in front of a machine, you don't see the CAM data. You see G-code.

Being able to spot a bad retract height at a glance could mean the difference between a 10 second fix and a toasted spindle.
 
CNC lathe hands, (the good ones) seldom use CAM. The best manual lathe pros provide a great pool of cnc lathe machinist.
 
in tech school i'm glad they still had us start the old school way from scratch and write out programs by hand made you learn and understand the basics. now this was a couple semester programming course and there was time for it. so the question is how much of this engineering class is dedicated towards programming do you have time to teach the basics enough for students to understand the code.

the way i tell it is back when we were youngins and learing the abc's you started from the basics....start with abc's, then make words, then put together sentences, then put a few of those together form a paragraph, handful of paragraphs and it turns into a paper. once you have that down there's a thing called cursive to make you faster once you have that mastered there's this magical thing called a computer and you'll never want to hand write out a paper ever again.

very similar approach to g&m programming its a language and in my opinion you have to know the basics and build off of it. its not as important these days to write code but it sure as hell is important to be able to read it and when the machine comes back and throws errors at you telling you your a dipshit you better be able to figure out why.....
 








 
Back
Top