[4]

Make Your Own PCBs on a CNC Mill

[3]
[10] Like what you see?
Click here to donate to this forum and upgrade your account!

petcnc

Active User
Registered
Joined
Dec 29, 2012
Messages
304
The Software needed

* Eagle CAD - download the free version of Eagle CAD from autodesk
* pcb-gcode - download the pcb-gcode Eagle CAD. Download here

Step 1: Setup the software
1. Setup Eagle following the instructions from autodesk.
2. Dowload PCB-GCode (Utility for EAGLE) and decompress it into a new folder

Step 2: Setting up PCB-GCODE in EAGLE
All files after decompressing pcb-gcode-3.6.2.4 are the following

1a.jpg
Search your computer, find the folder where EAGLE is installed and open it. In there there is a folder named ULP. I copy everything that is in the folder pcb-gcode-3.6.2.4 and paste it in ULP folder.

2a.jpg
When you click ULP button on EAGLE toolbox it opens the ULP folder and asks which file to open. Scroll down and open pcb-gcode setup and make all settings needed.

3a.jpg

First TAB is the Generation options:

4a.jpg
Generation Options settings
These are basic settings for what types of Tool Paths you want to create and how detailed they should be.
The Top Side and Bottom Side setting will depend on whether you will be making a single or double sided PCB.
Show preview is always good to have checked so you can see that everything turned out how you expected it to. As my vision is not what it used to be I like to keep the Width and Height at 1024 x 768.
Generate milling is used for cutting the PCB outline. I DO NOT USE IT AT THE MOMENT
Generate text is used to engrave text onto your PCB. Only text that uses the Vector font and is on EAGLE Layer 46 Milling will be included in the G-Code. I DO NOT USE IT AT THE MOMENT
Spot drill holes will make small marks wherever a hole will be drilled after the trace isolation cuts are made. This helps the drill bits get nice and centered when drilling the holes.
Prefer climb sets the overall direction that the CNC Mill should move in for milling. I do prefer to have my mill do climbing cuts and that is why I have this option checked.
Isolation lets you control how the software will outline each of your traces. These settings depend heavily on the tip diameter of the end mill or engraving bit that will be used to outline your traces.
Single pass only does one outline around your traces.
Minimum lets you set the smallest amount of space that your end mill or engraving bit can cut. 0 inches to ensure that every trace is outlined at least once to isolate it.
Maximum sets the maximum spacing that you want cut around each trace. This will determine how many times the CNC mill will outline each trace.
Step size tells the software how much space your want between isolation passes. If you are using an end mill, this should be about 40% of the tip diameter of your bit. 0.004 in. Engraving bits can use a step size equal to the flat diameter of the bit because it is tapered and that makes the cuts wider as it goes deeper into the carrier board.

Next is TAB is Machine:
5a.jpg
Machine settings control how fast the CNC Mill will cut, details about your cutting tools, and the units of measurement you wish to use.
Z Axis lets you set some standardized milling depths.
Z High sets the safe height for the mill to move around without running into anything like your clamps. 0.5 inches is a safe bet for this.
Z Up is the safe height for movements from one cut to the next. I set this to 0.1 inches.
Z Down sets the cutting depth for the trace isolation. This should be set to go just below the copper layer. I use -0.007 inches.
Drill Depth should be set to about 0.005 inches below the thickness of your carrier board. So if your carrier board is 0.062 inches, you would set this option to -0.067 inches.
Drill Dwell tells the machine how long it should wait before pulling the drill bit back out of a newly drilled hole. About 1 second is good to get a cleanly drilled hole.
The Tool Change options don’t work so well, but I put 0 in for Position X and Y and 1 inch for Position Z.
Spin up time is used to set the time it takes for the spindle to get to full speed once it is turned on. If your CNC Mill does not automatically turn your spindle or router on and off, don’t worry about this setting.
Units tells the software what unit of measurement you want to use for everything.
Feed Rates lets you set the optimal speed that your CNC Mill will move while cutting and drilling. This is very important to prevent your bits from breaking and getting clean cuts.
Etch settings are used for the trace isolation outlines
Drill sets the drilling speed.
Mill settings are used for cutting out the PCB when finished. I DO NOT USE IT AT THE MOMENT.
Text I DO NOT USE IT AT THE MOMENT.
Stencil I DO NOT USE IT AT THE MOMENT.
Click on the ? buttons if you really want to know what the Misc options are, but they are not important for what we are doing.

Next Tab is G-code Style: I choose Mach3
6a.jpg

Next Tab is Gcode options: select use simple drill code!
7a.jpg
The GCode Options window
NC File Comments PCB-GCode puts some rather long notes into the G-Code that it generates. This might result in errors when you send the G-Code file to CNC Mill. Un-checking all of the NC File Comments options will fix this issue.
Under Other Options, I only check the Do tool change with zero step and Use simple drill code options. The Format should be set to N%05d by default.
File Naming can be changed if you want to, but I would just leave it alone.

Next Tab is plugins: I only click the button “Accept and make my board”
8a.jpg

