Skip to content

Instantly share code, notes, and snippets.

@brandonagr
Last active August 29, 2015 14:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save brandonagr/23c461e4877607e5c3c3 to your computer and use it in GitHub Desktop.
Save brandonagr/23c461e4877607e5c3c3 to your computer and use it in GitHub Desktop.
Improve inner radius and gap
// Should match marker exactly or be slightly less
innerRadius = 17 / 2;
outerRadius = innerRadius + 2.5;
spacing = 2 * outerRadius + 5; // some gap between holders for flex when inserting marker
screwRadius = 1.75;
// Height of plate for screws, should be less than or equal to height
sizeOfScrewPlate = 12;
// Height of the part the marker snaps onto
height = 12;
// Number of marker holders
holeCount = 4;
// sides to circles
$fn = 128;
difference(){
union() {
// outer holders
for (i = [0:(holeCount-1)]){
translate([spacing * i,0,0])
cylinder(h = height, r = outerRadius);
}
// back plane connecting them
translate([0,-outerRadius,0])
cube([spacing * (holeCount-1),outerRadius - innerRadius,height]);
// screw plate
translate([0,-outerRadius,height])
// want rounded corners
union(){
translate([outerRadius,0,0])
cube([spacing * (holeCount-1) - sizeOfScrewPlate * 2,outerRadius - innerRadius,sizeOfScrewPlate]);
rotate([90,0,0])
translate([sizeOfScrewPlate, 0, innerRadius - outerRadius])
cylinder(h = outerRadius - innerRadius, r = sizeOfScrewPlate);
rotate([90,0,0])
translate([spacing * (holeCount - 1) - sizeOfScrewPlate, 0, innerRadius - outerRadius])
cylinder(h = outerRadius - innerRadius, r = sizeOfScrewPlate);
}
}
// cut out sides of holder to make it a C
for (i = [0:holeCount-1]){
translate([spacing * i,0,-10])
cylinder(h = 40, r = innerRadius);
translate([spacing*i,-6,-1])
rotate([0,0,45])
cube([outerRadius*2, outerRadius*2, height+2]);
}
// cut out holes for screws
for (i = [0:holeCount-1]){
translate([i * spacing + spacing * 0.5, 0, height + (sizeOfScrewPlate / 2)])
rotate([90,0,0])
cylinder(h = 40, r = screwRadius);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment