My self designed awesome 3D printer
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.

xyRepRap.scad 21KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613
  1. // #######################################################
  2. // ################## Config Parameters ##################
  3. // #######################################################
  4. slot = 30; // or 20
  5. slot_off = 1; // distance between adjacent slots
  6. // print area / volume
  7. heatbed_width = 400;
  8. heatbed_length = 400;
  9. heatbed_height = 6;
  10. // distance between heatbed edge and inner t-slot frame edge
  11. frame_off_x = 20;
  12. frame_off_y = 20;
  13. outer_width = heatbed_width + (2 * (slot + frame_off_x));
  14. outer_length = heatbed_length + (2 * (slot + frame_off_y));
  15. // TODO depend on print area height
  16. outer_height = 500;
  17. rail_mount_dist = 12;
  18. y_carriage_pos = 175;
  19. x_carriage_pos = 180;
  20. // distance between heatbed and z-carriage frame
  21. bed_x_off = 20;
  22. bed_y_off = 20;
  23. bed_z_dist = 30;
  24. // display heatbed centered in print volume
  25. bed_draw_height = (outer_height - heatbed_height) / 2; // + 175;
  26. show_outer_frame = true;
  27. show_extruders = false;
  28. show_z_motion = true;
  29. show_heatbed_frame = true;
  30. show_heatbed = true;
  31. show_xy_motion = true;
  32. show_x_carriage = false;
  33. show_belts = false;
  34. echo(print_x=heatbed_width, print_y=heatbed_length);
  35. echo(frame_x=outer_width, frame_y=outer_length, frame_z=outer_height);
  36. // #######################################################
  37. // ###################### Libraries ######################
  38. // #######################################################
  39. include <lib/tslot_xy.scad>
  40. include <lib/nema.scad>
  41. include <lib/Belt_Generator.scad>
  42. include <lib/Pulley_T-MXL-XL-HTD-GT2_N-tooth.scad>
  43. include <lib/bearing_idler.scad>
  44. include <lib/rail_mount.scad>
  45. include <lib/linear_bearing.scad>
  46. include <lib/extruder.scad>
  47. module gt2_belt(length) {
  48. if (show_belts) {
  49. difference() {
  50. belting("straight", "GT2_2mm", belt_length = length);
  51. translate([-5, -5, 6])
  52. cube([length + 10, 10, 10]);
  53. }
  54. }
  55. }
  56. // #######################################################
  57. // ######################## Frame ########################
  58. // #######################################################
  59. module slot_angle_connector() {
  60. color("gray")
  61. translate([slot, 0, 0])
  62. rotate([0, -90, 0])
  63. difference() {
  64. cube([slot, slot, slot]);
  65. translate([0, -5, 0])
  66. rotate([0, 45, 0])
  67. cube([2 * slot, 2 * slot, 2 * slot]);
  68. }
  69. }
  70. module foot() {
  71. color("yellow")
  72. translate([0, 0, 10])
  73. cylinder(d = 6, h = 20);
  74. color("yellow")
  75. difference() {
  76. sphere(d = 20);
  77. translate([-15, -15, -30])
  78. cube([30, 30, 30]);
  79. }
  80. }
  81. module lower_frame(double) {
  82. if (double) {
  83. translate([slot + slot_off, 0, slot])
  84. rotate([-90, 0, 0])
  85. tslot_2_x(slot, outer_width - (2 * (slot + slot_off)));
  86. translate([slot + slot_off, outer_length - slot, slot])
  87. rotate([-90, 0, 0])
  88. tslot_2_x(slot, outer_width - (2 * (slot + slot_off)));
  89. translate([0, slot + slot_off, 0])
  90. tslot_2_y(slot, outer_length - (2 * (slot + slot_off)));
  91. translate([outer_width - slot, slot + slot_off, 0])
  92. tslot_2_y(slot, outer_length - (2 * (slot + slot_off)));
  93. } else {
  94. translate([slot + slot_off, 0, 0])
  95. tslot_x(slot, outer_width - (2 * (slot + slot_off)));
  96. translate([slot + slot_off, outer_length - slot, 0])
  97. tslot_x(slot, outer_width - (2 * (slot + slot_off)));
  98. translate([0, slot + slot_off, 0])
  99. tslot_y(slot, outer_length - (2 * (slot + slot_off)));
  100. translate([outer_width - slot, slot + slot_off, 0])
  101. tslot_y(slot, outer_length - (2 * (slot + slot_off)));
  102. }
  103. }
  104. module frame() {
  105. // outer corner pillars
  106. tslot_z(slot, outer_height);
  107. translate([outer_width - slot, 0, 0])
  108. tslot_z(slot, outer_height);
  109. translate([0, outer_length - slot, 0])
  110. tslot_z(slot, outer_height);
  111. translate([outer_width - slot, outer_length - slot, 0])
  112. tslot_z(slot, outer_height);
  113. lower_frame(false);
  114. // top frame
  115. translate([0, 0, outer_height - slot])
  116. lower_frame(true);
  117. // end caps
  118. color("black")
  119. translate([0, 0, outer_height]) {
  120. cube([slot, slot, 2]);
  121. translate([outer_width - slot, 0, 0])
  122. cube([slot, slot, 2]);
  123. translate([0, outer_length - slot, 0])
  124. cube([slot, slot, 2]);
  125. translate([outer_width - slot, outer_length - slot, 0])
  126. cube([slot, slot, 2]);
  127. }
  128. // feet
  129. translate([slot / 2, slot / 2, -30])
  130. foot();
  131. translate([outer_width - slot / 2, slot / 2, -30])
  132. foot();
  133. translate([slot / 2, outer_length - slot / 2, -30])
  134. foot();
  135. translate([outer_width - slot / 2, outer_length - slot / 2, -30])
  136. foot();
  137. // connecting elements
  138. translate([slot + slot_off, 0, slot + slot_off])
  139. slot_angle_connector();
  140. translate([slot + slot_off, outer_length - slot, slot + slot_off])
  141. slot_angle_connector();
  142. translate([slot + slot_off, 0, outer_height - slot - slot_off - slot])
  143. rotate([0, 90, 0])
  144. slot_angle_connector();
  145. translate([slot + slot_off, outer_length - slot, outer_height - slot - slot_off - slot])
  146. rotate([0, 90, 0])
  147. slot_angle_connector();
  148. translate([outer_width - slot - slot_off, 0, slot + slot_off])
  149. rotate([0, -90, 0])
  150. slot_angle_connector();
  151. translate([outer_width - slot - slot_off, outer_length - slot, slot + slot_off])
  152. rotate([0, -90, 0])
  153. slot_angle_connector();
  154. translate([outer_width - slot - slot_off, 0, outer_height - slot - slot_off - slot])
  155. rotate([0, 180, 0])
  156. slot_angle_connector();
  157. translate([outer_width - slot - slot_off, outer_length - slot, outer_height - slot - slot_off - slot])
  158. rotate([0, 180, 0])
  159. slot_angle_connector();
  160. translate([slot, slot + slot_off, slot + slot_off])
  161. rotate([0, 0, 90])
  162. slot_angle_connector();
  163. translate([slot, slot + slot_off, outer_height - slot - slot_off - slot])
  164. rotate([0, 90, 90])
  165. slot_angle_connector();
  166. translate([0, outer_length - slot - slot_off, slot + slot_off])
  167. rotate([0, 0, -90])
  168. slot_angle_connector();
  169. translate([0, outer_length - slot - slot_off, outer_height - slot - slot_off - slot])
  170. rotate([0, 90, -90])
  171. slot_angle_connector();
  172. translate([outer_width, slot + slot_off, slot + slot_off])
  173. rotate([0, 0, 90])
  174. slot_angle_connector();
  175. translate([outer_width, slot + slot_off, outer_height - slot - slot_off - slot])
  176. rotate([0, 90, 90])
  177. slot_angle_connector();
  178. translate([outer_width - slot, outer_length - slot - slot_off, slot + slot_off])
  179. rotate([0, 0, -90])
  180. slot_angle_connector();
  181. translate([outer_width - slot, outer_length - slot - slot_off, outer_height - slot - slot_off - slot])
  182. rotate([0, 90, -90])
  183. slot_angle_connector();
  184. translate([slot + slot_off, slot + slot_off, slot])
  185. rotate([-90, 0, 0])
  186. slot_angle_connector();
  187. translate([outer_width - slot - slot_off, slot + slot_off, slot])
  188. rotate([-90, 0, 90])
  189. slot_angle_connector();
  190. translate([slot + slot_off, outer_length - slot - slot_off, 0])
  191. rotate([90, 0, 0])
  192. slot_angle_connector();
  193. translate([outer_width - slot - slot_off, outer_length - slot - slot_off, 0])
  194. rotate([90, 0, -90])
  195. slot_angle_connector();
  196. /*
  197. translate([slot + slot_off, slot + slot_off, outer_height])
  198. rotate([-90, 0, 0])
  199. slot_angle_connector();
  200. translate([outer_width - slot - slot_off, slot + slot_off, outer_height])
  201. rotate([-90, 0, 90])
  202. slot_angle_connector();
  203. translate([slot + slot_off, outer_length - slot - slot_off, outer_height - slot])
  204. rotate([90, 0, 0])
  205. slot_angle_connector();
  206. translate([outer_width - slot - slot_off, outer_length - slot - slot_off, outer_height - slot])
  207. rotate([90, 0, -90])
  208. slot_angle_connector();
  209. */
  210. }
  211. // #######################################################
  212. // ###################### Mechanics ######################
  213. // #######################################################
  214. module rail(length) {
  215. cylinder(d = rail_dia, h = length);
  216. echo(rail_dia=rail_dia, rail_len=length);
  217. }
  218. module y_rails() {
  219. // y smooth rail on blue side
  220. color("cyan")
  221. translate([rail_dia / 2 + rail_y_off_1, 18, -30])
  222. rotate([-90, 0, 0])
  223. rail(outer_length - slot - nema17_size - (2 * rail_mount_dist));
  224. // y carriage on blue side
  225. translate([rail_y_off_1 - (lm8uu_outer + lm8uu_dia_add) / 2 + y_carriage_rail_support, y_carriage_pos, -slot])
  226. y_carriage(idler_a_blue, idler_b_blue);
  227. // rail mounts for blue side
  228. color("green")
  229. translate([0, 2 * rail_mount_dist, -2 * slot])
  230. rail_mount(slot);
  231. color("green")
  232. translate([0, outer_length - (2 * slot) - nema17_size - rail_mount_dist + 5, -2 * slot])
  233. rail_mount(slot);
  234. // y smooth rail on red side
  235. color("cyan")
  236. translate([outer_width - (2 * slot) - rail_dia / 2 - rail_y_off_1, 18, -30])
  237. rotate([-90, 0, 0])
  238. rail(outer_length - slot - nema17_size - (2 * rail_mount_dist));
  239. // y carriage on red side
  240. translate([outer_width - slot - y_carriage_width - y_carriage_block_width, y_carriage_pos + y_carriage_length, -slot])
  241. rotate([0, 0, 180])
  242. y_carriage(idler_a_red, idler_b_red);
  243. // rail mounts for red side
  244. color("green")
  245. translate([outer_width - (2 * slot), 2 * rail_mount_dist + rail_mount_len, -2 * slot])
  246. rotate([0, 0, 180])
  247. rail_mount(slot);
  248. color("green")
  249. translate([outer_width - (2 * slot), outer_length - (2 * slot) - nema17_size - rail_mount_dist + 5 + rail_mount_len, -2 * slot])
  250. rotate([0, 0, 180])
  251. rail_mount(slot);
  252. }
  253. module x_rails() {
  254. // TODO length calculate properly!
  255. color("cyan")
  256. translate([30, y_carriage_pos, 15])
  257. rotate([0, 90, 0])
  258. rail(outer_width - (4 * slot));
  259. color("cyan")
  260. translate([30, y_carriage_pos + x_rail_dist, 15])
  261. rotate([0, 90, 0])
  262. rail(outer_width - (4 * slot));
  263. if (show_x_carriage) {
  264. translate([x_carriage_pos, y_carriage_pos - x_carriage_len_add, slot / 2])
  265. x_carriage();
  266. }
  267. }
  268. module motion_xy() {
  269. translate([slot, slot, outer_height])
  270. y_rails();
  271. translate([slot, slot + y_carriage_len_add, outer_height - (1.5 * slot)])
  272. x_rails();
  273. // left ("blue") motor
  274. translate([slot, outer_length - slot - nema17_size - nema17_mount_wall, outer_height + nema17_mount_wall])
  275. rotate([180, 0, 90]) {
  276. color("blue")
  277. translate([0, 0, -65])
  278. nema17(65);
  279. color("green")
  280. nema17_mount(slot);
  281. // blue motor pulley
  282. color("magenta")
  283. translate([nema17_size / 2, nema17_size / 2, 22.4])
  284. rotate([180, 0, 0])
  285. gt2_pulley();
  286. // blue gt2 belt at motor
  287. color("blue")
  288. translate([nema17_size / 2, nema17_size / 2 + 6.5, nema17_mount_wall + 1])
  289. rotate([0, 0, 180])
  290. gt2_belt(outer_length - (2 * slot) - nema17_size / 2 - x_rail_dist - y_carriage_pos - 15);
  291. color("blue")
  292. translate([-outer_length + (3 * slot) + 10 + nema17_size / 2, nema17_size / 2 - 6.5, nema17_mount_wall + 1])
  293. gt2_belt(outer_length - (3 * slot) - 10);
  294. }
  295. // right ("red") motor
  296. translate([outer_width - slot - nema17_size, outer_length - slot - nema17_size - nema17_mount_wall, outer_height + nema17_mount_wall])
  297. rotate([180, 0, 90]) {
  298. color("red")
  299. translate([0, 0, -65])
  300. nema17(65);
  301. color("green")
  302. nema17_mount(slot);
  303. // red motor pulley
  304. color("cyan")
  305. translate([nema17_size / 2, nema17_size / 2, 8.2])
  306. gt2_pulley();
  307. // red gt2 belt at motor
  308. color("red")
  309. translate([nema17_size / 2, nema17_size / 2 + 6.5, nema17_mount_wall + 8])
  310. rotate([0, 0, 180])
  311. gt2_belt(outer_length - (3 * slot) - 10);
  312. color("red")
  313. translate([nema17_size / 2 - (outer_length - (2 * slot) - nema17_size / 2 - x_rail_dist - y_carriage_pos - 15), nema17_size / 2 - 6.5, nema17_mount_wall + 8])
  314. gt2_belt(outer_length - (2 * slot) - nema17_size / 2 - x_rail_dist - y_carriage_pos - 15);
  315. }
  316. // x carriage belts on blue side
  317. color("blue")
  318. translate([slot + 29, slot + x_rail_dist + 7 + y_carriage_pos, outer_height - 1])
  319. rotate([180, 0, 0])
  320. gt2_belt(x_carriage_pos - 20);
  321. color("red")
  322. translate([slot + 15, slot + 23 + y_carriage_pos, outer_height - 8])
  323. rotate([180, 0, 0])
  324. gt2_belt(x_carriage_pos - 6);
  325. // x carriage belts on red side
  326. color("red")
  327. translate([slot + x_carriage_width + x_carriage_pos - 7, slot + x_rail_dist + 7 + y_carriage_pos, outer_height - 8])
  328. rotate([180, 0, 0])
  329. gt2_belt(outer_width - x_carriage_pos - (2 * slot) - x_carriage_width - 20);
  330. color("blue")
  331. translate([slot + x_carriage_width + x_carriage_pos - 7, slot + 23 + y_carriage_pos, outer_height - 1])
  332. rotate([180, 0, 0])
  333. gt2_belt(outer_width - x_carriage_pos - (2 * slot) - x_carriage_width - 10);
  334. // long back belts
  335. color("blue")
  336. translate([slot + 15, slot + 10, outer_height - 7])
  337. gt2_belt(outer_width - nema17_size - (2 * slot) + 13);
  338. color("red")
  339. translate([slot + 15, slot + 10, outer_height - 14])
  340. gt2_belt(outer_width - nema17_size - (2 * slot) + 13);
  341. // blue belt on red side
  342. color("blue")
  343. translate([outer_width - slot - 15, slot + 10, outer_height - 7])
  344. rotate([0, 0, 90])
  345. gt2_belt(y_carriage_pos + 10);
  346. // red belt on blue side
  347. color("red")
  348. translate([slot + 15, slot + 19 + y_carriage_pos, outer_height - 14])
  349. rotate([0, 0, -90])
  350. gt2_belt(y_carriage_pos + 10);
  351. // idler on blue side
  352. translate([slot + bearing_mount_width + 15, 0, outer_height - slot])
  353. rotate([0, 0, 90])
  354. slot_mount_bracket(slot, true);
  355. // idler on red side
  356. translate([outer_width - slot - 15, 0, outer_height - slot])
  357. rotate([0, 0, 90])
  358. slot_mount_bracket(slot, true);
  359. }
  360. // #######################################################
  361. // ####################### Heatbed #######################
  362. // #######################################################
  363. module heatbed_plate() {
  364. difference() {
  365. color("yellow")
  366. cube([heatbed_width, heatbed_length, heatbed_height]);
  367. #translate([bed_x_off + (slot / 2), bed_y_off + (slot / 2), -bed_z_dist - slot - 1])
  368. cylinder(d = 4.2, h = bed_z_dist + slot + heatbed_height + 2);
  369. #translate([heatbed_width - bed_x_off - (slot / 2), bed_y_off + (slot / 2), -bed_z_dist - slot - 1])
  370. cylinder(d = 4.2, h = bed_z_dist + slot + heatbed_height + 2);
  371. #translate([bed_x_off + (slot / 2), heatbed_length - bed_y_off - (slot / 2), -bed_z_dist - slot - 1])
  372. cylinder(d = 4.2, h = bed_z_dist + slot + heatbed_height + 2);
  373. #translate([heatbed_width - bed_x_off - (slot / 2), heatbed_length - bed_y_off - (slot / 2), -bed_z_dist - slot - 1])
  374. cylinder(d = 4.2, h = bed_z_dist + slot + heatbed_height + 2);
  375. }
  376. echo(max_bed_heater_width=heatbed_width - (2 * bed_x_off) - slot - 5);
  377. echo(max_bed_heater_length=heatbed_length - (2 * bed_y_off) - slot - 5);
  378. }
  379. module heatbed() {
  380. translate([slot + frame_off_x, slot + frame_off_y, bed_draw_height]) {
  381. if (show_heatbed) {
  382. %heatbed_plate();
  383. }
  384. // t-slots as heatbed frame
  385. translate([bed_x_off, bed_y_off, -slot - bed_z_dist])
  386. tslot_y(slot, heatbed_length - (2 * bed_y_off));
  387. translate([heatbed_width - slot - bed_x_off, bed_y_off, -slot - bed_z_dist])
  388. tslot_y(slot, heatbed_length - (2 * bed_y_off));
  389. translate([slot + bed_x_off + slot_off, bed_y_off, -slot - bed_z_dist])
  390. tslot_x(slot, heatbed_width - 2 * (bed_x_off + slot + slot_off));
  391. translate([slot + bed_x_off + slot_off, heatbed_length - slot - bed_y_off, -slot - bed_z_dist])
  392. tslot_x(slot, heatbed_width - 2 * (bed_x_off + slot + slot_off));
  393. translate([bed_x_off + slot, bed_y_off + slot, -slot - bed_z_dist])
  394. rotate([90, 0, 90])
  395. slot_angle_connector();
  396. translate([bed_x_off + slot, heatbed_length - slot - bed_y_off, -slot - bed_z_dist])
  397. rotate([90, 0, 0])
  398. slot_angle_connector();
  399. translate([heatbed_width - slot - bed_x_off, heatbed_length - slot - bed_y_off, -slot - bed_z_dist])
  400. rotate([90, 0, -90])
  401. slot_angle_connector();
  402. translate([heatbed_width - slot - bed_x_off, bed_y_off + slot, -slot - bed_z_dist])
  403. rotate([90, 0, 180])
  404. slot_angle_connector();
  405. }
  406. }
  407. z_rail_x_off = 60;
  408. z_rail_mount_len = 20;
  409. module motion_z_rail() {
  410. // bottom clamp
  411. color("green")
  412. translate([slot, 0, slot / 2 + 5 + (z_rail_mount_len - rail_mount_len) / 2])
  413. rotate([-90, 0, 90])
  414. rail_mount(slot, z_rail_mount_len);
  415. // top clamp
  416. color("green")
  417. translate([slot, 0, outer_height - slot / 2 + 5 + (z_rail_mount_len - rail_mount_len) / 2 - slot])
  418. rotate([-90, 0, 90])
  419. rail_mount(slot, z_rail_mount_len);
  420. // rail
  421. color("cyan")
  422. translate([0, rail_y_off, 4])
  423. rail(outer_height - slot - 8);
  424. }
  425. z_carriage_wall = 10;
  426. module z_carriage() {
  427. color("green")
  428. translate([frame_off_x + bed_x_off - z_rail_x_off, frame_off_y + bed_y_off - rail_y_off, 0]) {
  429. // bracket on long rail
  430. translate([-z_carriage_wall, -z_carriage_wall, 0])
  431. cube([z_carriage_wall, z_carriage_wall + (2 * slot), slot]);
  432. // bracket on short rail
  433. translate([0, -z_carriage_wall, 0])
  434. cube([3 * slot, z_carriage_wall, slot]);
  435. }
  436. // TODO proper long bearings
  437. color("magenta")
  438. translate([0, 0, (slot - (2 * lm8uu_height + 1)) / 2]) {
  439. %lm8uu();
  440. %translate([0, 0, lm8uu_height + 1])
  441. lm8uu();
  442. }
  443. }
  444. module motion_z() {
  445. // front left
  446. translate([slot + z_rail_x_off, slot, 0])
  447. motion_z_rail();
  448. // front right
  449. translate([outer_width - z_rail_x_off - slot, slot, 0])
  450. motion_z_rail();
  451. // back left
  452. translate([slot + z_rail_x_off, outer_length - slot, 0])
  453. rotate([0, 0, 180])
  454. motion_z_rail();
  455. // back right
  456. translate([outer_width - z_rail_x_off - slot, outer_length - slot, 0])
  457. rotate([0, 0, 180])
  458. motion_z_rail();
  459. // front left
  460. translate([slot + z_rail_x_off, slot + rail_y_off, bed_draw_height - bed_z_dist - slot])
  461. z_carriage();
  462. // front right
  463. translate([outer_width - slot - z_rail_x_off, slot + rail_y_off, bed_draw_height - bed_z_dist - slot])
  464. scale([-1, 1, 1])
  465. z_carriage();
  466. // back left
  467. translate([slot + z_rail_x_off, outer_length - slot - rail_y_off, bed_draw_height - bed_z_dist - slot])
  468. scale([1, -1, 1])
  469. z_carriage();
  470. // back right
  471. translate([outer_width - slot - z_rail_x_off, outer_length - slot - rail_y_off, bed_draw_height - bed_z_dist - slot])
  472. scale([-1, -1, 1])
  473. z_carriage();
  474. // yellow z-motor on top
  475. translate([(outer_width - nema17_size) / 2, outer_length - slot - nema17_size - nema17_mount_wall, outer_height + nema17_mount_wall])
  476. rotate([180, 0, 90]) {
  477. color("yellow")
  478. translate([0, 0, -65])
  479. nema17(65);
  480. color("green")
  481. nema17_mount(slot);
  482. // blue motor pulley
  483. color("orange")
  484. translate([nema17_size / 2, nema17_size / 2, 8.2])
  485. gt2_pulley();
  486. }
  487. }
  488. // #######################################################
  489. // ###################### Extruders ######################
  490. // #######################################################
  491. module extruders() {
  492. w = nema17_size + 25;
  493. translate([0, -bracket_height, outer_height - slot])
  494. rotate([0, 0, 90]) {
  495. translate([0, -(outer_width + w) / 4, 0])
  496. extruder(slot, "1");
  497. translate([0, -(outer_width + w) / 2, 0])
  498. extruder(slot, "2");
  499. translate([0, -(outer_width + w) * 3 / 4, 0])
  500. extruder(slot, "3");
  501. }
  502. }
  503. // ########################################################
  504. // ####################### Assembly #######################
  505. // ########################################################
  506. module assembly() {
  507. if (show_outer_frame) {
  508. frame();
  509. }
  510. if (show_xy_motion) {
  511. motion_xy();
  512. }
  513. if (show_extruders) {
  514. extruders();
  515. }
  516. if (show_z_motion) {
  517. motion_z();
  518. }
  519. if (show_heatbed_frame) {
  520. heatbed();
  521. }
  522. }
  523. assembly();