Explorar o código

add contact email, properly quote gpl license, minor wording tweaks for consistency

Fernando Pablo Lopez-Lezcano %!s(int64=11) %!d(string=hai) anos
pai
achega
0de6f61cfa
Modificáronse 1 ficheiros con 36 adicións e 19 borrados
  1. 36 19
      first_order.scad

+ 36 - 19
first_order.scad

@@ -2,16 +2,30 @@
 // SphEAR, First Order (B-format) Ambisonics Microphone
 //
 // Copyright 2015, Fernando Lopez-Lezcano, All Rights Reserved
+// nando@ccrma.stanford.edu
 //
-// Source code released under the GNU GPL License
-// http://www.gnu.org/licenses/gpl-3.0.en.html
 //
-// 3d models released under Creative Commons Non-Commercial Share-Alike
-// CC-NC-SA 3.0
-// http://creativecommons.org/licenses/by-nc-sa/3.0/
+//  This program is free software: you can redistribute it and/or modify
+//  it under the terms of the GNU General Public License as published by
+//  the Free Software Foundation, either version 3 of the License, or
+//  (at your option) any later version.
 //
+//  This program is distributed in the hope that it will be useful,
+//  but WITHOUT ANY WARRANTY; without even the implied warranty of
+//  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+//  GNU General Public License for more details.
+//
+//  You should have received a copy of the GNU General Public License
+//  along with this program.  If not, see <http://www.gnu.org/licenses/>.
+//
+//
+// 3d Models released under the Creative Commons license as follows:
+//   Attribution-NonCommercial-ShareAlike 4.0 International (CC BY-NC-SA 4.0)
+// http://creativecommons.org/licenses/by-nc-sa/4.0/
+
+
 // https://en.wikipedia.org/wiki/Tetrahedron
-// angle capsule to vertical = atan(sqrt(2)) = 54.7356103172
+// angle of capsule to vertical axis = atan(sqrt(2)) = 54.7356103172
 
 ////
 //// model parameters
@@ -48,7 +62,7 @@ mount_height = 4;
 rendermic = 1;
 renderset = 0;
 
-// what type of connection between capsule holders:
+// what type of connection to use between capsule holders:
 // 0 -> original cylinder beams
 // 1 -> interlocking beams (out)
 // 2 -> interlocking beams (in)
@@ -57,11 +71,12 @@ connect = 2;
 //// end of rendering control
 ////
 
-// adjustment for the size of the capsule
-//   (measured inside diameter was around 7.5 to 8.2 instead of 10, capsule diameter was 9.99)
+// adjustment for the radius of the capsule
+//   measured inside diameter of a trial print was around 7.5 to 8.2 
+//   instead of 10, capsule diameter was 9.99)
 fudge = 0.15;
 
-// adjustment for fit of slots
+// adjustment for fit of slots in connection legs and mount
 fit = 0.2;
 
 // wall thickness of cylinders
@@ -70,7 +85,7 @@ wall = 1;
 // number of facets for cylinders
 facets = 64;
 
-// the rest of the leg geometry
+// the rest of the connection leg geometry
 tetra = atan(sqrt(2));
 leg_length = 
 	connect == 0 ?
@@ -81,7 +96,7 @@ leg_length =
 slot_depth = connect == 1 ?
 	leg_thick * 1.5 : leg_thick;
 
-// holder geometry
+// microphone holder geometry
 capsule_sep_min = mic_radius * sin(tetra) - capsule_radius * cos(tetra);
 capsule_sep_max = capsule_sep_min + capsule_height * sin(tetra);
 capsule_bottom = mic_radius * cos(tetra) + capsule_radius * sin(tetra);
@@ -89,21 +104,20 @@ capsule_bottom = mic_radius * cos(tetra) + capsule_radius * sin(tetra);
 ////////
 // microphone capsule holder
 
-// azimuth: orientation of the capsule
-// elevation: orientation of the capsure
-// twist: adjust the angle of the mounts
-// mounts: number of mounts to create (2 for the bottom mics, 3 for the top)
+// azimuth: horizontal orientation of the capsule
+// elevation: vertical orientation of the capsure
+// mounts: vector with angles that correspond to the orientation of the legs
+// twist: rotate the whole capsule to match mounting legs
 
 module capsule (azimuth, elevation, mounts, twist) {
 	rotate([0, 0, azimuth]) {
 		rotate([0, (90 - elevation), 0]) {
   			translate([0, 0, rendermic == 0 ? 0 : mic_radius - capsule_height]) {
-				// the capsule holder
 				difference () {
 					union () {
 						// main capsule holder
 						cylinder(r = capsule_radius + wall, h = capsule_height, $fn = facets);	
-						// the attachment point to the other capsules
+						// the mounting legs
 						for (rot = mounts) {
 							rotate(a = rot + twist, v = [0, 0, 1]) {
 								// connect with cylindrical beams, very pretty
@@ -175,6 +189,9 @@ module capsule (azimuth, elevation, mounts, twist) {
 }
 
 // microphone mount
+//
+// wall: thickness of cylinder wall
+// separation: height of mount with respect of the microphone assembly
 
 module mount (wall, separation) {
 	translate([0, 0, -(separation + 1)]) {
@@ -207,7 +224,7 @@ module mount (wall, separation) {
 }
 
 // elevation angle for capsule holders
-elev = asin(1 / sqrt(3));
+elev = atan(1 / sqrt(2));
 
 // render a complete microphone
 if (rendermic == 1) {