openscad nema 17 carriage bearing 3/16 mount experimental
by cariaga · via Thingiverse
| Format | STL |
| Category | Mechanical |
| License | CC BY-SA |
| Uploaded | Apr 10, 2026 |
⬇ 3 downloads
👁 21 views
Description
definitely not optimal just figured i should upload it for future reference /* [Render Mode] */ render_mode = "All"; // [All, Top Pole Only, Bottom Pole Only, Carriage Only, Races Only, Center Core Only, Cap Only] /* [Visibility Toggles] */ show_carriage_mount = true; show_pole = true; show_inner_race = true; show_outer_race = true; show_key = true; show_core = true; show_cap = true; /* [Cap / Mounting Plate Settings] */ cap_thickness = 4.0; snap_depth = 4.0; cap_clearance = 0.35; mount_hole_dia = 3.4; /* [Main Parameters] */ ball_dia = 4.7625; race_height = 9.525; track_radius = 15; pole_height = 3; pole_radius = 12; motor_plate_thick = 3; core_radius = 5; core_gap = 0.4; titan_holes = 31.0; beam_width = 10; /* [Hidden] */ $fn = 100; key_w = ball_dia + 2.5; fit_tol = 0.15; key_z_offset = 2.13; dynamic_key_h = (race_height / 2) - key_z_offset; inner_ring_r = track_radius - (ball_dia/2) + 0.8; outer_internal_r = track_radius + (ball_dia/2) - 0.8; outer_external_r = outer_internal_r + 3; // --- MAIN LOGIC --- if (render_mode == "Cap Only") { outer_mount_cap(); } else if (render_mode == "Top Pole Only") { top_pole_piece(); } else if (render_mode == "Bottom Pole Only") { bottom_pole_piece(); } else if (render_mode == "Carriage Only") { slim_diy_carriage(); } else if (render_mode == "Center Core Only") { center_core(); } else if (render_mode == "Races Only") { inner_race(); translate([outer_external_r * 2.5, 0, 0]) outer_race(); } else { // ASSEMBLY VIEW: Carriage Top, Cap Bottom if (show_carriage_mount) translate([0, 0, (pole_height + race_height/2 + motor_plate_thick/2)]) slim_diy_carriage(); if (show_cap) translate([0, 0, -race_height/2 - cap_thickness]) outer_mount_cap(); if (show_outer_race) color("white") outer_race(); if (show_inner_race) color("cyan") inner_race(); if (show_core) color("gold") center_core(); if (show_pole) color("gray") { top_pole_piece(); bottom_pole_piece(); } if (show_key) color("red") top_flush_key(); } // --- MODULES --- module outer_mount_cap() { color("LimeGreen") difference() { union() { // Main Base Plate cylinder(h = cap_thickness, d = titan_holes + beam_width); // Support-free upward transition (Chamfer) // This creates a 45-degree slope so the sleeve isn't printing in mid-air translate([0, 0, cap_thickness]) cylinder(h = 2, r1 = titan_holes/2 + beam_width/2, r2 = outer_external_r + 2); // Upward Glue Sleeve translate([0, 0, cap_thickness + 2]) difference() { cylinder(h = snap_depth, r = outer_external_r + 2); translate([0, 0, -0.1]) cylinder(h = snap_depth + 0.2, r = outer_external_r + cap_clearance); } } // Mounting Holes for (x = [-1, 1], y = [-1, 1]) { translate([x * titan_holes/2, y * titan_holes/2, -1]) cylinder(d = mount_hole_dia, h = cap_thickness + 10); } // Center clearance hole cylinder(h = 100, r = outer_internal_r - 0.5, center = true); } } module center_core() { cylinder(h = pole_height + race_height, r = core_radius, center = true); } module top_pole_piece() { difference() { union() { cylinder(h = pole_height/2 + race_height/2, r = pole_radius); cylinder(h = race_height/2, r = inner_ring_r - 0.5); } cylinder(h = 100, r = core_radius + core_gap, center=true); } } module bottom_pole_piece() { mirror([0,0,1]) top_pole_piece(); } module inner_race() { difference() { cylinder(h = race_height, r = inner_ring_r, center = true); cylinder(h = race_height + 2, r = max(4, core_radius + core_gap), center = true); rotate_extrude() translate([track_radius, 0, 0]) circle(d = ball_dia); } } module outer_race() { difference() { cylinder(h = race_height, r = outer_external_r, center = true); cylinder(h = race_height + 2, r = outer_internal_r, center = true); rotate_extrude() translate([track_radius, 0, 0]) circle(d = ball_dia); translate([track_radius + (ball_dia/2), 0, key_z_offset + dynamic_key_h/2]) cube([outer_external_r, key_w + (fit_tol*2), dynamic_key_h + 0.1], center = true); } } module top_flush_key() { difference() { intersection() { translate([0, 0, key_z_offset + (dynamic_key_h)/2]) cylinder(h = dynamic_key_h, r = outer_external_r, center = true); translate([track_radius + (ball_dia/2), 0, key_z_offset + dynamic_key_h/2]) cube([outer_external_r, key_w, dynamic_key_h], center = true); } cylinder(h = race_height + 2, r = outer_internal_r, center = true); rotate_extrude() translate([track_radius, 0, 0]) circle(d = ball_dia); } } module slim_diy_carriage() { difference() { union() { hull() { translate([titan_holes/2, titan_holes/2, 0]) cylinder(d=beam_width, h=motor_plate_thick, center=true); translate([-titan_holes/2, -titan_holes/2, 0]) cylinder(d=beam_width, h=motor_plate_thick, center=true); } hull() { translate([-titan_holes/2, titan_holes/2, 0]) cylinder(d=beam_width, h=motor_plate_thick, center=true); translate([titan_holes/2, -titan_holes/2, 0]) cylinder(d=beam_width, h=motor_plate_thick, center=true); } cylinder(r = pole_radius + 1.2, h = motor_plate_thick, center = true); } for (x = [-1, 1], y = [-1, 1]) translate([x * titan_holes/2, y * titan_holes/2, 0]) cylinder(d = 3.4, h = 10, center = true); cylinder(r = max(4.5, core_radius + core_gap), h = 10, center = true); } }
Originally published on Thingiverse