Making code from sloppy drawings… Is it just me, or do other programmers have this problem? I program and set up a lot of curved and angled parts that can be tricky. Sometimes I am expected to do these really quickly. After all, the drawing is already done, right? I should just have to turn the lines that are already drawn into G-code with a program that takes care of all that. Yeah, right. In reality, I have to deal with sloppy drawings that cannot produce code without reworking or redrawing. I am talking about things like lines that should be tangent to an arc but are not, lines on top of lines on top of lines, lines and arcs that do not connect, distances and radiuses that are off by .00124879 of a mm, lines and arcs that are off of 0 in the Z plane by .00000154. You get the picture. I have been pointing this out to the proper authorities here to no avail. I spend a lot of time making up for others' incompetence and feel I don’t get credit for it. I cannot express enough the importance of clean drawings. These are not pencil drawings. Close enough does not get it.
Is this a common problem? Do you see a tendency in drafts people that have a lot of pencil drawing experience to do sloppy CAD drawing? How are others handling this?
From contributor B:
The only way to do it is the method you are using (fix them), and the only way it gets better is to charge setup fees for the sloppy .dwg and .dxf files that must be modified for the machinery to run productively.
Otherwise, in my experience, the quality of the dwgs will not improve.
As a side note, many draftsmen and CAD operators are pushed to generate dwgs as quickly as possible, and when they were being done, have or had had no idea the dwgs would be used to generate code for a machine.
On a positive note, there are some excellent CAD draftsman out there as well. I was visiting a prospective customer last month and was talking with his CAD man. After telling him what I needed, he took a 3-D Autocad file and pulled the parts he wanted off it, converted them to 2-D and cleaned up the files for me in 10 minutes. Have not got a bad drawing from him since. Other customers are not so hot, however...
Contributor J's advice is 100% accurate and crucial.
“If this is an internal company problem, I would request a meeting with management and those who create the CAD drawings. Perform a demonstration of your dxf-to-code software with a drawing that you know will not translate. Make it clear that the drawings must be "clean" for the translation to work. It sounds like your "CADsmen" aren't properly trained in the use of CAD. They should be using modifiers for intersections, tangents, etc.”
Then you need to go to their workstation and understand, start to finish, how their program is created. Are they creating the drawings from scratch and do they have full control over the accuracy and correctness? Or are they working with existing drawings that were created by an earlier person? Therefore, the root of the inconvenience is deeper and now two teams can tackle this task? Are all parties using software that requires precision and exactness?
In response to some of your points…
“I program and set up a lot of curved and angled parts that can be tricky.”
They’re not only tricky for you, my friend.
“Sometimes I am expected to do these really quickly. After all, the drawing is already done, right?”
I’d be willing to bet just as frequently those drawings are also done really quickly.
You get the point, right? Be fully educated to the issue and seek out the correct avenues, not the authorities.
Good draftsmen will give you clean geometry and you are lucky if your company has a good draftsman, but not all draftsmen are that conscientious about their work and you will just be talking to the wall when trying to change their drawing habits. If you have many draftsmen, then forget it. If you are talking about bad geometry in blocks, that's another story.
Ultimately, the responsibility of producing code that does not crash the machine falls on your shoulders. If you had a good draftsman who consistently gave you clean drawings, does that mean you would no longer check the drawings before generating code? If a spindle got trashed because of bad code created from bad geometry, then whose head would end up on the end of a spear? The draftsman, the operator, or the programmer?
I think you know what I'm getting at. You need to make it a ritual of going through each drawing you get and making sure that it's clean. As for the people that want a quick part, they have to go through you to get it, so either they need to wait the amount of time it takes you to do it correctly or they can do it by hand. And if there is someone standing over your shoulder pushing you to move faster, then this is the person you need to go off on.
In discussing the drawings from which the commands are generated, several have commented on problems resulting from (what seem to be) minor errors. I'd viewed the CNC as analogous to a vector graphic system or plotter: the tool moves to a designated point, drops, cuts to a second point, and raises. Why would the errors matter? Thanks for any clarification you can offer.
You're right in that in its simplest form, CNC work is like a plotter, but things go uphill fast from there. When looking at a CAD drawing, all the lines have to be closed vectors if you plan on cutting out a part. Any break, no matter how small, and you can't run a toolpath around it. Loops, crossed end points, end points that don't meet, poorly fitted arcs, line fragments, etc. are the bane of the poor CAM man and his CNC machine.
The worst files I deal with come from graphic artists. They are visually okay but terrible for the purposes they want me to use them for, with a multitude of the above errors being all too common.
Nothing like watching a rush job that you should have looked closer at merrily try to profile a line fragment on the pieces you are trying to cut.
You could write all these commands to run the CNC yourself, but doing it this way is very tedious, confusing and time consuming, let alone error prone. That’s where the CAM package comes in. Generally speaking, most CAM software will allow you to both draw your parts right in the software or somehow import existing drawings into it. Through varying methods, the CAM package will attempt to interpret the drawing and apply cuts to it. Software cannot tell if a rectangle in a drawing was intended to be a cutout for a grommet or the outside perimeter of a part, so somewhere along the line, the CNC programmer had to tell the software what needed to be done with that rectangle. Most CAM packages have a way to set up multiple methods for cutting similar geometry. The user can then pick one of those methods and "associate" it to their part drawing. Most CAM packages also have a way to import parts from a CAD package such as AutoCAD and have the cutting methods automatically "associated" to the lines based on a predefined layer naming convention. For example, you would draw a circle in AutoCAD on a layer called "DOOR_PULL" and you would have a cutting method set up in your CAM program that uses a 3/8 downward spiral router bit to conventional cut to the right of the line at a depth of .5" at such and such feed rate and so and so RPM. When that part gets cut, you will get a pocket for a door pull and all the programmer had to do was put the circle on a layer called "DOOR_PULL". The CAM package will finally write the tedious code for you that the machine will understand.
Your CAM package is still going to do what you tell it to do, even with bad geometry. Generally speaking again, most CAM packages have a feature that will detect and repair open shapes based on user-defined criteria. If a tool path designed for a closed shape is associated to a rectangle with a small gap at the corner and this feature is turned off or outside the range of error defined by the user, then the CAM package would most likely attempt to generate code for that rectangle, even though it really is not a rectangle. Depending on the software and the post processor, just about anything can happen at this point, ranging from mildly amusing to utterly devastating. Lines over lines are another issue. These hidden lines could end up on the wrong layer and end up with a tool path associated to it and you may never see it until it grabs the most expensive tool on the machine and attempts to plunge into the vacuum table or pod system and then do a rapid.
The worst I have seen a pen plotter do is to keep on chugging away as the paper shreds itself on the feed roller.
The only error I've had on plots were fills and hatches that "leaked" into unwanted areas. I can see the offset problem - similar to template routing with a guide. And I think I see the over-written line problem.
Is there a good article you could cite that would explain what and how to clean/purge a drawing for submission to a CNC shop?
When I started programming, sloppy drawings didn't matter because every line of code had to be typed in manually, but for more than 10 years now, I have strived and fought with my co-workers to provide clean and accurate drawings. I even encountered CADsmen that thought simply editing a dimension meant that the now incorrect geometry would be magically located correctly by the CNC post.
What this all comes down to is poor attitude and training of the people making the drawings. It doesn't take any longer or any more effort to do things right the first time!