1 |
prumer = 100; |
1 |
prumer = 100; |
2 |
rafek = 10; |
2 |
rafek = 10; |
3 |
tloustka_rafku = 10; |
3 |
tloustka_rafku = 10; |
4 |
tloustka_zebrovani = 5; |
4 |
tloustka_zebrovani = 5; |
5 |
tloustka_stredu = 12; |
5 |
tloustka_stredu = 12; |
6 |
prumer_stredu = 20; |
6 |
prumer_stredu = 20; |
7 |
prumer_hridele = 4+1; |
7 |
prumer_hridele = 4.7; |
8 |
polomer_zakriveni = 15; |
8 |
polomer_zakriveni = 15; |
9 |
dokonalost_kruhu = 100; |
9 |
dokonalost_kruhu = 100; |
10 |
vyska_loziska = 3; |
10 |
vyska_loziska = 3; |
11 |
mount_hole = 3.2; // mounting screw hole diameter |
11 |
mount_hole = 3.2; // mounting screw hole diameter |
12 |
|
12 |
|
13 |
pocet_vykrojeni = 6; |
13 |
pocet_vykrojeni = 6; |
14 |
vnitrni_polomer_zebrovani = 10; |
14 |
vnitrni_polomer_zebrovani = 10; |
15 |
|
15 |
|
16 |
module kolo(){ |
16 |
module kolo(){ |
17 |
intersection() { |
17 |
intersection() { |
18 |
difference() { |
18 |
difference() { |
19 |
cylinder(r=prumer/2, h=tloustka_rafku, center=true, $fn=dokonalost_kruhu); |
19 |
cylinder(r=prumer/2, h=tloustka_rafku, center=true, $fn=dokonalost_kruhu); |
20 |
cylinder(r=prumer/2-rafek, h=tloustka_rafku*2, center=true, $fn=dokonalost_kruhu); |
20 |
cylinder(r=prumer/2-rafek, h=tloustka_rafku*2, center=true, $fn=dokonalost_kruhu); |
21 |
} |
21 |
} |
22 |
rotate_extrude(convexity=10, $fn=dokonalost_kruhu){translate([prumer/2-polomer_zakriveni, 0, 0]){circle(r = polomer_zakriveni, $fn=dokonalost_kruhu);}} |
22 |
rotate_extrude(convexity=10, $fn=dokonalost_kruhu){translate([prumer/2-polomer_zakriveni, 0, 0]){circle(r = polomer_zakriveni, $fn=dokonalost_kruhu);}} |
23 |
} |
23 |
} |
24 |
|
24 |
|
25 |
difference() { |
25 |
difference() { |
26 |
union() { |
26 |
union() { |
27 |
translate([0,0,-(tloustka_rafku-tloustka_zebrovani)/2]) cylinder(r=prumer/2-tloustka_rafku, h=tloustka_zebrovani, center=true, $fn=dokonalost_kruhu); |
27 |
translate([0,0,-(tloustka_rafku-tloustka_zebrovani)/2]) cylinder(r=prumer/2-tloustka_rafku, h=tloustka_zebrovani, center=true, $fn=dokonalost_kruhu); |
28 |
translate([0,0,-(tloustka_rafku- tloustka_stredu)/2]) cylinder(r=prumer_stredu/2, h=tloustka_stredu, center=true, $fn=dokonalost_kruhu); |
28 |
translate([0,0,-(tloustka_rafku- tloustka_stredu)/2]) cylinder(r=prumer_stredu/2, h=tloustka_stredu, center=true, $fn=dokonalost_kruhu); |
29 |
} |
29 |
} |
30 |
difference() { |
- |
|
31 |
cylinder(r=prumer_hridele/2, h=tloustka_stredu*2, center=true, $fn=dokonalost_kruhu); |
- |
|
32 |
translate([-prumer_hridele/2,prumer_hridele/2 - 0.5,-2]) |
- |
|
33 |
cube([10, 10, 200], center=false); |
- |
|
34 |
} |
- |
|
35 |
|
30 |
|
36 |
translate([0,0,-tloustka_stredu/2 + vyska_loziska/2 ]) |
31 |
translate([0,0,-tloustka_stredu/2 + vyska_loziska/2 ]) |
37 |
cylinder(r=4, h=vyska_loziska ,center=true, $fn=dokonalost_kruhu); // vybrani na mozazne kluzne lozisko na vystupu motoru |
32 |
cylinder(r=4, h=vyska_loziska ,center=true, $fn=20); // vybrani na mozazne kluzne lozisko na vystupu motoru |
- |
|
33 |
rotate([0,0,30]){ |
- |
|
34 |
|
- |
|
35 |
translate([0,30,4]) |
- |
|
36 |
rotate([90,0,0]) |
- |
|
37 |
cylinder (h = 30, r= mount_hole/2, $fn=20); // hole for mounting screw. |
- |
|
38 |
|
- |
|
39 |
translate([-3 ,3, 0]) // hole for mounting nut. |
- |
|
40 |
cube([6, 3, 20], center = false); |
38 |
|
41 |
|
39 |
translate([0,30,4]) |
42 |
difference() { // D-cut on axis |
40 |
rotate([90,0,0]) |
43 |
translate([0,0, tloustka_stredu-vyska_loziska + 0.2]) |
41 |
cylinder (h = 30, r= mount_hole/2, $fn=20); // hole for mounting screw. |
44 |
cylinder(r=prumer_hridele/2, h=tloustka_stredu*2, center=true, $fn=20); |
42 |
|
- |
|
43 |
translate([-3 ,3, 0]) // hole for mounting nut. |
45 |
translate([-prumer_hridele/2,prumer_hridele/2 - 0.5,-2]) |
44 |
cube([6, 3, 20], center = false); |
46 |
cube([10, 10, 200], center=false); |
- |
|
47 |
} |
- |
|
48 |
} |
45 |
} |
49 |
} |
46 |
} |
50 |
} |
47 |
|
51 |
|
48 |
|
52 |
|
49 |
module vykrojeni(alfa,vnitrni_polomer,r,tloustka,sirka_okraje,polomer_rohu){ |
53 |
module vykrojeni(alfa,vnitrni_polomer,r,tloustka,sirka_okraje,polomer_rohu){ |
50 |
b = sin(alfa/2) * r; |
54 |
b = sin(alfa/2) * r; |
51 |
|
55 |
|
52 |
intersection() { |
56 |
intersection() { |
53 |
translate([r/2 + sirka_okraje/sin(alfa/2),0,0]){ |
57 |
translate([r/2 + sirka_okraje/sin(alfa/2),0,0]){ |
54 |
difference(){ |
58 |
difference(){ |
55 |
cube([r, 2*b, tloustka], center=true); |
59 |
cube([r, 2*b, tloustka], center=true); |
56 |
union(){ |
60 |
union(){ |
57 |
translate([-r/2,0,-tloustka]){ |
61 |
translate([-r/2,0,-tloustka]){ |
58 |
rotate([0,0,alfa/2]){ |
62 |
rotate([0,0,alfa/2]){ |
59 |
cube([r, b, tloustka*2], center=false); |
63 |
cube([r, b, tloustka*2], center=false); |
60 |
} |
64 |
} |
61 |
} |
65 |
} |
62 |
translate([-r/2 - sin(alfa/2) * b,-cos(alfa/2) * b,-tloustka]){ |
66 |
translate([-r/2 - sin(alfa/2) * b,-cos(alfa/2) * b,-tloustka]){ |
63 |
rotate([0,0,-alfa/2]){ |
67 |
rotate([0,0,-alfa/2]){ |
64 |
cube([r, b, tloustka*2], center=false); |
68 |
cube([r, b, tloustka*2], center=false); |
65 |
} |
69 |
} |
66 |
} |
70 |
} |
67 |
} |
71 |
} |
68 |
} |
72 |
} |
69 |
} |
73 |
} |
70 |
|
74 |
|
71 |
difference() { |
75 |
difference() { |
72 |
cylinder(r=r, h=tloustka, center=true,$fn=dokonalost_kruhu); |
76 |
cylinder(r=r, h=tloustka, center=true,$fn=dokonalost_kruhu); |
73 |
cylinder(r=vnitrni_polomer, h=tloustka*2, center=true,$fn=dokonalost_kruhu); |
77 |
cylinder(r=vnitrni_polomer, h=tloustka*2, center=true,$fn=dokonalost_kruhu); |
74 |
} |
78 |
} |
75 |
} |
79 |
} |
76 |
} |
80 |
} |
77 |
|
81 |
|
78 |
difference() { |
82 |
difference() { |
79 |
kolo(); |
83 |
kolo(); |
80 |
difference() { |
84 |
difference() { |
81 |
for (i=[0:pocet_vykrojeni-1]){ |
85 |
for (i=[0:pocet_vykrojeni-1]){ |
82 |
rotate([0,0,i * 360/pocet_vykrojeni]){ |
86 |
rotate([0,0,i * 360/pocet_vykrojeni]){ |
83 |
scale([1,1,3]) { |
87 |
scale([1,1,3]) { |
84 |
vykrojeni(360/pocet_vykrojeni,10,37,10,3); |
88 |
vykrojeni(360/pocet_vykrojeni,10,37,10,3); |
85 |
} |
89 |
} |
86 |
} |
90 |
} |
87 |
} |
91 |
} |
88 |
|
92 |
|
89 |
translate([0,0,-tloustka_zebrovani*2]) {cylinder(r=vnitrni_polomer_zebrovani, h=tloustka_zebrovani*3, center=false, $fn=dokonalost_kruhu);} |
93 |
translate([0,0,-tloustka_zebrovani*2]) {cylinder(r=vnitrni_polomer_zebrovani, h=tloustka_zebrovani*3, center=false, $fn=dokonalost_kruhu);} |
90 |
} |
94 |
} |
91 |
|
95 |
|
92 |
} |
96 |
} |