feat: add v1 of the mop handle
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
# pyright: reportUnusedCallResult=false, reportWildcardImportFromLibrary=false
|
||||
from build123d import *
|
||||
from svgpathtools.path import transform
|
||||
|
||||
def build_mop_scraper_holder(center_thickness: float):
|
||||
mop_diameter = 23.4
|
||||
@@ -48,6 +49,65 @@ def build_mop_scraper_holder(center_thickness: float):
|
||||
|
||||
return mop_scraper_holder
|
||||
|
||||
def build_mop_handle():
|
||||
mop_diameter = 23.4
|
||||
|
||||
thickness = 5
|
||||
|
||||
hand_curve_length = 70
|
||||
hand_curve_thickness = 5
|
||||
hand_curve_spacing = 50
|
||||
hand_curve_start_space = 10
|
||||
hand_curve_end_space = 20
|
||||
|
||||
flared_base_thickness = hand_curve_thickness
|
||||
flared_base_length = 5
|
||||
|
||||
screw_diameter = 4.75
|
||||
screw_head_diameter = 9.6
|
||||
screw_head_depth = 2
|
||||
|
||||
rounding = 5
|
||||
|
||||
handle_diam = (mop_diameter / 2) + thickness
|
||||
|
||||
with BuildPart() as mop_handle:
|
||||
with BuildSketch(Plane.XZ):
|
||||
with BuildLine() as profile:
|
||||
sl = Line((0, 0), (handle_diam, 0))
|
||||
hs1 = Line(sl @ 1, (handle_diam, hand_curve_start_space))
|
||||
h1 = ThreePointArc(hs1 @ 1, (handle_diam + hand_curve_thickness, (hs1 @ 1).Y + (hand_curve_length / 2)), (handle_diam, (hs1 @ 1).Y + hand_curve_length))
|
||||
hs2 = Line(h1 @ 1, (handle_diam, (h1 @ 1).Y + hand_curve_spacing))
|
||||
h2 = ThreePointArc(hs2 @ 1, (handle_diam + hand_curve_thickness, (hs2 @ 1).Y + (hand_curve_length / 2)), (handle_diam, (hs2 @ 1).Y + hand_curve_length))
|
||||
hs3 = Line(h2 @ 1, (handle_diam, (h2 @ 1).Y + hand_curve_end_space))
|
||||
fb = ThreePointArc(hs3 @ 1, (handle_diam + flared_base_thickness, (hs3 @ 1).Y + flared_base_length / 2), ((hs3 @ 1).X, (hs3 @ 1).Y + flared_base_length))
|
||||
el = Line(fb @ 1, (0, (fb @ 1).Y))
|
||||
Line(el @ 1, sl @ 0)
|
||||
make_face()
|
||||
revolve()
|
||||
|
||||
fillet(mop_handle.edges(), rounding)
|
||||
|
||||
with Locations(Plane((0, 0, thickness))):
|
||||
Cylinder(mop_diameter / 2, 99999, align=(Align.CENTER, Align.CENTER, Align.MIN), mode=Mode.SUBTRACT)
|
||||
# this is a seem channel
|
||||
with BuildSketch(Location((0, mop_diameter / 2, thickness))):
|
||||
Triangle(A=90, b=1, c=1)
|
||||
extrude(amount=99999, mode=Mode.SUBTRACT)
|
||||
|
||||
with Locations(Plane((0, 0, hand_curve_start_space + hand_curve_length + (hand_curve_spacing / 2)))):
|
||||
with PolarLocations(handle_diam, 2):
|
||||
with Locations(Rotation(0, 90, 0)):
|
||||
CounterBoreHole(screw_diameter / 2, screw_head_diameter / 2, screw_head_depth)
|
||||
|
||||
with Locations(Plane((0, 0, hand_curve_start_space + (hand_curve_length * 2) + hand_curve_spacing + (hand_curve_end_space / 2)))):
|
||||
with PolarLocations(handle_diam, 2, 90):
|
||||
with Locations(Rotation(0, 90, 0)):
|
||||
CounterBoreHole(screw_diameter / 2, screw_head_diameter / 2, screw_head_depth)
|
||||
|
||||
return mop_handle
|
||||
|
||||
|
||||
mop_scraper_holder_top = build_mop_scraper_holder(15)
|
||||
assert mop_scraper_holder_top.part is not None
|
||||
export_step(mop_scraper_holder_top.part, "mop_scraper_holder_top.step")
|
||||
@@ -55,3 +115,7 @@ export_step(mop_scraper_holder_top.part, "mop_scraper_holder_top.step")
|
||||
mop_scraper_holder_bottom = build_mop_scraper_holder(10)
|
||||
assert mop_scraper_holder_bottom.part is not None
|
||||
export_step(mop_scraper_holder_bottom.part, "mop_scraper_holder_bottom.step")
|
||||
|
||||
mop_handle = build_mop_handle()
|
||||
assert mop_handle.part is not None
|
||||
export_step(mop_handle.part, "mop_handle.step")
|
||||
|
||||
Reference in New Issue
Block a user