Browse Source

improve battery charger plug

master
Schoenberger, Philipp 6 years ago
parent
commit
aeb4e0cbd1
  1. 54
      3d/quad_charge_plug.scad
  2. 14
      3d/stick.scad

54
3d/quad_charge_plug.scad

@ -4,36 +4,44 @@ use <lib/cube.scad>;
module plug_surface () { module plug_surface () {
projection() projection()
translate([0,0,10]) translate([0,0,10])
intersection()
{ {
plug(); plug();
translate([-10,-10,-10])
;//cube([20,20,10]);
} }
} }
module plug() { module plug() {
rotate([-90,0,0])
rotate([270,0,0])
import("quad_plug.stl"); import("quad_plug.stl");
} }
translate([0,0,-10+10*$t])
rotate([180,0,180])
%plug() ;
difference () {
aligned_cube([8,5,5]);
union() {
translate([0,0,-0.1])
scale([1.05,1.1,1])
linear_extrude(4)
plug_surface();
}
module charger_plug() {
difference () {
// hull
aligned_cube([9,6,5]);
// plug cut
translate([0,0,1])
union() {
scale([1.2,1.3,1])
linear_extrude(5)
plug_surface();
}
// pin cuts
for (i= [1,-1]) {
translate([1*i,0,0])
aligned_cube([1,1,50]);
translate([1*i,0,-1])
aligned_cube([2,2,5]);
// pin cuts
for (i= [1,-1]) {
translate([1*i,0,-0.01])
aligned_cube([0.85,0.85,50]);
translate([1*i,0,1])
aligned_cube([2,2,5]);
}
} }
}
translate([0,1.9,-0.01])
aligned_cube([9,2,5]);
}
translate([0,0,5+10*$t])
rotate([0,0,0])
%plug() ;
charger_plug();

14
3d/stick.scad

@ -7,9 +7,9 @@ use <lib/cylinder.scad>
// draw itself // draw itself
stick(); stick();
module stick(h=10,is_ps2_shaft=0)
module stick(h=10,is_ps2_shaft=1)
{ {
$fn=32;
$fn=128;
translate([0,0,15-3]) { translate([0,0,15-3]) {
cylinder(d=5,h=h); cylinder(d=5,h=h);
translate([0,0,h]) translate([0,0,h])
@ -22,7 +22,7 @@ module stick(h=10,is_ps2_shaft=0)
} }
// dust protector // dust protector
translate([0,0,-3+2.9]) {
translate([0,0,0]) {
resize([30,30,22]) resize([30,30,22])
protector_cone(thickness=0.4*2.5); protector_cone(thickness=0.4*2.5);
} }
@ -77,13 +77,17 @@ module stick_mount(is_ps2_shaft=0) {
difference() { difference() {
color([1,0,1]) { color([1,0,1]) {
translate([0,0,5])
cylinder_flange_sphere($fn=32,r2=5, r1=3, h=5);
translate([0,0,4])
cylinder_flange_sphere($fn=32,r2=8, r1=3, h=4.5);
translate([0,0,8.5])
cylinder_flange_sphere($fn=32,r2=3, r1=8, h=4.5);
if ( is_ps2_shaft ) { if ( is_ps2_shaft ) {
cylinder(d=6.75,h=10); cylinder(d=6.75,h=10);
} else { } else {
cylinder(d=6,h=10); cylinder(d=6,h=10);
} }
//cylinder(d=15,h=0.1);
} }
translate([0,0,-eps]) translate([0,0,-eps])
if ( is_ps2_shaft ) { if ( is_ps2_shaft ) {

Loading…
Cancel
Save