//pulled from http://github.com/nathan7/nateplate/raw/master/nateplate.escad //the nateplate v2 - the awesome Y axis for Prusa3 //Licensed GPLv2+ and CC-BY-SA - pick your poison //(C) 2012 Nathan Zadoks //parameters $quality = 200; r = 7.5; cut_width = 0.005 * 25.4; offsetx_hole = 209; offsety_hole = 209; offsetx_belt = 22; hole_diam = 2.6; hole_sides = 6; hole_diam_threadless = 3; ziptie_width = 6; ziptie_thickness = 3; ziptie_offset = 1; xsize = offsetx_hole + r * 2; ysize = offsety_hole + r * 2; bearing_od = 15; bearing_len = 24; bearing_cutheight = 2.5; offsetx_bearing = 110; offsety_bearing = ysize / 3; cutout_clip_depth = 30; cutout_clip_width = 30; cutout_clip_offset = ysize - 2 * cutout_clip_width * 1.5; cutout_base = true; //for i2 compatibility /* here be dragons */ //calculations bearing_cutwidth = sin(acos(1 - (2 * bearing_cutheight) / bearing_od)) * bearing_od; //singular parts module ziptie() { square([ziptie_thickness - cut_width, ziptie_width - cut_width], center = true); } module bearing() { union() { square([bearing_cutwidth - cut_width, bearing_len - cut_width], r = 0, center = true); for (y = [-1, 1]) translate([y * (bearing_cutwidth + ziptie_offset * 2 + ziptie_thickness), 0] / 2) ziptie(); } } module hole() { circle(r = hole_diam / 2 / cos(pi / hole_sides) - cut_width / 2, $fn = hole_sides); } module belt_holes_i2() { for (x = [-1, 1]) for (y = [-1, 1]) translate([x * 18, y * 20] / 2) hole(); } module belt_holes_i3() { translate([0, -35 / 2]) union() { translate([-12, 0]) hole(); translate([12, 0]) hole(); translate([0, 35]) hole(); } } module base_cutout() { square([offsetx_bearing + bearing_od, ysize - offsety_bearing - bearing_len - 2 * r], r = r, center = true); } module clip() { square([cutout_clip_depth * 2, cutout_clip_width], r = r, center = true); } module spacer() { difference() { circle(r = r); circle(r = hole_diam_threadless / 2 / cos(pi / hole_sides) - cut_width / 2, $fn = hole_sides); } } //part arrangements module bearings() { for (x = [-1, 1]) for (y = [-1, 1]) translate([offsetx_bearing * x, offsety_bearing * y] / 2) bearing(); } module belt_holes() { union() { translate([offsetx_belt, 0]) union() { belt_holes_i2(); belt_holes_i3(); } belt_holes_i2(); } } module bed_holes() { for (x = [-1, 1]) for (y = [-1, 1]) translate([offsetx_hole * x, offsety_hole * y] / 2) hole(); } module base_cutouts() { for (y = [-1, 1]) translate([0, ysize * y] / 2) base_cutout(); } module clips() { for (x = [-1, 1]) for (y = [-1, 1]) translate([xsize * x, cutout_clip_offset * y] / 2) clip(); } module spacers() { for (x = [-1, 1]) for (y = [-1, 1]) translate([(xsize - cutout_clip_depth) * x, cutout_clip_offset * y] / 2) spacer(); } //actual stuff union() { //the nateplate itself difference() { difference(r = r) { square([xsize, ysize], r = r, center = true); clips(); if (cutout_base) base_cutouts(); } bearings(); belt_holes(); bed_holes(); } //free fancy spacers spacers(); }