44 lines
973 B
Python
44 lines
973 B
Python
from ocp_vscode import *
|
|
from build123d import *
|
|
set_port(3939)
|
|
|
|
tt = thickness_toolboard = 0.8
|
|
wc = width_connector = 20.0
|
|
lsp = length_straight_part = 5.0
|
|
tb = thickness_bevel = 2.5
|
|
teub = thickness_edge_until_board = 0.5
|
|
wbs = width_board_side = 15.0
|
|
ttc = thickness_total_connector = 4.0
|
|
cw = clamp_width = 9.8
|
|
rc = rotation_clamp = 45.0
|
|
dc = depth_clamp = 4.0
|
|
dcs = depth_clamp_space = 1.6
|
|
|
|
lp1 = line_point_1 = (cw+5)*0.75
|
|
lp2 = line_point_2 = ttc+dc
|
|
lp3 = line_point_3 = cw
|
|
lp4 = line_point_4 = dc
|
|
lp5 = line_point_5 = cw*0.75
|
|
lp6 = line_point_6 = ttc+tt
|
|
|
|
pts = [
|
|
(0, 0),
|
|
(cw, 0),
|
|
(cw, dc),
|
|
(lp5, dc),
|
|
(lp5, (dc+tt+ttc-dcs)),
|
|
(lp5+(5/2), (dc+tt+ttc-dcs)),
|
|
(lp5+(5/2), (dc+tt+ttc)),
|
|
(0, (dc+tt+ttc)),
|
|
(0, 0)
|
|
]
|
|
|
|
with BuildPart() as clamp:
|
|
with BuildSketch() as sk_clamp:
|
|
with BuildLine() as ln_clamp:
|
|
Polyline(pts)
|
|
make_face()
|
|
extrude(amount = cw)
|
|
|
|
show_all()
|