import cadquery as cq from cadquery.occ_impl.exporters import * from ocp_vscode import show hole_diam = 5 hole_dist = 24.5 bar_width = 8 bar_thickness = 2.75 height_padding = 2 lever_length = 32 lever_max_thickness = 8 bar_height = hole_dist + hole_diam + 2*height_padding clip = ( cq.Workplane("XY") # Start in the XY plane .box(bar_width, bar_height,bar_thickness) .edges("|Z and >Y or |Z and >X") .fillet(2) .faces(">Z") .workplane() .rect(0,hole_dist,forConstruction=True) .vertices(">X") .circle(hole_diam/2) .cutThruAll() ) upper_lever = cq.Sketch().trapezoid(bar_thickness, lever_length,100, angle=90).vertices("