Created
October 23, 2016 19:28
-
-
Save ednisley/1d6fedfd2f729755e681d5dcd6f24b54 to your computer and use it in GitHub Desktop.
OpenSCAD source code: Base for ceramic Mogul lamp socket
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
//---------------------- | |
// Base for Mogul ceramic socket | |
module MogulBase() { | |
Insert = [5.0,7.0,10.5]; // 10-32 brass insert, used for socket and chassis mounting | |
PCB = | |
[45,18,7.5] // Arduino Nano | |
; | |
BaseOD = 57.0; | |
BaseOAH = Insert[LENGTH] + 3*ThreadThick + PCB[2]; | |
ScrewOC = 1.5 * inch; | |
difference() { | |
cylinder(d=BaseOD,h=BaseOAH,$fn=16*4); // overall shape | |
translate([0,0,-Protrusion]) // central mounting insert | |
PolyCyl(Insert[OD],Insert[LENGTH] + Protrusion,6); | |
for (a=[90,-90]) // socket studs | |
rotate(a) | |
translate([ScrewOC/2,0,-Protrusion]) { | |
PolyCyl(Insert[OD],Insert[LENGTH] + Protrusion,6); | |
PolyCyl(Insert[ID],2*BaseOAH,6); | |
} | |
translate([(BaseOD - PCB[0])/2,0,BaseOAH - PCB[2]/2 + Protrusion/2]) | |
cube(PCB + [0,0,Protrusion],center=true); // Arduino PCB | |
rotate(45) | |
translate([0,0,BaseOAH - Ferrule[ID]/2 + Protrusion/2]) | |
rotate([0,90,0]) rotate(180/6) | |
PolyCyl(Ferrule[ID],BaseOD,6); | |
} | |
} |
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-6fW