SMC_PathCopier (FB)ΒΆ
FUNCTION_BLOCK SMC_PathCopier
The function block SMC_PathCopier
is designed to visualize a queue
currently used by the interpolator.
It reproduces the content of the input queue poqCNCPath
into its
output path vs3dt
.
It processes all elements of the queue in the given order.
In case of a linear element it adds only the start and end point to the path vs3dt
.
In case of curved elements it interpolates this element and adds n points to vs3dt
.
n depends on the length of the object and the input dPrecision
.
Processing is continued until the end of the queue is reached or until the
track vs3dt
is full and no more points can be added to.
In the latter case, the function block waits until the first element has
been deleted from the queue and hence the corresponding points can be deleted
in vs3dt
, too.
The function block is busy until the queue gets empty. It is typically used to display the next elements that are to be interpolated.
- InOut:
Scope
Name
Type
Initial
Comment
Input
bExecute
BOOL
A rising edge starts the function block.
bAbort
BOOL
TRUE
aborts the function block.udiNumberOfPointsInArray
UDINT
0
Number of points which are declared in
pBuffer
of the referred array.pBuffer
POINTER TO VisuStruct3DPathPoint
Pointer to the allocated array of points.
poqCNCPath
POINTER TO SMC_OUTQUEUE
Pointer to
SMC_OutQueue
which describes the path.dPrecision
LREAL
1
Defines the precision of the track, meaning how many points should be computed for an element in the queue. A value of 1 indicates that a point should be calculated every 1 unit of the path. A value of 2 indicates that two points should be calculated for every 1 unit of the path.
Output
bBusy
BOOL
TRUE
: FB is activevs3dt
VisuStruct3DTrack
Track output. To be setup as input of the visu element
Path3D
.