Introduction: Design a Raspberry Pi Hat: KiCad

The Raspberry Pi is a great tool that has given so many people a chance to develop cool software projects. The hardware extension of the Raspberry Pi has not yet grown to anywhere hear the strength of the Arduino. I want to help get it there.

You can view the blog where this tutorial came from at: OpenFET

To do this I created a totally open source Raspberry Pi Hat template. This template allows people to create whatever hardware they want for the Raspberry Pi without having to go through the work of figuring out how it will attach to the Pi and how it will receive power.

To create a Raspberry Pi Hat using this template you will need the following:

  • an Idea!
  • some knowledge of how to use KiCad
  • a soldering iron
  • somewhere to get electronic components (Digikey, Mouser, etc..)

Download and Install KiCad

Step 1: Download the Required Files

To create a Raspberry Pi Hat you are going to need the design template files. These can be obtained from git, you can clone it using git shell or you can download the zip file.

git clone


Download Project Files

These files are a complete KiCad project, the schematic and PCB are all included in these files. You can edit and change the files as much as you like!

Step 2: Add Your Own Touch to the Raspberry Pi Hat

Time for the fun part! You get to use your own creative freedom to make a Raspberry Pi Hat. You can make it as useful or as useless as you like. For this example we are going to make an LED bar-graph, just to keep it easy. And LED bar-graphs always look super cool!

You will need to do the following in the schematic

  • add 8 LEDs from the library on the side (Dont worry about the packages yet)
  • add 8 resistors
  • connect the 8 LEDs to different GPIO on the Pi
  • connect the other side of the LEDs to ground.

Once you have placed the components and connected the nets as seen in the above images you will then be able to link the components.

Step 3: Link the Components

This is the hard part. You need to link the components you are using to the footprints that they are associated with. Lets take our LED for example, LEDs come in all kinds of different packaged; through-hole, SMD, and in all different sizes. You need to choose which you want to use. In this example we will use a simple 3mm through-hole LED.

  1. Open CvPCB (It takes a second to load)
  2. Select footprints for the components that are blank
  3. Do this for the resistors and the LEDs (and any other components you may have added)
  4. Save and exit
  5. Finally generate the netlist, this will add the LEDs and resistors to the existing design.

Step 4: Design the PCB

Now you get to place the components on the PCB along with the existing parts of the Raspberry Pi Hat template. To do this you will need to complete the following. Keep in mind that all these steps are featured in the video if you get stuck.

  1. Open the PCB file from the project page
  2. Read netlist, you will see all the new parts added
  3. Place the parts where you want them to go
  4. Route traces to all of the new parts

You have now designed your first Raspberry Pi Hat! You can check your design using the DRC tool. For more information on this tool you can go to the KiCad documentation page. To get your design made you can export the Gerber files using KiCad and send them off to a PCB manufacturer (OSHPark, Seeed Studios, etc...). When you get them back you can solder all the components.

Hopefully in the near future I will also make an Instructable showing how to assemble the Hat, but dont worry its not to hard to figure out.