documentation continued

This commit is contained in:
Pierre Lecomte 2023-05-24 15:36:06 +02:00
parent 7600c13ae0
commit 2f66ac2eff
3 changed files with 42 additions and 19 deletions

View File

@ -6,7 +6,7 @@ build Spherical Microphone Arrays (SMA)s prototype for research or home use. The
designs are made with opensCAD, they are customizable and the different parts
can be directly 3D printed. Extra standard mechanical assembly elements may be
required such as screws or metal rods.
Two main configurations are proposed: open sphere or rigid sphere.
Two configurations are proposed: open sphere or rigid sphere.
The customization parameters are the array radius, the number and position of the microphones, their type and extra options such as the possibility to embed an USB sound card inside the array.
The microphone arrays signal processing for a Spherical Harmonic decomposition is provided as a code in the Faust language.
Also, Python codes are provided for the calibration of the Spherical Microphone Arrays using a robotic arm.
@ -18,4 +18,4 @@ The designs are in the `cad` folder:
- `sma_rigid_mchstreamer.scad` for rigid SMA configuration with digital MEMS microphone and embedded USB sound card.
Examples of SMA configurations are provide in `.json` files.
See the documentation in `.scad` files to customize a designs.
See the documentation in `.scad` files to create or customize a SMA design.

View File

@ -1,6 +1,15 @@
/*
* Open SMA design for cylindrical microphone capsules
* Copyright 2023 Pierre Lecomte - sekisushai@gmail.com
*/
include <threads.scad>;
//$fn=128;
open_sma();
// EDIT BELOW
/*[ Array parameters ]*/
// Last parameter is for support attach.
@ -24,6 +33,8 @@ neighbors =
[1, 2, 3], // support
];
// DO NOT EDIT BELOW HERE
module attach(id_mic, rmic=3.82, rstud=1.75, color="yellow"){
rtp = [r[id_mic], theta[id_mic], phi[id_mic]];
center = sph2cart(rtp);
@ -119,13 +130,6 @@ module support(stud=1.75){
}
}
for (i = [0:len(theta)-2]){
attach(i);
studs(i);
};
module studs(id_mic, rstud=1.75){
rtp = [r[id_mic], theta[id_mic], phi[id_mic]];
center = sph2cart(rtp);
@ -144,4 +148,11 @@ function cart2sph(vec)
= [norm(vec), acos(vec[2]/norm(vec)), atan2(vec[1],vec[0])];
function sph2cart(vec)
= [vec[0]*sin(vec[1])*cos(vec[2]), vec[0]*sin(vec[1])*sin(vec[2]), vec[0]*cos(vec[1])];
= [vec[0]*sin(vec[1])*cos(vec[2]), vec[0]*sin(vec[1])*sin(vec[2]), vec[0]*cos(vec[1])];
module open_sma(){
for (i = [0:len(theta)-2]){
attach(i);
studs(i);
};
};

View File

@ -1,5 +1,19 @@
include <threads.scad>;
/*
* Rigid SMA design for cylindrical microphone capsules
* Copyright 2023 Pierre Lecomte - sekisushai@gmail.com
*/
include <threads.scad>
/*
The rigid SMA is composed of two hemispherical shells to render separately for 3D printing.
*/
//top_shell_all();
bottom_shell_all();
// EDIT BELOW
/*[ Global parameters ]*/
// Resolution of outter surface (360 for 3D printing)
res = 32;
@ -49,12 +63,12 @@ hole_phi_offset = 45;
d_hole = 10;
/*
The mic stand threaded hole should be close to the passing cable hole. It's direction is set as an offset from the cable hole direction.abs
The mic stand threaded hole should be close to the passing cable hole. It's direction is set as an offset from the cable hole direction.
*/
// threaded hole offset from cable hole [theta(°), phi(°)]:
dir_thread = [13, 0];
// DO NOT EDIT BELOW HERE
// Hollow sphere
module hollow(r1=r-e, r2=r, fn1=$fn, fn2=$fn){
@ -77,8 +91,6 @@ square([3.55, 1.1*e]);
}
}
echo(len(theta));
module mics(){
rotate(mics_rotate)
for (i = [0 : len(theta)-1]){
@ -148,6 +160,9 @@ cylinder(d=d_hole, h=100);
rotate([(angle_min+angle_max)/2 + dir_thread[0],0, hole_phi_offset + dir_thread[1]])
translate([0,0,(r-3*e)])
render()
/*
Change here the type of threaded hole for mounting on a mic stand. See threads.scad file for help
*/
//english_thread(3/8,16,3.5*e/25.4,internal=true);
metric_thread (diameter=6, pitch=1, length=20);
}
@ -197,7 +212,4 @@ module test_mic(){
torus();
}
}
}
//top_shell_all();
bottom_shell_all();
}