Merging modern software development with electrons and metal
Random header image... Refresh for more!

Eagle 3D PCBs with Alibre: Extruding the PCB

Extruding the PCB – Overview

The first step to a complete 3D PCB model is to create the PCB.  The basic approach is to export a DXF outline of the PCB and its holes from Eagle PCB, import it into Alibre, and then extrude it.  It’s not as easy as it sounds.

Alibre Design refuses to extrude sketches with any overlap.  AD V11 did not show where the errors are, but V12 does (this feature alone makes V12 worth the upgrade).

If your PCB border has a non-zero width, Alibre will not extrude the PCB because the four corners overlap.  For some reason, Alibre Design does not accept the way the standard Eagle DXF script creates holes.

I did not have any success getting Alibre Design to extrude the silkscreen or trace layers, nor was I able to overlay the silkscreen or traces as a visible sketch on top the extruded PCB (maybe because Alibre Design does not support surfacing).

When extruding, CoCreate PE is about as picky as Alibre, but (like AD V12) it highlights what it doesn’t like.  SolidWorks doesn’t have problems extruding the standard Eagle DXF output.  VX Innovator is also less picky; I have successfully extruded the silkscreen layer.

I made a couple quick and dirty changes to the standard Eagle DXF creation ULP to fix the holes; the result is dxf-fsw.ulp.

Creating the PCB — Step By Step

  1. Open your project in Eagle, then open the Eagle Board editor with your PCB layout.  I used the FP-SMC-1 project as an example; you can download the files here.
  2. Make sure your borders have a width of 0.
  3. In the Eagle PCB board editor, turn on only the dimension, via, and pad layers (layers 17, 18, and 20).
    Layers for DXF creation in Eagle

    Layers for DXF creation in Eagle

    FP-SMC-1 in Eagle set for DXF creation

    FP-SMC-1 in Eagle set for DXF creation

  4. In the Eagle PCB Board editor, run the dxf-fsw.ulp ULP.
    1. Select a file name for Output file; I used FP-SMC-1.dxf with the appropriate path for my Eagle PCB setup.
    2. The Always vector font, Use wire widths, and Fill areas setting should not matter.
    3. The units do matter: you need to know them when you import the DXF.  I used inches.
    4. Then run the script by pressing OK.
    5. You can download my resulting file here FP-SMC-1.dxf

      Running the dxf-fsw ULP

      Running the dxf-fsw ULP

  5. Close Eagle PCB.
  6. Start Alibre Design.
  7. Select the File->Import menu, select AutoCAD DXF files for the file type, select the file (in my case, FP-SMC-1.dxf), and press Open.
    1. File Units need to match the units you used when creating the DXF in Eagle (I used inches).
    2. I don’t think Maintain Projection matters.
    3. Importing Only Visible Layers makes sense.
    4. Start importing by pressing OK.

      Importing DXF into Alibre

      Importing DXF into Alibre

  8. Select the Sketch->Activate 2D Sketch menu  (or press Ctrl+K).
  9. Select the Edit->Select All menu (or press Ctrl+A)
  10. Select the Edit->Copy menu (or press Ctrl+C)
  11. In the Alibre Home window select the File->New->Part (or press Ctrl+Shift+T)
  12. Select the Sketch->Activate Sketch menu (or press Ctrl+K)
  13. Select the plane to use for your new sketch.
    1. You can name the sketch.  It’s not a big deal in a simple part, but I would recommend named sketches in a complex part.
    2. I used the XY plane.  You can select the plane by either clicking on the plan in the work area, or clicking on the list of planes in the tree on the left (e.g. Planes->XY Plane).
  14. Select the Edit->Paste menu (or press Ctrl+V) to paste the DXF drawing into the sketch.
    1. You could select and move the sketch around if desired.

      FP-SMC-1 DXF pasted onto the sketch

      FP-SMC-1 DXF pasted onto the sketch

  15. Select the Sketch->Activate Sketch menu (or press Ctrl+K) to deactivate the sketch mode.
  16. Select Extrude Boss by menu (Feature->Boss->Extrude) or icon (typically the top right icon).
    1. Verify the correct sketch is selected.
    2. Use To Depth for Type.
    3. Use your PCB thickness for depth (0.062″ or 1/16″ for me).
    4. I reversed the extrude so the sketch is on top (probably doesn’t matter a lot).
    5. Leave everything else with the default settings, except you may want to name the extrusion.
    6. Start the extrusion by pressing OK.

      FP-SMC-1 ready for extrusion

      FP-SMC-1 ready for extrusion

  17. Save the PCB using the File->Save As menu (Ctrl+Shift+S); mine is available as FP-SMC-1 PCB.AD_PRT

    The extruded FP-SMC-1 PCB

    The extruded FP-SMC-1 PCB

  18. We are done creating the PCB itself.  Now we have to assemble the board inside of Alibre, so stay tuned.

Here is the FP-SMC-1 PCB as an Acrobat 3D PDF; if a correct version of Acrobat is installed, you can click on the PCB, and then rotate it and more.

June 29, 2010   3 Comments

A Bunch of Boards

First Batch of PCBs (assembled)

First Batch of PCBs (assembled)

I’ve been slowly working on a bunch of PCBs, and the first batch is finally here.

In the coming weeks, I will discuss each board in more detail, fill in the trac pages, and add the Eagle PCB files to my subversion repository.  I will also cover any mistakes I find, and possible improvements.

The initial lineup consists of the:

  • FP-SMC-1, which is finally here!  It’s a demo board designed to show how to design a custom PCB to replace typical control cabinet wiring.  It connects a Panasonic FP series PLC to a SMC pneumatic manifold.
  • CO-DB9-RJ45-2, designed to convert a CANOpen DB9 connector to dual RJ45 connectors.
  • CO-HDR-RJ45, designed to convert a CANOpen terminal block header to dual RJ45 connectors.
  • CO-M12-RJ45, designed to convert a CANOpen M12 connector to dual RJ45 connectors.
  • CO-TB-RJ45, designed to convert a CANOpen terminal block to dual RJ45 connectors.

November 5, 2009   3 Comments

Verifying PCB Footprints

A great way to waste time and money on Printed Circuit Boards (PCBs) is to create them with the wrong footprints.  It’s worth spending the time to verify before ordering.

The footprint is what a part looks like on the PCB: the holes, the pads, the silkscreen, etc.  PCB design software typically comes with footprint libraries, but some people (including myself and the guys at Sparkfun) prefer to do their own.

It’s easy to make a mistake when creating your own footprints.  You should still check all footprints, because the creator could have made a mistake or it could have been designed for a different part (for example, not all DB9F right angle through hole connectors have the same footprint).

There are two ways of verifying a part’s PCB footprint:

Model the PCB using a MCAD (mechanical CAD) program

  1. You have to create a PCB first that uses the footprint.
  2. You need a 3D model of the part, preferably from the manufacturer.
  3. You need a suitable MCAD program.  Links to some free personal use possibilities (such as CoCreate PE, PowerSHAPE-e, and Medusa4 Personal) are here.
  4. I discussed how I modeled the FP-SMC-1 here.

Mock the PCB using a life size printout

  1. You have to have the parts you are going to verify.  I like to have the parts first, anyway, since I like to see what the look like and how they work before I use them in a design.
  2. You have to create a PCB first that uses the footprint.
  3. You then print the footprint at life size (1:1 scale), with the pads, holes, and (optional) silkscreen showing.  You should check that the printout really is life size (printers aren’t perfect).
  4. Cut out the PCB, and then mount the parts onto the paper.  I find it’s easier to punch through hole parts through the paper when it’s backed by something like foam.
  5. Check the footprint with the parts mounted and removed: holes in right places, pads line up, silkscreen is visible, etc.
Parts inserted into paper PCB printout

Parts inserted into paper PCB printout

