Skip to content

pytha.create_cam_drill

Daniel Flassig edited this page Jun 12, 2026 · 1 revision

Creates a circular CAM drilling stencil as a new face-part and attaches CAM machining information to it.

If this stencil comes to lie on the surface of another part, the drilling is logically applied to that part. The drilling direction is in along the negative w_axis. Note that the CAD geometry of the other part is not instantly modified - the machining operation is only applied by the CAM postprocessor.

Note: This function requires the Workshop license. Without it, the call raises an error. Use check_license_workshop to test for availability beforehand.

pytha.create_cam_drill(diameter, depth [,origin [,options]])
Parameter Type Description
diameter number Diameter of the drilling (following the usual CAM convention for holes). Note that create_circle expects a radius instead.
depth number Drilling depth (in the negative w/normal direction)
origin {x,y,z} Optional: center point of the drilling
options {...} Optional: a table that may contain the following options:
options.u_axis {x,y,z} Local coordinate u-axis for the orientation of the drilling
options.v_axis {x,y,z} Local coordinate v-axis for the orientation of the drilling
options.w_axis {x,y,z} Local coordinate w-axis for the orientation of the drilling
options.segments number Segments of the circle
through boolean Treat the drilling as a through-hole, default: false
speed_profile string "LS", "SS", "LSL", "SSS", "LSU", "SFSU", where L is slow and S is fast, default: "LS"

Return value

Type Description
element_handle An element handle of the newly created part

Remarks

This function is similar to create_circle, but attaches CAM stencil information as well. Note that the former takes a diameter parameter while create_circle takes a radius.

Version Support:

Minimum PYTHA Version: V26

See also:

pytha, Workshop Functions, element handles, Axes and directions, create_cam_groove, create_circle

Clone this wiki locally