Created
December 18, 2023 20:17
-
-
Save loopj/8882b6b95265988cd1b6156baa3eba97 to your computer and use it in GitHub Desktop.
Generate PCB renders (SVG and PNG) from KiCad
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
mkdir -p temp | |
cd temp | |
# Export gerbers | |
kicad-cli pcb export gerbers ../pcbname.kicad_pcb -l F.Cu,B.Cu,F.Paste,B.Paste,F.SilkS,B.SilkS,F.Mask,B.Mask,Edge.Cuts | |
# Generate SVGs | |
tracespace -L *.* | |
# Generate PNGs | |
for file in *.svg; do | |
inkscape --export-type=png --export-dpi=600 --export-filename="${file%.svg}.png" "$file" | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment