Add circular pivot shape

This commit is contained in:
Quinn
2021-12-29 14:58:51 -08:00
parent 92ff7ba233
commit 5bc0f00304
+38 -4
View File
@@ -1,5 +1,7 @@
$fn = 300; $fn = 30;
collar_r = 34.7/2;
collar_h = 8.7; // short collar: 8.7, full: 18
collar_inner_corner_r = 9/2; //should roughly match shaft for best feel collar_inner_corner_r = 9/2; //should roughly match shaft for best feel
collar_inner_r = 13.2/2; //inner radius at bottom of official collar is 13.2 collar_inner_r = 13.2/2; //inner radius at bottom of official collar is 13.2
@@ -11,6 +13,13 @@ grommet_depth = 6.4; //thickness of grommet (when compressed)
pivot_depth = grommet_dist + grommet_depth / 2; pivot_depth = grommet_dist + grommet_depth / 2;
module rotate_about_pt(rotation, pt) {
translate(pt)
rotate(rotation)
translate(-pt)
children();
}
module collar (full = false, bezel = 1) { module collar (full = false, bezel = 1) {
h = 8.7; h = 8.7;
r = 34.7/2; r = 34.7/2;
@@ -46,6 +55,26 @@ module base (size = [37.16, 37.1, 2.8], r = 8) {
}; };
}; };
module ci_pivot (collar_h = 8.7, throw, shaft_r, depth, x_offset = 0, bev = 0.5) {
bottom_r = (pivot_depth + bev) * tan(throw) + shaft_r;
top_r = (collar_h - bev * 2) * tan(throw) + bottom_r;
bevel_r = bev * tan(45) + top_r;
union() {
translate([0,0,-pivot_depth]) {
cylinder(h = pivot_depth + bev, r = bottom_r);
}
translate([0,0,bev]) {
cylinder(h = collar_h - bev * 2, r1 = bottom_r, r2 = top_r);
}
translate([0,0,collar_h - bev]) {
cylinder(h = bev, r1 = top_r, r2 = bevel_r);
}
translate([0,0,collar_h]) {
cylinder(h = 100, r1 = bevel_r);
}
}
}
module sq_pivot (throw, shaft_r, depth, sharpness = 1, height = 50) { module sq_pivot (throw, shaft_r, depth, sharpness = 1, height = 50) {
corner_r = shaft_r / sharpness; corner_r = shaft_r / sharpness;
corner_offset = corner_r * (sharpness - 1); corner_offset = corner_r * (sharpness - 1);
@@ -169,7 +198,11 @@ module nroct_hollow (h, r, corner_r, slope) {
} }
}; };
translate([0,0,-pivot_depth]){
rotate([0,max_throw_circle,0]){
cylinder(h = 100, r = collar_inner_corner_r);
}
}
difference() { difference() {
difference() { difference() {
@@ -181,7 +214,8 @@ union() {
//oct_hollow(collar_h, collar_inner_r, collar_inner_corner_r, max_throw_circle); //oct_hollow(collar_h, collar_inner_r, collar_inner_corner_r, max_throw_circle);
//soct_hollow(collar_h, collar_inner_r, collar_inner_corner_r, max_throw_square); //soct_hollow(collar_h, collar_inner_r, collar_inner_corner_r, max_throw_square);
//roct_hollow(collar_h, collar_inner_r, collar_inner_corner_r, max_throw_square); //roct_hollow(collar_h, collar_inner_r, collar_inner_corner_r, max_throw_square);
nroct_hollow(collar_h, collar_inner_r, collar_inner_corner_r, max_throw_square); //nroct_hollow(collar_h, collar_inner_r, collar_inner_corner_r, max_throw_square);
ci_pivot(collar_h, max_throw_circle, collar_inner_corner_r, pivot_depth);
}; };
/* /*
@@ -189,7 +223,7 @@ translate([0, -13, -0.1]) {
font = "Open Sans:style=Bold"; font = "Open Sans:style=Bold";
mirror([1,0,0]) { mirror([1,0,0]) {
linear_extrude(0.6) linear_extrude(0.6)
//text("QJ-SQR-V2", font=font, size=3.5, halign = "center"); //text("QJ-SQR-V2", font=font, size=3.5, halign = "center");h = 8.7;
//text("QJ-OCT-V2", font=font, size=3.5, halign = "center"); //text("QJ-OCT-V2", font=font, size=3.5, halign = "center");
//text("QJ-OCS-V2", font=font, size=3.5, halign = "center"); //text("QJ-OCS-V2", font=font, size=3.5, halign = "center");
//text("QJ-OCR-V2", font=font, size=3.5, halign = "center"); //text("QJ-OCR-V2", font=font, size=3.5, halign = "center");