chiark / gitweb /
summit-lantern-hook: wip
[reprap-play.git] / summit-lantern-hook.scad
1 // -*- C -*-
2
3 include <utils.scad>
4
5 height = 60;
6 th = 6;
7 curl = 10;
8 width = 85;
9 sides_depth = 35;
10
11 $fa = 3;
12 $fs = 0.3;
13
14 // calculated
15
16 upper_r = th/2;
17 upper_ctr_maj_r = curl/2 + upper_r;
18
19 zmin = curl/2 + th;
20
21 module UpperPlan(){
22   circle(r = upper_r);
23 }
24
25 module Upper(){
26   translate([upper_ctr_maj_r, 0, 0])
27     linextr(-0.1, height + 0.1)
28     UpperPlan();
29   translate([0, 0, height]){
30     rotate([90,0,0])
31       rotate_extrude(angle=180)
32       translate([upper_ctr_maj_r, 0])
33       UpperPlan();
34     translate([-upper_ctr_maj_r, 0,0])
35       sphere(r= upper_r);
36   }
37 }
38
39 module Lower(){
40   difference(){
41     linextr(-zmin, 0)
42       square(center = true, [curl + th*2, th]);
43     linextr_y_xz(-th, th)
44       circle(r = curl/2);
45   }
46   linextr(-zmin, -zmin + th) {
47     square(center=true, [th, width]);
48     for (m=[0,1])
49       mirror([0,m])
50         translate([0, width/2 - th/2 ])
51         square(center=true, [ sides_depth, th ]);
52   }
53 }
54
55 module Hook(){
56   Upper();
57   Lower();
58 }
59
60 Hook();