I did find a few threads on this topic, but none of them were specific to v6, and I think a few things changed. …I think I have done this before in v5, but i don’t really remember how…
What’s the best workflow for creating (SMD) pads from imported vector graphics?
I would like to avoid using freeCAD for this.
I can import a svg or dxf, put the same shape on the mask and copper layer and just put them on top of an smd pad…but it feels like there must be a better way to do this ( and this might confuse the rule check…)
but it feels like there must be a better way to do this
I think you are already 90% right. my complete workflow (only used for real difficult shapes):
create pad-shape as dxf (used software: QCAD). Only use lines+arcs+ellipses for drawing. Be sure to draw a completely closed shape. Check for unwanted zero-length-linesegments. Be sure to draw only one outline, not two concentric lines.
in kicad footprint editor: prepare the “special pad” with an already named smd-pad with correct pad-number
import dxf-file, ungroup imported shape, select all imported lines and “Create Polygon From Selection”.
delete the original imported shape, leaving the polygon alone
change polygon-layer to F.copper, set filled-checkbox
select prepared Pad, RMB-click–>context-menu–>Edit Pad as graphic shapes
the FP-editor changes into a special “pad editing mode”. See the yellow info-warning-message at top of screen.
move the imported polygon on top of the Pad.
end the special “pad editing mode” with another right-click–>context-menu–>“finish Pad editing mode”. The original pad and the shape on top of that are combined into one irregular shaped Pad.
The irregular shaped Pad is respected with DRC-rule-checker.
I found out that some steps can be omitted if you import the graphics as a SVG because then shapes that have 0.0mm (‘hairline’) width will already be filled in KiCAD.
This is how i do it:
set line width to 0.0 in Inkscape → Import yourfile.svg in kicad → place small SMD pad on top of graphics → right click-‘Edit Pad as Graphic Shapes’ → exit pad editing mode
In my case this made sense because I was using Inkscape an an intermediary step anyways…so depending on your export options this might or might not save some time.
Using the SVG import it seems like i can throw anything at it, bezier-curves, vectorized text etc.
internal holes will be ignored. I can even import multiple shapes in one file and and then add the pads.
I tested it in 6.0.4 and can confirm that internal holes work just fine now .
SVG features like linecaps and dashed lines don’t work, but this is expected as those are features that as far as i know lines in KiCand can’t have. …but that’s fine because one can just convert them into filled shapes before import.