/Modules/Mechanical/LCDholder/CAD/src/LCD_16x2_box.scad
0,0 → 1,47
$fn = 100;
 
 
module LCD_frontPanel(){
WIDTH = 7; // pocet der na zakl desku. Min je 8
FOOT_X_SHIFT = 0; // posun v ose X, tzn. vysunutí ven, nebo dovnitř. 0 je v rovine s kratsi hranou zakl. desky ASBASE1115
DISPLAY_Z_SHIFT = 2; // mezera, která vznikne mezi "nohou" a spodní hranou PCB
FOOT_THICK = 7; // síla spodní "nohy" (toho, v cem jsou srouby)
BHEAD_HEIGHT = 2.5; // vyska hlavicky sroubu
BHEAD_DIAMETER = 6; // vyska hlavicky sroubu
BOLT_DIAMETER = 3.2; // vyska hlavicky sroubu
NUT_HEIGHT = 2.1; // vyska matky
NUT_DIAMETER = 6; // vyska matky
CLEAR = 0.1;
difference(){
union(){
translate([0, 4 +FOOT_X_SHIFT, 0+DISPLAY_Z_SHIFT/2])cube([80,8,36+DISPLAY_Z_SHIFT], center=true);
translate([0, 4 +FOOT_X_SHIFT/2, (-36-FOOT_THICK)/2])cube([80,8+FOOT_X_SHIFT,FOOT_THICK], center=true);
translate([+75/2, 0, +31/2+DISPLAY_Z_SHIFT]) rotate([90,0,0]) cylinder(FOOT_THICK, 2.3/2, 2.3/2);
translate([+75/2, 0, -31/2+DISPLAY_Z_SHIFT]) rotate([90,0,0]) cylinder(FOOT_THICK, 2.3/2, 2.3/2);
translate([-75/2, 0, +31/2+DISPLAY_Z_SHIFT]) rotate([90,0,0]) cylinder(FOOT_THICK, 2.3/2, 2.3/2);
translate([-75/2, 0, -31/2+DISPLAY_Z_SHIFT]) rotate([90,0,0]) cylinder(FOOT_THICK, 2.3/2, 2.3/2);
hull(){
translate([-40+10.16/2, -0.8, (-36)/2-FOOT_THICK]) cylinder(FOOT_THICK, 10.16/2, 10.16/2);
translate([+40-10.16/2, -0.8, (-36)/2-FOOT_THICK]) cylinder(FOOT_THICK, 10.16/2, 10.16/2);
}
/*#hull(){
translate([-5.08 + (-WIDTH/2+1)*10.16, -0.8, (-36)/2-FOOT_THICK]) cylinder(FOOT_THICK, 10.16/2, 10.16/2);
translate([-5.08 + (-WIDTH/2+5)*10.16, -0.8, (-36)/2-FOOT_THICK]) cylinder(FOOT_THICK, 10.16/2, 10.16/2);
}*/
}
union(){
translate([0, 4 + FOOT_X_SHIFT, +DISPLAY_Z_SHIFT]) cube([72,8,25.3], center=true);
translate([-5, FOOT_X_SHIFT, 36/2-4+DISPLAY_Z_SHIFT]) cube([41,4,4]);
for (x=[1:WIDTH]){
translate([-5.08 + (-WIDTH/2+x)*10.16, -0.8, (-36)/2-FOOT_THICK]) cylinder(12, BOLT_DIAMETER/2, BOLT_DIAMETER/2);
translate([-5.08 + (-WIDTH/2+x)*10.16, -0.8, (-36)/2-BHEAD_HEIGHT]) cylinder(3+10, BHEAD_DIAMETER/2, BHEAD_DIAMETER/2);
translate([-5.08 + (-WIDTH/2+x)*10.16, -0.8, (-36)/2-FOOT_THICK]) cylinder(NUT_HEIGHT, NUT_DIAMETER/2, NUT_DIAMETER/2, $fn=6);
}
}
}
}
 
 
LCD_frontPanel();
/Modules/Mechanical/PLCASE1115/CAD/src/PLCASE1115.scad
2,6 → 2,10
mount_hole = 3.5;
clear = 0.175;
thickness = 1.2;
baseboard_thickness = 2;
teeth_width = 8;
teeth_count = 6;
teeth_size = 1;
 
$fn=20;
 
11,25 → 15,35
cylinder(r=MLAB_grid/2 - 0.3,h=legs_height);
}
}
// teeth
for(count = [1:teeth_count]){
position = 150/(teeth_count+1)*count;
#translate ([position-teeth_width/2+1,-5+thickness/2,0]) cube([teeth_width-1, teeth_size, 5-baseboard_thickness]);
translate ([position-teeth_width/2+1,110+5-thickness/2,0]) cube([teeth_width-1, teeth_size, 5-baseboard_thickness]);
}
 
 
difference () {
minkowski() {
cube([150+thickness/2,110+thickness/2,height+thickness/2]); // base plastics brick
cylinder(r=5,h=0.1);
}
translate ([thickness, thickness, 0])
minkowski() {
cube([150-thickness, 110-thickness, height]); // hollow
cylinder(r=5,h=0.1);
}
minkowski() {
cube([150+thickness/2,110+thickness/2,height+thickness/2]); // base plastics brick
cylinder(r=5,h=0.1);
}
translate ([thickness, thickness, 0])
minkowski() {
cube([150-thickness, 110-thickness, height]); // hollow
cylinder(r=5,h=0.1);
}
 
translate ([thickness/2, thickness/2, 0])
difference () {
minkowski() {
cube([150-thickness/2+clear, 110-thickness/2+clear, 5]); // hollow for BASE1115
cylinder(r=5,h=0.1);
}
/// TODO Fixing cilinders teeths
}
translate ([thickness/2, thickness/2, 0])
difference () {
minkowski() {
cube([150-thickness/2+clear, 110-thickness/2+clear, 5]); // hollow for BASE1115
cylinder(r=5,h=0.1);
}
}
for(count = [1:teeth_count]){ // teeth space
position = 150/(teeth_count+1)*count;
translate ([position-teeth_width/2,-5-thickness,0]) cube([1,110+10+2*thickness,5]);
translate ([position+teeth_width/2,-5-thickness,0]) cube([1,110+10+2*thickness,5]);
}
}