Eagle and Gerber Files

Tuesday, January 31st, 2006

We submitted the files to pcbexpress and they said that the .drl file was not the NC drill file. I had to run the excellon.cam job file to generate the .drd file.

Recently I had to use Eagle to adjust a colleague’s PCB layout. To install it on a Mac, first download and install X11. Next download Eagle from cadsoft and uncompress the file. You should now see a directory. Inside, there’s a readme.txt file that tells you to run a bunch of commands in the terminal so that you can use the ‘install’ script that’s in the directory…but immediately following these commands it says:

NOTE: the installation procedure described here is not mandatory.
You can just extract the TGZ archive to any location of your choice
and use it there directly. All the ‘install’ script does is to copy
the program and man-page to the default location and set up a
symbolic link to the executable in /usr/bin/eagle.

So, just copy the directory to your /Applications directory and you should be set.

Now (drumroll), in order to run Eagle you first have to start the X11 server. After X11 is up and running, double-click on the ‘eagle’ file in the ./bin directory in Eagle’s main directory. That’s it.

After creating your schematic and pcb layout, you need to generate the appropriate files to submit to a PCB manufacturer. Most of these places will require Gerber files. I’m submitting my designs to PCBexpress and I found these easy to follow directions on their site…to generate Gerber files from Eagle, download these .cam job files and follow these instructions.
These .cam files will generate the appropriate Gerber files for you to submit. For a two layer PCB (traces on top and bottom), you’ll use E1.cam or E2.cam. Here are the files that are commonly generated with the .cam files downloaded from pcbexpress:

.bot – bottom traces
.top – top traces
.bsk – bottom silkscreen
.slk – top silkscreen
.smb – bottom solder mask
.smt – top solder mask
.drl – drill tool file

Happy PCB designing! There’s something satisfying about laying out component and solving the puzzle of connecting them together without crossing wires. :)

DIY USB Charger

Friday, January 20th, 2006

Rachel wanted an external charger to charge up her iPod nano but Apple sells iPod one for $30! I wanted to see if I can cook something with the stuff in my miscellaneous electronics closet.

Disclaimer: This info is provided with no guarantees. If you don’t know what you’re doing, do not try to put this together.

I found a 5V (1A) power supply that I purchased to use for microcontroller projects. I bought it from allelectronics (part number: PS-513) and it was only $4.50.

I didn’t have a female USB plug, so I bought a USB extension cable from Target for $8.

You’ll also need a multimeter, a soldering iron and some heat shrink, 1/4″ diameter. (You can use electrical tape, too.)

  1. Cut the male phone connector off of the power supply. Remove an inch or so of the the outer insulation and you should see four wires. Red/Black => +5 and Yellow/White => GND. Strip the Red and White wires. I plugged in the power supply and the voltage measure 5.2V. The USB specs indicate that USB hubs will supply voltages in the range of 4.4V to 5.25V (more specifically 4.7V to 5.25 V for High power devices and 4.4V to 5.25V for Low power devices.)
  2. Cut the USB extension cable. I just cut my 6′ cable in half. One should haver the male connector and the other should have the female connector. We’re going to use the half that has the female connector. Remove some of the insulation, the metal foil, and shield, from the cut end and you’ll see four wires. Red is +5 and Black is GND.
  3. Now, connect (just twist together for now):
    • Red (power supply) to Red (USB cable)
    • White (power supply) to Black (USB cable)


  4. You can do a little test before plugging in a real device. Take the other section of the cut USB cable (the one with the male connector) remove the insulation, and strip the red and black wires. Plug the male USB connector into the female USB connector. Plug the power supply into the wall. Take a voltage reading from the red and black wires you just stripped. If you see +5V then you’re set! If you see -5V then you’ve misconnected the wires between the power supply and the USB cable(w/ female connector)

Now you’re ready to plug in your USB device. I have a “broken” mobiblu MP3 player. It doesn’t play music anymore, but it still responds to charging. I plugged my power supply into the wall. I plugged my mobiblu into the female connector of my homemade charger…and voila the mobiblu shows that it’s charging from a charger! If you don’t have a device that you can test on, make sure that you check all the voltages before plugging in something expensive…like your iPod. If you have a USB light or something try that first.

So now all you have to do is tidy up your work by soldering the connections you made and heat shrink (or tape up) the section of exposed cable and you’re project is complete.
solder and heatshrink

You can do this with any regulated 5V power supply. There are lots of places you can get them. Jameco has them.

Some more info on USB specs
(including pinouts and voltage specs).

Good Luck!