From 95a11e7600eebe1e80915dcdccf766ca31ba6cd7 Mon Sep 17 00:00:00 2001 From: Sam Hadow Date: Wed, 15 Apr 2026 16:29:12 +0200 Subject: [PATCH] hole pattern change --- flower_pot.py | 2 ++ flower_pot/pot.scad | 9 ++++++++- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/flower_pot.py b/flower_pot.py index 0efef9d..1589a06 100644 --- a/flower_pot.py +++ b/flower_pot.py @@ -55,6 +55,8 @@ def main() -> None: if not SCAD_DIR.exists(): raise SystemExit(f"Missing SCAD directory: {SCAD_DIR}") + print("Dimensions less than 20mm will result in unusable stl files.\n") + base_radius = ask_float("Flower pot radius (base_radius) in mm: ") wall_height = ask_float("Flower pot height (wall_height) in mm: ") wall_height_tray = ask_float("Tray height (wall_height_tray) in mm: ") diff --git a/flower_pot/pot.scad b/flower_pot/pot.scad index b91bbe2..1a8d683 100644 --- a/flower_pot/pot.scad +++ b/flower_pot/pot.scad @@ -56,7 +56,14 @@ module holes_pattern() { union() { circle(d = hole_d); - for(r = [base_radius * 0.33, base_radius * 0.66]) { + // rings based on the base radius + hole_circles = (base_radius < 35) + ? [base_radius * 0.5] + : (base_radius < 55) + ? [base_radius * 0.33, base_radius * 0.66] + : [base_radius * 0.25, base_radius * 0.5, base_radius * 0.75]; + + for(r = hole_circles) { for(a = [0 : 60 : 359]) { rotate([0, 0, a]) translate([r, 0, 0])