Add 2 more pillars, adjust component position

This commit is contained in:
Roberto Alsina 2023-03-28 11:15:41 -03:00
parent 68b407f5b5
commit 0a2bba4067
7 changed files with 41 additions and 39 deletions

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -35,7 +35,9 @@ mounting_pillar_positions = [
(6, 6), (6, 6),
(6, 40), (6, 40),
(120, 6), (120, 6),
(120, 40),
(170, 6), (170, 6),
(170, 40),
(width - 6, 6), (width - 6, 6),
(width - 6, 30), (width - 6, 30),
] ]
@ -47,12 +49,12 @@ usb_offset = width - 48
# CPU holder position from back-left corner of the case # CPU holder position from back-left corner of the case
cpu_offset_x = 160 cpu_offset_x = 180
cpu_offset_y = 25 cpu_offset_y = 3
# Battery holder position from back-left corner of the case # Battery holder position from back-left corner of the case
battery_offset_x = 19 battery_offset_x = 15
battery_offset_y = 5 battery_offset_y = 3
# Offset for the USB port from back-right corner of the case # Offset for the USB port from back-right corner of the case
usb_offset = 48 usb_offset = 48
@ -154,43 +156,43 @@ def model():
if __name__ == "__main__": if __name__ == "__main__":
# left_cutout = cq.Sketch().polygon( model = model()
# [(0, 0), (width / 2, 0), (width / 2, -height), (0, -height), (0, 0)],
# mode="a",
# )
# right_side = ( left_cutout = cq.Sketch().polygon(
# model() [(0, 0), (width / 2, 0), (width / 2, -height), (0, -height), (0, 0)],
# .faces("<Z") mode="a",
# .workplaneFromTagged("mid_height") )
# .transformed(offset=cq.Vector(0, 0, -thickness / 2))
# .center(-width / 2, height / 2)
# .placeSketch(left_cutout)
# .cutBlind(100)
# )
# exporters.export(right_side, "right_side.stl") right_side = (
model.faces("<Z")
.workplaneFromTagged("mid_height")
.transformed(offset=cq.Vector(0, 0, -thickness / 2))
.center(-width / 2, height / 2)
.placeSketch(left_cutout)
.cutBlind(100)
)
# right_cutout = cq.Sketch().polygon( exporters.export(right_side, "right_side.stl")
# [
# (width / 2, 0),
# (width, 0),
# (width, -height),
# (width / 2, -height),
# (width / 2, 0),
# ],
# mode="a",
# )
# left_side = ( right_cutout = cq.Sketch().polygon(
# model() [
# .faces("<Z") (width / 2, 0),
# .workplaneFromTagged("mid_height") (width, 0),
# .transformed(offset=cq.Vector(0, 0, -thickness / 2)) (width, -height),
# .center(-width / 2, height / 2) (width / 2, -height),
# .placeSketch(right_cutout) (width / 2, 0),
# .cutBlind(100) ],
# ) mode="a",
# exporters.export(left_side, "left_side.stl") )
exporters.export(model(), "model.stl") left_side = (
model.faces("<Z")
.workplaneFromTagged("mid_height")
.transformed(offset=cq.Vector(0, 0, -thickness / 2))
.center(-width / 2, height / 2)
.placeSketch(right_cutout)
.cutBlind(100)
)
exporters.export(left_side, "left_side.stl")
exporters.export(model, "model.stl")

Binary file not shown.

Binary file not shown.