summaryrefslogtreecommitdiff
path: root/Filamenthalter/Filamenthalter.scad
blob: 2c85ba6f61608835a95dd1431e2658255dcfd9c8 (plain)
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
r = 29/2;
rDick = 35/2;
d = 110;
Rand = 5;
dSchraube = 11;
dSchraubenKopf = 10;
dNut = 2;
eps = 0.1;

Teil = "beide";

module Stab() {
  difference() {
    union() {
      cylinder(r=rDick+Rand, h=Rand);
      translate([0,0,Rand+d])
        cylinder(r=r+Rand, h=Rand);
      translate([0,0,Rand])
        cylinder(r1=rDick, r2=r, h=d+Rand+dNut);
    }
    translate([0,0,-1])
      cylinder(r=dSchraube/2, h=d+2*Rand+3);
    translate([-dSchraubenKopf/2-eps,-dSchraubenKopf/2-eps,d+3*Rand-dSchraubenKopf+1])
      cube(dSchraubenKopf + 2*eps);
  }
}

module Deckel() {
  difference() {
    cylinder(r=r+Rand, h=Rand+dNut);
    translate([-dSchraubenKopf/2-eps,-dSchraubenKopf/2-eps,-1])
      cube(dSchraubenKopf + 2*eps);
    translate([0,0,Rand])
      cylinder(r=r+2*eps, h=dNut+1);
  }
}

if (Teil == "Stab") {
  Stab();
} else if (Teil == "Deckel") {
  Deckel();
} else if (Teil == "beide") {
  translate([r+rDick+3*Rand,0,0])
    Stab();
  Deckel();
}