]> www.fi.muni.cz Git - things.git/blob - rc-plane-wheel.scad
mini-arrow-firewall: adjust dimensions
[things.git] / rc-plane-wheel.scad
1 infty = 100;
2 eps = 0.01;
3
4 wheel_d = 60;
5 wheel_h = 4;
6 wheel_thick_outer = 1;
7 wheel_thick_inner = 2;
8 wheel_rim = 4.5;
9
10 min_wall = 0.5;
11
12 spokes = 5;
13 spoke_w =  5;
14 spoke_h = 2.5;
15
16 center_d = 12;
17 center_hole = 4;
18 center_h = 10;
19
20 module body() {
21         // rim
22         difference() {
23                 cylinder(r = wheel_d/2, h = wheel_h, $fn = 128);
24                 translate([0,0,min_wall-eps])
25                         cylinder(r1 = wheel_d/2 - wheel_thick_inner,
26                                 r2 = wheel_d/2 - wheel_thick_outer,
27                                 h = wheel_h - min_wall+ 2*eps);
28                 translate([0,0,-eps])
29                         cylinder(r = wheel_d/2 - wheel_rim,
30                                 h = min_wall+2*eps);
31         }
32
33         // spokes
34         for (a = [0:360/spokes:360-eps]) {
35                 rotate([0, 0, a])
36                 hull() {
37                         translate([-spoke_w/2, 0, 0])
38                                 cube([spoke_w, wheel_d/2 - min_wall/2, min_wall]);
39                         translate([-min_wall/2, 0, spoke_h-eps])
40                                 cube([min_wall, wheel_d/2 - min_wall/2, eps]);
41                 }
42         }
43
44         cylinder(r1 = center_d/2, r2 = center_hole/2 + 2*min_wall, h = center_h);
45 }
46
47 difference() {
48         body();
49         // center hole
50         translate([0, 0, -eps])
51                 cylinder(r = center_hole/2, h = center_h + 2*eps);
52 }