adapt x-ends to 10mm rods
authorClinton Ebadi <clinton@unknownlamer.org>
Sun, 2 Oct 2016 01:34:57 +0000 (21:34 -0400)
committerClinton Ebadi <clinton@unknownlamer.org>
Sun, 2 Oct 2016 01:34:57 +0000 (21:34 -0400)
 * Use smooth_rod_d in x-end code instead of assuming 8mm
 * Allow repositioning motor/leadscrew

scad/configuration.scad
scad/x-end-motor.scad
scad/x-end.scad

index cadadae..aacb441 100644 (file)
@@ -1,4 +1,4 @@
-smooth_rod_d      = 8;
+smooth_rod_d      = 10;
 threaded_rod_d    = 10;
 tie_wrap_w        = 5;
 tie_wrap_t        = 2;
@@ -14,6 +14,12 @@ belt_thickness = 0.8;
 
 idler_bearing_inner_d = 4; // 624 bearing
 
-bearing_diameter = 15;
+bearing_diameter = 19;
 bearing_cut_extra = 0.2; // padding so it's not too tight
 
+zmotor_delta_x = 5;
+zmotor_delta_y = -3;
+
+// settings...
+rod_distance = 50;
+x_box_height = 5 + rod_distance + smooth_rod_d;
index b430f6a..e938a13 100644 (file)
@@ -6,6 +6,7 @@
 // http://prusamendel.org
 // Alterations for reprap Wilson by Martin Rice <mrice411@gmail.com>
 
+include <configuration.scad>
 use <x-end.scad>
 
 offs_adjuster_y = 5.5;
