Browse Source

Made meachnical design better for FDM.

master
Maximilian Stiefel 7 years ago
parent
commit
4c6b0afa3e
  1. BIN
      cad/mechanics_rev4/housing/.box.scad.swp
  2. BIN
      cad/mechanics_rev4/housing/.dimensions.scad.swp
  3. 97
      cad/mechanics_rev4/housing/box.scad
  4. 65
      cad/mechanics_rev4/housing/box_female.scad
  5. 27974
      cad/mechanics_rev4/housing/box_female.stl
  6. 64
      cad/mechanics_rev4/housing/box_male.scad
  7. 21842
      cad/mechanics_rev4/housing/box_male.stl
  8. 130
      cad/mechanics_rev4/housing/dimensions.scad
  9. 21786
      cad/mechanics_rev4/housing/lid_back.stl
  10. 75
      cad/mechanics_rev4/housing/lid_f_b.scad
  11. 44270
      cad/mechanics_rev4/housing/lid_front.stl
  12. 62
      cad/mechanics_rev4/housing/lid_l_r.scad
  13. 15654
      cad/mechanics_rev4/housing/lid_left.stl
  14. 15654
      cad/mechanics_rev4/housing/lid_right.stl
  15. 59
      cad/mechanics_rev4/housing/lid_t_b.scad
  16. 15682
      cad/mechanics_rev4/housing/lid_top.stl
  17. 9702
      cad/mechanics_rev4/housing/logo.dxf
  18. BIN
      cad/mechanics_rev4/housing/logo.png
  19. 75
      cad/mechanics_rev4/housing/main.scad
  20. 41
      cad/mechanics_rev4/housing/open_box.scad
  21. 31
      cad/mechanics_rev4/housing/oring.scad
  22. 30
      cad/mechanics_rev4/housing/roundy.scad
  23. BIN
      cad/mechanics_rev4/housing/screenshot_closed.png
  24. BIN
      cad/mechanics_rev4/housing/screenshot_cut_closed.png
  25. BIN
      cad/mechanics_rev4/housing/screenshot_cut_open.png
  26. BIN
      cad/mechanics_rev4/housing/screenshot_open.png
  27. 24
      cad/mechanics_rev4/housing/screw_holes.scad
  28. 30
      cad/mechanics_rev4/housing/screw_sinkings.scad
  29. 39
      cad/mechanics_rev4/pcb/dimensions.scad
  30. 43
      cad/mechanics_rev4/pcb/glass_holder.scad
  31. BIN
      cad/mechanics_rev4/pcb/glass_slide_holder.jpg
  32. 10614
      cad/mechanics_rev4/pcb/glass_slide_holder.stl
  33. 40
      cad/mechanics_rev4/pcb/led_illuminator.scad
  34. 52
      cad/mechanics_rev4/pcb/legs.scad
  35. 42
      cad/mechanics_rev4/pcb/main.scad
  36. 6729
      pcbs/analog_board_v0.2/_autosave-analog_board_v0.2.kicad_pcb
  37. 26
      pcbs/analog_board_v0.2/analog_board_v0.2.kicad_pcb
  38. 30
      pcbs/analog_board_v0.2/analog_board_v0.2.kicad_pcb-bak
  39. 4
      pcbs/analog_board_v0.22/analog_board_v0.22.bak

BIN
cad/mechanics_rev4/housing/.box.scad.swp

Binary file not shown.

BIN
cad/mechanics_rev4/housing/.dimensions.scad.swp

Binary file not shown.

97
cad/mechanics_rev4/housing/box.scad

@ -0,0 +1,97 @@
/////////////////////////////////////////////////////////////////////////////////
// Module for the box without lids just to structure the code a bit better.
//
// Author: Maximilian Stiefel
// Last modification: 20.07.2017
/////////////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////////
// Includes
/////////////////////////////////////////////////////////////////////////////////
// Dimesnions
include <dimensions.scad>
use <dimensions.scad>
// Module to make a nice round box
include <roundy.scad>
use <roundy.scad>
// Module for screw holes
include <screw_holes.scad>
use <screw_holes.scad>
// Module for orings
include <oring.scad>
use <oring.scad>
module box()
{
/////////////////////////////////////////////////////////////////////////
// Vars
/////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////
// Action
/////////////////////////////////////////////////////////////////////////
difference()
{
// Main body
roundy(housing_outside_width, housing_outside_depth, housing_outside_height);
union()
{
// Cut out basic inner shape
cube([housing_inside_width, housing_inside_depth, housing_inside_height], center = true);
// Cut out all six sides
// Left and right
cube([housing_inside_width + 3*housing_thickness, lid_l_r_width, lid_l_r_height], center = true);
// Front and back
cube([lid_f_b_width, housing_inside_depth + 3*housing_thickness, lid_f_b_height], center = true);
// Cut deepenings for lids
// Left and right
for(x = [-1, 1])
translate([x*housing_outside_width/2 - x*lids_depth/2 + x*0.1, 0, 0])
rotate([0, 90, 0])
roundy(lid_l_r_x, lid_l_r_y, lids_depth + 0.2, center = true);
// Front and back
for(y = [-1, 1])
translate([0, y*housing_outside_depth/2 - y*lids_depth/2 + y*0.1, 0])
rotate([90, 0, 0])
cube([lid_f_b_x, lid_f_b_y, lids_depth + 0.2], center = true);
// Screw holes
// Left and right
for(x = [-1, 1])
translate([x*housing_outside_width/2 - x*drill_depth_m3, 0, 0])
rotate([90, 0, 90])
screw_holes(lid_l_r_holes_x, lid_l_r_holes_y, drill_thread_dia_m3, 2*lids_depth);
// Front and back
for(y = [-1, 1])
translate([0, y*housing_outside_depth/2 - y*drill_depth_m3, 0])
rotate([90, 0, 0])
screw_holes(lid_f_b_holes_x, lid_f_b_holes_y, drill_thread_dia_m3, 2*lids_depth);
// O-rings
// Left and right
for(x = [-1, 1])
translate([x*housing_outside_width/2 - x*lids_depth - x*oring_channel_depth/2, 0, 0])
rotate([90, 0, 90])
oring(oring_l_r_x, oring_l_r_y, oring_channel_width, oring_channel_depth);
// Front and back
for(y = [-1, 1])
translate([0, y*housing_outside_depth/2 - y*lids_depth - y*oring_channel_depth/2, 0])
rotate([90, 0, 0])
oring(oring_f_b_x, oring_f_b_y, oring_channel_width, oring_channel_depth);
// Cut holes for battery holder
translate([battery_holder_pos_x, battery_holder_pos_y, 0.01 - (housing_inside_height + drill_depth_m3)/2])
cylinder(r = drill_thread_dia_m3/2, h = drill_depth_m3, center = true);
translate([battery_holder_pos_x - battery_holder_hole_dis_x, battery_holder_pos_y + battery_holder_hole_dis_y, 0.01 - (housing_inside_height + drill_depth_m3)/2])
cylinder(r = drill_thread_dia_m3/2, h = drill_depth_m3, center = true);
}
}
}

