Part Wedge

From FreeCAD Documentation
Revision as of 19:47, 19 February 2022 by C4e (talk | contribs)

This documentation is not finished. Please help and contribute documentation.

GuiCommand model explains how commands should be documented. Browse Category:UnfinishedDocu to see more incomplete pages like this one. See Category:Command Reference for all commands.

See WikiPages to learn about editing the wiki pages, and go to Help FreeCAD to learn about other ways in which you can contribute.

Part Wedge

Menu location
Part → Create primitives → Wedge
Workbenches
Part
Default shortcut
None
Introduced in version
-
See also
Part Primitives

Description

The Part Wedge command creates a parametric wedge solid.

Screenshot of a Part Wedge solid with default values

Create a parametric Wedge object. This Wedge defaults to a larger square base and a smaller square top.

Usage

  1. Switch to the Part Workbench
  2. There are several ways to invoke the command:

Example

Part Wedge scripting example

A Part Wedge object with the values of the bottom scripting example are shown here.


Default Size and Placement

Placement: The default orientation places the base in the XZ plane and the top outward in the Y axis direction. The default base corner is the 0,0,0 origin.

Base Face:

  • X : 10 mm
  • Z : 10 mm

Height:

  • Y : 0-10 mm

Top Face:

  • X : 2-8 mm
  • Z : 2-8 mm


Parametric Inputs

Using the default placement, the below inputs are:

  • DataX min/max : Base face X axis span
  • DataY min/max: Wedge height span
  • DataZ min/max : Base face Z axis span
  • DataX2 min/max : Top face X axis span
  • DataZ2 min/max : Top face Z axis span

More examples for wedges

Properties

See also: Property editor.

A Part Wedge object is derived from a Part Feature object and inherits all its properties. It also has the following additional properties:

Data

Wedge

  • DataXmin (Length): Base face X minimum value
  • DataYmin (Length): Wedge height minimum value
  • DataZmin (Length): Base face Z minimum value
  • DataX2min (Length): Top face X minimum value
  • DataZ2min (Length): Top face Z minimum value
  • DataXmax (Length): Base face X maximum value
  • DataYmax (Length): Wedge height maximum value
  • DataZmax (Length): Base face Z maximum value
  • DataX2max (Length): Top face X maximum value
  • DataZ2max (Length): Top face Z maximum value

Scripting

A Part Wedge is created with the addObject() method of the document.

wedge = FreeCAD.ActiveDocument.addObject("Part::Wedge", "myWedge")
  • Where myWedge is the name for the object. The name must be unique for the entire document.
  • The function returns the newly created object.

The Label is the user editable name for the object. It can be easily changed by

wedge.Label = "new myWedgeName"

You can access and modify attributes of the wedge object. For example, you may wish to modify the minimum or maximum coordinate parameters.

wedge.Xmin = 1
wedge.Ymin = 2
wedge.Zmin = 3
wedge.X2min = 4
wedge.Z2min = 6
wedge.Xmax = 15
wedge.Ymax = 20
wedge.Zmax = 55
wedge.X2max = 10
wedge.Z2max = 12

You can change its placement and orientation with:

wedge.Placement = FreeCAD.Placement(FreeCAD.Vector(1, 2, 3), FreeCAD.Rotation(75, 60, 30))