Introduction: Fritzing - Creating Your Own Parts
This Tutorial will take you through the steps of creating your own Fritzing parts using Digilent parts as an example.
During the process of creating Fritzing parts for Digilent I have been in close contact with the Fritzing parts expert. Much of the feedback he gave me was information that I didn't find on their website or on any other parts tutorial I could find. Because of this I felt I needed to make my own Tutorial combining all of the missing information from other tutorials.
I hope this helps make other people have a much more smooth experience creating parts than I've had.
I've attached to this intro a zip file containing illustrator templates for pins and commonly used parts.
Step 1: Required Downloads
The first piece of software you will need, is of course, Fritzing, which is free.
In order to make your parts, you need to make the images for all three views: breadboard, schematic, and PCB. These images need to be exported into SVG format.
1. I personally use Adobe Illustrator (Digilent has no affiliation with Adobe). However, Illustrator is not cheap. If you'd like to try it for free you can always download the 30 day free trial.
2. The other option is to use Inkscape, which is free.
From what I've experienced there are some compatibility issues between the two, but other than that people find one better than the other based on personal preference. I would recommend getting Inkscape and the 30 day free trial of Illustrator and testing them out before you decide to go for the purchase of Illustrator.
The last thing you need to do download is the Fritzing standard fonts. Fritzing uses OCR A and Droid Sans, both of which can be found here.
You may also want to download Fritzing templates for the three views, although I will include files for all three views of the example part I create in this tutorial.
Step 2: Breadboardview SVG
I usually begin making my parts by starting with the SVG image for the breadboard view.
Throughout this tutorial I will use the PmodENC, PmodBB, and chipKIT Pi as examples. I've included the SVG images and png images to this step. The png files are for preview and if you would like to download the SVG files you can open them in either AI or Inkscape to look at the individual parts in the image.
First, you'll want to open Illustrator or Inkscape and create a new file. Name the file so it is clear exactly what that image is. For example; PmodBB-Breadboard.
The next thing you'll want to do is show rulers and right click on the ruler to pick what units you want to use. It is important that you actually measure the parts in your chosen units and use that for your images.
Next choose the rectangle tool and draw the basic shape for the board. If the board is not exactly a rectangle it is easiest to cut out of the base rectangle rather than add shapes. You can create the shape you want to cut out and then use the remove front tool in the pathfinder. All what appears to be white circles in the examples are actually holes.
Next add whatever other components you want to add.
Note: If you plan on making multiple parts I extremely advise you to create a file of often used parts. That way you only have to measure it and create it once and it helps with consistency. For example, in my commonly used parts file I have switches (shown in PmodENC), screws (shown in PmodBB), buttons (shown in the chipKIT Pi), ports (shown in the chipKIT Pi), female and male pins (as shown in all examples), and circles for commonly sized holes.
In this file I also have a text box. If you use one size and font a lot, which you will have to, it saves time to copy and paste in this template text box and change the text than start from scratch every time.
You may also want to add logos to your parts. If your logos don't show up when you upload it to Fritzing you need a different file format. I used eps files for the logos on the Digilent Boards.
Step 3: Schematic View SVG
When creating the SVG for the schematic view first create the basic rectangle with the same demensions as the board. It should be filled with white and have a black outline.
Then put the name in the center.
The pins in schematic view have very specific standards. The pins must be 0.1 inch apart and 0.1 inch long. The pins also must be colored accordingly:
red: voltage input pins. (3V, 5V, VIN, etc.)
blue: input pins/analog pins, reset, ref pins etc
green: output pins/digital pins
black: ground pins
ps: Sorry about the sloppy image editing. I wanted to fix this as soon as possible so I don't mislead anyone. I will fix the actual images eventually.
Step 5: PCB View SVG
The PCB view SVG consists of multiple layers so that the PCB view of the Fritzing image can have more layers. However, the Fritzing layers do not directly correlate to AI layers-- they are actually sub-layers as shown in the last image. The easiest way to deal with the layers is to create your image all in two layers (silkscreen and copper1) and then add layers and move images around in the layer window when you are finished.
The examples that I give consist of two Fritzing layers, the copper layer and the silkscreen layer. The silkscreen layer is all of the black parts of the image, including the outline of the board shape. The copper layer has the gold colored circles that represent the pins, and the base shape of the board with no fill or outline. In AI the layer hierarchy will consist of:
-> copper1 (contains the copper parts)
The order of the images in your layers is very important. You want the pins to be above the outline in the copper1 layer otherwise you will not be able to select anything but the outline. In other words the images closest to the top in the copper layer will hide the images closer to the bottom.
Fritzing recommends that you name each of the pins in AI the same as they are named in Fritzing. You would do this in the layers menu and this way Fritzing will assign the PCB pins for you. However I found naming the pins took longer than just assigning them once I got into the PCB view. If you would like a closer look at the layers, I've attached my svg files for the Digilent PmodBB and PmodENC.
Just as in the breadboard view I recommend creating a commonly used parts file for PCB. This would consist of common configurations of pins.
I found that the easiest and fastest way to create the PCB view was to start with the silkscreen layer.
1. Copy and paste the base shape and all the text from the breadboard view into that layer. This way the text is all in the same place as the breadboard view
2. Next, make the text black and the base shape with no fill and a .3 pt black outline.
3. Then, copy in the black outline of the pins
4. Then create the copper1 layer.
6. Then put the gold colored circles in for the pins in the copper layer. make sure the pins are in the exact same location as those of the breadboard view. The copper1 layer only needs to have the pins no outline or anything else. Anything that is in this layer will be copper colored in Fritzing.
7. Then create a new layer called copper0 and drop copper one into that layer.
8. Then create the base layer and drag silkscreen and then copper0 into it.
For more information about Fritzing's graphic standards, including specific colors click here.
Step 6: Get a Generic Part
Next you'll need to find a generic part in Fritzing to use as a base for your new part. I usually use the generic IC found in core parts.
If you need an odd number of pins you can change the package to SIP (Single Inline) or use generic pins under core parts and connection.
Next change the number of pins to the number you want. If you plan on using the automatically generated Breadboard image it is very important that you get the number of pins right, because changing the number of pins in the editor does not change the graphic.
Step 7: New Parts Editor
Make sure the generic part is selected, open the parts menu and select new parts editor.
For this tutorial I will use the PmodENC as an example. I use the generic DIP with 6 pins.
Step 8: Metadata
The new parts editor window will open.
There are six sections in the new parts editor that ill need to be filled out; Breadboard, Schematic, PCB, Icon, Metadata and Connectors. I like to start with Metadata because otherwise I tend to forget it.
On the top of the new parts editor click the tab on the top that says "Metadata".
Metadata holds all the information about your part that will show up in the inspector. The images above show the information filled out for the generic DIP and for the Pmod that I am using as an example.
Step 9: Connectors
Although you can name and select the type of connectors in any view, I find it easiest to do it in connector view. Doing this in the Breadboard or other views requires a lot of double clicking and reloading which slow down the proccess.
Click the tab on the top of the new parts editor called "Connectors".
In the Connectors tab you can change the number of pins (this does not change the number of pins on the graphics), set the pins all to the same type, select between through-hole and SMD, and change the name, description and type of individual pins.
Step 10: Breadboard View
Click the tab on the top of the new parts editor that says Breadboard.
Open the file menu and select load image for view. Load your breadboard image that you previously created.
Next you'll need to select the graphic for each pin. Check marks in the list to the right means a graphic was selected for that pin. Double click select graphic on the pin you want to assign. Click on the graphic you want to assign to that pin, it will be highlighted in pink.
The graphic that you select will be what you can attach wires to in Fritzing. It will automatically select the center as the connection point, but you can change that where it says terminal point.
Once you have finished assigning all of the pins you are done in the Breadboard view.
Step 11: Schematic View
Click on the tab on the top of the new parts editor that says "Schematic".
The schematic view will automatically be created for you by Fritzing. However, until the new release you have to upgrade to the new 0.1 inch standard. Open the edit menu and select upgrade to the new 0.1 inch standard.
The pins are already selected, so you are done in schematic view.
Note: if you upload a custom schematic view you will have to select the pin graphics like you did in breadboard view.
Step 12: PCB View
Click the tab on the top of the new parts editor that says PCB. Open the File menu and click load image for view. Select the PCB SVG that you created and select graphics for the pins just as you did in the breadboard view.
Step 13: Icon
The last thing you have to change is the icon. Most often the icon for Fritzing parts is the same image as the Breadboard Image. When you open the file menu you can select reuse breadboard image.
Step 14: Save As New Part
Now you have completed all the changes to make your new part. Go to the file menu and select save as new part.
Step 15: FIlename
Fritzing will ask for a filename prefix, I usually use the name of the part.
The new parts editor will close and your sketch will still be there.
Step 16: Export
Your new part will be in the MyParts bin. If you want to keep that part in the MyParts bin make sure you save changes to the MyParts bin when you close Fritzing,
So that you have the part separate from Fritzing and so that you can share your part and show off your work, you will want to export the part. Right click on the part and select export part.
Name the part and save it wherever you want.
Step 17: Feedback!
I created this Tutorial to try and be as complete as possible but I may have missed a step here or there. If you have any confusion whatsoever or would like a step explained more please feel free to comment and I will try to clarify or add another step.
Feedback is incredibly important in keeping Tutorials thorough and up to date!
We have a be nice policy.
Please be positive and constructive.