FUNCTION_BLOCK SMC_RecomputeABCSlopes
Recomputes the slopes of the additional axes A,B,C so that a smooth movement results. The slope at the end of elemnt i is set as (AddAxisValue(i+1) - AddAxisValue(i-1)) / (ElementLength(i) + ElementLength(i+1)). At a stop, the slope is either set to zero, or set so that the interpolation of the additional axis is linear, depending on the input modeAtStop.
InOut:
Scope |
Name |
Type |
Initial |
Comment |
Input |
bExecute |
BOOL |
Starts on the rising edge |
|
poqDataIn |
POINTER TO SMC_OUTQUEUE |
Input path queue |
||
nSizeOutQueue |
UDINT |
The size of pbyBufferOutQueue in bytes |
||
pbyBufferOutQueue |
POINTER TO ARRAY [0..0] OF SMC_GEOINFO |
The buffer for the output queue |
||
dAngleTol |
LREAL |
0.001 |
The angle tolerence (in angular degrees) to detect stops between elements |
|
modeNoStop |
Determines how the slope is set at element transitions without a stop. The default is SET_SMOOTH_CARDINAL. |
|||
modeAtStop |
Determines how the slope is set at element transitions with a stop. The default, due to compatibility with older versions, is SET_ZERO. |
|||
Output |
bDone |
BOOL |
Indicates the entire input path has been processed |
|
bBusy |
BOOL |
Indicates the function block is still busy processing |
||
bError |
BOOL |
An error has occurred |
||
wErrorID |
SMC_ERROR |
Error-ID |
||
poqDataOut |
POINTER TO SMC_OUTQUEUE |
The queue for the output path |