65
cad/mechanics_rev4/housing/box_female.scad

@ -0,0 +1,65 @@
/////////////////////////////////////////////////////////////////////////////////
// Female part of the box.
//
// Author: Maximilian Stiefel
// Last modification: 31.07.2017
/////////////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////////
// Includes
/////////////////////////////////////////////////////////////////////////////////
// Dimesnions
include <dimensions.scad>
use <dimensions.scad>
// Module for raw box without any lids
include <box.scad>
use <box.scad>
// Module for screw holes
include <screw_holes.scad>
use <screw_holes.scad>
////////////////////////////////////////////////////////////////////////////////
// Vars
/////////////////////////////////////////////////////////////////////////////////
// Set minimum angle of a fragment
$fa = 0.5;
// Set minimum size of a fragment
$fs = 0.5;
////////////////////////////////////////////////////////////////////////////////
// Action
/////////////////////////////////////////////////////////////////////////////////
color(myColor1)
{
translate([0, 0, housing_outside_height/2])
//rotate([180, 0, 0])
{
difference()
{
// Draw hole box
box();
union()
{
// Cut off half of it
translate([0, 0, housing_outside_height/4])
cube([housing_outside_width + 1, housing_outside_depth + 1, housing_outside_height/2 + 0.01], center = true);
// Draw cylinders for mortise joint
translate([0, 0, -(mortise_joint_height - mortise_joint_cone_height)/2])
screw_holes(housing_inside_width + housing_thickness/2, housing_inside_depth + housing_thickness/2, mortise_joint_dia, mortise_joint_height - mortise_joint_cone_height);
// Draw cones
rotate([180, 0, 0])
for(x=[-0.5,+0.5])
for(y=[-0.5,+0.5])
translate([x*(housing_inside_width + housing_thickness/2), y*(housing_inside_depth + housing_thickness/2), mortise_joint_height - mortise_joint_cone_height/2 - 0.01])
cylinder(r1 = mortise_joint_dia/2, r2 = 1, mortise_joint_cone_height, center = true);
}
}
}
}

27974
cad/mechanics_rev4/housing/box_female.stl

File diff suppressed because it is too large

64
cad/mechanics_rev4/housing/box_male.scad

@ -0,0 +1,64 @@
/////////////////////////////////////////////////////////////////////////////////
// Male part of the box.
//
// Author: Maximilian Stiefel
// Last modification: 31.07.2017
/////////////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////////
// Includes
/////////////////////////////////////////////////////////////////////////////////
// Dimesnions
include <dimensions.scad>
use <dimensions.scad>
// Module for raw box without any lids
include <box.scad>
use <box.scad>
// Module for screw holes
include <screw_holes.scad>
use <screw_holes.scad>
////////////////////////////////////////////////////////////////////////////////
// Vars
/////////////////////////////////////////////////////////////////////////////////
// Set minimum angle of a fragment
$fa = 0.5;
// Set minimum size of a fragment
$fs = 0.5;
////////////////////////////////////////////////////////////////////////////////
// Action
/////////////////////////////////////////////////////////////////////////////////
color(myColor1)
{
translate([0, 0, housing_outside_height/2])
rotate([180, 0, 0])
union()
{
rotate([180, 0, 0])
{
// Draw cylinders for mortise joint
translate([0, 0, (mortise_joint_height - mortise_joint_cone_height - allowance05)/2 - 0.01])
screw_holes(housing_inside_width + housing_thickness/2, housing_inside_depth + housing_thickness/2, mortise_joint_dia - allowance05, mortise_joint_height - mortise_joint_cone_height - allowance05);
// Draw cones
for(x=[-0.5,+0.5])
for(y=[-0.5,+0.5])
translate([x*(housing_inside_width + housing_thickness/2), y*(housing_inside_depth + housing_thickness/2), mortise_joint_height - mortise_joint_cone_height/2 - allowance05 - 0.01])
cylinder(r1 = (mortise_joint_dia - allowance05)/2, r2 = 1, mortise_joint_cone_height, center = true);
}
difference()
{
// Draw hole box
box();
// Cut off half of it
translate([0, 0, -housing_outside_height/4])
cube([housing_outside_width + 1, housing_outside_depth + 1, housing_outside_height/2 + 0.01], center = true);
}
}
}