Pictured above is a printout of the FP-SMC-1 PCB layout with the parts inserted.  You can see that the text is readable, and silkscreen outlines appear correct, and such.

Paper PCB printout after parts inserted

Paper PCB printout after parts inserted

Pictured above is a view of the FP-SMC-1 layout printout after I removed the parts.  You can see, especially in the larger version, that all the holes (made by the connectors’ pins) line up with the layout’s holes.  (Click on the picture to see the full size version).

In some ways, it’s easier to use the second method.  MCAD programs are fun, but they do have a substantial learning curve; I’ve found mating parts is often very challenging.  But it can also be challenging to poke parts through paper accurately, and I haven’t tried the second method with surface mount parts yet.

November 4, 2009   4 Comments

FP-SMC-1 PCB Layout Is Done

3D Model Top View

3D Model Top View

It’s designed!  After taking way too much time, I have finally finished the layout for my FP-SMC-1 board.  Here’s the proof: above is a 3-D model of the board; below are pictures of the layout and the board model from the bottom.

PCB Layout

PCB Layout

PCB Bottom View

PCB Bottom View

The board hasn’t been built yet, because I wanted to model it first, and I haven’t found a good place to get one-off prototype PCBs made.

Creating the board model was challenging, but worth it, because it gives me more confidence that my board layout is correct.  I use the 3-D model to check:

  1. That my PCB footprints are correct.  Look at the picture of the board bottom, and notice how all the pins line up with the holes.  (This check relies on correct 3-D models from the manufacturer.  If you create 3-D models yourself, it’s possible for you to make a mistake in the model, but the manufacturer’s models should be correct).
  2. That my board dimensions are correct and the PCB will fit into the holder.
  3. That my component layout makes sense.  Look at the far left of the board top view picture, and notice that there is clearance between the connectors and the little plastic tabs on the PCB holder that stick out into the board area.

I will go over making the model in detail later, but what I did was roughly:

  1. In Eagle PCB board layout, turn on only the dimension, via, and pad layers (layers 17, 18, and 20)
  2. In Eagle PCB board layout, use a ULP to create DXF of the pads, vias, and dimensions.
    1. Eagle includes DXF.ULP to create DXFs.  However, this file does not produce DXFs that can be used to extrude a through-hole board.  To get DXFs that CoCreate can extrude, I had to modify DXF.ULP and then delete and re-create the board outline using DoubleCAD.
  3. Import the DXF file into CoCreate and extrude it to 0.062″.
  4. Import models of all the components (fortuneately, all the parts have STEP models available from the manufacturer).
  5. Assemble (using mates) all the components onto the PCB
  6. Assemble the PCB holder
  7. Mate the PCB to the PCB holder.

It sounds so easy, but mechanical CAD software has a high learning curve, just like PCB software.  However, if you’re a software guy, don’t be scared — I’m primarily a software guy, and if I can figure out how to make a PCB and then model it, then you can too.

I was originally planning on doing a series of blog posts on the FP-SMC-1 PCB covering just the automation-related aspects of the project, and not covering the details of using the tools (such as Eagle PCB).  However, after I looked at various Eagle PCB tutorials, I decided that none of them explained Eagle the way I think it should be explained.  I did not find any tutorials on making mechanical 3-D models.

So I have decided to write up a lengthy tutorial on how to design and make the FP-SMC-1 board.  The tutorial will be on my Trac site, since I think Trac is better suited for a lengthy tutorial, but I will blog here about my progess (hint: don’t expect the tutorial to be done quickly).

March 18, 2009   3 Comments

All I need is the board

FP-SMC-1 Parts

I have all the parts for the FP-SMC-1 board project except for the PCB. I’ve done a rough hand-sketched schematic; the next step is to create an Eagle PCB library with all the schematic symbols needed.


May 23, 2008   No Comments

Making an Interface PCB II – Parts and Resources

Updated 1/23/2008 with AMP socket connector part numbers (which some people find easier to hand assemble than 3M, but they are more expensive), and a bit more on MCAD.

