Role: This interface is used to retrieve TCP traces from a product. This product is the assembly node representing the inverse kinematics assembly.
A TCP trace is the graphical output of a task simulation. This output is the trajectory path generated by the TCP, defined by lines and points. Each point represents the location of the TCP at a given time.
The following code snippet can be used to obtain a handle from a product:
Dim MyRobot As Product
'retrieval of the product
...
'retrieval of the trace manager
Dim objDevice As TCPTraceManager
set objDevice = MyRobot.GetTechnologicalObject("TCPTraceManager")
'activate the trace
objDevice.TCPTraceMode=True
'Get the last path
Dim NbPath As Long
NbPath = objDevice.GetNbPath
If NbPath>0 Then
' retrieval of the last trace
Dim RobotTCPTrace As TCPTrace
Set RobotTCPTrace = objDevice.GetPath(NbPath)
'Export the trace points
RobotTCPTrace.Export("C:\TEMP\DEBUG.xls")
End If
Properties
- Property InitStatus() As
-
Indicates whether the tracing capability must delete previous traces
when the simulation starts.
- True: previous traces are deleted
- False: previous traces are kept
- Parameters:
-
- oInitStatus
- Boolean. Indicates if the tracing capability is activ or not. dd>
- Property TCPTraceMode() As
-
Indicates if the tracing capability is activ or not.
- True: tracing capability activated
- False: tracing capability deactivated
- Parameters:
-
- oTCPTraceMode
- Boolean. Indicates if the tracing capability is activ or not. dd>
Methods
- Func GetAttachedOwner() As
-
Retrieves the default attached owner of the trace. By default, the
owner of the trace is the robot assembly node. If the robot is moved,
the trace will follow. However, in some scenarios, the trace might be
drawn related to another product (or even with respect to the world)
like for example when dealing with a workpiece positioner.
- Parameters:
-
- oOwner
- CATIABase. Attached owner of the trace. Output parameter. Returns nothing if the trace is defined related to the world dd>
- Func GetNbPath() As
-
Get the number of TCP trace.
- Parameters:
-
- oNb
- Long. Number of traces. Output parameter. dd>
- Func GetPath( iIndex) As
-
Get the iIndex path(trace)(starting at 1).
- Parameters:
-
- iIndex
- Long. Path/Trace index starting at 1. Input parameter. dd>
- oTCPPath
- DNBIATCPTrace. Pointer on the trace. Output parameter. dd>
- Sub RemoveAllPath()
- Remove all traces from the current resource. All traces associated with the current resource will be removed from the 3D and deleted.
- Sub RemovePathByIndex( iIndex)
-
Remove a specific path based on its position in the list. The trace
will be removed from the 3D viewer and deleted.
- Parameters:
-
- iIndex
- Long. Position index starting at 1. Must be positiv. Input parameter. dd>
- Sub RemovePathByObject( TCPPath)
-
Remove a specific trace based on the object. The trace will be removed
from the 3D viewer and deleted.
- Parameters:
-
- TCPPath
- DNBIATCPTrace. Path to be removed. dd>
- Sub ResetAttachedOwner()
-
Resets the attached owner of the trace to the world. When a new
trace will be created, it will defined with respect to the world.
Remark: this will not change the exported values. - Sub SetAttachedOwner( iOwner)
-
Sets the default attached owner of the trace. By default, the owner
of the trace is the robot. When a new trace is created, the attached
owner is used to set it upon the trace.
Remark: set the attached owner will not change the exported values.- Parameters:
-
- iOwner
- CATIABase. Attached owner of the trace. Input parameter. dd>