fix: Mount output

This commit is contained in:
Leni Aniva 2024-09-04 16:27:51 -07:00
parent 66cdd1b359
commit 114aec4944
Signed by: aniva
GPG Key ID: 4D9B1C8D10EA4C50
1 changed files with 14 additions and 4 deletions

View File

@ -380,14 +380,18 @@ class WingProfile(Model):
centred=(True, True),
flip_y=self.flip,
)
@submodel(name="spacer-s0-electronic")
def spacer_s0_electronic_mount(self) -> MountingBox:
def spacer_s0_electronic_mount(self, circle: bool = False) -> MountingBox:
"""
This one has hexagonal holes
"""
face = ELECTRONIC_MOUNT_HEXNUT.cutting_face()
face = self.electronic_board.nut.cutting_face()
diam = self.electronic_board.bolt.diam_thread
holes = [
Hole(x=h.x, y=h.y, face=face, tag=h.tag)
Hole(
x=h.x, y=h.y, tag=h.tag,
face=None if circle else face,
diam=diam if circle else None)
for h in self.electronic_board.mount_holes
]
return MountingBox(
@ -399,6 +403,12 @@ class WingProfile(Model):
flip_y=False,#self.flip,
generate_reverse_tags=True,
)
@submodel(name="spacer-s0-electronic-hex")
def spacer_s0_electronic_mount_hex(self) -> MountingBox:
return self.spacer_s0_electronic_mount(False)
@submodel(name="spacer-s0-electronic-circle")
def spacer_s0_electronic_mount_circle(self) -> MountingBox:
return self.spacer_s0_electronic_mount(True)
@submodel(name="spacer-s0-electronic2")
def spacer_s0_electronic_mount2(self) -> MountingBox:
"""