Commit | Line | Data |
---|---|---|
e5d97a09 | 1 | // PRUSA Mendel |
d3618a65 NZ |
2 | // Bushings |
3 | // GNU GPL v3 | |
4 | // Josef Průša | |
5 | // josefprusa@me.com | |
6 | // prusadjs.cz | |
7 | // http://www.reprap.org/wiki/Prusa_Mendel | |
8 | // http://github.com/prusajr/PrusaMendel | |
9 | ||
e5d97a09 | 10 | include <configuration.scad> |
d3618a65 NZ |
11 | |
12 | /** | |
13 | * @id bushing | |
14 | * @name Bushing | |
15 | * @category Printed | |
16 | * @id bushing | |
e5d97a09 | 17 | */ |
d3618a65 | 18 | |
2fc35ca2 VAH |
19 | // Linear bearing options |
20 | lm8uu_diameter=(bearing_type==0) ? 16 : 15; | |
21 | lm8uu_length=(bearing_type==0) ? 24 : 25; | |
22 | lm8uu_radius = lm8uu_diameter / 2; | |
23 | block_height = 2*lm8uu_length+17; | |
24 | ||
25 | // basic building blocks, housings for 1 bushing/bearing | |
26 | // at [0,0] there is center of the smooth rod, pointing in Z | |
d3618a65 | 27 | |
e5d97a09 VAH |
28 | module linear_bushing_square(h=11) { |
29 | translate([0,0,h/2]) { | |
30 | difference(){ | |
31 | union(){ | |
3ade0448 | 32 | translate([-10.5/2,0,0]) cube(size = [10.5,13.8,h], center = true); |
e5d97a09 | 33 | cube(size = [13.8,13.8,h], center = true); |
3ade0448 | 34 | } |
2fc35ca2 | 35 | cube(size = [9,9,h+0.02], center = true); |
e5d97a09 VAH |
36 | } |
37 | } | |
38 | } | |
39 | ||
e5d97a09 VAH |
40 | module linear_bushing_round(h=11) { |
41 | difference(){ | |
42 | union(){ | |
3ade0448 | 43 | translate([-10.5/2,0,h/2]) cube(size = [10.5,15,h], center = true); |
e5d97a09 VAH |
44 | cylinder(r=7.5, h=h); |
45 | } | |
46 | translate([0,0,-0.01]) cylinder(r=5.1, h=h+0.02); | |
47 | } | |
48 | } | |
49 | ||
50 | module linear_bushing_bronze(h=11) { | |
51 | difference(){ | |
52 | union(){ | |
3ade0448 | 53 | translate([-10.5/2,0,h/2]) cube(size = [10.5,15,h], center = true); |
e5d97a09 VAH |
54 | cylinder(r=10.5, h=h); |
55 | } | |
56 | translate([0,0,-0.01]) cylinder(r=8.1, h=h+0.02); | |
57 | } | |
58 | } | |
59 | ||
2fc35ca2 VAH |
60 | // select right bushing and cut it at angle, so it can be printed upside down |
61 | module linear_bushing_long(h=30){ | |
e5d97a09 VAH |
62 | intersection(){ |
63 | if (bushing_type == 0) { | |
2fc35ca2 | 64 | linear_bushing_square(h); |
e5d97a09 VAH |
65 | } |
66 | if (bushing_type == 1) { | |
2fc35ca2 | 67 | linear_bushing_round(h); |
e5d97a09 VAH |
68 | } |
69 | if (bushing_type == 2) { | |
2fc35ca2 | 70 | linear_bushing_bronze(h); |
e5d97a09 VAH |
71 | } |
72 | if (bushing_type == 2) { | |
73 | translate([0, 0, 0]) rotate([0,-55,0]) cube([30, 40, 80], center=true); | |
74 | } else { | |
75 | translate([0, 0, -4]) rotate([0,-45,0]) cube([30, 40, 80], center=true); | |
76 | } | |
2fc35ca2 VAH |
77 | } |
78 | } | |
e5d97a09 | 79 | |
2fc35ca2 VAH |
80 | module linear_bushing(h=65){ |
81 | translate([-9.5,0,h/2]) cube([2,15,h], center=true); | |
82 | linear_bushing_long(h); | |
83 | if (h>30) { | |
84 | translate([0,0,h]) mirror([0,0,1]) linear_bushing_long(30); | |
e5d97a09 VAH |
85 | } |
86 | } | |
87 | ||
2fc35ca2 VAH |
88 | //this is for Z axis |
89 | module bushing_negative(h=65){ | |
90 | if (bearing_choice == 1) { | |
91 | if (bushing_type == 0) { | |
92 | translate([0,0,h/2]) cube(size = [9,9,h+0.02], center = true); | |
93 | } | |
94 | if (bushing_type == 1) { | |
95 | translate([0,0,-0.01]) cylinder(r=5.1, h=h+0.02); | |
96 | } | |
97 | if (bushing_type == 2) { | |
98 | translate([0,0,-0.01]) cylinder(r=8.1, h=h+0.02); | |
99 | } | |
100 | } else { | |
101 | translate([0,0,-0.01]) cylinder(r=lm8uu_radius+0.4, h=h+0.02); | |
102 | } | |
e5d97a09 | 103 | |
2fc35ca2 | 104 | } |
e5d97a09 | 105 | |
2fc35ca2 VAH |
106 | module firm_foot(){ |
107 | difference(){ | |
108 | union() { | |
109 | translate([0,13,0]) cube_fillet([3,18,20], top=[11,0,0,0], center=true); | |
110 | } | |
111 | translate([1.5,14,0]) rotate([0,-90,0]) screw(); | |
e5d97a09 | 112 | } |
d3618a65 NZ |
113 | } |
114 | ||
2fc35ca2 | 115 | module spring_foot(){ |
d3618a65 | 116 | |
2fc35ca2 VAH |
117 | difference(){ |
118 | union() { | |
119 | translate([0,34,0]) cube_fillet([3,14,20], top=[11,0,0,0], center=true); | |
120 | translate([7,28,0]) cube_fillet([16,3,20], center=true); | |
121 | translate([7,14,0]) cube_fillet([16,3,20], center=true); | |
122 | translate([12,21,0]) intersection() { | |
123 | difference(){ | |
124 | cylinder(r=8.5,h=20, center=true); | |
125 | cylinder(r=5.5,h=21, center=true); | |
126 | } | |
127 | translate([5,0,0]) cube([10,30,20], center=true); | |
128 | } | |
129 | translate([0,10,0]) cube_fillet([3,10,20], vertical=[0,3,0,0], center=true); | |
130 | } | |
131 | translate([1.5,34,0]) rotate([0,-90,0]) screw(); | |
132 | } | |
133 | } | |
134 | ||
135 | module y_bearing(float=false){ | |
136 | if (bearing_choice == 2) { | |
137 | linear_bearing(lm8uu_length+4); | |
138 | } else { | |
139 | linear_bushing_long(20); | |
140 | } | |
141 | translate([-9,0,10]) { | |
142 | if (float) { | |
143 | spring_foot(); | |
144 | mirror([0,1,0]) spring_foot(); | |
145 | } else { | |
146 | firm_foot(); | |
147 | mirror([0,1,0]) firm_foot(); | |
148 | } | |
149 | } | |
150 | } | |
d3618a65 NZ |
151 | |
152 | ||
2fc35ca2 VAH |
153 | module linear_bearing(h=65){ |
154 | linear_holder_base(h); | |
155 | translate([-(10-5.5)/2-lm8uu_radius+2,0,1]) cube(size = [10-5.5,20,2], center = true); | |
156 | translate([-(10-5.5)/2-lm8uu_radius+2,0,h-1]) cube(size = [10-5.5,20,2], center = true); | |
157 | if ( (h-4)/2 > lm8uu_length){ | |
158 | translate([-(10-5.5)/2-lm8uu_radius+2,0,h/2]) cube(size = [10-5.5,20, (h-4)-2*lm8uu_length], center = true); | |
159 | } | |
160 | } | |
161 | ||
e5d97a09 | 162 | module linear_holder_base(length){ |
d3618a65 | 163 | |
e5d97a09 VAH |
164 | difference(){ |
165 | union(){ | |
166 | //main block | |
3ade0448 VAH |
167 | translate([-10.5/2,0,length/2]) cube(size = [10.5,lm8uu_diameter+5,length], center = true); |
168 | translate([0,0,0]) cylinder(h = length, r=lm8uu_radius+2.5, $fn=60); | |
e5d97a09 VAH |
169 | } |
170 | //main axis | |
3ade0448 | 171 | translate([0,0,-2]) cylinder(h = length+4, r=(lm8uu_diameter+0.8)/2, $fn=50); |
e5d97a09 VAH |
172 | // not needed for zip tie |
173 | //main cut | |
3ade0448 | 174 | translate([10,0,length/2]) cube(size = [20,14,length+4], center = true); |
e5d97a09 | 175 | //smooth entry cut |
3ade0448 | 176 | translate([12,0,length/2]) rotate([0,0,45]) cube(size = [20,20,length+4], center = true); |
e5d97a09 | 177 | } |
d3618a65 NZ |
178 | } |
179 | ||
d3618a65 | 180 | |
2fc35ca2 VAH |
181 | %cylinder(r=4, h=90); |
182 | y_bearing(); | |
183 | translate([0,46,0]) y_bearing(); | |
184 | translate ([-30,23,0]) mirror([1,0,0]) y_bearing(true); |