-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathIndex Stops.scad
99 lines (83 loc) · 1.41 KB
/
Index Stops.scad
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
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
/**
* Simple tabs to attach to 8MM rods to serve as endstops on the X and Y axes
*/
$fa = 1;
$fs = 0.1;
rodDiameter = 8;
thickness = 7;
length = 8;
openingWidth = 6;
armDistance = 9;
distanceOffsetX = -1.4;
construction();
module construction ()
{
difference()
{
{
union()
{
body();
arms();
}
}
{
cutouts();
}
}
}
module body()
{
difference()
{
{
cylinder( d = rodDiameter + thickness, h = length );
}
{
translate( [0, 0, -1] ) cylinder( d = rodDiameter, h = length + 2 );
translate( [0, (-1 * (openingWidth/2)), -1] ) cube( [10, openingWidth, length + 2] );
}
}
}
module arms()
{
translate( [(rodDiameter/2) + distanceOffsetX, (openingWidth/2), 0] )
{
arm();
translate( [0, ( -1 * (openingWidth * (5/3)) ), 0] )
{
arm();
}
}
}
module arm()
{
armWidth = thickness - 3;
hull()
{
{
cube( [armDistance - distanceOffsetX, armWidth, length] );
}
{
translate( [armDistance + (armWidth/2) + (distanceOffsetX/2), (armWidth/2), 0] ) cylinder( d = armWidth, h = length );
}
}
}
// M3-sized cutouts
module cutouts()
{
nutWallThickness = 1.6;
boltDiameter = 3.7;
translate( [(armDistance/2) - (distanceOffsetX * 2), (openingWidth/2) + nutWallThickness, (length/2)] )
{
rotate( [-90, 0, 0] )
{
nutTrap();
translate( [0, 0, -25] ) cylinder( d = boltDiameter, h = 50 );
}
}
}
module nutTrap()
{
cylinder( h = 4.5, r = (6.8/2), $fn=6 );
}