-
Notifications
You must be signed in to change notification settings - Fork 18
pytha.create_cam_groove
Creates a rectangular CAM groove 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 slot is logically applied to that part. The machining 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_workshopto test for availability beforehand.
pytha.create_cam_groove(length, width, depth [,origin [,options]])| Parameter | Type | Description |
|---|---|---|
length |
number |
Length of the groove (in u direction) |
width |
number |
Width of the groove (in v direction, centered around the origin) |
depth |
number |
Groove depth (in the negative w/normal direction) |
origin |
{x,y,z} |
Optional: start point of the groove, centered on the v axis |
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 plane |
options.v_axis |
{x,y,z} |
Local coordinate v-axis for the orientation of the plane |
options.w_axis |
{x,y,z} |
Local coordinate w-axis for the orientation of the plane-normal |
options.type |
string |
"saw" or "router" for the corresponding machining process |
options.tool_name |
string |
Tool name that matches the "Name" field in the PYTHA Worshop settings tool table |
options.length_correction |
string |
"minimum-void", "maximum-void" or "automatic-extension", where the void refers to the resulting slot |
| Type | Description |
|---|---|
element_handle |
An element handle of the newly created part |
This function is similar to create_rectangle, but the resulting part additionally carries the CAM machining information. In addition, the groove rectangle is centered in v direction. Half of the width is in +v, half in -v. This matches the CNC experience of running a tool along the u-axis.
Minimum PYTHA Version: V26
pytha, Workshop Functions, element handles, Axes and directions, create_cam_drill, create_rectangle