chiark / gitweb /
rope-adjuster: wip, teeth
[reprap-play.git] / rope-adjuster.scad
1 // -*- C -*-
2
3 include <utils.scad>
4
5 hole_dia = 10;
6 around_hole = 5;
7 thick = 4;
8 lever_len = 50;
9
10 teeth_n = 4;
11 teeth_bite = 4;
12 teeth_pitch = 4;
13 teeth_gap = 3;
14 teeth_back = 1;
15 teeth_height = 12;
16
17 module Circles(r) {
18   for (x = [-1,+1] * 0.5 * lever_len) {
19     translate([x, 0])
20       circle(r);
21   }
22 }
23
24 module Plan() {
25   difference(){
26     hull(){
27       Circles(hole_dia/2 + around_hole);
28     }
29     Circles(hole_dia/2);
30   }
31 }
32
33 module TeethPlan(){
34   translate([
35              lever_len/2 - hole_dia/2 - teeth_bite - teeth_gap*1.5,
36              -0.5 * teeth_n * teeth_pitch,
37              ]) {
38     for (m=[0,1]) {
39       mirror([m,0]) {
40         translate([ teeth_bite + teeth_gap/2, 0 ])
41           rectfromto([ -0.1, 0 ],
42                      [ teeth_back, teeth_n * teeth_pitch ]);
43         for (i= [ 0: teeth_n-1 ]) {
44           translate([teeth_gap/2, teeth_pitch*i])
45             polygon([[ 0,0 ],
46                      [ teeth_bite, 0 ],
47                      [ teeth_bite, teeth_pitch ]]);
48         }
49       }
50     }
51   }
52 }
53
54 module Adjuster(){
55   linextr(0,thick)
56     Plan();
57   linextr(thick - 0.1, thick + teeth_height)
58     TeethPlan();
59 }
60
61 Adjuster();