From 6666f1760ae58f2ed0e430a8c80aa0e8f310d37f Mon Sep 17 00:00:00 2001 From: Pierre Lecomte Date: Wed, 24 May 2023 16:47:00 +0200 Subject: [PATCH] add metal rod lengths + doc update --- cad/sma_open.scad | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/cad/sma_open.scad b/cad/sma_open.scad index 080a0c5..7d52442 100644 --- a/cad/sma_open.scad +++ b/cad/sma_open.scad @@ -8,11 +8,14 @@ */ // To visualize the whole SMA -open_sma(); +//open_sma(); // To render only one attach or the support, ready to print //ready_to_print(5); +// To echo le metal rod length for i-th microphone: +//studs(0); + // EDIT BELOW //$fn=128; //for final render @@ -145,11 +148,13 @@ module studs(id_mic, rstud=1.75){ for (i=[0:len(neighbors[id_mic])-1]){ neighbor = sph2cart([r[neighbors[id_mic][i]], theta[neighbors[id_mic][i]], phi[neighbors[id_mic][i]]]); rtp2=cart2sph(neighbor-center); + h = norm(neighbor-center)-2*16; + echo("Metal rod length:", h); translate(center) rotate([0, rtp2[1], rtp2[2]]) - color("blue") + color("blue") translate([0,0,16]) - cylinder(r=rstud,h=norm(neighbor-center)-2*16); + cylinder(r=rstud,h=h); } }