aboutsummaryrefslogtreecommitdiff
path: root/psu.scad
diff options
context:
space:
mode:
authorGravatar Jonas Gunz <himself@jonasgunz.de> 2024-09-14 19:34:30 +0200
committerGravatar Jonas Gunz <himself@jonasgunz.de> 2024-09-14 19:34:30 +0200
commit471dbd8d1d578ad6d2d558c1c1bb2e39d589f070 (patch)
treed68792abf2307b8b0391f95a2523d80c763186ce /psu.scad
parentc380946750613f9ace78919154a30f00f175ee1e (diff)
downloadoscad_gridfinity-471dbd8d1d578ad6d2d558c1c1bb2e39d589f070.tar.gz
psu
Diffstat (limited to 'psu.scad')
-rw-r--r--psu.scad35
1 files changed, 25 insertions, 10 deletions
diff --git a/psu.scad b/psu.scad
index a2e8fda..4e0ae8c 100644
--- a/psu.scad
+++ b/psu.scad
@@ -23,6 +23,8 @@ usb_x = 11.6 + tol;
usb_y = 21.5 + tol;
usb_z = 1 + tol;
+usb_location = [100,0,0];
+
module module_negative() {
rotate([90,0,0]) linear_extrude(5) {
translate([-2, module_y/2 - module_clip_width/2]) square([2,module_clip_width]);
@@ -46,17 +48,30 @@ module usb_hole_negative() {
translate([-1,-5,0]) cube([usb_x+2,5,8]);
}
-usb_location = [100,0,0];
+module psu_lid() {
+ gridfinity(ux, uy, 1, lip=true, magnets=false, fill = false, bottom_height = 0);
+}
-difference() {
- gridfinity(ux, uy, uz, lip=true, magnets=false, fill = false, bottom_height = 0);
- translate(concat(gf_inner_origin(), [gf_inner_bottom()])) {
- translate([5,0,10]) module_negative();
- translate([90,0,15]) plug_negative();
- translate([90,0,15+plug_distance]) plug_negative();
- translate(usb_location) usb_hole_negative();
+module psu_cover() {
+ difference() {
+ gridfinity(ux, uy, uz + 1, lip=true, magnets=false, fill = false, bottom_height = 0);
+ translate(concat(gf_inner_origin(), [gf_inner_bottom()])) {
+ translate([0,-5,0]) cube([gf_inner(ux),5,gf_top(uz+1)-gf_inner_bottom() + 5]);
+ }
}
}
-translate(concat(gf_inner_origin(), [gf_inner_bottom()]))
- translate(usb_location) usb_inset();
+module psu_main() {
+ difference() {
+ gridfinity(ux, uy, uz, lip=true, magnets=false, fill = false, bottom_height = 0);
+ translate(concat(gf_inner_origin(), [gf_inner_bottom()])) {
+ translate([5,0,10]) module_negative();
+ translate([90,0,15]) plug_negative();
+ translate([90,0,15+plug_distance]) plug_negative();
+ translate(usb_location) usb_hole_negative();
+ }
+ }
+
+ translate(concat(gf_inner_origin(), [gf_inner_bottom()]))
+ translate(usb_location) usb_inset();
+}