use spokes on wheels
[challenge-bot] / 3d-printables / wheel-data.scad
index 2fd9f7f5fb2a585cd5927941855dbcd6cc148ec6..70dc71039d081f537db10ccc54f10b20bcce0a10 100644 (file)
@@ -67,13 +67,19 @@ module wheel(radius,
              shaft_flat_width,
              wall_width,
              tread_radius) {
+  spoke_count = 7;
+  spoke_width = radius / 3;
   difference() {
     rim(radius, wall_width * 2, width);
     translate([0, 0, width / 2]) {
       tread(radius, tread_radius); } }
   linear_extrude(height = wheel_square_spoke_thickness) {
     difference() {
-      square(wheel_square_spoke_size, center = true);
+      union(){
+        for(spoke = [0: spoke_count - 1]) {
+          rotate(spoke * 360 / spoke_count) {
+            translate([-spoke_width / 2, 0]){
+            square([spoke_width, radius - 2]); } } } }
       mounting_screw_flat(); } }
   translate([0, 0, wheel_square_spoke_thickness]) {
     motor_shaft_holder(shaft_radius,