-
Notifications
You must be signed in to change notification settings - Fork 1
/
hanging_hook.scad
60 lines (40 loc) · 1.21 KB
/
hanging_hook.scad
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
// Hang your coat for Bill
// hanging_hook part
// by ftoad, 08/24/2011
//
//************Variables**********************************************************
padding = 0.1;
rect_points = [[0,0], [16.45,0],[20,32],[16.45,69.78],[0,69.78],[-3.65,32]]; // turn this into the appropriate variable type
rect_path =[[0,1,2,3,4,5]] ;
square_points = [[0,0], [0,13.78],[16.84,13.78],[16.84,0]];
square_path = [[0,1,2,3]];
profile= 5;
fn_rule = 100;
hook_points = [[0,0],[6,0],[6,10],[4,15],[2,15],[0,10]];
hook_path = [[0,1,2,3,4,5]];
//************Modules **************************************************************
module base(){
polygon(points= rect_points,paths=rect_path );
}
module inner_square(){
polygon(points=square_points,paths=square_path);
}
module hook(){
polygon(points = hook_points, paths=hook_path);
}
//************Build**************************************************************
difference(){
linear_extrude(height=profile, $fn=fn_rule){
base();
}
translate([0,20,-padding]) {
linear_extrude(height=2*profile,$fn=fn_rule){
inner_square();
}
}
}
translate([5,15,profile]){
linear_extrude(height=3,twist=0){
hook();
}
}