My self-made 3D-printable designs, mainly in OpenSCAD
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

valve-mount.scad 3.0KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126
  1. width = 20;
  2. height = 20;
  3. hole_dia = 4.4;
  4. hole_off = 25.4 / 2;
  5. hole_angle = 45;
  6. ground_height = 10 + 5;
  7. dist = 1;
  8. wall = 3;
  9. base_depth = 25;
  10. support_l = 5;
  11. add_width = 7;
  12. add_height = 7;
  13. add_support = 3;
  14. section_gap_height = 10;
  15. section_gap_part = 5;
  16. valve_count = 2;
  17. $fn = 42;
  18. w = width + add_width;
  19. h = height + ground_height + add_height;
  20. l_all = valve_count * w + (valve_count - 1) * dist;
  21. module prism(l, w, h) {
  22. polyhedron(
  23. points = [[0,0,0], [l,0,0], [l,w,0], [0,w,0], [0,w,h], [l,w,h]],
  24. faces = [[0,1,2,3],[5,4,3,2],[0,4,5,1],[0,3,4],[5,2,1]]
  25. );
  26. }
  27. module gap(l, w, h, p) {
  28. difference() {
  29. translate([-0.001, 0.001, 0])
  30. cube([l + 0.002, w + 0.001, h]);
  31. translate([-1, w, h])
  32. rotate([180, 0, 0])
  33. prism(l + 2, w, h / 2 - p / 2);
  34. translate([-1, 0, h / 2 - p / 2])
  35. rotate([-90, 0, 0])
  36. prism(l + 2, h / 2 - p / 2, w);
  37. }
  38. }
  39. module strengthening(l) {
  40. difference() {
  41. translate([0, wall, h - height - add_height + wall])
  42. cube([l, add_support, height + add_height]);
  43. translate([0, wall, wall + h - section_gap_height / 2 - (height + add_height) / 2])
  44. gap(l, add_support, section_gap_height, section_gap_part);
  45. }
  46. translate([0, wall + add_support, h - height - add_height + wall])
  47. rotate([180, 0, 0])
  48. prism(l, add_support, add_support);
  49. }
  50. module section(l) {
  51. translate([0, 0, wall])
  52. cube([l, wall, h]);
  53. cube([l, base_depth, wall]);
  54. translate([l, wall + support_l, wall])
  55. rotate([0, 0, 180])
  56. prism(l, support_l, support_l);
  57. translate([l, wall, 0])
  58. rotate([0, 0, 180])
  59. strengthening(l);
  60. }
  61. module holes() {
  62. rotate([0, hole_angle, 0]) {
  63. translate([-hole_off, -add_support, 0])
  64. rotate([-90, 0, 0])
  65. cylinder(d = hole_dia, h = wall + add_support + 2);
  66. translate([hole_off, -add_support, 0])
  67. rotate([-90, 0, 0])
  68. cylinder(d = hole_dia, h = wall + add_support + 2);
  69. }
  70. }
  71. module valve() {
  72. difference() {
  73. translate([0, 0, -wall])
  74. section(w);
  75. translate([w / 2, -1, ground_height + (add_height + height) / 2]) {
  76. //holes();
  77. scale([-1, 1, 1])
  78. holes();
  79. }
  80. }
  81. }
  82. module all_valves() {
  83. difference() {
  84. translate([0, 0, wall])
  85. for (i = [0 : valve_count - 1]) {
  86. if (i == 0) {
  87. translate([i * w, 0, 0])
  88. valve();
  89. } else {
  90. translate([i * w + (i - 1) * dist, 0, -wall])
  91. section(dist);
  92. translate([i * w + (i - 1) * dist + dist, 0, 0])
  93. valve();
  94. }
  95. }
  96. for (i = [0 : valve_count - 1]) {
  97. translate([i * w + (i - 1) * dist + dist + w / 2, wall + support_l + (base_depth - wall - support_l) / 2, -1])
  98. cylinder(d = hole_dia, h = wall + 2);
  99. }
  100. }
  101. }
  102. //rotate([0, -90, 0])
  103. all_valves();