chiark / gitweb /
adafruit-powerboost: 1000: wip
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Sun, 21 Nov 2021 17:59:43 +0000 (17:59 +0000)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Sun, 21 Nov 2021 17:59:43 +0000 (17:59 +0000)
Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
adafruit-powerboost-1000.scad

index eb3f8527945475c85b1528ecbe690a0d73807cc7..1b6e8772c50747d7799a8f7d4b5b5352db97bde1 100644 (file)
@@ -9,9 +9,20 @@ psu_hole_pos = [ 2.05, // from back edge of psu_sz[0]
                 0.55 * 0.5 * 25.4, // from centreline
                 ];
 
+psu_led_low_x = 4;
+
+psu_led_usbend_y_min = 4.5;
+psu_led_chrg_min_x = -1.0;
+psu_led_chrg_max_x = 3.0;
+psu_led_chrg_both_sz_y = 7.0;
+
+psu_led_low_sz_x = 4.5;
+psu_led_low_min_y = -1.5;
+psu_led_low_max_y = 2.5;
+
 psu_baffle_cnr_y = 7.45; // from connector end
-psu_baffle_th = [ 0.8, 3.5 ];
 psu_usbend_led_x = 4.5;
+psu_baffle_th = [ 0.8, 3.5 ];
 psu_usbend_led_y = 4.5;
 psu_innerend_led_depth = 10;
 
@@ -20,6 +31,9 @@ psu_innerend_led_depth = 10;
 psu_usbend_led_depth = psu_baffle_cnr_y*2 - psu_usbend_led_x;
 
 module PsuLedBafflePlan(){
+//  AtPsuMountCorner(0,0) {
+//    translate([0,
+//            psu_led_usbend_y_min + psu_led_chrg_both_sz_y/2
 }
 
 module PsuLedWindowsPlanCore(){
@@ -28,24 +42,23 @@ module PsuLedWindowsPlanCore(){
       // Two LEDs one side of inlet connector
       // "Full" (near edge) and "Chrg" (inner)
       AtPsuMountCorner(0,0) {
-       rectfromto([ -(psu_board_support_wall + 0.1),
-                    +psu_usbend_led_x ],
-                  [ psu_usbend_led_y,
-                    +psu_usbend_led_depth ]);
+       translate([0, psu_led_usbend_y_min ])
+         rectfromto([ psu_led_chrg_min_x, 0 ],
+                    [ psu_led_chrg_max_x,
+                      psu_led_chrg_both_sz_y ]);
       }
 
       // One LED, "Low", other side of inlet connector
       AtPsuMountCorner(1,0) {
-       sz = psu_baffle_cnr_y - psu_board_support_wall - psu_baffle_th[0];
-       translate([0, psu_baffle_cnr_y])
-         rectfromto([ -(psu_board_support_wall + 0.1),
-                      -sz/2 ],
-                    [ psu_sz[0]/2,
-                      +sz/2 ]);
+       translate([0, psu_led_usbend_y_min ])
+         rectfromto([ 0,
+                      psu_led_low_min_y ],
+                    [ psu_led_low_sz_x,
+                      psu_led_low_max_y ]);
       }
 
       // One LED, PWR, near outlet USB pads
-      AtPsuMountCorner(1,1){
+      AtPsuMountCorner(0,1){
        rectfromto([0,0],
                   [psu_sz[0]/2 - psu_hole_pos[1] - psu_hole_dia/2,
                     psu_innerend_led_depth]);