Skip to content

Instantly share code, notes, and snippets.

@bdpdx
Last active April 15, 2022 20:28
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bdpdx/899847c0c926401982b1b44fdc6f880e to your computer and use it in GitHub Desktop.
Save bdpdx/899847c0c926401982b1b44fdc6f880e to your computer and use it in GitHub Desktop.
Routing:
to make vias, run a trace and then just switch layers.
it's useful to map f2 and f3 to top/bottom respectively so it's easy to switch on the fly
Useful commands:
show (net) // e.g. "show 5v" -> shows all elements on that net
Ground pour:
create polygon on four corners of board
width of .1524mm, 0.006"
isolate .3048mm, 0.012"
enable thermals
rank 6 so lower rank pours (power) take precendence
after connecting polygon to GND net type or click RATSNEST to show it
type "ripup @;" to hide pours (this can be tied to a function key)
type "ratsnest" to show them again
pour both top and bottom layers
automatic calculation of polygons can be turned off/on with "SET POLYGON_RATSNEST OFF;"
Power pour, same as above but use lower rank
Great sites:
https://learn.sparkfun.com/tutorials/using-eagle-board-layout/all#finishing-touches
http://dangerousprototypes.com/blog/2012/07/18/eagle-polygons/
If eagle appears to get stuck:
• you cannot select any part
- close the brd and sch windows and close the project in the control panel
- restart eagle
- reopen the project
- make sure any used libraries are in-use (green dot in the control panel)
• airwires are not visible
- type "rat *"
How to add a vector image to the silkscreen:
- If there is a vector image source (best):
- Get an SVG somehow, either directly from the designer, or import a pdf in Illustrator, whatever.
- Open the file in Illustrator and chop out everything you don't need (ungroup, delete, etc.)
- (optional) tweak the image so it goes edge-to-edge, i.e. so there aren't full transparent edges. You can also trim in Photoshop if this is a problem. This may not be necessary at all for your image.
- In Illustrator I had an image with multiple colors.
- I first used View -> Show Transparency Grid to let me see what was behind my objects
- Then I selected all objects and used Edit -> Edit Colors -> Recolor Artwork to change all the objects to white
- Now in Illustrator the vector art was all white on transparent.
- Export this file as an SVG.
- Open the vector image in Photoshop.
- Photoshop will ask what size to rasterize the vector image into:
- The EAGLE import BMP tool has a scaling function, but it's easiest to just map 1 pixel in the image to 1 physical
mil on the pcb. So a 1000x1000 pixel image will map to a 1 inch by 1 inch square on the board. There is no
scaling in EAGLE so figure out the target size and get the image mapped 1:1 pixel:mil in Photoshop.
- The silkscreen only has one color, so the image in Photoshop needs to be reduced to white on black.
- Make a new layer in photoshop and drag it to the bottom, fill it with black. This ensures there are no transparent pixels.
- Now choose Image -> Mode -> Bitmap to convert it to a flatted two image, white & black.
- use 50% threshold conversion algo
- Save As BMP. The BMP dialog should say the image has 1-bit color depth. If not, fix it.
- Open Eagle, make a project and edit the board.
- Choose File -> Import -> Bitmap...
- Say OK to the first dialog.
- You will see a color dialog with two colors, click "Set all" then "OK"
- On the next dialog, all the defaults are good.
- Scaled
- Mil
- Scale Factor 1
- Start layer 200
- Choose OK and the script will start processing the bmp.
- It will show a dialog asking "Accept Script?" Choose "Run Script"
- The image will now be rendered into layers 200 and 201.
- Hide all layers and then show just layer 200. This should be the layer you want but layer 201 will have the inverse and might look cool too.
- On layer 200 hit cmd-A to select all then cmd-C to copy the logo.
- Open the library manager (Libary -> Open Library Manager)
- Edit your favorite library or create a new one.
- Add a new footprint called "MyLogo"
- In the footprint editor, hit cmd-v to paste the logo.
- For some reason on mine I have to zoom way out to see the logo that got pasted. Immediately after pasting it though you can move it, so zoom out then drag it around until the center of the image is over the origin crosshairs.
- Now choose "fit to window", the image should be front and center.
- The image gets pasted from layer 200 in the board to layer 200 in the footprint. We need to move it to the tNames layer.
- cmd-a select all
- Click the wrench and choose Layer, then pick layer 25 tNames.
- Now to actually apply the wrench action, move the mouse over the origin crosshairs and right-click to see the context menu and choose "Change: Group"
- Save the footprint
- Go back to the device view and create a new symbol, called "MyLogo". Make a simple box around the crosshairs and add a text line above it that says "MyLogo"
- Save the symbol
- Go back to the device view and create a new device called "MyLogo"
- Add the MyLogo symbol to the device, and add the MyLogo footprint (New button -> Add local package)
- Save the device and close the library editor
- We're done making the new part.
- Go into the schematic and add the new MyLogo part
- Open the board view and the silkscreen will be there.
- If you want it on the back of the board use the mirror tool and click on it.
- Move the logo wherever you want it.
- Done.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment