Files
film-scanner/stock_parts.scad

54 lines
1001 B
OpenSCAD

stock_color = "#aaa4";
bushing_od = 12;
bushing_id = 8;
bushing_len = 8;
nema17_face = 42.3;
module colorize(colorname) {
if (use_colors) {
color(colorname) union() { children(); }
} else {
children();
}
}
module bushing() {
colorize(stock_color) render() {
difference() {
cylinder(d = bushing_od, h = bushing_len);
translate([0,0,-1])
cylinder(d = bushing_id, h = bushing_len + 2);
}
}
}
// located with the shaft in +z, face on the XY plane
module nema17(depth = 23.5) {
face = 42.3;
screw_pitch = 31 / 2;
color(stock_color)
render()
difference() {
union() {
translate([-face/2, -face/2, -depth])
cube([face, face, depth]);
translate([0,0,-1]) {
cylinder(d=22, h=2+1);
cylinder(d=5, h=22+1);
}
}
translate([1.25, -5, 4])
cube([10, 10, 20]);
// screw holes
for (x = [-screw_pitch, screw_pitch],
y = [-screw_pitch, screw_pitch]) {
translate([x,y,-10])
cylinder(d=5,h=20);
}
}
}