chiark / gitweb /
05bcf1d53b8e83e714017f2de9b49d91f8a6208d
[reprap-play.git] / osstest-arm-net-bracket.scad
1 // -*- C -*-
2
3 holedist = 64;
4 tonguewidth = 10;
5 tongue2width = 15;
6 totaldepth = 26;
7 tongue2depth = 35;
8 thick = 4;
9 tabover = 7+6;
10 tabunder = 15;
11
12 tabsidel = 7;
13 tabsider = 7+10;
14
15 tonguethick = 4;
16 tongue2thick = 5;
17 strapthick = 2;
18 strapwidth = 5;
19 ridgewidth = 2;
20
21 hstrengthick = 2.5;
22 hstrengdepth = strapwidth;
23
24 cutoutover = 7;
25 rcutoutside = 7+2 - 0.5;
26 lcutoutside = 7-6.5 - 0.5;
27
28 holedia = 3.5;
29
30 tongue2x = tongue2width - holedist;
31
32 module Tongue(tw,tt,ad,slots=2){
33   y0=thick+0.1;
34   yn=ad-ridgewidth-strapwidth;
35   difference(){
36     translate([-tw, 0, 0])
37       cube([tw, ad, tt+strapthick]);
38     for (yi=[1:slots-1])
39       translate([-tw-1, y0 + (yn-y0)*yi/(slots-1), tt])
40         cube([tw+2, strapwidth, strapthick+0.05]);
41   }
42 }
43
44 module Object(){
45   difference(){
46     translate([-holedist-tabsider, 0, 0]) {
47       cube([tabsidel+tabsider+holedist, thick, tabunder+tabover]);
48       cube([tabsidel+tabsider+holedist, thick+hstrengdepth, hstrengthick]);
49     }
50     translate([0,-25,tabunder+cutoutover]) {
51       translate([-(holedist+rcutoutside), 0,0])
52         mirror([1,0,0])
53         cube([50,50,50]);
54       translate([lcutoutside, 0,0])
55         cube([50,50,50]);
56     }
57     for (x=[-holedist,0])
58       translate([x, 0, tabunder]) {
59         translate([0, -1, 0]) {
60           rotate([-90,0,0]) {
61             cylinder(r= holedia/2+0.5, h=thick+2, $fn=20);
62           }
63         }
64         translate([0, 19.95 + thick, 0])
65           cube(center=true,[10,40,10]);
66       }
67   }
68   Tongue(tonguewidth,tonguethick,totaldepth,3);
69   translate([tongue2x,0,0])
70     Tongue(tongue2width,tongue2thick,tongue2depth+thick,5);
71 }
72
73 Object();