Configure side screw separate from top screw

This commit is contained in:
Matt McWilliams 2023-05-10 19:55:17 -04:00
parent e053ac5a2a
commit a6b7ba1a82
2 changed files with 5 additions and 6 deletions

2
common

@ -1 +1 @@
Subproject commit 890aa4f1633ba5507bd23e37dc2333de8ce5ae45
Subproject commit 257ddc18bf17a2943d1cb465c68cb0949f8274b1

View File

@ -154,7 +154,7 @@ module sprocketed_roller_body (pos = [0, 0, 0], rot = [0, 0, 0], sprockets = 8,
}
}
module sprocketed_roller (pos = [0, 0, 0], rot = [0, 0, 0], sprockets = 8, bevel = false, reinforced = false, bolts = false, model = "", set_screw_top = false) {
module sprocketed_roller (pos = [0, 0, 0], rot = [0, 0, 0], sprockets = 8, bevel = false, reinforced = false, bolts = false, model = "", set_screw_side = true, set_screw_top = false) {
D = (FrameC * sprockets) / PI;
difference () {
union () {
@ -165,7 +165,8 @@ module sprocketed_roller (pos = [0, 0, 0], rot = [0, 0, 0], sprockets = 8, bevel
translate(pos) rotate(rot) translate([0, 0, 10]) gearbox_motor_shaft_void();
if (set_screw_top) {
translate(pos) rotate(rot) rotate([180, 0, 0]) m3_bolt_void([0, 0, -11]);
} else {
}
if (set_screw_side) {
translate(pos) rotate(rot) m3_nut_void(pos=[D/4, 0, 8.5], rot = [90, 0, 90], H = D/2);
}
}
@ -191,9 +192,7 @@ module sprocketed_roller_reinforced (pos = [0, 0, 0], rot = [0, 0, 0], sprockets
LIBRARY = false;
PART = "sprocketed_roller_reinforced";
if (!LIBRARY && PART == "sprocketed_roller_reinforced") {
rotate([180, 0, 0]) sprocketed_roller(sprockets = 18, bevel = false, model = "gearbox_motor", reinforced = true, bolts = true, set_screw_top = true);
rotate([180, 0, 0]) sprocketed_roller(sprockets = 18, bevel = false, model = "gearbox_motor", reinforced = true, bolts = true, set_screw_top = true, set_screw_side = true);
} else if (!LIBRARY && PART == "sprocketed_wheel") {
rotate([180, 0, 0]) color("red") sprocketed_roller_reinforced(sprockets = 18, bevel = false, model = "gearbox_motor", bolts = true);
}