MotionSession Class¶
-
class
NXOpen.Motion.
MotionSession
¶ Bases:
object
Represents motion session
To obtain an instance of this class, refer to
NXOpen.Session
New in version NX5.0.0.
Methods¶
Method | Description |
---|---|
CloneSimulation | Clone the Simulation. |
ConstraintsToMotionObject | Convert mating conditions and constraints to links and joints @return the link which will be fixed to ground |
CreateNamingSimulation | Create the Simulation with an input name. |
CreatePhysicsConversionBuilder | Creates a NXOpen.Motion.PhysicsConversionBuilder @return |
CreateSimulation | Create the Simulation. |
DeleteSimulation | Delete the Simulation. |
DirectOpenSimulation | Direct open the Simulation. |
ExportProcessSimulateKinematics | Export kinematics for Process Simulate |
FixLinkToGround | Fix the link to ground @return the joint object created |
GetFullName | Get the full name for a scenario name @return full path to the file |
GetScenarioNames | Get all scenario names @return scenario names |
InitializeMechanisms | Initialize the mech |
ReparentSimulation | Reparent the Simulation. |
Method Detail¶
CloneSimulation¶
-
MotionSession.
CloneSimulation
¶ Clone the Simulation.
Signature
CloneSimulation(masterPart, motionSimName)
Parameters: - masterPart (
NXOpen.NXObject
) – the master part - motionSimName (str) – motion simulation part which ready to be cloned NOTE: The full Unicode character set is not supported for this parameter.
Returns: new motion simulation part name
Return type: str
New in version NX5.0.0.
License requirements: mechanisms (“MECHANISMS”)
- masterPart (
ConstraintsToMotionObject¶
-
MotionSession.
ConstraintsToMotionObject
¶ Convert mating conditions and constraints to links and joints
Signature
ConstraintsToMotionObject(scenarioPart, masterPart)
Parameters: - scenarioPart (
NXOpen.NXObject
) – the scenario part object - masterPart (
NXOpen.NXObject
) – the master part object
Returns: the link which will be fixed to ground
Return type: New in version NX6.0.1.
License requirements: mechanisms (“MECHANISMS”)
- scenarioPart (
CreateNamingSimulation¶
-
MotionSession.
CreateNamingSimulation
¶ Create the Simulation with an input name.
Signature
CreateNamingSimulation(masterPart, inputSimName)
Parameters: - masterPart (
NXOpen.NXObject
) – the master_part - inputSimName (str) – the input simulation name NOTE: The full Unicode character set is not supported for this parameter.
Returns: the created motion simulation part name
Return type: str
New in version NX8.0.0.
License requirements: mechanisms (“MECHANISMS”)
- masterPart (
CreatePhysicsConversionBuilder¶
-
MotionSession.
CreatePhysicsConversionBuilder
¶ Creates a
NXOpen.Motion.PhysicsConversionBuilder
Signature
CreatePhysicsConversionBuilder(scenarioPart)
Parameters: scenarioPart ( NXOpen.NXObject
) –Returns: Return type: NXOpen.Motion.PhysicsConversionBuilder
New in version NX8.0.0.
License requirements: mechanisms (“MECHANISMS”)
CreateSimulation¶
-
MotionSession.
CreateSimulation
¶ Create the Simulation.
Signature
CreateSimulation(masterPart)
Parameters: masterPart ( NXOpen.NXObject
) – the master_partReturns: created motion simulation part name Return type: str New in version NX5.0.0.
License requirements: mechanisms (“MECHANISMS”)
DeleteSimulation¶
-
MotionSession.
DeleteSimulation
¶ Delete the Simulation.
Signature
DeleteSimulation(masterPart, motionSimName)
Parameters: - masterPart (
NXOpen.NXObject
) – the master_part - motionSimName (str) – motion simulation part which ready to be deleted NOTE: The full Unicode character set is not supported for this parameter.
New in version NX5.0.0.
License requirements: mechanisms (“MECHANISMS”)
- masterPart (
DirectOpenSimulation¶
-
MotionSession.
DirectOpenSimulation
¶ Direct open the Simulation.
Signature
DirectOpenSimulation(motionSimName)
Parameters: motionSimName (str) – motion simulation part name NOTE: The full Unicode character set is not supported for this parameter. New in version NX5.0.0.
License requirements: mechanisms (“MECHANISMS”)
ExportProcessSimulateKinematics¶
-
MotionSession.
ExportProcessSimulateKinematics
¶ Export kinematics for Process Simulate
Signature
ExportProcessSimulateKinematics()
New in version NX8.5.0.
License requirements: mechanisms (“MECHANISMS”)
FixLinkToGround¶
-
MotionSession.
FixLinkToGround
¶ Fix the link to ground
Signature
FixLinkToGround(link)
Parameters: link ( NXOpen.NXObject
) – the link objectReturns: the joint object created Return type: NXOpen.NXObject
New in version NX6.0.1.
License requirements: mechanisms (“MECHANISMS”)
GetFullName¶
-
MotionSession.
GetFullName
¶ Get the full name for a scenario name
Signature
GetFullName(masterPart, scenarioName)
Parameters: - masterPart (
NXOpen.NXObject
) – the master part object - scenarioName (str) – scenario name to check (with or without extension) NOTE: The full Unicode character set is not supported for this parameter.
Returns: full path to the file
Return type: str
New in version NX7.0.0.
License requirements: mechanisms (“MECHANISMS”)
- masterPart (
GetScenarioNames¶
-
MotionSession.
GetScenarioNames
¶ Get all scenario names
Signature
GetScenarioNames(masterPart)
Parameters: masterPart ( NXOpen.NXObject
) – the master part objectReturns: scenario names Return type: list of str New in version NX7.0.0.
License requirements: mechanisms (“MECHANISMS”)
InitializeMechanisms¶
-
MotionSession.
InitializeMechanisms
¶ Initialize the mech
Signature
InitializeMechanisms()
New in version NX6.0.0.
License requirements: mechanisms (“MECHANISMS”)
ReparentSimulation¶
-
MotionSession.
ReparentSimulation
¶ Reparent the Simulation.
Signature
ReparentSimulation(motionSimFullName, destinationDirectory)
Parameters: - motionSimFullName (str) – motion simulation full name NOTE: The full Unicode character set is not supported for this parameter.
- destinationDirectory (str) – destination directory NOTE: The full Unicode character set is not supported for this parameter.
New in version NX5.0.0.
License requirements: mechanisms (“MECHANISMS”)