Use only one bolt for angle bracket

This commit is contained in:
Leni Aniva 2025-05-14 22:40:53 -07:00
parent 670d4a8c21
commit b83bf5a57d
Signed by: aniva
GPG Key ID: D5F96287843E8DFB
1 changed files with 20 additions and 2 deletions

View File

@ -33,8 +33,7 @@ class Onbashira(Model):
angle_joint_bolt_head_depth: float = 3.0
# Position of the holes, with (0, 0) being the centre of each side
angle_joint_bolt_position: list[float] = field(default_factory=lambda: [
(20, 10),
(60, 10),
(40, 12),
])
angle_joint_flange_thickness: float = 7.8
angle_joint_flange_radius: float = 40.0
@ -63,6 +62,7 @@ class Onbashira(Model):
material_side: Material = Material.WOOD_BIRCH
material_bearing: Material = Material.PLASTIC_PLA
material_spacer: Material = Material.PLASTIC_PLA
material_bearing_ball: Material = Material.ACRYLIC_TRANSPARENT
material_brace: Material = Material.PLASTIC_PLA
@ -251,6 +251,24 @@ class Onbashira(Model):
loc=Cq.Location(0, 0, -self.bearing_disk_thickness/2)
)
)
z = -self.bearing_disk_gap/2
for i in range(self.n_side):
loc = Cq.Location.rot2d(i * 360/self.n_side) * Cq.Location(self.rotor_bind_radius, 0, z)
a = a.addS(
self.rotor_spacer(),
name=f"spacerRotor{i}",
material=self.material_spacer,
role=Role.STRUCTURE,
loc=loc
)
loc = Cq.Location.rot2d((i+0.5) * 360/self.n_side) * Cq.Location(self.stator_bind_radius, 0, z)
a = a.addS(
self.rotor_spacer(),
name=f"spacerStator{i}",
material=self.material_spacer,
role=Role.STRUCTURE,
loc=loc
)
for i in range(self.n_bearing_balls):
ball = self.bearing_ball()
loc = Cq.Location.rot2d(i * 360/self.n_bearing_balls) * Cq.Location(self.bearing_track_radius, 0, 0)