HackSpace_-_October_2019

(Rick Simeone) #1
FORGE

dialog to automatically launch the exported project in
KiCad. Check this option and then click Export.
You should now see KiCad boot, and it should
open the PCBnew application and have your
design already there. One of the first useful things
to do is to check that everything is as it should
appear by clicking View > 3dViewer and you
should see a rotatable 3D model of your PCB as it
stands (Figure 4).
Whilst it is totally possible to build an entire PCB
in Inkscape using svg2shenzhen, we were interested
to see if the svg2shenzhen output could be added
to using the typical KiCad workflow to enable a
combination of two approaches to PCB design.
As a test to see if it worked, we added a simple
circuit that is a breakout board for an ATtiny85
microcontroller. First, we saved our work in PCBnew
and closed it and opened Eeschema. Opening
Eeschema gives a dialog box that the project does
not contain a schematic file, and asks if we want
to create one. Having created one, we have a blank
Eeschema document. Into this, using standard
KiCad workflow and libraries, we added an ATtiny85
component, power and GND inputs, a bypass
capacitor across the VCC and GND pins on the
microcontroller, and an 8-pin header to which we are
going to break out the ATtiny.
We then wired the schematic using the wire tool
and again, as we did in the KiCad tutorials of issues
17 and 18, annotated the schematic, assigned
footprints to the schematic symbols, and created
a netlist.


Moving back to PCBnew, we then read the netlist
and that imported the components and the rat’s nest
perfectly, whilst still keeping the elements we drew
in Inkscape. Perfect! We then laid out and routed the
PCB with the new components. We were interested
to see that KiCad correctly observed the board edge
cuts, particularly when it came to flooding the PCB
areas with copper fill zones. As you can see from
Figure 5, it’s simply a case of using the ‘Add Filled
Zones’ tool to draw an area larger than the PCB and
KiCad will detect the board edges and pour the filled
area within the PCB edges. Finally, it’s also worth
noting that if you notice at any time something you
need to correct in Inkscape (in our example we had
placed the HackSpace magazine logo too low initially
as it clashed with the header pins), you can go back
to the saved Inkscape file, make a change, and re-
export the KiCad layers from Inkscape and overwrite
the earlier files. This won’t affect the Eeschema
documents or netlists within the KiCad project file,
but it will overwrite the PCBnew file. This means
that you will lose any work you have undertaken in
PCBnew (our added components and routing for
example), so it’s worth triple-checking you are happy
with the Inkscape layout parts of the board before
adding lots of work in KiCad.
Having completed the design in both Inkscape and
KiCad, it’s worth double-checking the board again in
the 3D viewer before placing your order (Figure 6 ). If
you are using OSH Park, which allows you to directly
upload the PCBnew file, then after finishing your
design you simply need to save your work in KiCad
and upload.
We were really impressed with svg2shenzhen,
finding it a highly usable piece of software and
indeed it makes creating complex or organic shapes
for KiCad simple to achieve. If you give it a try and
create something, make sure to send us a picture or
share a tweet with us @hackspacemagazine.

You can use the
KiCad 3D viewer to
check everything
is correctly laid out
and orientated on
the different layers.

QUICK TIP


All the techniques
used in KiCad in
this tutorial are
included in the KiCad
tutorials featured in
HackSpace magazine
issues 17 and 18.

QUICK TIP


Figure 5
KiCad recognises the edge cut lines made in Inkscape
and floods inside them correctly

Figure 6
Final checks of the
complete design,
again using the 3D
viewer in KiCad
Free download pdf