Created
February 5, 2017 01:32
-
-
Save ednisley/efb81121536b33d61ea8ad586a5b6ff8 to your computer and use it in GitHub Desktop.
OpenSCAD source code: USB Cable clip for LED bandsaw light
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// LED Cable Clips | |
// Ed Nisley - KE4ZNU - October 2014 | |
// February 2017 - adapted for USB cables | |
Layout = "Show"; // Show Build | |
//- Extrusion parameters must match reality! | |
ThreadThick = 0.25; | |
ThreadWidth = 0.40; | |
HoleWindage = 0.2; // extra clearance | |
Protrusion = 0.1; // make holes end cleanly | |
function IntegerMultiple(Size,Unit) = Unit * ceil(Size / Unit); | |
//---------------------- | |
// Dimensions | |
Base = [15.0,15.0,6*ThreadThick]; // base over sticky square | |
CableOD = 3.8; | |
BendRadius = 5.0; | |
CornerRadius = Base[0]/5; | |
CornerSides = 4*4; | |
NumSides = 6*3; | |
//-- Oval clip with central passage | |
module OvalPass() { | |
intersection() { | |
hull() | |
for (i=[-1,1], j=[-1,1]) | |
translate([i*(Base[0]/2 - CornerRadius),j*(Base[1]/2 - CornerRadius),0]) | |
rotate(180/CornerSides) | |
cylinder(r=CornerRadius,h=Base[2] + 1.00*CableOD,$fn=CornerSides,center=false); | |
union() { | |
translate([0,0,Base[2]/2]) // oversize mount base | |
scale([2,2,1]) | |
cube(Base,center=true); | |
for (j=[-1,1]) // bending ovals | |
translate([0,j*(Base[1]/2 - 0.125*(Base[1] - CableOD)/2),(Base[2] - Protrusion)]) | |
resize([Base[0]/0.75,0,0]) | |
cylinder(d1=0.75*(Base[1]-CableOD), | |
d2=(Base[1]-CableOD)/cos(0*180/NumSides), | |
h=(CableOD + Protrusion), | |
center=false,$fn=NumSides); | |
} | |
} | |
if (Layout == "Show") | |
color("Red",0.3) | |
translate([0,0,Base[2] + CableOD/2]) | |
rotate([0,90,0]) | |
cylinder(d=CableOD,h=2*Base[0],center=true,$fn=48); | |
} | |
//---------------------- | |
// Build it | |
OvalPass(); | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
More details on my blog at http://wp.me/poZKh-6u7