chiark / gitweb /
air-hockey-puck: wip
[reprap-play.git] / clip-spring-holder-clip.scad
1 // -*- C -*-
2 //
3 // For holding the spring while reassembling a candle holder.
4
5 include <utils.scad>
6
7 spring_body_w = 5.0;
8 spring_body_l = 6.0;
9 axle_dia = 2.0;
10 recess_d = 13.0;
11 total_len = 45.0;
12
13 th_y = 1.5;
14 th_x = 2;
15 handle_th = 2.5;
16
17 // calculated
18
19 outer_sz = [spring_body_l + th_x*2, spring_body_w + th_y*2];
20 handle_sz = [outer_sz[0], handle_th];
21 th_z = th_x;
22
23 echo(outer_sz);
24
25 module OuterElevation(){
26   square(center=true, outer_sz);
27 }
28
29 module Elevation(){
30   difference(){
31     OuterElevation();
32
33     square(center=true, [spring_body_l, spring_body_w]);
34     square(center=true, [outer_sz[0] + 10, axle_dia]);
35   }
36 }
37
38 module Clip(){
39   linextr(-th_z, recess_d) Elevation();
40   linextr(-th_z, 0) OuterElevation();
41   linextr(recess_d - total_len, 0) square(center=true, handle_sz);
42 }
43
44 module Print(){
45   rotate([0, 90, 0]) Clip();
46 }
47
48 Print();