21842
cad/mechanics_rev4/housing/box_male.stl

File diff suppressed because it is too large

130
cad/mechanics_rev4/housing/dimensions.scad

@ -0,0 +1,130 @@
/////////////////////////////////////////////////////////////////////////////////
// File for all dimensions, so they can be changed globally.
//
// Author: Maximilian Stiefel
// Last modification: 07.07.2017
/////////////////////////////////////////////////////////////////////////////////
// Allowance
allowance15 = 15;
allowance10 = 10;
allowance5 = 5;
allowance1 = 1;
allowance05 = 0.5;
// Dimensions battery holder
battery_holder_width = 53.5;
battery_holder_depth = 50.5;
battery_holder_height = 13;
// Dimensions motherboard
motherboard_width = 80;
motherboard_depth = 1.6;
motherboard_height = 50;
// Dimensions plugin boards
pluginboard_width = 80;
pluginboard_depth = 1.6;
pluginboard_height = 50;
// Dimensions magnet
extra_space_magnet = 10;
// Dimensions housing inside (cubic)
housing_inside_width = motherboard_width + allowance15;
housing_inside_depth = pluginboard_height + extra_space_magnet + allowance5;
housing_inside_height = motherboard_height + battery_holder_height + allowance10;
echo(housing_inside_width=housing_inside_width);
echo(housing_inside_depth=housing_inside_depth);
echo(housing_inside_height=housing_inside_height);
// Dimensions housing
housing_thickness = 12; // Make it thick to avoid light comming through the walls
housing_outside_width = housing_inside_width + 2*housing_thickness;
housing_outside_depth = housing_inside_depth + 2*housing_thickness;
housing_outside_height = housing_inside_height + 2*housing_thickness;
echo(housing_outside_width=housing_outside_width);
echo(housing_outside_depth=housing_outside_depth);
echo(housing_outside_height=housing_outside_height);
// Colors
myColor1 = "DodgerBlue";
myColor2 = "Maroon";
// Lids dimensions
lids_depth = housing_thickness/3;
echo(lids_depth=lids_depth);
lid_l_r_height = (3/4)*housing_inside_height;
lid_l_r_width = (3/4)*housing_inside_depth;
lid_l_r_overlap = (1.7)*housing_thickness;
lid_l_r_x = lid_l_r_height + lid_l_r_overlap;
lid_l_r_y = lid_l_r_width + lid_l_r_overlap;
lid_f_b_width = housing_inside_width - 10;
lid_f_b_height = housing_inside_height - 5;
lid_f_b_overlap = (1.7)*housing_thickness;
lid_f_b_x = lid_f_b_width + lid_f_b_overlap;
lid_f_b_y = lid_f_b_height + lid_f_b_overlap;
lid_t_b_width = housing_inside_width;
lid_t_b_height = housing_inside_depth;
lid_t_b_overlap = (1.7)*housing_thickness;
lid_t_b_x = lid_t_b_width + lid_t_b_overlap;
lid_t_b_y = lid_t_b_height + lid_t_b_overlap;
// Screw holes
drill_dia_m3 = 3.2;
drill_thread_dia_m3 = 2.5;
drill_depth_m3 = 6;
drill_sinking_dia1_m3 = 5.5;
drill_sinking_dia2_m3 = 3;
drill_sinking_height_m3 = 2;
echo(drill_depth_m3=drill_depth_m3);
lid_l_r_holes_x = lid_l_r_width + (5/10)*lid_l_r_overlap;
lid_l_r_holes_y = lid_l_r_height + (5/10)*lid_l_r_overlap;
lid_f_b_holes_x = lid_f_b_width + (5/10)*lid_f_b_overlap;
lid_f_b_holes_y = lid_f_b_height + (5/10)*lid_f_b_overlap;
lid_t_b_holes_x = lid_t_b_width + (5/10)*lid_t_b_overlap;
lid_t_b_holes_y = lid_t_b_height + (5/10)*lid_t_b_overlap;
motherboard_mounting_x = motherboard_width - 2*5;
motherboard_mounting_y = motherboard_height - 2*5;
motherboard_mounting_d = 6;
motherboard_mounting_h = 6;
electronics_offset = 8;
// O-rings
oring_channel_depth = 1.2;
oring_channel_width = 2;
oring_l_r_x = lid_l_r_width + 2*oring_channel_width + 6;
oring_l_r_y = lid_l_r_height + 2*oring_channel_width + 6;
oring_f_b_x = lid_f_b_width + 2*oring_channel_width + 6;
oring_f_b_y = lid_f_b_height + 2*oring_channel_width + 6;
oring_t_b_x = lid_t_b_width + 2*oring_channel_width + 6;
oring_t_b_y = lid_t_b_height + 2*oring_channel_width + 6;
// Mortise joint
mortise_joint_height = 20;
mortise_joint_dia = 6;
mortise_joint_cone_height = 5;
// Dimensions battery holder
battery_holder_width = 53.5;
battery_holder_depth = 50.5;
battery_holder_height = 13;
battery_holder_hole_dis_x = 12.5;
battery_holder_hole_dis_y = 36.5;
battery_holder_pos_x = battery_holder_hole_dis_x/2;
battery_holder_pos_y = -battery_holder_hole_dis_y/2;

