X-Git-Url: http://challenge-bot.com/repos/?p=challenge-bot;a=blobdiff_plain;f=wheel.scad;h=c361773198b866ae8b6b2bd8ad7385a0d2c5e2f1;hp=aa3d2686ddca632ccd461197b6df8f1cd28708de;hb=3e81f99776f9741e1245e44e050f8052dfa9d85d;hpb=bc02cd240d188c85cc1333510e63b2a2ff516bc7 diff --git a/wheel.scad b/wheel.scad index aa3d268..c361773 100644 --- a/wheel.scad +++ b/wheel.scad @@ -4,10 +4,13 @@ // https://gitorious.org/ozzloy/challenge-bot // https://github.com/waynegramlich/challenge-bot +wheel_depth = 7.65; +wheel_radius = 68/2; + module encoder_shaft(){ - motor_shaft_big = 7/2; - motor_shaft_small = 4.65; - motor_shaft_length = 7.65 / 2; + motor_shaft_big = 3.7; + motor_shaft_small = 4.8; + motor_shaft_length = wheel_depth / 2; intersection(){ cylinder(h = motor_shaft_length, @@ -17,14 +20,41 @@ module encoder_shaft(){ cube([motor_shaft_big * 2.1, motor_shaft_small, motor_shaft_length], center = true);}} +module mounting_screw(){ + cylinder(h = wheel_depth * 1.1, r = 1, $fn = 100, center = true);} + module wheel(){ - depth = 7.65; - radius = 68/2; - difference(){ - cylinder(h = depth, r = radius, center = true, $fn=100); - translate([0, 0, 7.65/4]) - scale([1, 1, 1.1]) - encoder_shaft(); - cylinder(h = depth * 1.1, r = 1, $fn = 100, center = true);}} - -translate([0, 0, 7.65/2]) wheel(); + translate([0, 0, wheel_depth / 2]){ + difference(){ + cylinder(h = wheel_depth, r = wheel_radius, center = true, $fn=100); + translate([0, 0, wheel_depth/4]){ + scale([1, 1, 1.1]){ + encoder_shaft();}} + mounting_screw(); + for(i = [0 : 4]){ + rotate(i * 360/5, [0, 0, 1]){ + translate([0, 0, -0.6 * wheel_depth]) + between_spokes();}}}}} + +module wheel_block(){ + cube([wheel_radius, wheel_radius, wheel_depth]);} + +module pie_slice(){ + intersection(){ + translate([0, 0, wheel_depth / 2]){ + cylinder(h = wheel_depth, + r = 0.7 * wheel_radius, + center = true);} + translate([0, wheel_radius * 0.3, 0]){ + rotate([0, 0, (360/5)/2]){ + intersection(){ + wheel_block(); + rotate([0, 0, 90 - 360/5]) + wheel_block();}}}}} + +module between_spokes(){ + minkowski(){ + pie_slice(); + cylinder(h = wheel_depth, r = 1, $fn=100);}} + +wheel();