From a32ae4e71835b922effa4aaee20c3bb0b9a8280b Mon Sep 17 00:00:00 2001 From: cpu Date: Sat, 5 Sep 2026 20:01:30 +0200 Subject: [PATCH] improvements --- export.sh | 21 ++++++++++++++++----- millproject | 23 ++++++++++++----------- 2 files changed, 28 insertions(+), 16 deletions(-) diff --git a/export.sh b/export.sh index ab345d1..2d8a624 100755 --- a/export.sh +++ b/export.sh @@ -20,8 +20,19 @@ mkdir -p "$GCODE_DIR" echo "Exporting gerbers..." kicad-cli pcb export drill --generate-map -o "$GERBERS_DIR" "$PCB_FILE" kicad-cli pcb export gerbers -o "$GERBERS_DIR" -l Edge.Cuts "$PCB_FILE" -kicad-cli pcb export gerbers -o "$GERBERS_DIR" -l Front "$PCB_FILE" -kicad-cli pcb export gerbers -o "$GERBERS_DIR" -l Back "$PCB_FILE" +kicad-cli pcb export gerbers -o "$GERBERS_DIR" -l F.Cu "$PCB_FILE" +kicad-cli pcb export gerbers -o "$GERBERS_DIR" -l B.Cu "$PCB_FILE" + +echo "Exporting SVGs..." +kicad-cli pcb export svg -o "$GERBERS_DIR" -l B.Mask \ + --mode-multi --page-size-mode 1 --black-and-white \ + --drill-shape-opt 0 --exclude-drawing-sheet "$PCB_FILE" + +kicad-cli pcb export svg -o "$GERBERS_DIR" -l F.SilkS \ + --negative \ + --mode-multi --page-size-mode 1 --black-and-white \ + --drill-shape-opt 0 --exclude-drawing-sheet "$PCB_FILE" + # kicad-cli pcb export svg -o "$GERBERS_DIR" -l Edge.Cuts \ # --mode-multi --page-size-mode 1 --black-and-white \ # --drill-shape-opt 0 --exclude-drawing-sheet "$PCB_FILE" @@ -33,7 +44,7 @@ docker run --rm -it \ ptodorov/pcb2gcode \ --config millproject \ --output-dir "$GCODE_DIR" \ - --front "$GERBERS_DIR/$PCB_FILE_PREFIX-Front.gtl" \ - --back "$GERBERS_DIR/$PCB_FILE_PREFIX-Back.gbl" \ + --front "$GERBERS_DIR/$PCB_FILE_PREFIX-F_Cu.gtl" \ + --back "$GERBERS_DIR/$PCB_FILE_PREFIX-B_Cu.gbl" \ --drill "$GERBERS_DIR/$PCB_FILE_PREFIX.drl" \ - --outline "$GERBERS_DIR/$PCB_FILE_PREFIX-Edge_Cuts.gm1" \ No newline at end of file + --outline "$GERBERS_DIR/$PCB_FILE_PREFIX-Edge_Cuts.gm1" diff --git a/millproject b/millproject index ce9102d..12928e9 100644 --- a/millproject +++ b/millproject @@ -9,11 +9,11 @@ zchange=35 # Tool changing height in mm # Place a 5x7cm board in the lower right quadrant of the coordinate system # This will allow you to probe the fixed jaw of the vise for (0,0) on the CNC. -# For two-sided boards, the PCB needs to be flipped along the axis x=VALUE -mirror-axis=80 # set this to half of your board width +# The PCB needs to be flipped along the axis x=VALUE +mirror-axis=16.5 # set this to half of your board width # Drilling -zdrill=-2.2 # drilling depth +zdrill=-3.5 # drilling depth drill-feed=400 # Vertical mm/min feed drill-speed=24000 # Spindle RPM #onedrill=true # Use a single drill for all holes @@ -21,20 +21,21 @@ nog81=true # replace G81 with G0+G1 (no G81 in GRBL) drill-side=back # Milling -zwork=-0.1 # V-bit plunge depth +zwork=-0.05 # V-bit plunge depth #mill-diameters=0.11 # 60 deg V-bit dia at -0.1 plunge depth #mill-diameters=0.08 # 45 deg V-bit dia at -0.1 plunge depth -mill-diameters=0.05 # 30 deg V-bit dia at -0.1 plunge depth +#mill-diameters=0.05 # 30 deg V-bit dia at -0.1 plunge depth +mill-diameters=0.12 # 30 deg V-bit dia at -0.04 plunge depth mill-speed=24000 # Spindle RPM -mill-feed=600 # Horizontal feedrate in mm/min +mill-feed=450 # Horizontal feedrate in mm/min mill-vertfeed=100 # Plunge rate in mm/min -voronoi=true # cuts the milling time significantly, but check with this on and off if everything looks ok +voronoi=true # cuts the milling time significantly, but check in https://ncviewer.com/ with this on and off if everything looks ok preserve-thermal-reliefs = true # has effect only if voronoi=true # Cutting -zcut=-2.2 +zcut=-3 cutter-diameter=2.1 -cut-feed=400 +cut-feed=800 cut-vertfeed=50 cut-infeed=4 cut-speed=24000 @@ -42,5 +43,5 @@ cut-side=back # Tabs bridgesnum=4 # Total 4 tabs -bridges=0.5 # Tab width 0.5 mm -zbridges=0.8 # bridges height (default to zsafe) +bridges=0.4 # Tab width 0.5 mm +zbridges=0.8 # bridges height (default to zsafe)