diff --git a/enclosure/COVER.scad b/enclosure/COVER.scad new file mode 100644 index 0000000..59248b5 --- /dev/null +++ b/enclosure/COVER.scad @@ -0,0 +1,161 @@ + +$fs = 0.1; + + + +use + + +cover_length = 80; +cover_width = 35; +cover_thickness = 2.1; +Resolution = 50; +module round_hull(r,w) +{ + +$fn=Resolution; +hull() +{ + circle(r); + translate([w,0,0,])circle(r); + } + + } +module drafted_pin(radius, hieght) +{ + + +c1 = radius; +h = hieght; +c2 =(h < c1)? c1 - h : 0; + +cylinder(h,c1,c2); + + + } + + module s_cover(width,length,thickness){ + + + + + union(){ difference() + { + linear_extrude(thickness)round_hull(width/2,length-width); + translate([width/4+(length-width),0,0])cube([width/2,width,10],true); + translate([-width/4,0,0])cube([width/2,width,10],true); + + + } + + translate([(length-width),0,0])cylinder(h=thickness,r1 = width/2, r2 =width/2-(sqrt(2)*thickness)); + + } + } +module cover(width,length,thickness) + { +//width = 30; +//length = 60; +//thickness = 2; + +module joint() + { + + + rotate([90,0,0])translate([3,4,0])drafted_pin(3,2); + + } + + +Resolution = 50; + + + union(){union(){ +translate([0,width/2,0]) + s_cover(width,length,thickness); + + + rotate([90,0,0])translate([3,4,-width])cylinder(width,4,4); + + joint(); + + }mirror([0,1,0])translate([0,-width,0]) joint();} + + + } + + + + + + + + +module cover_unit(){ +difference(){union(){ +union() +{ +translate([-15,-10,0]) cube([cover_length+3,cover_width+20,2.1]); +translate([-2,-10,2])cube([10,10,8]); +} +translate([0,cover_width,0])mirror([0,1,0]){ + translate([-2,-10,2])cube([10,10,8]); + } +} + +#translate([-1.7,0,0])cube([3,cover_width,3]); +/* +translate([0,30,0])mirror([0,1,0])rotate([90,0,0])translate([3,4,0])drafted_pin(3+0.15,2+0.15); +rotate([90,0,0])translate([3,4,0])drafted_pin(3+0.15,2+0.15); + +*/ + +//scale([1,1,1.04])translate([0,0,-0.05]) +color("green"){cover(cover_width,cover_length,cover_thickness);} + +//color("red")translate([46.6,18,7])rotate([90,90,0])scale([1.05,1.05,1.05])lock_m(); + + translate([cover_length-cover_width/2-2.8,cover_width/2,2]) cube([2,6.5,3],true); + +//translate([3,15,-1])s_cover(cover_width,cover_length,cover_thickness+2); +} + + +difference(){ +translate([0,0.3,0])color("blue"){cover(cover_width-0.6,cover_length-1,cover_thickness);} +#translate([cover_length-cover_width/2-9.6,cover_width/2-2.6,-1])cube([11,5+0.6,8]); +} + + + +//width = 30-0.6; +//length = 50-0.6; +//thickness=2; + + +difference(){ +color("red")translate([cover_length-cover_width/2-6.6,cover_width/2+2.7,7])rotate([90,90,0])lock_m(); + /*difference() + { + + color("green"){cover(cover_width,cover_length,cover_thickness);} + + color("green")scale(0.99){cover(cover_width,cover_length,cover_thickness);} + }*/ +translate([-0.5,0,-0.2])translate([cover_length-cover_width/2,cover_width/2,cover_thickness])rotate([0,45,0])translate([1,0,0])cube([sqrt(2)*cover_thickness,cover_width+2,sqrt(2)*cover_thickness],true); + +} + +tollerance = 0.1; +difference(){ +translate([cover_length-cover_width/2-1.8,cover_width/2-3.5,2])cube([3,7,3]); + + translate([cover_length-cover_width/2-6.6,cover_width/2+3,6.2]) translate([4.5,-2.5,-11.7]) + scale([1+tollerance,2,1+tollerance])translate([-4.5,2.5,11.7])rotate([90,90,0])lock_m(); + + + } + +} + +cover_unit(); \ No newline at end of file diff --git a/enclosure/COVER.stl b/enclosure/COVER.stl new file mode 100644 index 0000000..0331405 Binary files /dev/null and b/enclosure/COVER.stl differ diff --git a/enclosure/COVER_v2.stl b/enclosure/COVER_v2.stl new file mode 100644 index 0000000..f1e8c84 Binary files /dev/null and b/enclosure/COVER_v2.stl differ diff --git a/enclosure/COVER_v3.stl b/enclosure/COVER_v3.stl new file mode 100644 index 0000000..46593a3 Binary files /dev/null and b/enclosure/COVER_v3.stl differ diff --git a/enclosure/KRAKE_PWArev2.STL b/enclosure/KRAKE_PWArev2.STL new file mode 100644 index 0000000..741b2a3 Binary files /dev/null and b/enclosure/KRAKE_PWArev2.STL differ diff --git a/enclosure/U_Box_V105_Krake_RevB.scad b/enclosure/U_Box_V105_Krake_RevB.scad index 3b263d8..6f4c424 100644 --- a/enclosure/U_Box_V105_Krake_RevB.scad +++ b/enclosure/U_Box_V105_Krake_RevB.scad @@ -16,7 +16,7 @@ // https://www.thingiverse.com/thing:5849866 include - +use KrakeEnclosureVersion = 0.1; // change this with each rev @@ -30,7 +30,9 @@ GPAD = 0; // [0:Off, 1:On] //////////////////////////////////////////////////////////////////// GPAD_TShell = 0; -GPAD_TShellWithVESA = 1; +GPAD_TShell2 = 0; +GPAD_TShell3 = 1; +GPAD_TShellWithVESA = 0; GPAD_BShell = 0; GPAD_FPanL = 0; GPAD_BPanL = 0; @@ -56,7 +58,7 @@ Width = 138 + 13; Height = 40; Thick = 2; // Wall thickness Filet = 2; // Corner rounding -Resolution = 50; // Filet smoothness +Resolution = 10; // Filet smoothness m = 0.9; // Panel/rail tolerance PCBFeet = 1; // Enable PCB feet Vent = 1; // Enable vents @@ -932,7 +934,9 @@ if(PCB_SIMPLE==1){ } } // Fin PCB } + if(PWA_GPAD==1){ + //////////////////// - PCB only visible in the preview mode - ///////////////////// translate([3*Thick+2,Thick+5,Thick+FootHeight+PCBThick/2+.1]){ @@ -947,11 +951,12 @@ if(PWA_GPAD==1){ if(PWA_KRAKE==1){ //////////////////// - PCB only visible in the preview mode - ///////////////////// - translate([3*Thick+2,Thick+5,Thick+FootHeight+PCBThick/2-.1]){ - rotate([0,0,90])translate([0,0,PCBThick-0.2]); + translate([(3*Thick)+2,Thick+5,Thick+FootHeight+PCBThick/2-.1]) + { + echo(Thick+FootHeight+PCBThick/2-.1) rotate([0,0,90])translate([-55.88,17.78,0]) color(Couleur3) - import("KRAKE_PWArev1.stl", convexity=3); + import("KRAKE_PWArev2.stl", convexity=3); //%cube ([PCBLength,PCBWidth,PCBThick]); //translate([PCBLength/2,PCBWidth/2,0]){ //color("Olive") @@ -1031,3 +1036,187 @@ if (T_BShellScrew==1){ }//fin de sides holes +module RoundBox2(Length, Width, Height,f=1){// Cube bords arrondis + $fn=Resolution; + + + translate([f,f,0]) minkowski() +{ + cube([Length-(2*f),Width-(2*f),Height-1]); + cylinder(r=f,h=1,false); +} + +}// End of RoundBox Module + + +//RoundBox2(10,10,20,0.25); + +module round_hull(r,w) +{ + +$fn=Resolution; +hull() +{ + circle(r); + translate([w,0,0,])circle(r); + } + + } + + + + if(GPAD_TShell3==1){ + union(){ + difference(){ + translate([0,Width,Height+0.2]){ + color( Couleur1,1){ + rotate([0,180,180]){ + + Coque(); + } + } + } + translate([34,32,40])rotate([180,0,90])translate([-15,-10,-1]) cube([80+3,35+20,5]); + } + +translate([34,32,40+0.2])rotate([180,0,90])cover_unit(); +} + + } + +ACB_x = 38.77-5; +ACB_y = 42.44; +ACB_z = Height; +AC_button_x = 38.77; +AC_button_y = 44.44; + + +if(GPAD_TShell2==1){ + +union(){ +union(){difference(){difference(){union(){ +if(GPAD_TShell2==1){ + difference(){ // Coque haut - Top Shell + translate([0,Width,Height+0.2]){ + color( Couleur1,1){ + rotate([0,180,180]){ + + Coque(); + } + } + } + + + + + } +{ + //linear_extrude(4)square([30,65]); +} +} +//translate([27.808,22.77,19.9+17.9]) +//linear_extrude(4)square([30,65]); +translate([ACB_x,ACB_y,ACB_z-10])rotate([0,0,90])linear_extrude(10)round_hull(20,34); +} + + translate([ACB_x,ACB_y,ACB_z-5])rotate([0,0,90])translate([0,0 ,0.5])linear_extrude(5)round_hull(16,34); + +} + + +AC_buttons(); +} +AC_buttons_pins(); +} + +} +ACB_tips(); + +} +module AC_buttons_pins() +{ + translate([AC_button_x,AC_button_y,-0.5+ACB_z-10])rotate([0,180,0])AC_button_Pin(); + translate([AC_button_x,AC_button_y+29.67,-0.5+ACB_z-10])rotate([0,180,0])AC_button_Pin(); + } + + +module AC_button_Pin() +{ + + union(){difference(){difference(){ + cylinder(1,2,2,true); + + rotate_extrude(convexity = 10)translate([2, 0, 0]) + circle(r = 0.5); + + +} +translate([0,0,2])cube(4,true);} +cylinder(5.175,1.5,1.5,false); +} + + +} + + +module AC_buttons() +{ + + + +translate([AC_button_x+5,AC_button_y-4,25])rotate([0,0,90])ACB(); +translate([AC_button_x+5,AC_button_y-4+29.67,25])rotate([0,0,90])ACB(); + + + } + + +module ACB(){ +linear_extrude(20)union(){ +mirror([1,0,0])translate([-8,0,0])ACB_s(4); +ACB_s(4); +} +module ACB_s(width = 5) +{ + + length = 24; + + union(){union() + +{ +square([width,1],false); + +square([1,length]); +translate([0,length,0])rotate([0,0,-90])difference(){difference(){ + + circle(r = 1); + translate([0.5,0.5,0])square([1,2],true); + + }translate([0,-1,0])square(2,true); +} + + } +translate([1,length-1,0])square([0,1]); +} + +} + +} + + + + + +module ACB_tips(){ +translate([AC_button_x,AC_button_y,35.5])ACB_tip(); +translate([AC_button_x,AC_button_y+29.67,35.5]) ACB_tip(); + } +module ACB_tip(width = 5) +{ + difference(){ + sphere(d= width); + translate([0,0,-width/2])cube(width,true); + }} + +//rotate([0,0,90])translate([27,-22,Height-10])linear_extrude(10)round_hull(10,20); +//rotate([0,0,90])translate([27,-22,Height-5])translate([0,0 ,0.5])linear_extrude(5)round_hull(8,20); \ No newline at end of file diff --git a/enclosure/U_Box_V105_Krake_RevB2.3mf b/enclosure/U_Box_V105_Krake_RevB2.3mf new file mode 100644 index 0000000..9c16c2b Binary files /dev/null and b/enclosure/U_Box_V105_Krake_RevB2.3mf differ diff --git a/enclosure/U_Box_V105_Krake_RevB2.stl b/enclosure/U_Box_V105_Krake_RevB2.stl new file mode 100644 index 0000000..bbfe945 Binary files /dev/null and b/enclosure/U_Box_V105_Krake_RevB2.stl differ diff --git a/enclosure/button_cap.scad b/enclosure/button_cap.scad new file mode 100644 index 0000000..8dde63a --- /dev/null +++ b/enclosure/button_cap.scad @@ -0,0 +1,26 @@ + +//$fs = 1; + +//$fa = 0.1; +module button_cap(){ +$fn = 200; +union(){ +translate([0,0,-20-5])cylinder(20,4.5,4.5); +translate([0,0,-5])difference(){ + +cylinder(5+2,1.45,1.45); + +translate([0,0,-1])cylinder(12,0.7,0.7); + +} + +mirror([0,0,0])translate([-1.5,1.8,-5])cube([3,2,2.5+5]); +mirror([0,1,0])translate([-1.5,1.8,-5])cube([3,2,2.5+5]); +mirror([1,1,0])translate([-1.5,1.8,-5])cube([3,2,2.5+5]); +mirror([1,1,0])mirror([0,1,0])translate([-1.5,1.8,-5])cube([3,2,2.5+5]); + +} + +} + +button_cap(); \ No newline at end of file diff --git a/enclosure/button_cap.stl b/enclosure/button_cap.stl new file mode 100644 index 0000000..b2e8b9d Binary files /dev/null and b/enclosure/button_cap.stl differ diff --git a/enclosure/latch.scad b/enclosure/latch.scad new file mode 100644 index 0000000..47c2fab --- /dev/null +++ b/enclosure/latch.scad @@ -0,0 +1,101 @@ + +$fn = 50; +rotate_d = 10; +tip_lenght = 6; +thikness = 5; +width = 7; +height = 7; + +module locker() +{ + + r1 = 7; + + cylinder(8,5,5); + cylinder(3,1,r1); + translate([0,0,5])mirror([0,0,1])cylinder(2,1,r1); + translate([0,0,2])cylinder(h= 1, r = r1); + translate([0,0,8.5])cube([2,9,2],true) + + ;} + + + + + + + + + + module the_tip(){ + { difference(){ + translate([height-1,width/2+0.5,0.5]) + + rotate([90,0,90]) linear_extrude(1)minkowski(){ + square([tip_lenght-1,thikness-1],false); + + + + //translate([height-1,(width/2)+tip_lenght,thikness/2])rotate([90,0,90]) + circle(r = 0.5); + } + + + translate([height-1-0.1,width/2-0.2,-0.1])rotate([90,0,90])linear_extrude(2)square([0.5+0.2,thikness+0.2]); + } + }} + + + + module latch(h = 10, width = width, thikness = thikness){ + union(){ + + translate([0,-width/2,0])cube([h,width,thikness]); + cylinder(r =width/2,h = thikness); + } + } + + module lock_m(){ + + union(){ + difference() + {latch(height, width); + translate([0,0,-0.1])latch(height*2,width-1,width+5); + rotate([0,0,rotate_d])translate([0,-1,-1])cube([20,10,10]); + translate([0,-1,-1]) cube([20,10,10]); + } + + + rotate([0,0,rotate_d])translate([3,1,0]){snap();} + + + translate([0,-4,0])the_tip(); + + rotate([0,0,rotate_d])translate([0,(width-1)/2,0])cube([height+0.5,0.5,thikness]); + } + } + + // lock_m(); + + translate([4.5,-2.5,-11.7]) + scale(1)translate([-4.5,2.5,11.7])rotate([90,90,0])lock_m(); + + + +module snap(w = 5,h= height) + { + + + difference(){ + translate([height-5.5,(w/2)+2,thikness/2])rotate([0,0,0])cube([7.3,4,thikness],true); + + translate([height-3,w-(0.5),thikness/2])rotate([0,0,45])cube([5,8,thikness*2],true); + + translate([height-8,w-(0.5),thikness/2])rotate([0,0,45])cube([8,5,thikness*2],true); + + + } + + + } + \ No newline at end of file diff --git a/enclosure/recessed.scad b/enclosure/recessed.scad new file mode 100644 index 0000000..501e8d3 --- /dev/null +++ b/enclosure/recessed.scad @@ -0,0 +1,120 @@ +ACB_x = 38.77-5; +ACB_y = 42.44; +ACB_z = 40; +AC_button_x = 38.77; +AC_button_y = 44.44; + +use + + +translate([33,32,40])rotate([180,0,90])cover_unit(); +/* +difference(){translate([ACB_x,ACB_y,ACB_z-10])rotate([0,0,90])linear_extrude(10)round_hull(20,34); + + + translate([ACB_x,ACB_y,ACB_z-5])rotate([0,0,90])translate([0,0 ,0.5])linear_extrude(5)round_hull(16,34); + translate([30,15,ACB_z])cube([50,50,50],true); +}*/ + +AC_buttons(); +AC_buttons_pins(); + + + +module round_hull(r,w) +{ + +$fn=50; +hull() +{ + circle(r); + translate([w,0,0,])circle(r); + } + + } + +module AC_buttons_pins() +{ + translate([AC_button_x,AC_button_y,-0.5+ACB_z-10])rotate([0,180,0])AC_button_Pin(); + translate([AC_button_x,AC_button_y+29.67,-0.5+ACB_z-10])rotate([0,180,0])AC_button_Pin(); + } + + +module AC_button_Pin() +{ + + union(){difference(){difference(){ + cylinder(1,2,2,true); + + rotate_extrude(convexity = 10)translate([2, 0, 0]) + circle(r = 0.5); + + +} +translate([0,0,2])cube(4,true);} +cylinder(5.175,1.5,1.5,false); +} + + +} + + +module AC_buttons() +{ + + + +translate([AC_button_x+5,AC_button_y-4,25])rotate([0,0,90])ACB(); +translate([AC_button_x+5,AC_button_y-4+29.67,25])rotate([0,0,90])ACB(); + + + } + + +module ACB(){ +linear_extrude(20)union(){ +mirror([1,0,0])translate([-8,0,0])ACB_s(4); +ACB_s(4); +} +module ACB_s(width = 5) +{ + + length = 24; + + union(){union() + +{ +square([width,1],false); + +square([1,length]); +translate([0,length,0])rotate([0,0,-90])difference(){difference(){ + + circle(r = 1); + translate([0.5,0.5,0])square([1,2],true); + + }translate([0,-1,0])square(2,true); +} + + } +translate([1,length-1,0])square([0,1]); +} + +} + +} + + + + + +module ACB_tips(){ +translate([AC_button_x,AC_button_y,35.5])ACB_tip(); +translate([AC_button_x,AC_button_y+29.67,35.5]) ACB_tip(); + } +module ACB_tip(width = 5) +{ + difference(){ + sphere(d= width); + translate([0,0,-width/2])cube(width,true); + }} +