Partː Tubo

From FreeCAD Documentation
Revision as of 21:38, 26 December 2023 by Marco T (talk | contribs) (Created page with "Il comando 24px '''Part Tubo''' crea un tubo parametrico solido. Nel sistema di coordinate definito dalla sua proprietà {{PropertyData|Placement}}, la faccia inferiore del tubo si trova sul piano XY con il centro nell'origine.")

Part Tubo

Posizione nel menu
Parte → Primitive → Crea tubo
Ambiente
Part
Avvio veloce
Nessuno
Introdotto nella versione
0.19
Vedere anche
Part Primitive

Descrizione

Il comando Part Tubo crea un tubo parametrico solido. Nel sistema di coordinate definito dalla sua proprietà DatiPlacement, la faccia inferiore del tubo si trova sul piano XY con il centro nell'origine.

Utilizzo

Create

  1. There are several ways to invoke the command:
    • Press the Part Tube button.
    • Select the Part → Primitives → Create tube option from the menu.
  2. The Tube task panel opens and a preview of the tube is displayed in the 3D view.
  3. Specify the dimensions.
  4. The preview is dynamically updated.
  5. Press the OK button.
  6. The tube is created.
  7. Optionally change the DatiPlacement of the tube in the Property editor, or with the Std TransformManip command.

Edit

  1. Double-click the tube in the Tree view
  2. The Tube task panel opens.
  3. Change one or more dimensions.
  4. The tube is dynamically updated in the 3D view.
  5. Press the OK button.

Example

Part Tube from the scripting example

A Part Tube object created with the scripting example below is shown here.

Properties

See also: Property editor.

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

Data

Attachment

The object has the same attachment properties as a Part Part2DObject.

Tube

  • DatiHeight (Length): The height of the tube. The default is 10mm.
  • DatiInner Radius (Length): The inner radius of the tube. Must be smaller than DatiOuter Radius. Can be 0. The default is 2mm.
  • DatiOuter Radius (Length): The outer radius of the tube. Must be larger than DatiInner Radius. The default is 5mm.

Scripting

See also: Autogenerated API documentation, Part scripting and FreeCAD Scripting Basics.

A Part Tube can be created with the addTube() method (introduced in version 0.20) of the Shapes module:

tube = Shapes.addTube(FreeCAD.ActiveDocument, "myTube")
  • Where "myTube" is the name for the object.
  • The function returns the newly created object.

Example:

import FreeCAD as App
from BasicShapes import Shapes

doc = App.activeDocument()

tube = Shapes.addTube(FreeCAD.ActiveDocument, "myTube")
tube.Height = 20
tube.InnerRadius = 2
tube.OuterRadius = 3
tube.Placement = App.Placement(App.Vector(2, 4, 5), App.Rotation(60, 60, 30))

doc.recompute()