1
0
mirror of https://github.com/nophead/NopSCADlib.git synced 2025-08-12 10:23:58 +02:00

Added hole for grub screw to shaft coupling.

This commit is contained in:
Martin Budden
2020-11-10 14:49:11 +00:00
parent 03beaec470
commit b583202fb7

View File

@@ -35,7 +35,20 @@ module shaft_coupling(type, colour = "silver") { //! Draw the shaft coupling
d1 = sc_diameter1(type);
d2 = sc_diameter2(type);
grub_length = 3;
module grub_screw_positions() {
grub_offset_z = 5;
for(z = [-length / 2 + grub_offset_z, length / 2 - grub_offset_z])
translate_z(z)
for(a = [0, 90])
rotate([-90, 0, a])
translate_z(diameter / 2 + 1)
children();
}
color(colour) {
render(convexity=2) difference() {
union() {
translate_z(-length / 2)
linear_extrude(length / 2)
difference() {
@@ -48,14 +61,13 @@ module shaft_coupling(type, colour = "silver") { //! Draw the shaft coupling
circle(d = d2);
}
}
grub_screw_positions()
rotate([180, 0, 0])
cylinder(r = screw_radius(M3_grub_screw), h = 5);
}
}
grub_offset_z = 5;
grub_length = 3;
for(z = [-length / 2 + grub_offset_z, length / 2 - grub_offset_z])
translate_z(z)
for(a = [0, 90])
rotate([-90, 0, a])
translate_z(diameter / 2 + 1)
grub_screw_positions()
not_on_bom() screw(M3_grub_screw, grub_length);
}