initial commit
This commit is contained in:
commit
6dbaf36928
|
@ -0,0 +1,8 @@
|
|||
include <supports.scad>;
|
||||
include <plate.scad>;
|
||||
|
||||
for(x=[0:3]) {
|
||||
for(y=[0:1])
|
||||
translate([60*x,60*y,0])
|
||||
plate4x4(thickness=4);
|
||||
}
|
|
@ -0,0 +1,34 @@
|
|||
// this SCAD file defines the top plate for the case of a neotrellis monome-compatible grid controller.
|
||||
// the file is designed to be parametric, for easier testing.
|
||||
// TODO tolerances
|
||||
// first, we declare some parameters, that will be useful to tweak while testing the model:
|
||||
|
||||
// Button size (in mm)
|
||||
button_size = 10;
|
||||
// Spacing between buttons (in mm)
|
||||
spacing = 5;
|
||||
// Tolerance for button holes (how much larger they are than a button)
|
||||
tolerance = 0.4;
|
||||
// outer spacing - spacing between the edge of the silicon part and the buttons
|
||||
outer_spacing = 2.5;
|
||||
|
||||
// module for a 4x4 unit of the top plate.
|
||||
module plate4x4(thickness) {
|
||||
difference() {
|
||||
cube(
|
||||
[outer_spacing*2+button_size*4+spacing*3,
|
||||
outer_spacing*2+button_size*4+spacing*3,
|
||||
thickness]);
|
||||
for(x=[0:3]) {
|
||||
for(y=[0:3]) {
|
||||
translate(
|
||||
[outer_spacing-(tolerance/2)+((button_size+spacing)*x),
|
||||
outer_spacing-(tolerance/2)+((button_size+spacing)*y),
|
||||
-0.5])
|
||||
cube([button_size+tolerance,button_size+tolerance,thickness+1]);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
plate4x4(1);
|
|
@ -0,0 +1,35 @@
|
|||
// this SCAD file defines the support structures for the neotrellis grid. (potentially also bottom case)
|
||||
pcb_size = 60; // the PCB is 60x60mm square
|
||||
pcb_depth = 7.57; // the PCB is 7.57mm deep, overall (including connector + lEDs)
|
||||
connector_depth=5.7; // the connector on the bottom of the PCB is 5.8mm thick.
|
||||
pcb_thickness= 1.7; // the PCB itself (just the board, w/o components) is roughly 1.7mm thick
|
||||
|
||||
wall_width=5; // width of support structure walls
|
||||
support_depth=10; // depth of support structure wall
|
||||
|
||||
cutout_width=25; // width of the cutouts in the support structure, for wires etc
|
||||
cutout_depth=5; // depth of the cutouts in the support structure
|
||||
|
||||
// translate everything down relative to the PCB reference
|
||||
translate([0,0,-support_depth-pcb_thickness]) {
|
||||
// create outer walls by differencing a box with an inner box that is smaller
|
||||
difference() {
|
||||
// outer box - the size of the overall box
|
||||
cube([pcb_size,pcb_size,support_depth]);
|
||||
translate([wall_width,wall_width,-1]) {
|
||||
// inner box - cuts a hole to create outer walls rather than a box
|
||||
cube([pcb_size-(wall_width*2),pcb_size-(wall_width*2),support_depth+1.01]);
|
||||
}
|
||||
translate([-1, pcb_size/2-cutout_width/2, support_depth-cutout_depth]) {
|
||||
cube([pcb_size+2,cutout_width,cutout_depth+1]); // cutouts in one direction
|
||||
}
|
||||
translate([pcb_size/2-cutout_width/2, -1, support_depth-cutout_depth])
|
||||
cube([cutout_width, pcb_size+2, cutout_depth+1]); // cutouts in the other direction
|
||||
}
|
||||
}
|
||||
// load and position the PCB as a reference
|
||||
rotate([180,0,0]) {
|
||||
translate([pcb_size/2,-pcb_size/2]) {
|
||||
%import("pcb-single.stl");
|
||||
}
|
||||
}
|
|
@ -0,0 +1,101 @@
|
|||
// this SCAD file defines the support structures for the neotrellis grid. (potentially also bottom case)
|
||||
pcb_size = 60; // the PCB is 60x60mm square
|
||||
pcb_depth = 7.57; // the PCB is 7.57mm deep, overall (including connector + lEDs)
|
||||
connector_depth=5.7; // the connector on the bottom of the PCB is 5.8mm thick.
|
||||
pcb_thickness= 1.7; // the PCB itself (just the board, w/o components) is roughly 1.7mm thick
|
||||
|
||||
support_width=5; // width of support structure walls
|
||||
support_depth=10; // depth of support structure wall
|
||||
floor_depth = 1; // depth of the bottom floor of the support
|
||||
|
||||
|
||||
wall_height = (pcb_depth-connector_depth)+4; // height of walls above the top of the supports
|
||||
wall_width = 1; // width of walls above the top of the supports
|
||||
|
||||
cutout_width=25; // width of the cutouts in the support structure, for wires etc
|
||||
cutout_depth=5; // depth of the cutouts in the support structure
|
||||
|
||||
pcbs_wide=2; // how many trellis PCBs are in the grid, width-wise
|
||||
pcbs_long=4; // how many trellis PCBs are in the grid, length-wise
|
||||
|
||||
tolerance = 0.4;
|
||||
|
||||
// translate everything down relative to the PCB reference
|
||||
translate([0,0,-support_depth-pcb_thickness]) {
|
||||
// create basic grid of support units
|
||||
difference() {
|
||||
union() {
|
||||
// create large outer box
|
||||
translate([-wall_width,-wall_width]) {
|
||||
difference() {
|
||||
cube([pcb_size*pcbs_long+wall_width*2,pcb_size*pcbs_wide+wall_width*2,support_depth+wall_height]);
|
||||
translate([wall_width,wall_width]) {
|
||||
cube([pcb_size*pcbs_long,pcb_size*pcbs_wide,support_depth+wall_height+0.1]);
|
||||
}
|
||||
}
|
||||
}
|
||||
for(x=[0:pcbs_long-1]) {
|
||||
for(y=[0:pcbs_wide-1]) {
|
||||
translate([pcb_size*x,pcb_size*y,0]) {
|
||||
support_unit();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
// add lengthwise internal cutouts
|
||||
for(x=[0:pcbs_wide-1]) {
|
||||
translate(
|
||||
[pcb_size/2,
|
||||
(pcb_size/2-cutout_width/2)+(pcb_size*x),
|
||||
support_depth-cutout_depth]) {
|
||||
cube([(pcb_size*(pcbs_long-1)),cutout_width,cutout_depth+1]);
|
||||
}
|
||||
}
|
||||
// add widthwise internal cutouts
|
||||
for(x=[0:pcbs_long-1]) {
|
||||
translate(
|
||||
[(pcb_size/2-cutout_width/2) + ((pcb_size)*x),
|
||||
pcb_size/2,
|
||||
support_depth-cutout_depth]) {
|
||||
cube([cutout_width, pcb_size*(pcbs_wide-1), cutout_depth+1]);
|
||||
}
|
||||
}
|
||||
// add cutout for USB port
|
||||
translate(
|
||||
[pcb_size*(pcbs_long-1)+wall_width+1,
|
||||
pcb_size/2-cutout_width/2+pcb_size,
|
||||
support_depth-cutout_depth
|
||||
]) {
|
||||
cube([pcb_size, cutout_width, cutout_depth+1]);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// load and position the PCB grid as a reference
|
||||
rotate([180,0,0]) {
|
||||
translate([pcb_size/2,-pcb_size/2-pcb_size]) {
|
||||
for(x=[0:pcbs_long-1]) {
|
||||
for(y=[0:pcbs_wide-1]) {
|
||||
translate([pcb_size*x,pcb_size*y,0]) {
|
||||
%import("pcb-single.stl");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// a support unit is the individual box underneath one trellis PCB. no cutouts are included in the module as these differ depending on position.
|
||||
module support_unit() {
|
||||
// outer box - the size of the overall box
|
||||
difference() {
|
||||
cube([pcb_size,pcb_size,support_depth]);
|
||||
translate([support_width,support_width,floor_depth]) {
|
||||
// inner box - cuts a hole in the center of the box to create walls+floor
|
||||
cube(
|
||||
[pcb_size-(support_width*2),
|
||||
pcb_size-(support_width*2),
|
||||
support_depth+1.01]);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue