My self-made 3D-printable designs, mainly in OpenSCAD
Ви не можете вибрати більше 25 тем Теми мають розпочинатися з літери або цифри, можуть містити дефіси (-) і не повинні перевищувати 35 символів.

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202
  1. include <roundedcube.scad>
  2. $fn = 50;
  3. rail_width = 21.0 + 0.2;
  4. rail_height = 6.0 + 0.2 + 2;
  5. rail_lip_width_small = 1.5 - 0.2;
  6. rail_lip_width_big = 3.5 - 0.2;
  7. rail_lip_height = 1.1 - 0.1;
  8. module rail_lip(l) {
  9. hull() {
  10. translate([-1, -0.1, 0])
  11. cube([l + 2, 0.2, rail_lip_width_big]);
  12. translate([-1, rail_lip_height - 0.1, (rail_lip_width_big - rail_lip_width_small) / 2])
  13. cube([l + 2, 0.1, rail_lip_width_small]);
  14. }
  15. }
  16. module rail(l) {
  17. difference() {
  18. cube([l, rail_width, rail_height]);
  19. translate([0, 0, rail_height - rail_lip_width_big]) {
  20. rail_lip(l);
  21. translate([l, rail_width, 0])
  22. rotate([0, 0, 180])
  23. rail_lip(l);
  24. }
  25. }
  26. }
  27. laser_dia = 6.5;
  28. laser_len = 14.0;
  29. module laser() {
  30. cylinder(d = laser_dia, h = laser_len);
  31. }
  32. frame_gap = 0.2;
  33. frame_sphere = 20;
  34. frame_add_touch = 4.0;
  35. frame_wall = 1.5;
  36. frame_mount_hole = 2.0;
  37. frame_mid_len = frame_mount_hole + (2 * frame_wall);
  38. frame_mid_dia = laser_dia + (2 * frame_wall);
  39. frame_tail_len = 8.0;
  40. frame_tail_width = frame_mid_dia + 0.5;
  41. frame_negative_width = frame_sphere * 2 / 3 + 7;
  42. frame_hole_dia = 2.9;
  43. frame_hole_off = 1.8;
  44. frame_hole_neg_off = 10;
  45. frame_hole_neg_len = 15;
  46. frame_hole_neg_deg_a = 9;
  47. frame_hole_neg_deg_b = frame_hole_neg_deg_a;
  48. frame_hole_neg_rad_small = frame_mid_len + ((frame_sphere + frame_tail_len) / 2) - frame_hole_off;
  49. frame_hole_neg_rad_large = frame_mid_len + ((frame_sphere + frame_tail_len) / 2) + frame_hole_off;
  50. frame_len = frame_sphere + frame_mid_len + frame_tail_len;
  51. module laser_frame_screw_arc(radius, deg) {
  52. for (r = [-deg : 1 : deg])
  53. translate([radius, 0, 0])
  54. rotate([0, 0, r])
  55. translate([-radius, 0, 0])
  56. cylinder(d = frame_hole_dia, h = frame_negative_width + frame_hole_neg_len);
  57. }
  58. module laser_frame(added_gap = 0, negative = 0) {
  59. difference() {
  60. union() {
  61. translate([0, 0, (frame_sphere / 2) + (frame_len - frame_sphere)])
  62. sphere(d = frame_sphere + added_gap);
  63. if (negative == 0) {
  64. translate([0, 0, frame_len - frame_sphere - frame_mid_len - 0.5])
  65. cylinder(d = frame_mid_dia + added_gap, h = frame_mid_len + frame_add_touch + 1.0);
  66. translate([-(frame_tail_width + added_gap) / 2, -(frame_tail_width + added_gap) / 2, frame_len - frame_sphere - frame_mid_len - frame_tail_len])
  67. roundedcube([frame_tail_width + added_gap, frame_tail_width + added_gap, frame_tail_len]);
  68. } else {
  69. translate([0, 0, frame_len - frame_add_touch])
  70. cylinder(d = laser_dia + added_gap, h = frame_mid_len + frame_add_touch);
  71. translate([-frame_negative_width / 2, -frame_negative_width / 2, frame_len - frame_sphere - frame_mid_len - frame_tail_len - (added_gap * 3) - 1])
  72. cube([frame_negative_width, frame_negative_width, frame_len - frame_sphere + frame_add_touch + (added_gap * 3) + 1]);
  73. translate([-frame_hole_neg_off + frame_negative_width + frame_hole_neg_len, 0, frame_len - frame_sphere - frame_mid_len - frame_tail_len + (frame_tail_len / 2) - frame_hole_off])
  74. rotate([0, -90, 0])
  75. laser_frame_screw_arc(frame_hole_neg_rad_large, frame_hole_neg_deg_a);
  76. translate([0, -frame_hole_neg_off, frame_len - frame_sphere - frame_mid_len - frame_tail_len + (frame_tail_len / 2) + frame_hole_off])
  77. rotate([-90, -90, 0])
  78. laser_frame_screw_arc(frame_hole_neg_rad_small, frame_hole_neg_deg_b);
  79. }
  80. }
  81. if (negative == 0) {
  82. translate([0, 0, -1])
  83. cylinder(d = laser_dia + (2 * frame_gap), h = frame_len + 2);
  84. translate([0, 0, (frame_len - frame_sphere - frame_mid_len) + (frame_mid_len / 2)])
  85. rotate([0, 90, 0]) {
  86. cylinder(d = frame_mount_hole, h = frame_mid_dia);
  87. rotate([-90, 0, 0])
  88. cylinder(d = frame_mount_hole, h = frame_mid_dia);
  89. }
  90. translate([-frame_tail_width / 2 - 1, 0, frame_len - frame_sphere - frame_mid_len - frame_tail_len + (frame_tail_len / 2) - frame_hole_off])
  91. rotate([0, 90, 0])
  92. cylinder(d = frame_hole_dia, h = frame_tail_width + 2);
  93. translate([0, -frame_tail_width / 2 - 1, frame_len - frame_sphere - frame_mid_len - frame_tail_len + (frame_tail_len / 2) + frame_hole_off])
  94. rotate([-90, 0, 0])
  95. cylinder(d = frame_hole_dia, h = frame_tail_width + 2);
  96. }
  97. }
  98. }
  99. body_width = 25.0;
  100. body_length = 45.0;
  101. body_height = 35.0;
  102. body_frame_gap = 0.5;
  103. body_frame_off = 15;
  104. body_cube_rounding = 1.0;
  105. body_hole_dia = 2.2;
  106. body_hole_off_x = 2.2;
  107. body_hole_off_z = body_hole_off_x;
  108. module body() {
  109. difference() {
  110. //cube([body_length, body_width, body_height]);
  111. roundedcube([body_length, body_width, body_height], false, body_cube_rounding);
  112. translate([-1, (body_width - rail_width) / 2, body_height - rail_height + 0.1])
  113. rail(body_length + 2);
  114. translate([body_length - frame_len, body_width / 2, body_frame_off])
  115. rotate([0, 90, 0]) {
  116. laser_frame(body_frame_gap, 1);
  117. %laser_frame();
  118. }
  119. translate([body_hole_off_x, -1, body_hole_off_z])
  120. rotate([-90, 0, 0])
  121. cylinder(d = body_hole_dia, h = body_width + 2);
  122. translate([body_length - body_hole_off_x, -1, body_hole_off_z])
  123. rotate([-90, 0, 0])
  124. cylinder(d = body_hole_dia, h = body_width + 2);
  125. translate([body_hole_off_x, -1, body_height - rail_height - body_hole_off_z])
  126. rotate([-90, 0, 0])
  127. cylinder(d = body_hole_dia, h = body_width + 2);
  128. translate([body_length - body_hole_off_x, -1, body_height - rail_height - body_hole_off_z])
  129. rotate([-90, 0, 0])
  130. cylinder(d = body_hole_dia, h = body_width + 2);
  131. translate([-1, body_width / 2, body_height / 2.35])
  132. rotate([0, 90, 0])
  133. cylinder(d = 10, h = 20);
  134. }
  135. }
  136. bodies_gap = 0.05;
  137. module body_half(half = 0) {
  138. difference() {
  139. body();
  140. if (half == 0) {
  141. translate([-1, (bodies_gap - body_width) / 2, -1])
  142. cube([body_length + 2, body_width, body_height + 2]);
  143. } else {
  144. translate([-1, (body_width - bodies_gap) / 2, -1])
  145. cube([body_length + 2, body_width, body_height + 2]);
  146. }
  147. }
  148. }
  149. module print() {
  150. translate([0, 0, body_width])
  151. rotate([-90, 0, 0])
  152. body_half(0);
  153. translate([0, body_height * 2 + 5, 0])
  154. rotate([90, 0, 0])
  155. body_half(1);
  156. translate([body_length + 10, body_height + 2, 0])
  157. laser_frame(0, 0);
  158. }
  159. //laser_frame(0, 0);
  160. //laser_frame(0.5, 1);
  161. //body_half(0);
  162. //body_half(1);
  163. //body();
  164. print();