Quellcode durchsuchen

added y-carriage

Thomas Buck vor 6 Jahren
Ursprung
Commit
968773092d
2 geänderte Dateien mit 134 neuen und 22 gelöschten Zeilen
  1. 120
    1
      lib/linear_bearing.scad
  2. 14
    21
      xyRepRap.scad

+ 120
- 1
lib/linear_bearing.scad Datei anzeigen

@@ -7,6 +7,28 @@ lm8uu_outer = 15;
7 7
 lm8uu_inner = 8;
8 8
 lm8uu_height = 24;
9 9
 
10
+x_rail_dist = 50;
11
+
12
+lm8uu_dia_add = 0.5;
13
+lm8uu_len_add = 1.0;
14
+rail_dia_add = 3.0;
15
+y_carriage_wall = 10; // z-axis
16
+y_carriage_len_add = 15; // y-axis
17
+y_carriage_width = 25; // x-axis
18
+y_carriage_block_width = 10; // x-axis
19
+y_carriage_block_height = 10; // z-axis
20
+y_carriage_rail_support = 2; // dist between rail and edge
21
+
22
+y_carriage_length = x_rail_dist + (2 * y_carriage_len_add);
23
+
24
+rail_mount_dia_add = 0.4;
25
+x_rail_mount_width = 10;
26
+x_rail_cutout_z = 0.5; // in x-axis
27
+x_rail_cutout_x = 0.5; // in z-axis
28
+x_rail_cutout_y = x_rail_dist - (2 * y_carriage_len_add);
29
+x_rail_hole_off = 5;
30
+x_rail_block_len = (y_carriage_length - x_rail_cutout_y) / 2;
31
+
10 32
 module lm8uu() {
11 33
     $fn = 15;
12 34
     difference() {
@@ -16,4 +38,101 @@ module lm8uu() {
16 38
     }
17 39
 }
18 40
 
19
-//lm8uu();
41
+// TODO add cable tie lm8uu mounting
42
+
43
+module y_carriage() {
44
+    $fn = 20;
45
+    
46
+    // attaching to x-rails
47
+    color("green")
48
+    translate([y_carriage_width, 0, -y_carriage_block_height])
49
+    difference() {
50
+        cube([x_rail_mount_width, y_carriage_length, y_carriage_block_height + y_carriage_wall]);
51
+        
52
+        translate([0, -1, y_carriage_block_height])
53
+            cube([x_rail_cutout_z, y_carriage_length + 2, y_carriage_wall + 1]);
54
+        
55
+        translate([0, -1, y_carriage_block_height - (x_rail_cutout_x / 2)])
56
+            cube([y_carriage_block_width + 1, y_carriage_length + 2, x_rail_cutout_x]);
57
+        
58
+        translate([0, (y_carriage_length - x_rail_cutout_y) / 2, y_carriage_block_height])
59
+            cube([y_carriage_block_width + 1, x_rail_cutout_y, y_carriage_wall + 1]);
60
+        
61
+        for (i = [y_carriage_len_add : x_rail_dist : x_rail_dist + y_carriage_len_add]) {
62
+            translate([0, i, y_carriage_block_height])
63
+                rotate([0, 90, 0])
64
+                cylinder(d = lm8uu_inner + rail_mount_dia_add, h = y_carriage_block_width + 1);
65
+        }
66
+        
67
+        for (i = [0 : x_rail_block_len + x_rail_cutout_y : x_rail_block_len + x_rail_cutout_y]) {
68
+            translate([y_carriage_block_width / 2, x_rail_hole_off + i, -1]) {
69
+                cylinder(d = 3.2, h = y_carriage_wall + 2 + y_carriage_block_height);
70
+                cylinder(d = 6.1, h = 3.8, $fn = 6);
71
+                translate([0, 0, y_carriage_wall + y_carriage_block_height - 2.5])
72
+                    cylinder(d = 6.1, h = 3.8);
73
+            }
74
+            
75
+            translate([y_carriage_block_width / 2, x_rail_block_len - x_rail_hole_off + i, -1]) {
76
+                cylinder(d = 3.2, h = y_carriage_wall + 2 + y_carriage_block_height);
77
+                cylinder(d = 6.1, h = 3.8, $fn = 6);
78
+                translate([0, 0, y_carriage_wall + y_carriage_block_height - 2.5])
79
+                    cylinder(d = 6.1, h = 3.8);
80
+            }
81
+        }
82
+    }
83
+    
84
+    // attaching to y-rail
85
+    color("green")
86
+    difference() {
87
+        union() {
88
+            cube([y_carriage_width, y_carriage_length, y_carriage_wall]);
89
+            
90
+            translate([y_carriage_width - y_carriage_block_width, 0, -y_carriage_block_height])
91
+                cube([y_carriage_block_width, y_carriage_length, y_carriage_block_height]);
92
+        }
93
+        
94
+        translate([(lm8uu_outer + lm8uu_dia_add) / 2 + y_carriage_rail_support, 0, 0])
95
+        rotate([-90, 0, 0]) {
96
+            translate([0, 0, -1])
97
+                cylinder(d = lm8uu_inner + rail_dia_add, h = y_carriage_length + 2);
98
+            
99
+            translate([0, 0, y_carriage_rail_support - lm8uu_len_add / 2])
100
+                cylinder(d = lm8uu_outer + lm8uu_dia_add, h = lm8uu_height + lm8uu_len_add);
101
+        
102
+            translate([0, 0, y_carriage_length - lm8uu_height - y_carriage_rail_support - lm8uu_len_add / 2])
103
+                cylinder(d = lm8uu_outer + lm8uu_dia_add, h = lm8uu_height + lm8uu_len_add);
104
+        }
105
+    }
106
+    
107
+    color("yellow")
108
+    translate([(lm8uu_outer + lm8uu_dia_add) / 2 + y_carriage_rail_support, 0, 0])
109
+    rotate([-90, 0, 0]) {
110
+        // y-bearings
111
+        %translate([0, 0, y_carriage_rail_support])
112
+            lm8uu();
113
+        %translate([0, 0, y_carriage_length - lm8uu_height - y_carriage_rail_support])
114
+            lm8uu();
115
+    }
116
+}
117
+
118
+/*
119
+
120
+translate([(lm8uu_outer + lm8uu_dia_add) / 2 + y_carriage_rail_support, 0, 0])
121
+rotate([-90, 0, 0]) {
122
+    // y-bearings
123
+    %translate([0, 0, y_carriage_rail_support])
124
+        lm8uu();
125
+    %translate([0, 0, y_carriage_length - lm8uu_height - y_carriage_rail_support])
126
+        lm8uu();
127
+}
128
+
129
+// x-rails
130
+for (i = [y_carriage_len_add : x_rail_dist : x_rail_dist + y_carriage_len_add]) {
131
+    %translate([y_carriage_width + 1, i, 0])
132
+        rotate([0, 90, 0])
133
+        cylinder(d = lm8uu_inner, h = 50);
134
+}
135
+
136
+y_carriage();
137
+
138
+*/

+ 14
- 21
xyRepRap.scad Datei anzeigen

@@ -220,6 +220,7 @@ module frame() {
220 220
 // #######################################################
221 221
 
222 222
 rail_mount_dist = 12;
223
+y_carriage_pos = 175;
223 224
 
224 225
 module rail(length) {
225 226
     cylinder(d = rail_dia, h = length);
@@ -233,13 +234,9 @@ module y_rails() {
233 234
         rotate([-90, 0, 0])
234 235
         rail(outer_length - slot - nema17_size - (2 * rail_mount_dist));
235 236
     
236
-    // some lm8uu bearings on red side
237
-    color("yellow")
238
-    for (i = [0 : 30 : 60]) {
239
-        translate([rail_dia / 2 + rail_y_off_1, 60 + i, -30])
240
-            rotate([-90, 0, 0])
241
-            lm8uu();
242
-    }
237
+    // y carriage on blue side
238
+    translate([rail_y_off_1 - (lm8uu_outer + lm8uu_dia_add) / 2 + y_carriage_rail_support, y_carriage_pos, -slot])
239
+        y_carriage();
243 240
     
244 241
     // rail mounts for blue side
245 242
     color("green")
@@ -255,13 +252,10 @@ module y_rails() {
255 252
         rotate([-90, 0, 0])
256 253
         rail(outer_length - slot - nema17_size - (2 * rail_mount_dist));
257 254
     
258
-    // some lm8uu bearings on red side
259
-    color("yellow")
260
-    for (i = [0 : 30 : 60]) {
261
-        translate([outer_width - (2 * slot) - rail_dia / 2 - rail_y_off_1, 60 + i, -30])
262
-            rotate([-90, 0, 0])
263
-            lm8uu();
264
-    }
255
+    // y carriage on red side
256
+    translate([outer_width - slot - y_carriage_width - y_carriage_block_width, y_carriage_pos + y_carriage_length, -slot])
257
+        rotate([0, 0, 180])
258
+        y_carriage();
265 259
     
266 260
     // rail mounts for red side
267 261
     color("green")
@@ -274,13 +268,12 @@ module y_rails() {
274 268
         rail_mount(slot);
275 269
 }
276 270
 
277
-x_rail_dist = 50;
278
-
279 271
 module x_rails() {
280
-    translate([30, 200, 15])
272
+    // TODO length calculate properly!
273
+    translate([30, y_carriage_pos, 15])
281 274
         rotate([0, 90, 0])
282 275
         rail(outer_length - (4 * slot));
283
-    translate([30, 200 + x_rail_dist, 15])
276
+    translate([30, y_carriage_pos + x_rail_dist, 15])
284 277
         rotate([0, 90, 0])
285 278
         rail(outer_length - (4 * slot));
286 279
 }
@@ -289,9 +282,9 @@ module motion_xy() {
289 282
     translate([slot, slot, outer_height])
290 283
         y_rails();
291 284
     
292
-    //color("cyan")
293
-    //translate([slot, slot, outer_height - (1.5 * slot)])
294
-    //    x_rails();
285
+    color("cyan")
286
+    translate([slot, slot + y_carriage_len_add, outer_height - (1.5 * slot)])
287
+        x_rails();
295 288
 
296 289
     // left ("blue") motor
297 290
     translate([slot, outer_length - slot - nema17_size - nema17_mount_wall, outer_height + nema17_mount_wall])

Laden…
Abbrechen
Speichern