21786
cad/mechanics_rev4/housing/lid_back.stl

File diff suppressed because it is too large

75
cad/mechanics_rev4/housing/lid_f_b.scad

@ -0,0 +1,75 @@
/////////////////////////////////////////////////////////////////////////////////
// Module for the front and back lid.
//
// Author: Maximilian Stiefel
// Last modification: 28.07.2017
/////////////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////////
// Includes
/////////////////////////////////////////////////////////////////////////////////
// Dimesnions
include <dimensions.scad>
use <dimensions.scad>
// Module to make a nice round box
include <roundy.scad>
use <roundy.scad>
// Module for screw holes
include <screw_holes.scad>
use <screw_holes.scad>
// Module for screw holes
include <screw_sinkings.scad>
use <screw_sinkings.scad>
module lid_f_b(logo, mounting)
{
/////////////////////////////////////////////////////////////////////////
// Vars
/////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////
// Action
/////////////////////////////////////////////////////////////////////////
translate([0, 0, -lids_depth/2])
rotate([180, 0, 0])
difference()
{
// Main body for the lid
union()
{
// Actual lid
cube([lid_f_b_x - allowance05, lid_f_b_y - allowance05, lids_depth], center = true);
translate([0, 0, housing_thickness/2 - 0.01])
cube([lid_f_b_width - allowance05, lid_f_b_height - allowance05, housing_thickness - lids_depth], center = true);
// Mounting cylinders
translate([0, -electronics_offset, (housing_thickness - lids_depth/2 + motherboard_mounting_h/2 - 0.01)])
screw_holes(motherboard_mounting_x, motherboard_mounting_y, motherboard_mounting_d, mounting*motherboard_mounting_h);
}
union()
{
// Cut out cylindric holes for screws to mount the lid on the housing
screw_holes(lid_f_b_holes_x, lid_f_b_holes_y, drill_dia_m3, 2*lids_depth);
// Cut out sinking holes
translate([0, 0, -lids_depth/2 + drill_sinking_height_m3/2 + 0.5])
screw_sinkings(lid_f_b_holes_x, lid_f_b_holes_y, drill_sinking_dia1_m3, drill_sinking_dia2_m3, drill_sinking_height_m3);
// Cut out drill holes in mounting cylinders
translate([0, -electronics_offset, (housing_thickness - lids_depth/2 + motherboard_mounting_h/2 - 0.01)])
screw_holes(motherboard_mounting_x, motherboard_mounting_y, drill_thread_dia_m3, mounting*(motherboard_mounting_h + 1) );
// Logo
// Can be turned off by setting logo to 0
translate([-47.5, 15, -lids_depth/2 - 0.01 + 3])
rotate([180, 0, 0])
linear_extrude(height = logo*3)
scale(0.95)
import("logo.dxf");
}
}
}

44270
cad/mechanics_rev4/housing/lid_front.stl

File diff suppressed because it is too large

62
cad/mechanics_rev4/housing/lid_l_r.scad

@ -0,0 +1,62 @@
/////////////////////////////////////////////////////////////////////////////////
// Module for the left and right lid.
//
// Author: Maximilian Stiefel
// Last modification: 28.07.2017
/////////////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////////
// Includes
/////////////////////////////////////////////////////////////////////////////////
// Dimesnions
include <dimensions.scad>
use <dimensions.scad>
// Module to make a nice round box
include <roundy.scad>
use <roundy.scad>
// Module for screw holes
include <screw_holes.scad>
use <screw_holes.scad>
// Module for screw holes
include <screw_sinkings.scad>
use <screw_sinkings.scad>
module lid_l_r()
{
/////////////////////////////////////////////////////////////////////////
// Vars
/////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////
// Action
/////////////////////////////////////////////////////////////////////////
rotate([0, 90, 0])
translate([0, 0, -lids_depth/2])
rotate([180, 0, 0])
difference()
{
// Main body for the lid
union()
{
roundy(lid_l_r_x - allowance05, lid_l_r_y - allowance05, lids_depth);
translate([0, 0, housing_thickness/2 -0.01])
cube([lid_l_r_height - allowance05, lid_l_r_width - allowance05, housing_thickness - lids_depth], center = true);
echo(housing_thickness=housing_thickness);
echo(lids_depth=lids_depth);
}
union()
{
// Cut out cylindric holes
screw_holes(lid_l_r_holes_y, lid_l_r_holes_x, drill_dia_m3, 2*lids_depth);
translate([0, 0, -lids_depth/2 + drill_sinking_height_m3/2 + 0.5])
screw_sinkings(lid_l_r_holes_y, lid_l_r_holes_x, drill_sinking_dia1_m3, drill_sinking_dia2_m3, drill_sinking_height_m3);
}
}
}

15654
cad/mechanics_rev4/housing/lid_left.stl

File diff suppressed because it is too large

15654
cad/mechanics_rev4/housing/lid_right.stl

File diff suppressed because it is too large

59
cad/mechanics_rev4/housing/lid_t_b.scad

