summaryrefslogtreecommitdiff
path: root/mech/pcb_case
diff options
context:
space:
mode:
authorxengineering <me@xengineering.eu>2023-12-23 22:38:56 +0100
committerxengineering <me@xengineering.eu>2024-01-02 14:24:58 +0100
commit382f78cfee52d0a29e1b5948ade7a1de293e9e30 (patch)
tree17bcf54cc98f66f7c15f0eb50010c68ee602726d /mech/pcb_case
parent432589acd8b56f881bd5006497a1dbb722a502a8 (diff)
downloadsoundbox-382f78cfee52d0a29e1b5948ade7a1de293e9e30.tar
soundbox-382f78cfee52d0a29e1b5948ade7a1de293e9e30.tar.zst
soundbox-382f78cfee52d0a29e1b5948ade7a1de293e9e30.zip
mech: pcb_case: Add bolt_tolerance_test.scad
This should make sure the right hole diameter is selected for bolts.
Diffstat (limited to 'mech/pcb_case')
-rw-r--r--mech/pcb_case/bolt_tolerance_test.scad21
1 files changed, 21 insertions, 0 deletions
diff --git a/mech/pcb_case/bolt_tolerance_test.scad b/mech/pcb_case/bolt_tolerance_test.scad
new file mode 100644
index 0000000..b658183
--- /dev/null
+++ b/mech/pcb_case/bolt_tolerance_test.scad
@@ -0,0 +1,21 @@
+include <bolt.scad>
+
+module bolt_tolerance_test() {
+ steps = 3;
+ step_width = 0.1;
+ height = 3;
+
+ for(i = [-steps : steps]) {
+ tol = bolt_ds_tol + i * step_width;
+ echo(tol=tol);
+ translate([i*5*bolt_ds,0,0])
+ difference() {
+ cube([5*bolt_ds, 5*bolt_ds, height]);
+ translate([2.5*bolt_ds,2.5*bolt_ds,0]) {
+ cylinder(d=bolt_ds+tol,h=height,$fn=50);
+ }
+ }
+ }
+}
+
+bolt_tolerance_test();