chiark / gitweb /
scaffold-clamp: wip vhook
[reprap-play.git] / scaffold-clamp-vhook.scad
1 // -*- C -*-
2
3 hinge_units = 4;
4
5 include <scaffold-clamp-common.scad>
6
7 vhook_th = 10;
8
9 theta = atan2( smooth_r, main_r );
10
11 vhook_inside = 15;
12
13 // calculated
14
15 vhook_y0 = -cos(theta) * (main_r + smooth_r);
16 vhook_ctr = vhook_y0 - vhook_inside/2;
17
18 //echo(theta);
19
20 module VHookPlan() {
21   PlanWeldMainCircle(){
22     rectfromto([ -vhook_th/2, 0 ],
23                [ +vhook_th/2, vhook_y0 ]);
24   }
25 }
26
27 module VHookProfile() {
28   translate([0, -vhook_inside/2 - vhook_th/2])
29     circle(r = vhook_th/2);
30 }
31
32 module PartB(){ ////toplevel
33  GeneralB();
34 }
35
36 module PartA(){ ////toplevel
37   DummyA();
38   linextr(min_z, max_z)
39     VHookPlan();
40   //translate([0, vhook_y0, 50]) rotate([0,0,-90]) color("black") cube(10);
41   // translate([0,0,-150]) rotate([0,0,180 + theta]) color("blue") cube(100);
42 }
43
44 module PlanDemo(){ ////toplevel
45   GeneralPlanDemo();
46   translate([0, -tube_dia*1.5]) {
47     VHookPlan();
48     translate([0, vhook_ctr, 5])
49       for (m=[0,1]) {
50         mirror([0,m])
51           color("blue") VHookProfile();
52       }
53   }
54 }