tool: Light panel #9

Merged
aniva merged 11 commits from tool/lighting into main 2025-01-28 17:56:22 -08:00
1 changed files with 19 additions and 0 deletions
Showing only changes of commit 9d78bf604a - Show all commits

View File

@ -13,6 +13,10 @@ class LightPanel(Model):
length: float = 300.0
width: float = 200.0
attach_height: float = 20.0
attach_diam: float = 8.0
attach_depth: float = 12.7
grid_height: float = 20.0
grid_top_height: float = 5.0
# Distance from grid to edge
@ -91,6 +95,21 @@ class LightPanel(Model):
thickness=self.base_thickness,
)
@target(name="attachment")
def attachment(self) -> Cq.Workplane:
l = self.length / 2
w = self.width / 2
return (
Cq.Workplane('XY')
.box(
l, w, self.attach_height,
centered=(True, True, False),
)
.faces(">Z")
.hole(self.attach_diam, self.attach_depth)
)
def assembly(self) -> Cq.Assembly:
assembly = (
Cq.Assembly()