Fixed offsets on aux
This commit is contained in:
@@ -23,6 +23,11 @@ $fingerStep = 5;
|
|||||||
$xBase = (($width + $space) * $columns) + $space;
|
$xBase = (($width + $space) * $columns) + $space;
|
||||||
$yBase = (($length + $space) * $rows) + $space;
|
$yBase = (($length + $space) * $rows) + $space;
|
||||||
|
|
||||||
|
$pcbHeight = 1.6;
|
||||||
|
$dampenerHeight = 1;
|
||||||
|
|
||||||
|
$pcbDampenerOffset = $pcbHeight + $dampenerHeight + $clearance;
|
||||||
|
|
||||||
|
|
||||||
module pin(){
|
module pin(){
|
||||||
cylinder(h=$holes, r=1, center=false);
|
cylinder(h=$holes, r=1, center=false);
|
||||||
@@ -102,26 +107,33 @@ leftTopDampener();
|
|||||||
module case(){
|
module case(){
|
||||||
// Then adjust the shim, aux and pico.
|
// Then adjust the shim, aux and pico.
|
||||||
// Last add magnets, don't forget the clearance.
|
// Last add magnets, don't forget the clearance.
|
||||||
$baseHeight = 6;
|
$baseHeight = 6.2;
|
||||||
|
|
||||||
module magnets(){
|
module magnets(){
|
||||||
cylinder(h=$magnetHeight + $clearance, r=$magnetWidth + $clearance / 2);
|
cylinder(h=$magnetHeight + $clearance, r=$magnetWidth + $clearance / 2);
|
||||||
}
|
}
|
||||||
module aux(){
|
module aux(){
|
||||||
$topToCenterOfAux = 15.4;
|
$topLeftOfPcbToCenterOfAux = 15.4;
|
||||||
$auxHoleRadius = 4;
|
$measurementPcbPlaneToCenterOfAux = 2.8;
|
||||||
|
$auxClearanceFromBase = $measurementPcbPlaneToCenterOfAux - $dampenerHeight;
|
||||||
|
$auxHoleRadius = 3.15;
|
||||||
$auxHoleLength = 17 + $shellWidth/2;
|
$auxHoleLength = 17 + $shellWidth/2;
|
||||||
|
$auxCableRadius = 4.15;
|
||||||
// Move to the position along the wall the aux will be
|
// Move to the position along the wall the aux will be
|
||||||
translate([-($shellWidth/2 + $clearance),$switchDistance * $rows - $topToCenterOfAux,0])
|
translate([-($shellWidth/2 + $clearance),$switchDistance * $rows - $topLeftOfPcbToCenterOfAux,-$auxClearanceFromBase])
|
||||||
// Make cylinder perpendicular with the wall
|
// Make cylinder perpendicular with the wall
|
||||||
rotate([0,90,0])
|
rotate([0,90,0]){
|
||||||
|
// Aux component clearance
|
||||||
cylinder(h=$auxHoleLength,r=$auxHoleRadius);
|
cylinder(h=$auxHoleLength,r=$auxHoleRadius);
|
||||||
|
// Aux cable housing clearance
|
||||||
|
cylinder(h=$shellWidth/2,r=$auxCableRadius );
|
||||||
|
}
|
||||||
// TODO: move magnets to somewhere else.
|
// TODO: move magnets to somewhere else.
|
||||||
translate([0,0,5])
|
translate([0,0,5])
|
||||||
magnets();
|
magnets();
|
||||||
}
|
}
|
||||||
module pico(){
|
module pico(){
|
||||||
$edgeToCenterOfUsb = 23;
|
$topLeftEdgeOfPcbToCenterOfUsb = 23;
|
||||||
$usbHoleWidth = 12;
|
$usbHoleWidth = 12;
|
||||||
$usbHoleHeight = 9;
|
$usbHoleHeight = 9;
|
||||||
$usbOffsetFromPcb = 2.4;
|
$usbOffsetFromPcb = 2.4;
|
||||||
@@ -129,7 +141,7 @@ module case(){
|
|||||||
$picoWidth = 25;
|
$picoWidth = 25;
|
||||||
$picoLength = 53;
|
$picoLength = 53;
|
||||||
// Move to position along the wall the usb will be
|
// Move to position along the wall the usb will be
|
||||||
translate([$edgeToCenterOfUsb - ($usbHoleWidth/2), $switchDistance * $rows, -$usbOffsetFromPcb]){
|
translate([$topLeftEdgeOfPcbToCenterOfUsb - ($usbHoleWidth/2), $switchDistance * $rows, -$usbOffsetFromPcb]){
|
||||||
union() {
|
union() {
|
||||||
// Create a hole for the usb cable to go through
|
// Create a hole for the usb cable to go through
|
||||||
cube([$usbHoleWidth,$shellWidth,$usbHoleHeight]);
|
cube([$usbHoleWidth,$shellWidth,$usbHoleHeight]);
|
||||||
@@ -145,7 +157,7 @@ module case(){
|
|||||||
$shimPoints = [
|
$shimPoints = [
|
||||||
[0 - $shellWidth / 2, - $baseHeight],
|
[0 - $shellWidth / 2, - $baseHeight],
|
||||||
[$switchDistance * $columns + $shellWidth/2 + $clearance, 0],
|
[$switchDistance * $columns + $shellWidth/2 + $clearance, 0],
|
||||||
[$switchDistance * $columns + $shellWidth/2 + $clearance, - $baseHeight]
|
[$switchDistance * $columns + $shellWidth/2 + $clearance, - ($baseHeight + $clearance)]
|
||||||
];
|
];
|
||||||
// Face z/x-plane
|
// Face z/x-plane
|
||||||
rotate([90,0,0])
|
rotate([90,0,0])
|
||||||
|
|||||||
Reference in New Issue
Block a user