Update 4/6/2011: Alibre Design Express hasn’t been available for years, and since Alibre Design Personal Edition isn’t suitable for PCB modeling, your low cost (<$500) MCAD options are limited.  Check out my Affordable MCAD post for some current choices that might work (depending on your needs).

A list of the parts and resources needed for the FP-SMC-1 Interface PCB. The Phoenix parts are available from a number of sources, including Digikey, but Mouser (who I will use) and Online Components sell them in small quantities.


  1. Eagle PCB. I’ll be using the Light version (free for non-commercial, $49 for commercial).
  2. Viewmate from PentaLogix, which is a free Gerber viewer.
  3. Alibre Design Xpress which will help check the mechanical side of the PCB (free). If time allows, I’ll cover other options for checking the mechanical fit of the PCB.

Board Houses:

  1. Sierra Proto Express
  2. Possibly SparkFun/BatchPCB (can be cheaper for 1 PCB)

Bill of Material for circuit board (excluding PCB):

  1. 4 Pin Header 10 pin (2×5) AMP 5102321-1
  2. 1 Pin Header 26 pin (2×13) AMP 5102321-6
  3. 15 Phoenix ZFK3DS 1,5-5,08 Terminal Block (Part Number 1704415)
  4. 1 Phoenix ZFK3DSA 1,5-6,08 (click on Additional Products) End Terminal Block (Part Number 1704554)
  5. 3 Phoenix ZFKDS 1,5-W-5,08 Terminal Block (Part Number 1706714)
  6. 1 Phoenix ZFKDSA 1,5-W-7,62 (click on Additional Products) End Terminal Block (Part Number 1706730)
  7. 2 Phoenix UMK-FE DIN rail feet (Part Number 2970031)
  8. 2 Phoenix UMK-SE 11,25 side elements (Part Number 2970002)
  9. 2 Phoenix UMK-BE 45 base (Part Number 2970015)

Bill of Material for cables:

  1. 8 IDC Socket Connectors 10 pin (2×5) 3M 89110-0101 or AMP 1658621-1
  2. 8 Strain Reliefs 3M 3448-89110 or AMP 499252-5
  3. 2 IDC Socket Connectors 26 pin (2×13) 3M 89126-0101 or AMP 1658621-6
  4. 2 Strain Reliefs 3M 3448-89126 or AMP 499252-3
  5. Ribbon cable 26 conductor AWG 26/28 0.050″ pitch (available from 3M and others, length depending on your need)
  6. Ribbon cable 10 conductor AWG 26/28 (available from 3M and others, length depending on your need)


July 26, 2007   1 Comment

Making An Interface PCB I – Introduction

This series describes how to have a PCB made for factory equipment from start to finish using a real board. I am not going to concentrate on the details of the PCB layout software (there are plenty of tutorials available for that), but instead cover details such as getting the right output out of the PCB layout software.

I am going to design a PCB that could be useful in a machine, using components I like. You should be able to learn from this example to design your own low cost board. The PCB will be designed to interface a Panasonic FP0 or FP Sigma PLC to a SMC pneumatic manifold. I am naming the board FP-SMC-1.
The board interfaces 16 PLC outputs to a SMC 26-pin header manifold. SMC uses this design on various manifolds that can have up to 12 stations, and each station can use 1 (for single acting) or 2 (for double acting) outputs. In my board, I use up to 8 stations; all of them can be single or double acting.

The board interfaces 16 PLC inputs to terminal blocks, so you can have two limit sensors (extended, retracted) for each pneumatic cylinder.

The board has a four power terminals, two +24V and two GND. Providing extra 24V and Ground connections allows the board to power another board.

The board mounts on a Phoenix UMK DIN-rail holder. I have successfully used the UMK series before. Phoenix also provides 3-D models, which is useful.

I will be using Eagle PCB to create the schematic and layout the PCB. I will be using Sierra Proto Express as the board house. I plan on investigating the creation of a 3-D board model.


July 9, 2007   No Comments