aboutsummaryrefslogtreecommitdiff
path: root/tabletop_tablet_stand_base.scad
blob: bdb1aabbef1373a5ff73ef7eeb3856b8380ed021 (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
thickness = 15;
legWidth = 50;
rearLegLength = 40;
frontLegLength = 90;
frontLegCenterRotationDegrees = 65;

nutInsetHeight = 7;
nutInsetDiameter = 20;

threadDiameter = 6;

module leg(width, length, thickness) {
  translate([-width/2, 0, 0])
    cube([width, length, thickness]);

  translate([0, length, 0])
    cylinder(r = width/2, h = thickness);
}

difference() {
  union() {
    // rear leg
    rotate([0, 0, 180])
      leg(legWidth, rearLegLength, thickness);

    // right leg
    rotate([0, 0, -frontLegCenterRotationDegrees])
      leg(legWidth, frontLegLength, thickness);

    // leftleg
    rotate([0, 0, +frontLegCenterRotationDegrees])
      leg(legWidth, frontLegLength, thickness);
  }

  // thread hole
  cylinder(r = threadDiameter/2, h = thickness);

  // nut inset
  translate([0, 0, thickness - nutInsetHeight])
    cylinder(r = nutInsetDiameter/2, h = nutInsetHeight);
}