Next the preview screen will pop up: A red cross marks the point of origin (If it is at a distance from the board you designed, like here, you must go back to EAGLE board and move the board closer to 0,0 (point of origin)

9a.jpg

The proper alignment should be like this

9b.jpg

In the folder where EAGLE saves the project you are working there will be two files with the extension “.tap” that have been created by this procedure. One of them is named «name.bot.drill.tap» and the other «name.bot.etch.tap». I named my project “test2a” so the two gcode files are named accordingly.

10a.jpg

Step 3: Design a Board With Eagle
EAGLE is free to use for making small PCBs up to 8cm^2. I assume that you already have EAGLE installed and that you know how to use it for creating a PCB design. If this is not the case, I recommend checking out any one of the many tutorials that people have made for EAGLE like this one.

Use Eagle CAD DRC to Enforce Design Limitations
1. In Eagle CAD, select 'Tools->DRC->Clearance'
2. Set all of the 'Different Signals' clearances to a value larger than your engraving tool (12mil seems to work for a 30deg V-Bit)
3. If you already have a board designed, select 'Check' to see what parts of your board may be too close together to isolate

Step 4: Make the G-Code for the Board

Use pcb-gcode to generate G-Code from Eagle CAD
1. Open your board design in Eagle CAD
2. From the Eagle CAD click ULP button select pcb-gcode setup.ulp and run
3. The pcb-gcode dialog will pop up.
4. On the 'Generation Options' tab, select 'Generate bottom outlines', 'Generate bottom drills' 'Show preview', Spot drill holes, Prefer climb
5. On the 'Machine' tab, set 'Spindle Up Time' to 3 and set the feed rates to 300mm/min
6. Set 'Z High' to 12mm, 'Z Up' to 3mm, 'Z Down' to -0.08mm
7. Use calipers to determine the thickness of your board and enter that value plus 0.1mm or so for 'Drill Depth'
8. On the 'GCode Style' tab, select 'Mach3 - EMC for Windows'
9. On the 'GCode Options' tab, select all of the 'NC File Comments' options as well as 'Do tool change with zero step'
10. Click 'Accept and make my board'
11. An image view window will pop up and display what will be etched. pcb-gcode will join signals that are too close so look at the image carefully to make sure that all signals are properly isolated.

Step 5: Mill!

Load the Gcode
Click 'Cycle Start' on the Mach3 Screen to begin engraving
Use the spindle speed control to adjust the spindle speed to something appropriate. If the speed is too low you may see ragged chips of copper. If the speed is too high you may see copper being finely polished instead of cut.

Step 6: Drill!

1. When milling has finished, raise the spindle.
2. Click 'Go To Zero' on the Mach3 Program Run tab
3. Use the page up key to raise the spindle again
4. Remove the engraving bit from the spindle
5. Chuck an appropriately small carbide tipped drill bit
6. Use 'File->Load GCode' within Mach3 to load your drilling G-Code (named something.bot.drill.tap)
7. Use the page down key to lower the spindle until it is just barely touching the work piece
8. Click 'Zero Z' on Mach3
9. Click 'Cycle Start' on Mach3 to begin drilling

There is my first effort using the above steps.

Milling

PC221914s.jpg

Drilling

PC221916s.jpg

Final pcb

PC221919s.jpg

Not bad for the first pcb on the mill!!

Good Luck!
Petros
 

brino

Active User
H-M Supporter - Gold Member ($25)
Joined
Jan 2, 2014
Messages
3,760
Great thorough write-up and fantastic results.
Thanks for sharing!
-brino
 

gr8legs

Active User
H-M Platinum Supporter ($50)
Joined
Oct 31, 2014
Messages
249
Thanks for an excellent write up - I've used Eagle CAD for some time and never explored the various ULPs to discover the g-code one. Very cool! Great for a really fast turnaround on a prototype!

In addition to do-it-yourself milling of PCBs there are a couple of fab shops that offer low-cost etched boards from Eagle files that may be worth exploring, especially for boards with a lot of through-holes or fine geometry that would be challenging to make on a mill.

OshPark.com (USA) will give you 3 boards from an Eagle file for $5 per square inch. I've used them often and been very satisfied with the results.

There is also Olimex.com (Bulgaria) whom I have used once or twice before discovering OshPark and although I cannot remember what they charge it's in the same ballpark.

I have no connection with either other than as a satisfied customer.

Stu
 

petcnc

Active User
Registered
Joined
Dec 29, 2012
Messages
304
Thanks for an excellent write up - I've used Eagle CAD for some time and never explored the various ULPs to discover the g-code one. Very cool! Great for a really fast turnaround on a prototype!

In addition to do-it-yourself milling of PCBs there are a couple of fab shops that offer low-cost etched boards from Eagle files that may be worth exploring, especially for boards with a lot of through-holes or fine geometry that would be challenging to make on a mill.

OshPark.com (USA) will give you 3 boards from an Eagle file for $5 per square inch. I've used them often and been very satisfied with the results.

There is also Olimex.com (Bulgaria) whom I have used once or twice before discovering OshPark and although I cannot remember what they charge it's in the same ballpark.

I have no connection with either other than as a satisfied customer.

Stu
Thank you Stu for the info.
Unfortunately, I live on the other side of the pond and it takes some time for a pcb to arrive, moreover goes through a stupid customs system as it comes from outside EU. If I need one PCB its faster to DIY it.
Petros
 

markba633csi

Platinum
Registered
Joined
Apr 30, 2015
Messages
4,178
Is your table surface considered "0" in the z direction? I don't follow the -.067 inch setting; would that not put the tool into the table?
Mark
ps I see a few ground islands that for high frequency circuits should be tied to the main ground plane area with jumper wires but other than that, nice result!
 
Last edited:

petcnc

Active User
Registered
Joined
Dec 29, 2012
Messages
304
Is your table surface considered "0" in the z direction? I don't follow the -.067 inch setting; would that not put the tool into the table?
Mark
ps I see a few ground islands that for high frequency circuits should be tied to the main ground plane area with jumper wires but other than that, nice result!
Exactly! the idea is that the drillbit must go through the thickness of the material. That's the reason you must use some sacrificial material (wood?) under the copper board. If you secure it straight on the mill table you will end up with a nice drilled pattern on the table or a broken drill bit at the first hole.

PC201898s.jpg

Moreover as the surface must be 100% flat you start the procedure by milling flat the sacrificial surface and then you secure the copper board on it.

In my case you can see that I left a higher edge at y+ to secure the copper board

PC201897s.jpg

As for high frequency signals, I never thought of that you see the circuit I designed is a timer that will energize a relay once every 24 hours. Nothing fancy, it just uses the pulses from an old crystal clock to count the time.
When I finish the project I will post it here.

Petros
 
Last edited:

markba633csi

Platinum
Registered
Joined
Apr 30, 2015
Messages
4,178
I still don't quite follow, it is -.067" with respect to what surface? Obviously I don't have a CNC background. Would it not be .062 minus 0.005 = .057? with respect to the sacrificial surface? I was talking about the milling operation not the drilling
Mark
 

petcnc

Active User
Registered
Joined
Dec 29, 2012
Messages
304
I still don't quite follow, it is -.067" with respect to what surface? Obviously I don't have a CNC background. Would it not be .062 minus 0.005 = .057? with respect to the sacrificial surface? I was talking about the milling operation not the drilling
Mark
Mark,
Z0 is the surface of the copper board.
Z Down sets the cutting depth for the trace isolation. This should be set to go just below the copper layer.
Drill Depth should be set to about 0.005 inches below the thickness of the carrier board. So if your carrier board is 0.062 inches, you would set this option to -0.067 inches.
This way the drill bit will penetrate the full thickness of the copeer board (in my case copper carrier is 1.5mm thick so I made full depth 1.8mm)

Merry Christmas

Petros
 
Last edited:

markba633csi

Platinum
Registered
Joined
Apr 30, 2015
Messages
4,178
Ah yes I see, Z down is what I was wondering about- you would make it the copper thickness plus a few thousandths
 

MontanaAardvark

H-M Supporter - Gold Member
H-M Supporter - Gold Member ($25)
Joined
Jan 3, 2015
Messages
391
I still don't quite follow, it is -.067" with respect to what surface? Obviously I don't have a CNC background. Would it not be .062 minus 0.005 = .057? with respect to the sacrificial surface? I was talking about the milling operation not the drilling
Mark
It might be helpful to know the thickness of the copper on a circuit board.

The industry specifies this in "ounces of copper" like 1 ounce or 1/2 ounce. That's measured over a one square foot panel. 1 ounce copper is .0014 thick and half ounce is half that or .0007". Commercial boards are often thicker because of being solder coated, or during the time that holes through the board are plated, they get more plating, and power handling boards can start out as 2 ounce copper, .0028". Both 1 and 1/2 are pretty common, with most modern boards being 1/2 ounce with very fine traces and gaps between them - things like .005" wide traces spaced .005" apart, or thinner.

So a board that's .062 thick, double sided with 1 ounce copper is .0648 thick. Setting the drill to go .067 is just barely going through the board. The included angle of the tip of the bit might not go all the way through.

Hope that's useful. I was just passing through and since I'm a retired electrical engineer/radio designer, this stuff was my world once or twice a year for decades.
 

jmarkwolf

Active User
Registered
Joined
Nov 9, 2012
Messages
358
I've acquired a like-new LPKF Protomat S62 circuit board milling machine complete. Very nice, Google it.

Don't have a need for it. Will trade for machines/tools.
 

petcnc

Active User
Registered
Joined
Dec 29, 2012
Messages
304
I've acquired a like-new LPKF Protomat S62 circuit board milling machine complete. Very nice, Google it.

Don't have a need for it. Will trade for machines/tools.
This machine trends at 12,000 $
You are talking serious money here!!!!
 
[5] [7]
Top