diff options
author | xengineering <me@xengineering.eu> | 2024-01-10 19:46:10 +0100 |
---|---|---|
committer | xengineering <me@xengineering.eu> | 2024-01-10 21:07:42 +0100 |
commit | cad2b003b8c936237a909d4076beb0bfd6607b00 (patch) | |
tree | 413aa30f5b7e03c50d91dd2b2032e48447c6f0c4 /mech | |
parent | ca969ac44ea1c2194193eb444c4e6e8ca222c8bf (diff) | |
download | soundbox-cad2b003b8c936237a909d4076beb0bfd6607b00.tar soundbox-cad2b003b8c936237a909d4076beb0bfd6607b00.tar.zst soundbox-cad2b003b8c936237a909d4076beb0bfd6607b00.zip |
mech: Rework front panel
The positions of the connectors had to be adapted to the new PCB case
dimensions.
Furthermore the micro USB port which is built in to supply the device
with power is now the only visible micro USB port from the outside. The
other one is unused and could lead to confusion. User might plug in the
power cable into the wrong port.
Hiding this misleading USB port is an elegant way to avoid this problem.
Developers can still open the device to make use of that port if
required.
Diffstat (limited to 'mech')
-rw-r--r-- | mech/panel_front.scad | 63 | ||||
-rw-r--r-- | mech/production.scad | 4 |
2 files changed, 53 insertions, 14 deletions
diff --git a/mech/panel_front.scad b/mech/panel_front.scad index 31f4ff7..f430789 100644 --- a/mech/panel_front.scad +++ b/mech/panel_front.scad @@ -2,7 +2,6 @@ use <pcb_case/conversion.scad> use <pcb_case/panel.scad> tol = 2; -cinch_d = 8.8; module panel_front(pcb_dim, margins, t) { dim = dim_pcb_to_case(pcb_dim, margins, t); @@ -10,22 +9,62 @@ module panel_front(pcb_dim, margins, t) { difference() { pcb_case_panel_front(pcb_dim, margins, t); - translate([x_off, 17-tol/2, 7.7-tol/2]) mini_hdmi_hole(t); - translate([x_off, 47.7-tol/2, 8-tol/2]) micro_usb_hole(t); - translate([x_off, 60.1-tol/2, 8-tol/2]) micro_usb_hole(t); - translate([x_off, 42.6+cinch_d/2, 26.5+cinch_d/2]) cinch_hole(t); - translate([x_off, 58.5+cinch_d/2, 26.5+cinch_d/2]) cinch_hole(t); + mini_hdmi_hole(pcb_dim, margins, t); + for(v=[ + [usb_max_y-usb_max_delta_y-tol/2, 0.75*t], + [usb_max_y-usb_delta_y-tol/2, t] + ]) { + translate([0, v[0], 0]) { + micro_usb_hole(pcb_dim, margins, t, v[1]); + } + } + for(y = [cinch_max_y-cinch_d/2, cinch_max_y-cinch_delta_y+cinch_d/2]) { + translate([0, y, 0]) { + cinch_hole(pcb_dim, margins, t); + } + } } } -module mini_hdmi_hole(t) { - cube([t, 14+tol, 8.9+tol]); +hdmi_delta_y = 11.8; +hdmi_delta_z = 3.9; +hdmi_max_y = 31.7; +hdmi_max_z = 13.7; +module mini_hdmi_hole(pcb_dim, margins, t) { + case_dim = dim_pcb_to_case(pcb_dim, margins, t); + translate([ + case_dim[0]-2*t, + hdmi_max_y-hdmi_delta_y-tol/2, + hdmi_max_z-hdmi_delta_z-tol/2]) { + cube([t, hdmi_delta_y+tol, hdmi_delta_z+tol]); + } } -module micro_usb_hole(t) { - cube([t, 10.5+tol, 6.6+tol]); +usb_delta_y = 8; +usb_max_delta_y = 20.6; +usb_delta_z = 3; +usb_max_y = 71.55; +usb_max_z = 12.7; +module micro_usb_hole(pcb_dim, margins, t, dx) { + echo(dx); + case_dim = dim_pcb_to_case(pcb_dim, margins, t); + translate([ + case_dim[0]-2*t, + 0, + usb_max_z-usb_delta_z-tol/2]) { + cube([dx, usb_delta_y+tol, usb_delta_z+tol]); + } } -module cinch_hole(t) { - rotate([0, 90, 0]) cylinder(d=cinch_d+tol, h=t, $fn=30); +cinch_d = 8.8; +cinch_delta_y = 24.5; +cinch_max_y = 70.4; +cinch_max_z = 34.25; +module cinch_hole(pcb_dim, margins, t) { + case_dim = dim_pcb_to_case(pcb_dim, margins, t); + translate([case_dim[0]-2*t, 0, cinch_max_z-cinch_d/2]) { + rotate([0, 90, 0]) { + cylinder(d=cinch_d+tol, h=t, $fn=30); + } + } } diff --git a/mech/production.scad b/mech/production.scad index 7ca3051..5d04fbd 100644 --- a/mech/production.scad +++ b/mech/production.scad @@ -23,8 +23,8 @@ module production() { translate([-t, -t, -t]) pcb_case_panel_back(pcb_dim, margins, t); - translate([dim[0], dim[1]+spacing, 0]) - rotate([0, -90, 0]) + translate([0, dim[1]+spacing, t]) + rotate([0, 90, 0]) translate([2*t-dim[0], -t, -t]) panel_front(pcb_dim, margins, t); |