My self-made 3D-printable designs, mainly in OpenSCAD
選択できるのは25トピックまでです。 トピックは、先頭が英数字で、英数字とダッシュ('-')を使用した35文字以内のものにしてください。

esr-case.scad 3.0KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118
  1. /*
  2. * Created by:
  3. * Thomas Buck <xythobuz@xythobuz.de> in June 2016
  4. *
  5. * Licensed under the Creative Commons - Attribution license.
  6. */
  7. // -----------------------------------------------------------
  8. width = 67;
  9. height = 67.5;
  10. hole_nub = 5;
  11. hole = 2;
  12. hole_width = 60;
  13. hole_height = 40;
  14. hole_offset_top = 3;
  15. wall_size = 1.4;
  16. depth_top = 3.6;
  17. depth_pcb = 1.6;
  18. depth_bottom = 4.1;
  19. depth_gap = 1.8;
  20. depth = depth_top + depth_pcb + depth_bottom + depth_gap;
  21. screw_nub_depth = depth_bottom + depth_gap;
  22. switch_width = 11.8;
  23. switch_height = 5.8;
  24. switch_hole = 2.2;
  25. switch_hole_dist = 15;
  26. switch_x = 2.5;
  27. switch_y = 0;
  28. cutout_width = 12;
  29. cutout_height = 2;
  30. cutout_x = 25.6;
  31. helper_disc = 5;
  32. helper_disc_height = 0.4;
  33. $fn = 20;
  34. // -----------------------------------------------------------
  35. module nub() {
  36. difference() {
  37. cylinder(d = hole_nub, h = screw_nub_depth);
  38. translate([0, 0, -1])
  39. cylinder(d = hole, h = screw_nub_depth + 2);
  40. }
  41. }
  42. module nubs() {
  43. nub();
  44. translate([hole_width, 0, 0])
  45. nub();
  46. translate([0, hole_height, 0])
  47. nub();
  48. translate([hole_width, hole_height, 0])
  49. nub();
  50. }
  51. module switch() {
  52. translate([0, 0, switch_height / 2])
  53. rotate([0, 90, 0])
  54. cylinder(d = switch_hole, h = wall_size + 2);
  55. translate([0, (switch_hole_dist - switch_width) / 2, 0])
  56. cube([wall_size + 2, switch_width, switch_height]);
  57. translate([0, switch_hole_dist, switch_height / 2])
  58. rotate([0, 90, 0])
  59. cylinder(d = switch_hole, h = wall_size + 2);
  60. }
  61. // -----------------------------------------------------------
  62. // base
  63. cube([width + (2 * wall_size), height + (2 * wall_size), wall_size]);
  64. // left wall
  65. difference() {
  66. translate([0, 0, wall_size])
  67. cube([wall_size, height + (2 * wall_size), depth]);
  68. translate([-1, wall_size + height - hole_offset_top - hole_height + hole_nub, wall_size])
  69. cube([wall_size + 2, hole_nub, hole]);
  70. translate([-1, (switch_hole / 2) + wall_size + switch_x, wall_size + switch_y])
  71. switch();
  72. }
  73. // bottom wall
  74. translate([0, 0, wall_size])
  75. cube([width + (2 * wall_size), wall_size, depth]);
  76. // right wall
  77. translate([width + wall_size, 0, wall_size])
  78. cube([wall_size, height + (2 * wall_size), depth]);
  79. // top wall
  80. difference() {
  81. translate([0, height + wall_size, wall_size])
  82. cube([width + (2 * wall_size), wall_size, depth]);
  83. translate([wall_size + cutout_x, height + wall_size - 1, wall_size + depth - cutout_height])
  84. cube([cutout_width, wall_size + 2, cutout_height + 1]);
  85. }
  86. translate([wall_size + (width - hole_width) / 2, wall_size + height - hole_height - hole_offset_top, wall_size])
  87. nubs();
  88. cylinder(d = helper_disc, h = helper_disc_height);
  89. translate([width + (2 * wall_size), height + (2 * wall_size), 0])
  90. cylinder(d = helper_disc, h = helper_disc_height);
  91. translate([0, height + (2 * wall_size), 0])
  92. cylinder(d = helper_disc, h = helper_disc_height);
  93. translate([width + (2 * wall_size), 0, 0])
  94. cylinder(d = helper_disc, h = helper_disc_height);