-
-
Notifications
You must be signed in to change notification settings - Fork 4
/
solenoid-mount.scad
41 lines (32 loc) · 1.06 KB
/
solenoid-mount.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
module SolenoidMount() {
bottom_padding = 2;
solenoid_z = 12;
solenoid_x = 11.5;
solenoid_y = 21;
wall_thickness = 1;
case_z = solenoid_z;
case_x = solenoid_x + (wall_thickness * 2);
case_y = solenoid_y + (wall_thickness * 2);
shaft_width_front = 3;
shaft_width_back = 6;
corner_height = 3;
union() {
difference() {
linear_extrude(corner_height + bottom_padding)
square(size = [case_x, case_y], center = true);
// Solenoid cutout
translate([0, 0, bottom_padding])
linear_extrude(solenoid_z)
square(size = [solenoid_x, solenoid_y], center = true);
for(i = [-1, 1]) {
translate([0, i *((solenoid_y / 2) + (wall_thickness / 2)), bottom_padding])
linear_extrude(solenoid_z)
square(size = [shaft_width_back, wall_thickness], center = true);
translate([i *((solenoid_x / 2) + (wall_thickness / 2)), 0, bottom_padding])
linear_extrude(solenoid_z)
square(size = [wall_thickness, solenoid_y - 4], center = true);
}
}
}
}
SolenoidMount();