Skip to content

Commit c7ed13d

Browse files
committed
Make Lite stls printable
1 parent d32f247 commit c7ed13d

1 file changed

Lines changed: 47 additions & 25 deletions

File tree

src/LiteCase/LiteCase.scad

Lines changed: 47 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ lite_w = 80 - 18;
1212

1313

1414
// 0,0,0: Mitte des Lite-PCB, auf der Seite mit dem OpenBIkeSensor logo, x: Richtung USB-Port, Z: Richtung Ultraschallsensoren
15-
$fn = 120;
15+
$fn = 20;
1616

1717
Lite_PCB_x = 44;
1818
Lite_PCB_y = 29.2;
@@ -168,36 +168,58 @@ module LiteElectronics(onlyboards = false) {
168168
USB_hole();
169169
}
170170

171-
difference() {
172-
union() {
173-
translate([- 7, 0, Lite_ESP_position_z + 0.8 + 0.05 - Lite_screwmount_top])rotate([0, 0, 90])
174-
Screwbump(size = 4, hole_diameter = 3.2, height = Lite_screwmount_height, bottom = true, toppart = Lite_screwmount_top);
175-
translate([lite_w - 7.3, 12, Lite_ESP_position_z + 0.8 + 0.05 - Lite_screwmount_top])rotate([0, 0, - 90])
176-
Screwbump(size = 4, hole_diameter = 3.2, height = Lite_screwmount_height, bottom = true, toppart = Lite_screwmount_top);
177-
translate([lite_w - 7.3, - 12, Lite_ESP_position_z + 0.8 + 0.05 - Lite_screwmount_top])rotate([0, 0, - 90])
178-
Screwbump(size = 4, hole_diameter = 3.2, height = Lite_screwmount_height, bottom = true, toppart = Lite_screwmount_top);
179-
translate([23.8, - 3.5, - 17.9])rotate([180, 0, 90])StandardMountAdapter(screwholes = false, channels = false, twoholes = false);
180-
difference() {
181-
union() {
182-
rotate([90, 90, 0])Box();
183-
difference() {
184-
translate(Lite_USB + [0, 0, - 3.5 - 1.6 + 1]) {
185-
rounded_cube(28, 16.5, 6.5, 0, 1.5, center = true);
186-
187-
difference() {
188-
#rounded_cube(30, 15, 6.5, 0, 1.5, center = true);
189-
translate([8, - 20, - 5])cube([4, 60, 20]);
171+
172+
module lite_case() {
173+
difference() {
174+
union() {
175+
translate([-7, 0, Lite_ESP_position_z + 0.8 + 0.05 - Lite_screwmount_top])rotate([0, 0, 90])
176+
Screwbump(size = 4, hole_diameter = 3.2, height = Lite_screwmount_height, bottom = true, toppart =
177+
Lite_screwmount_top);
178+
translate([lite_w - 7.3, 12, Lite_ESP_position_z + 0.8 + 0.05 - Lite_screwmount_top])rotate([0, 0, -90])
179+
Screwbump(size = 4, hole_diameter = 3.2, height = Lite_screwmount_height, bottom = true, toppart =
180+
Lite_screwmount_top);
181+
translate([lite_w - 7.3, -12, Lite_ESP_position_z + 0.8 + 0.05 - Lite_screwmount_top])rotate([0, 0, -90])
182+
Screwbump(size = 4, hole_diameter = 3.2, height = Lite_screwmount_height, bottom = true, toppart =
183+
Lite_screwmount_top);
184+
translate([23.8, -3.5, -17.9])rotate([180, 0, 90])StandardMountAdapter(screwholes = false, channels = false,
185+
twoholes = false);
186+
difference() {
187+
union() {
188+
rotate([90, 90, 0])Box();
189+
difference() {
190+
translate(Lite_USB + [0, 0, -3.5 - 1.6 + 1]) {
191+
rounded_cube(28, 16.5, 6.5, 0, 1.5, center = true);
192+
193+
difference() {
194+
#rounded_cube(30, 15, 6.5, 0, 1.5, center = true);
195+
translate([8, -20, -5])cube([4, 60, 20]);
196+
}
190197
}
198+
translate(Lite_USB + [10, 0, 0])cube([4, 20, 12.5], center = true);
191199
}
192-
translate(Lite_USB + [10, 0, 0])cube([4, 20, 12.5], center = true);
193200
}
194-
}
195-
hull() translate([23.8, - 3.5, - 18])rotate([180, 0, 90])StandardMountAdapter(screwholes = false, channels = false);
201+
hull() translate([23.8, -3.5, -18])rotate([180, 0, 90])StandardMountAdapter(screwholes = false, channels =
202+
false);
196203

204+
}
197205
}
206+
LiteElectronics();
207+
LidCutter();
198208
}
199-
LiteElectronics();
200-
LidCutter();
209+
210+
}
211+
212+
// split into conveniently printable parts and orient for printing.
213+
rotate([0,180,0])translate([-30,0,-Lite_ESP_position_z-0.8])difference() {
214+
lite_case();
215+
216+
translate([40, 0, Lite_ESP_position_z + 0.8+49.95])cube([120, 90, 100], center = true);
217+
}
218+
219+
rotate([0,180,0])translate([-30,40,Lite_ESP_position_z-lite_l/2+1.6])intersection() {
220+
lite_case();
221+
222+
translate([40, 0, Lite_ESP_position_z + 0.8+49.95])cube([120, 90, 100], center = true);
201223
}
202224

203225
if ($preview) translate([80, 0, 0])LiteElectronics();

0 commit comments

Comments
 (0)