dac38b58 |
1 | // challenge-bot |
2 | // GNU AGPLv3 (or later at your option) |
3 | // project available at these locations: |
4 | // https://gitorious.org/ozzloy/challenge-bot |
5 | // https://github.com/waynegramlich/challenge-bot |
6 | |
978bd219 |
7 | $fn = 60; |
8 | |
9 | // 3/16 inch in mm deck_depth = 4.7625; |
be16f419 |
10 | // 1/4 inch in mm = 6.35 |
11 | // subtract a little to be a squeeze fit |
8b340909 |
12 | deck_depth = 4.7625 - 0.4; |
dac38b58 |
13 | sonar_plate_width = 20; |
8ca271e9 |
14 | // sonar sensor measurements taken with calipers: |
49bffb72 |
15 | // 10.82 in between, 42.33 outside, 15.82 diameter |
8ca271e9 |
16 | // measured diameter of 15.82 with calipers, |
17 | // but when printed ends up being too small |
18 | sonar_sensor_radius = 15.82 / 2 + 0.3; |
dac38b58 |
19 | sonar_sensor_height = 13.8; |
49bffb72 |
20 | between_sensor_centers = 15.82 + 10.82; |
21 | sonar_plate_length = 3 + between_sensor_centers + sonar_sensor_radius + 3; |
74f8c088 |
22 | sonar_holder_length = sonar_plate_length + 10; |
23 | sonar_holder_width = sonar_plate_width + 3; |
49bffb72 |
24 | sonar_holder_depth = 4; |
8ca271e9 |
25 | |
49bffb72 |
26 | deck_holder_length = 30; |
74f8c088 |
27 | |
28 | module sensors(){ |
29 | translate([between_sensor_centers / 2, 0, 0]){ |
30 | cylinder(r = sonar_sensor_radius, h = sonar_sensor_height);} |
31 | translate([-between_sensor_centers / 2, 0, 0]){ |
32 | cylinder(r = sonar_sensor_radius, h = sonar_sensor_height);}} |
33 | |
49bffb72 |
34 | module sensor_holder(){ |
35 | difference(){ |
36 | cube([sonar_holder_length, sonar_holder_width, sonar_holder_depth]); |
37 | translate([sonar_holder_length / 2, sonar_holder_width / 2, -0.05]){ |
38 | sensors();}} |
39 | translate([sonar_holder_length, 0, 0]){ |
be16f419 |
40 | cube([sonar_holder_depth + 0.7, deck_depth, deck_depth - 0.7]); |
41 | translate([sonar_holder_depth + 0.7, 0, 0]){ |
49bffb72 |
42 | // subtract a little bit (0.3) to make it fit |
be16f419 |
43 | cube([deck_depth - 0.7, sonar_holder_width, deck_depth - 0.7]);}}} |
49bffb72 |
44 | |
74f8c088 |
45 | module deck_holder(){ |
be16f419 |
46 | deck_holder_width = sonar_holder_width - deck_depth; |
47 | cube([deck_holder_length, sonar_holder_depth, deck_holder_width]); |
49bffb72 |
48 | cube([sonar_holder_depth, |
49 | sonar_holder_depth * 2 + deck_depth, |
be16f419 |
50 | deck_holder_width]); |
49bffb72 |
51 | translate([0, sonar_holder_depth + deck_depth, 0]){ |
be16f419 |
52 | cube([deck_holder_length, sonar_holder_depth, deck_holder_width]);} |
49bffb72 |
53 | translate([sonar_holder_depth + deck_depth, 0, 0]){ |
54 | cube([sonar_holder_depth, |
55 | sonar_holder_depth * 2 + deck_depth, |
be16f419 |
56 | deck_holder_width]);}} |
74f8c088 |
57 | |
be16f419 |
58 | translate([0, sonar_holder_depth * 2 + deck_depth + 2, 0]){ |
59 | sensor_holder();} |
60 | deck_holder(); |