@@ -15,7 +16,7 @@ adj_block_z = 32;
 motor_offs_z = 0;
 
 module adjustomatic() {
-
+translate ([0, 0, 6.5])
    difference() {     
        translate(v=[-(15+17/2+adj_block_x/2),offs_adjuster_y,58-adj_block_z/2]) 
           cube(size=[adj_block_x,adj_block_y,adj_block_z],center=true);
@@ -40,7 +41,7 @@ module adjustomatic() {
 // mean it moves away from the motor and toward the X carriage, giving
 // more room for leads and also extra space for the auto bedleveling
 // servo housing which is on this side of the extruder):
-endstop_sw_offs_adjust = -2;
+endstop_sw_offs_adjust = -0;
 
 module pocket_endstop() // endstop holder grafted onto the side toward the rods
 {
@@ -65,6 +66,7 @@ module pocket_endstop() // endstop holder grafted onto the side toward the rods
 }
 
 module x_end_motor_sr() {
+     // TODO: use x_box_height
     difference() { 
        cube(size=[8,12,10]);
        #translate([4,11.5,9]) rotate([0,90,0]) 
@@ -119,10 +121,10 @@ module x_end_motor_holes(){
   translate(v=[0,0,0]) rotate(a=[0,-90,0]) rotate(a=[0,0,90]) cylinder(h = 70, r=17, $fn=6);
 
   // zip tie retainer for securing end stop wiring
-  #translate([-5,-59,14]) difference() { cylinder(r=4.5,h=4,$fn=16);
+  #translate([-5,-63,14]) difference() { cylinder(r=4.5,h=4,$fn=16);
                                           translate([0,0,-1]) cylinder(r=2.5,h=7,$fn=16);
                                         }
-  #translate([-5,-46,28]) rotate([90,0,0]) difference() { cylinder(r=4.5,h=4,$fn=16,center=true);
+  #translate([-5,-48,x_box_height-30.5]) rotate([90,0,0]) difference() { cylinder(r=4.5,h=4,$fn=16,center=true);
        translate([0,0,-1]) cylinder(r=2.5,h=7,$fn=16,center=true);
   }
  }
index b475840..0e5ead5 100644 (file)
@@ -5,14 +5,19 @@
 // http://www.reprap.org/wiki/Prusa_Mendel
 // http://prusamendel.org
 
+// todo: make x-end height global and make anything relying implicitly
+// on the height of the x-end use that for positioning.
+
+// bearing height, strain relief (&& maybe make dependent upon the bearing diameter)
+
 use <bearing.scad>
+include <configuration.scad>
 
-rod_distance = 45;
-pushfit_d = 8.15;
+pushfit_d = smooth_rod_d + 0.15;
 hex_nut_r = 4.75;
 
 module nut_trap_base () {
-     cube(size=[7.8,20,8],center=true);
+     cube(size=[16,21,8],center=true);
      translate ([2,0,0]) cylinder(h=8,r=12.5,$fn=50,center=true);
 }
 
@@ -21,9 +26,9 @@ module nut_trap () {
                // center post of brass nut
                    cylinder(h=12,r=5.45,$fn=50,center=true);
                    // holes for m3 screws in brass nut
-                   #translate(v=[8,0,0]) cylinder(h=12,r=1.8,$fn=20,center=true);
+                   translate(v=[8,0,0]) cylinder(h=12,r=1.8,$fn=20,center=true);
                   // screw hole would interfere with the linear bearings
-//                   #rotate([0,0,90]) translate(v=[8,0,0]) cylinder(h=12,r=1.8,$fn=20,center=true);
+                   #rotate([0,0,90]) translate(v=[8,0,0]) cylinder(h=12,r=1.8,$fn=20,center=true);
                   rotate([0,0,180]) {
                        translate(v=[8,0,0]) cylinder(h=12,r=1.8,$fn=20,center=true);
                        // add a trap for an m3 nylock nut since this part
@@ -38,12 +43,13 @@ module nut_trap () {
 
 module x_end_base(){
 // Main block
-height = 58;
-translate(v=[-15,-9,height/2]) cube(size = [17,39,height], center = true);
+height = x_box_height;
+// TODO: calculate correct translate(y) + cube(y) using size of bearing
+translate(v=[-15,-10,height/2]) cube(size = [17,45,height], center = true);
 // Bearing holder
  vertical_bearing_base();      
 //Nut trap
- translate(v=[-2-2,-17,4]) nut_trap_base ();
+ translate(v=[-4-zmotor_delta_y,-17-zmotor_delta_x,4]) nut_trap_base ();
  // Cube
 // #translate(v=[-2-2,-17,4]) cube(size = [8,16,8], center = true);
  // Hexagon
@@ -56,6 +62,7 @@ module x_end_holes(){
  translate(v=[-1,0,0]){
  // Stress relief
  translate(v=[-5.5-10+1.5,-10-1,30]) cube(size = [20,1,28], center = true);
+ // Cut out for belt (this is NOT centered because the motor isn't centered)
  difference(){
        translate(v=[-5.5-10+1.5,-10,30]) cube(size = [10,46,28], center = true);
 
@@ -69,13 +76,13 @@ module x_end_holes(){
 }
 
 
-
+ pushrod_extra_z = 2.5;
 // Bottom pushfit rod
-translate(v=[-15,-41.5,6]) rotate(a=[-90,0,0]) pushfit_rod(pushfit_d,50);
+#translate(v=[-15,-41.5,smooth_rod_d/2+pushrod_extra_z]) rotate(a=[-90,0,0]) pushfit_rod(pushfit_d,50);
 // Top pushfit rod
-translate(v=[-15,-41.5,rod_distance+6]) rotate(a=[-90,0,0]) pushfit_rod(pushfit_d,50);
+translate(v=[-15,-41.5,rod_distance+smooth_rod_d/2+pushrod_extra_z]) rotate(a=[-90,0,0]) pushfit_rod(pushfit_d,50);
 // Nut trap
-translate(v=[0,-17,3]) nut_trap ();
+translate(v=[-zmotor_delta_y,-17-zmotor_delta_x,3]) nut_trap ();
 // #translate(v=[0,-17,-0.5]) cylinder(h = 4, r1=3.4, r2=2.9, $fn=25);
 // translate(v=[0,-17,3]) rotate([0,0,30]) cylinder(h = 10, r=hex_nut_r, $fn = 6);
 }