@ -0,0 +1,59 @@
/////////////////////////////////////////////////////////////////////////////////
// Module for the top and bottom lid.
//
// Author: Maximilian Stiefel
// Last modification: 28.07.2017
/////////////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////////
// Includes
/////////////////////////////////////////////////////////////////////////////////
// Dimesnions
include <dimensions.scad>
use <dimensions.scad>
// Module to make a nice round box
include <roundy.scad>
use <roundy.scad>
// Module for screw holes
include <screw_holes.scad>
use <screw_holes.scad>
// Module for screw holes
include <screw_sinkings.scad>
use <screw_sinkings.scad>
module lid_t_b()
{
/////////////////////////////////////////////////////////////////////////
// Vars
/////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////
// Action
/////////////////////////////////////////////////////////////////////////
translate([0, 0, -lids_depth/2])
rotate([180, 0, 0])
difference()
{
// Main body for the lid
union()
{
roundy(lid_t_b_x - allowance05, lid_t_b_y - allowance05, lids_depth);
translate([0, 0, housing_thickness/2 - 0.01])
cube([lid_t_b_width - allowance05, lid_t_b_height - allowance05, housing_thickness - lids_depth], center = true);
}
union()
{
// Cut out cylindric holes
screw_holes(lid_t_b_holes_x, lid_t_b_holes_y, drill_dia_m3, 2*lids_depth);
translate([0, 0, -lids_depth/2 + drill_sinking_height_m3/2 + 0.5])
screw_sinkings(lid_t_b_holes_x, lid_t_b_holes_y, drill_sinking_dia1_m3, drill_sinking_dia2_m3, drill_sinking_height_m3);
}
}
}

15682
cad/mechanics_rev4/housing/lid_top.stl

File diff suppressed because it is too large

9702
cad/mechanics_rev4/housing/logo.dxf

File diff suppressed because it is too large

BIN
cad/mechanics_rev4/housing/logo.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 211 KiB

75
cad/mechanics_rev4/housing/main.scad

