SpHEAR_arm.scad 6.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198
  1. //
  2. // Spherical Harmonics Ear Project (*SpHEAR)
  3. //
  4. // Customized WidowXL Robotic Arm Components
  5. //
  6. // Copyright 2018, Fernando Lopez-Lezcano, All Rights Reserved
  7. // nando@ccrma.stanford.edu
  8. //
  9. // This program is free software: you can redistribute it and/or modify
  10. // it under the terms of the GNU General Public License as published by
  11. // the Free Software Foundation, either version 3 of the License, or
  12. // (at your option) any later version.
  13. //
  14. // This program is distributed in the hope that it will be useful,
  15. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  16. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  17. // GNU General Public License for more details.
  18. //
  19. // You should have received a copy of the GNU General Public License
  20. // along with this program. If not, see <http://www.gnu.org/licenses/>.
  21. //
  22. // 3d Models released under the Creative Commons license as follows:
  23. // Attribution-NonCommercial-ShareAlike 4.0 International (CC BY-NC-SA 4.0)
  24. // http://creativecommons.org/licenses/by-nc-sa/4.0/
  25. facets = 128;
  26. s5_plate_w = 47.0;
  27. s5_plate_d = 29.0;
  28. s5_plate_t = 5.9 + 4.5;
  29. s5_mount_hole_w = 38.0;
  30. s5_mount_hole_d = 22.0;
  31. // holes for mounting to arm plate
  32. s5_hole_r = 2.7/2;
  33. // center hole for servo plate
  34. s5_center_hole_d = 8.5;
  35. // holes to mount servo to plate
  36. module s5_plate_holes () {
  37. for (mw = [0, 1]) mirror([mw, 0, 0]) {
  38. for (md = [0, 1]) mirror([0, md, 0]) {
  39. translate([s5_mount_hole_w/2, s5_mount_hole_d/2, -1.0]) {
  40. cylinder(r = s5_hole_r + 0.15, h = 20.0, $fn = facets);
  41. }
  42. }
  43. }
  44. }
  45. // holes to mount adaptor to servo
  46. module s5_servo_holes () {
  47. translate([0, 0, -0.01]) {
  48. // center hole for servo
  49. cylinder(r = 6.5/2, h = 20.0, $fn = facets);
  50. // holes for mounting servo to plate
  51. for (m = [0, 1]) mirror([m, 0, 0]) {
  52. translate([15, -4.5, 0]) {
  53. cylinder(r = s5_hole_r, h = 20.0, $fn = facets);
  54. cylinder(r = 5/2, h = 3.25, $fn = facets);
  55. }
  56. translate([15, - 4.5 + 17, 0]) {
  57. cylinder(r = s5_hole_r, h = 20.0, $fn = facets);
  58. cylinder(r = 5/2, h = 3.25, $fn = facets);
  59. }
  60. }
  61. }
  62. }
  63. // basic mounting plate
  64. module s5_plate () {
  65. difference() {
  66. mp_r = 2.0;
  67. union() {
  68. translate([-s5_plate_w/2 + mp_r, -s5_plate_d/2 + mp_r, 0]) {
  69. intersection() {
  70. minkowski() {
  71. cube([s5_plate_w - 2*mp_r, s5_plate_d - 2*mp_r, s5_plate_t]);
  72. cylinder(r = mp_r, h = 0.001, $fn = facets);
  73. }
  74. // rounded top
  75. translate([0, 0, -mp_r]) minkowski() {
  76. cube([s5_plate_w - 2*mp_r, s5_plate_d - 2*mp_r, s5_plate_t]);
  77. sphere(r = mp_r, $fn = facets);
  78. }
  79. }
  80. }
  81. // extended support for plate screws
  82. for (m = [0, 1]) mirror([m, 0, 0]) translate([15, - 4.5 + 17, 0]) {
  83. cylinder(r = 7/2, h = 5.5, $fn = facets);
  84. }
  85. }
  86. // hollow out servo space
  87. s_w = 24.40;
  88. translate([-s_w/2, -12.50, 5.5/2]) {
  89. cube([s_w, 40, 10]);
  90. }
  91. // and shave top as well
  92. s_tw = 35.60;
  93. m_r = 6.0;
  94. translate([-s_tw/2 + m_r, -12.50 + m_r, 5.5 - 0.2]) {
  95. minkowski() {
  96. cube([s_tw - 2*m_r, 40, 10]);
  97. cylinder(r = m_r, h = 0.001, $fn = facets);
  98. }
  99. }
  100. }
  101. }
  102. // plate that screws into MX28T servo and has sockets to attach
  103. // to microphone mount
  104. module arm_attachment_plate () {
  105. // 25.0 is separation between sockets
  106. plate_w = grip_sep * 2 + arm_l + 4 * wall;
  107. plate_d = arm_w + 4 * wall;
  108. plate_t = 5.0;
  109. translate([-plate_w/2, -plate_d/2, 0]) {
  110. cube([plate_w, plate_d, plate_t]);
  111. }
  112. }
  113. // holes for MX28T servo
  114. module arm_attachment_holes () {
  115. // center of servo
  116. translate([0, 0, -0.01]) cylinder(r = 9.0/2, h = 10.0, $fn = facets);
  117. // screw holes
  118. for (r = [45, -45, 135, -135]) rotate([0, 0, r]) {
  119. translate([8.0, 0, -0.01]) {
  120. cylinder(r = 2.7/2, h = 10.0, $fn = facets);
  121. }
  122. translate([8.0, 0, 3.25]) {
  123. cylinder(r = 3.9/2, h = 10.0, $fn = facets);
  124. }
  125. }
  126. }
  127. // model WidowXL (dimensions of original gripper)
  128. wall = 1.0;
  129. // sliding block (dimensions from WidowXL gripper blocks)
  130. arm_l = 10.2 + 0.38;
  131. arm_w = 21.5 + 0.38;
  132. // x profile
  133. arm_profile_s = 10.25;
  134. arm_b_prof = 4.25;
  135. // connection socket
  136. arm_s_h = 21.0;
  137. // separation between centers of sockets
  138. grip_sep = 25.4 * 1.5 / 2 + arm_l / 2;
  139. // block that can be screwed to existing gripper of stock WidowXL arm
  140. module arm_gripper_block () {
  141. translate([-arm_l/2, -arm_w/2, 0]) difference() {
  142. // body
  143. translate([-(4 * wall)/2, -2 * wall, 0]) {
  144. cube([arm_l + 4 * wall, arm_w + 4 * wall, arm_s_h]);
  145. }
  146. // carve out corners for better fit
  147. translate([0.2, 0.2, 0]) cylinder(r = 0.4, h = arm_s_h, $fn = facets);
  148. translate([arm_l, 0.2, 0]) cylinder(r = 0.4, h = arm_s_h, $fn = facets);
  149. translate([arm_l, arm_w, 0]) cylinder(r = 0.4, h = arm_s_h, $fn = facets);
  150. translate([0.2, arm_w, 0]) cylinder(r = 0.4, h = arm_s_h, $fn = facets);
  151. // arm gripper block
  152. union() {
  153. cube([arm_l, arm_w, arm_s_h + 0.1]);
  154. translate([-arm_l/2, arm_w/2 - arm_profile_s/2, - arm_b_prof - arm_profile_s - 10]) {
  155. cube([20, arm_profile_s, arm_profile_s + 10]);
  156. }
  157. }
  158. }
  159. }
  160. // MX28T servo mounting plate
  161. //
  162. // attaches MX28T servo to arm to act as wrist rotation servo with 360 degree
  163. // of rotation instead of the stock dual AX12A wrist rotation and gripper servos
  164. // with 300 degree rotation limit
  165. *difference() {
  166. s5_plate();
  167. s5_plate_holes();
  168. s5_servo_holes();
  169. }
  170. // microphone mount attachment, screws into MX28T servo and has sockets
  171. // for the microphone mount pillars
  172. difference() {
  173. union() {
  174. arm_attachment_plate();
  175. for (m = [0, 1]) mirror([m, 0, 0]) translate([grip_sep, 0, 5.0]) arm_gripper_block();
  176. }
  177. arm_attachment_holes();
  178. }