chiark / gitweb /
tower-base wip new attach
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Sat, 15 Sep 2012 17:57:24 +0000 (18:57 +0100)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Sat, 15 Sep 2012 17:57:24 +0000 (18:57 +0100)
tower-base.scad

index a96143c39e7899485e4f94463aeab7880aa69b24..8c3536785e9999ef97371cfeff44e90545fdd33b 100644 (file)
@@ -7,7 +7,8 @@ pillarthick=8;
 sidethick=2.5;
 archthick=6.5;
 frameextra=3.5;
-framesplay=1;
+framesplayx=1;
+framesplayy=5;
 botleftgap=4.5;
 botleftstand=0.75;
 archoutwards=(pillarthick-archthick)/sqrt(8);
@@ -19,14 +20,15 @@ d=0.01;
 
 mw2=motorwidth/2;
 
-include <Libs.scad> //  Libs.scad is @ http://www.thingiverse.com/thing:6021
+include <doveclip.scad>
 
 module corner() {
        $fn=30;
        frameheight= motorheight + frameextra;
        slopeheight= totalheight - frameheight;
-       slope = (mw2 + archoutwards - framesplay)/slopeheight;
-       echo(sqrt(2)*slope);
+       slopex = (mw2 + archoutwards - framesplayx)/slopeheight;
+       slopey = (mw2 + archoutwards - framesplayy)/slopeheight;
+       //echo(sqrt(2)*slope);
 
        translate([-mw2,-mw2,0]) union(){
                difference(){
@@ -40,8 +42,8 @@ module corner() {
                }
                intersection(){
                        multmatrix
-                          ([   [       1,      0,      slope -archoutwards ],
-                               [       0,      1,      slope -archoutwards ],
+                          ([   [       1,      0,      slopey, -archoutwards ],
+                               [       0,      1,      slopex, -archoutwards ],
                                [       0,      0,      1, frameheight  ],
                                [       0,      0,      0,      1       ]])
                                translate([0,0,-frameextra])
@@ -93,8 +95,8 @@ module halfside() {
 module towerbase() {
        difference(){
                union(){
-                       for (angle=[0,90,180,270])
-                               rotate([0,0,angle]) corner();
+                       for (mirx=[0,1]) for (miry=[0,1])
+                               mirror([mirx,0,0]) mirror([0,miry,0]) corner();
                        for (angle=[0,90,180]) {
                                rotate([0,0,angle]) halfside();
                                rotate([0,0,angle]) mirror([1,0,0]) halfside();
@@ -106,13 +108,10 @@ module towerbase() {
                        [       0,      0,      0,      1       ] ])
                        cube([100,200,100]);
        }
-       translate([0,0,totalheight])
-               rotate([0,-90,0])
-               intersection(){
-                       dovetail(height=10.1, male=true);
-                       translate([dovebasecutcylz,0,-100])
-                               cylinder(r=dovebasecutcylr,h=200);
-               };
+       translate([0,-5.0,totalheight]) {
+               rotate([-90,0,0])
+                               DoveClipPair(h=10.1);
+       }
 }
 
 //intersection(){