@ -0,0 +1,75 @@
/////////////////////////////////////////////////////////////////////////////////
// Main file to assemble everything.
//
// Author: Maximilian Stiefel
// Last modification: 20.07.2017
/////////////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////////
// Includes
/////////////////////////////////////////////////////////////////////////////////
// Dimesnions
include <dimensions.scad>
use <dimensions.scad>
// Module for raw box without any lids
include <box.scad>
use <box.scad>
// Module for raw box without any lids
include <lid_l_r.scad>
use <lid_l_r.scad>
// Module for raw box without any lids
include <lid_f_b.scad>
use <lid_f_b.scad>
// Module for raw box without any lids
include <lid_t_b.scad>
use <lid_t_b.scad>
////////////////////////////////////////////////////////////////////////////////
// Vars
/////////////////////////////////////////////////////////////////////////////////
// 0 = put lids, 1 = remove lids
close = 0;
// Set minimum angle of a fragment
$fa = 0.5;
// Set minimum size of a fragment
$fs = 0.5;
////////////////////////////////////////////////////////////////////////////////
// Action
/////////////////////////////////////////////////////////////////////////////////
//difference()
//{
union()
{
color(myColor1)
{
// Lid right
translate([housing_outside_width/2 + close*20, 0, 0])
lid_l_r();
// Lid left
translate([-housing_outside_width/2 - close*20, 0, 0])
rotate([0, 180, 0])
lid_l_r();
// Lid front
translate([0, -housing_outside_depth/2 - close*20, 0])
rotate([90, 0, 0])
lid_f_b(1,0);
// Lid back
translate([0, +housing_outside_depth/2 + close*20, 0])
rotate([-90, 180, 0])
lid_f_b(0,1);
color(myColor1, 0.8)
box();
}
//translate([-200, 0, 0])
//cube([400,400,400], center=true);
//}

41
cad/mechanics_rev4/housing/open_box.scad

@ -0,0 +1,41 @@
/////////////////////////////////////////////////////////////////////////////////
// Module for a open box with rounded edges.
//
// Author: Maximilian Stiefel
// Last modification: 26.04.2017
/////////////////////////////////////////////////////////////////////////////////
module open_box(width, length, height, thickness)
{
/////////////////////////////////////////////////////////////////////////
// Vars
/////////////////////////////////////////////////////////////////////////
edge_rounding = 8;
compensation = 2*abs(edge_rounding-thickness);
/////////////////////////////////////////////////////////////////////////
// Action
/////////////////////////////////////////////////////////////////////////
translate([0, 0, 0]) difference(){
// Hull 4 cylinders which are compensated against the thickness
// so the actual desired thickness/2 and edge rounding is always achieved.
hull(){
// x=0, y=0
translate([edge_rounding, edge_rounding, 0])
cylinder(r = edge_rounding, h = height + thickness);
// x=width, y=0
translate([width + edge_rounding - compensation, edge_rounding, 0])
cylinder(r = edge_rounding, h = height + thickness);
// x=0, y=length
translate([edge_rounding, length + edge_rounding - compensation,0])
cylinder(r = edge_rounding, h = height + thickness);
//x=width, y=length
translate([width + edge_rounding - compensation, length + edge_rounding - compensation,0])
cylinder(r = edge_rounding, h = height + thickness);
}
translate([thickness, thickness, thickness])
cube([width, length, height + 1]);
}
}

31
cad/mechanics_rev4/housing/oring.scad

@ -0,0 +1,31 @@
/////////////////////////////////////////////////////////////////////////////////
// Module for oring deepnings.
//
// Author: Maximilian Stiefel
// Last modification: 28.07.2017
/////////////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////////
// Includes
/////////////////////////////////////////////////////////////////////////////////
// Module to make a nice round box
include <roundy.scad>
use <roundy.scad>
module oring(xdim, ydim, channel_width, channel_depth)
{
/////////////////////////////////////////////////////////////////////////
// Vars
/////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////
// Action
/////////////////////////////////////////////////////////////////////////
difference()
{
roundy(xdim, ydim, channel_depth + 0.1);
roundy(xdim - 2*channel_width, ydim - 2*channel_width, channel_depth + 0.15);
}
}

30
cad/mechanics_rev4/housing/roundy.scad

@ -0,0 +1,30 @@
/////////////////////////////////////////////////////////////////////////////////
// Module for a open box with rounded edges.
//
// Author: Maximilian Stiefel
// Last modification: 26.04.2017
/////////////////////////////////////////////////////////////////////////////////
module roundy(width, depth, height, center)
{
/////////////////////////////////////////////////////////////////////////
// Vars
/////////////////////////////////////////////////////////////////////////
edge_rounding = 5;
transx = -width/2;
transy = -depth/2;
transz = -height/2;
/////////////////////////////////////////////////////////////////////////
// Action
/////////////////////////////////////////////////////////////////////////
// Hull 4 cylinders
// The thickness of the cylinders (edge_rounding) is compensated
//translate([transx, transy, transz])
hull(){
for(x=[-1, +1])
for(y=[-1, +1])
translate([x*width/2 + -x*edge_rounding, y*depth/2 + -y*edge_rounding, 0])
cylinder(r = edge_rounding, h = height, center =true);
}
}

BIN
cad/mechanics_rev4/housing/screenshot_closed.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 43 KiB

BIN
cad/mechanics_rev4/housing/screenshot_cut_closed.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 22 KiB

BIN
cad/mechanics_rev4/housing/screenshot_cut_open.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 34 KiB

BIN
cad/mechanics_rev4/housing/screenshot_open.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 43 KiB

24
cad/mechanics_rev4/housing/screw_holes.scad

@ -0,0 +1,24 @@
/////////////////////////////////////////////////////////////////////////////////
// Module for four holes along a rectangle for screw threads.
//
// Author: Maximilian Stiefel
// Last modification: 09.07.2017
/////////////////////////////////////////////////////////////////////////////////
module screw_holes(xdim, ydim, dia, depth)
{
/////////////////////////////////////////////////////////////////////////
// Vars
/////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////
// Action
/////////////////////////////////////////////////////////////////////////
union(){
for(x=[-1, +1])
for(y=[-1, +1])
translate([x*xdim/2, y*ydim/2, 0])
cylinder(r = dia/2, h = depth, center =true);
}
}

30
cad/mechanics_rev4/housing/screw_sinkings.scad

@ -0,0 +1,30 @@
/////////////////////////////////////////////////////////////////////////////////
// Module for four sinking holes, that cone-shaped screw heads can sink in.
//
// Author: Maximilian Stiefel
// Last modification: 09.07.2017
/////////////////////////////////////////////////////////////////////////////////
module screw_sinkings(xdim, ydim, dia1, dia2, depth)
{
/////////////////////////////////////////////////////////////////////////
// Vars
/////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////
// Action
/////////////////////////////////////////////////////////////////////////
union(){
for(x=[-1, +1])
for(y=[-1, +1])
translate([x*xdim/2, y*ydim/2, 0])
union()
{
translate([0, 0, -depth + 0.1])
cylinder(r = dia1/2, h = depth, center = true);
cylinder(r1 = dia1/2, r2 = dia2/2, h = depth, center = true);
}
}
}

39
cad/mechanics_rev4/pcb/dimensions.scad

@ -0,0 +1,39 @@
/////////////////////////////////////////////////////////////////////////////////
// File for all dimensions, so they can be changed globally.
//
// Author: Maximilian Stiefel
// Last modification: 29.07.2017
/////////////////////////////////////////////////////////////////////////////////
allowance05 = 0.5;
// Glass dimensions
glass_slide_height = 1;
glass_slide_depth = 26 + allowance05;
glass_slide_width = 76;
// Holder dimensions
window_size = 20;
holder_height = 3 + glass_slide_height + allowance05;
holder_depth = glass_slide_depth + allowance05 + 4;
holder_width = 80; // Width of the PCB
echo(holder_height=holder_height);
// LED illuminator dimensions
led_illuminator_dia = 10;
led_illuminator_height = 15;
led_pos_x = 18;
led_pos_y = 13;
led_illuminator_thickness = 2;
led_illuminator_slot = 4;
led_illuminator_angle = 35;
leg_outer_dia = 5;
leg_inner_dia = 2.5;
leg_height = led_illuminator_height;
leg_pos_y = 13;
leg_pos_x = 2.5;
leg_distance = 6.5;
leg_drill_depth = 7;
myColor1 = "LimeGreen";

43
cad/mechanics_rev4/pcb/glass_holder.scad

@ -0,0 +1,43 @@
/////////////////////////////////////////////////////////////////////////////////
// Glass slide holder to be mounted on the PCB.
//
// Author: Maximilian Stiefel
// Last modification: 29.06.2017
/////////////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////////
// Includes
/////////////////////////////////////////////////////////////////////////////////
// Dimesnions
include <dimensions.scad>
use <dimensions.scad>
/////////////////////////////////////////////////////////////////////////////////
// Vars
/////////////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////////
// Action
/////////////////////////////////////////////////////////////////////////////////
module glass_holder()
{
translate([0, 0, holder_height/2 + leg_height -0.01])
difference()
{
// Main body
cube([holder_width, holder_depth, holder_height], center = true);
union()
{
// Cut glass slide out and make an entrance
translate([-2.5, 0, 2])
cube([glass_slide_width + allowance05 + 5, glass_slide_depth + allowance05, holder_height], center = true);
// Cut out a cylinder for the LED
translate([glass_slide_width/2 - led_pos_x, 0, 0])
cylinder(r = led_illuminator_dia/2, h = 20, center = true);
// Cut out a "window" where the receiver photodiode is sitting
translate([glass_slide_width/2 - led_pos_x, glass_slide_depth/2, 2])
cube([window_size, 10, 10], center = true);
}
}
}

BIN
cad/mechanics_rev4/pcb/glass_slide_holder.jpg

Binary file not shown.

After

Width:  |  Height:  |  Size: 25 KiB

10614
cad/mechanics_rev4/pcb/glass_slide_holder.stl

File diff suppressed because it is too large

40
cad/mechanics_rev4/pcb/led_illuminator.scad

@ -0,0 +1,40 @@
/////////////////////////////////////////////////////////////////////////////////
// Illuminator for LED to keep the UV light away from the photodiode.
//
// Author: Maximilian Stiefel
// Last modification: 29.06.2017
/////////////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////////
// Includes
/////////////////////////////////////////////////////////////////////////////////
// Dimesnions
include <dimensions.scad>
use <dimensions.scad>
/////////////////////////////////////////////////////////////////////////////////
// Vars
/////////////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////////
// Action
/////////////////////////////////////////////////////////////////////////////////
module illuminator()
{
translate([glass_slide_width/2 - led_pos_x, 0, led_illuminator_height/2 + 0.01])
difference()
{
cylinder(r = led_illuminator_dia/2 + led_illuminator_thickness, led_illuminator_height, center = true);
union()
{
// Cut out inner cylinder
cylinder(r = led_illuminator_dia/2, led_illuminator_height + 0.01, center = true);
// Cut out slot
rotate([0, 0, led_illuminator_angle + 180])
translate([led_illuminator_dia/2, 0, -led_illuminator_height/2 - 0.01])
cube([led_illuminator_dia/2, led_illuminator_slot, led_illuminator_height], center = true);
}
}
}

52
cad/mechanics_rev4/pcb/legs.scad

@ -0,0 +1,52 @@
/////////////////////////////////////////////////////////////////////////////////
// Legs for the glass slide holder.
//
// Author: Maximilian Stiefel
// Last modification: 29.06.2017
/////////////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////////
// Includes
/////////////////////////////////////////////////////////////////////////////////
// Dimesnions
include <dimensions.scad>
use <dimensions.scad>
/////////////////////////////////////////////////////////////////////////////////
// Vars
/////////////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////////
// Action
/////////////////////////////////////////////////////////////////////////////////
module legs()
{
difference()
{
union()
{
// Legs at the left
for(y = [0, 1])
translate([glass_slide_width/2 - leg_pos_x, -y*leg_distance,0])
cylinder(r = leg_outer_dia/2, h = leg_height);
// Legs at the right
for(y = [0, 1])
translate([-glass_slide_width/2 + leg_pos_x, y*leg_distance, 0])
cylinder(r = leg_outer_dia/2, h = leg_height);
}
union()
{
// Legs at the left
for(y = [0, 1])
translate([glass_slide_width/2 - leg_pos_x, -y*leg_distance, -0.01])
cylinder(r = leg_inner_dia/2, h = leg_drill_depth);
// Legs at the right
for(y = [0, 1])
translate([-glass_slide_width/2 + leg_pos_x, y*leg_distance, -0.01])
cylinder(r = leg_inner_dia/2, h = leg_drill_depth);
}
}
}

42
cad/mechanics_rev4/pcb/main.scad

@ -0,0 +1,42 @@
/////////////////////////////////////////////////////////////////////////////////
// Main file to bring everything together.
//
// Author: Maximilian Stiefel
// Last modification: 29.06.2017
/////////////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////////
// Includes
/////////////////////////////////////////////////////////////////////////////////
// Dimesnions
include <dimensions.scad>
use <dimensions.scad>
// Module for the glass holder
include <glass_hollder.scad>
use <glass_holder.scad>
// Module for the legs
include <legs.scad>
use <legs.scad>
// Module for the legs
include <led_illuminator.scad>
use <led_illuminator.scad>
/////////////////////////////////////////////////////////////////////////////////
// Vars
/////////////////////////////////////////////////////////////////////////////////
$fa = 0.5; // minimum facet angle is now 0.5
$fs = 0.5; // minimum facet size is now 0.5 mm
/////////////////////////////////////////////////////////////////////////////////
// Action
/////////////////////////////////////////////////////////////////////////////////
color(myColor1)
{
glass_holder();
legs();
illuminator();
}

6729
pcbs/analog_board_v0.2/_autosave-analog_board_v0.2.kicad_pcb

File diff suppressed because it is too large

26
pcbs/analog_board_v0.2/analog_board_v0.2.kicad_pcb

@ -5,7 +5,7 @@
(no_connects 0)
(area 68.642858 46.15 215.357144 148.850001)
(thickness 1.6)
(drawings 54)
(drawings 52)
(tracks 364)
(zones 0)
(modules 238)
@ -4676,30 +4676,6 @@
)
)
(dimension 13 (width 0.3) (layer Dwgs.User)
(gr_text "13,000 mm" (at 166.6 116.5 270) (layer Dwgs.User)
(effects (font (size 1.5 1.5) (thickness 0.3)))
)
(feature1 (pts (xy 180.5 123) (xy 167.5 123)))
(feature2 (pts (xy 180.5 110) (xy 167.5 110)))
(crossbar (pts (xy 170.2 110) (xy 170.2 123)))
(arrow1a (pts (xy 170.2 123) (xy 169.613579 121.873496)))
(arrow1b (pts (xy 170.2 123) (xy 170.786421 121.873496)))
(arrow2a (pts (xy 170.2 110) (xy 169.613579 111.126504)))
(arrow2b (pts (xy 170.2 110) (xy 170.786421 111.126504)))
)
(dimension 6.4 (width 0.3) (layer Dwgs.User)
(gr_text "6,400 mm" (at 173.7 117.1 270) (layer Dwgs.User)
(effects (font (size 1.5 1.5) (thickness 0.3)))
)
(feature1 (pts (xy 180.5 123) (xy 175.100001 123)))
(feature2 (pts (xy 180.5 116.6) (xy 175.100001 116.6)))
(crossbar (pts (xy 177.800001 116.6) (xy 177.800001 123)))
(arrow1a (pts (xy 177.800001 123) (xy 177.21358 121.873496)))
(arrow1b (pts (xy 177.800001 123) (xy 178.386422 121.873496)))
(arrow2a (pts (xy 177.800001 116.6) (xy 177.21358 117.726504)))
(arrow2b (pts (xy 177.800001 116.6) (xy 178.386422 117.726504)))
)
(gr_text <1 (at 136.3345 124.587) (layer F.SilkS)
(effects (font (size 1.5 1.5) (thickness 0.3)))
)

