]> www.fi.muni.cz Git - things.git/blob - rc-control-horn-long.scad
modified Kaze parts
[things.git] / rc-control-horn-long.scad
1 eps = 0.01;
2 infty = 100;
3
4 wall = 1;
5
6 slot_off_x = 8;
7 slot_off_y = 8;
8
9 slot_l = 30;
10 slot_depth_front = 6;
11 slot_depth_rear = 2;
12
13 hole_h = 20;
14 hole_d = 1.5;
15 hole_step = 1.8*hole_d;
16 n_holes = 3;
17
18 base_angle = 8.5;
19
20 hole_side = 2*wall;
21
22 module horn() {
23         difference() {
24         hull() {
25                 // base
26                 rotate([0, 0, base_angle]) {
27                         translate([slot_off_x, slot_depth_front-eps, 0])
28                                 cube([eps, eps, wall]);
29                         translate([slot_off_x + slot_l - eps, slot_depth_rear-eps, 0])
30                                 cube([eps, eps, wall]);
31                 }
32
33                         for (y = [1:n_holes]) {
34                                 translate([0, hole_h -(y-1)*hole_step, 0])
35                                         cylinder(r = hole_d/2 + hole_side,
36                                                 h = wall, $fn = 6);
37                         }
38                 }
39
40                 for (y = [1:n_holes]) {
41                         translate([0, hole_h -(y-1)*hole_step, -eps])
42                                 cylinder(r = hole_d/2, h = wall + 2*eps, $fn = 6);
43                 }
44         }
45
46         // slot
47         rotate([0, 0, base_angle]) hull() {
48                 translate([slot_off_x, 0, 0])
49                         cube([eps, slot_depth_front, wall]);
50                 translate([slot_off_x + slot_l - eps, 0, 0])
51                         cube([eps, slot_depth_rear, wall]);
52         }
53 }
54
55 horn();