30
pcbs/analog_board_v0.2/analog_board_v0.2.kicad_pcb-bak

@ -1,11 +1,11 @@
(kicad_pcb (version 4) (host pcbnew 4.0.6-e0-6349~52~ubuntu17.04.1)
(kicad_pcb (version 4) (host pcbnew 4.0.7-e0-6372~58~ubuntu17.04.1)
(general
(links 300)
(no_connects 0)
(area 68.642858 46.15 215.357144 148.850001)
(thickness 1.6)
(drawings 52)
(drawings 54)
(tracks 364)
(zones 0)
(modules 238)
@ -31,7 +31,7 @@
(37 F.SilkS user)
(38 B.Mask user)
(39 F.Mask user hide)
(40 Dwgs.User user hide)
(40 Dwgs.User user)
(41 Cmts.User user)
(42 Eco1.User user)
(43 Eco2.User user)
@ -4676,6 +4676,30 @@
)
)
(dimension 13 (width 0.3) (layer Dwgs.User)
(gr_text "13,000 mm" (at 166.6 116.5 270) (layer Dwgs.User)
(effects (font (size 1.5 1.5) (thickness 0.3)))
)
(feature1 (pts (xy 180.5 123) (xy 167.5 123)))
(feature2 (pts (xy 180.5 110) (xy 167.5 110)))
(crossbar (pts (xy 170.2 110) (xy 170.2 123)))
(arrow1a (pts (xy 170.2 123) (xy 169.613579 121.873496)))
(arrow1b (pts (xy 170.2 123) (xy 170.786421 121.873496)))
(arrow2a (pts (xy 170.2 110) (xy 169.613579 111.126504)))
(arrow2b (pts (xy 170.2 110) (xy 170.786421 111.126504)))
)
(dimension 6.4 (width 0.3) (layer Dwgs.User)
(gr_text "6,400 mm" (at 173.7 117.1 270) (layer Dwgs.User)
(effects (font (size 1.5 1.5) (thickness 0.3)))
)
(feature1 (pts (xy 180.5 123) (xy 175.100001 123)))
(feature2 (pts (xy 180.5 116.6) (xy 175.100001 116.6)))
(crossbar (pts (xy 177.800001 116.6) (xy 177.800001 123)))
(arrow1a (pts (xy 177.800001 123) (xy 177.21358 121.873496)))
(arrow1b (pts (xy 177.800001 123) (xy 178.386422 121.873496)))
(arrow2a (pts (xy 177.800001 116.6) (xy 177.21358 117.726504)))
(arrow2b (pts (xy 177.800001 116.6) (xy 178.386422 117.726504)))
)
(gr_text <1 (at 136.3345 124.587) (layer F.SilkS)
(effects (font (size 1.5 1.5) (thickness 0.3)))
)

4
pcbs/analog_board_v0.22/analog_board_v0.22.bak

@ -120,9 +120,9 @@ $EndComp
Wire Wire Line
4825 3025 4625 3025
Wire Wire Line
4625 2875 4625 3025
4625 3025 4625 2875
Wire Wire Line
4125 2875 4625 2875
4625 2875 4125 2875
Wire Wire Line
7675 3025 6525 3025
Wire Wire Line

Loading…
Cancel
Save