SMC_PathCopierFile (FB)¶
FUNCTION_BLOCK SMC_PathCopierFile
The function block SMC_PathCopierFile reads and decodes a G-code
file (sFileName) and creates an array of points from the generated path.
The inputs pvl and piStartPosition are transferred to the
function blocks SMC_ReadNCFile2 and SMC_NCInterpreter,
see the input documentation there.
This function block is used to provide an overview over a complete CNC program.
- InOut:
Scope
Name
Type
Initial
Comment
Input
bExecuteBOOLA rising edge starts the function block
udiNumberOfPointsInArrayUDINT0
Number of points which are declared in
pBufferof the referred array.pBufferPOINTER TO VisuStruct3DPathPoint
Pointer to the allocated array of points
sFileNameSTRINGCNC file name to be read
pvlPOINTER TO SMC_VarList
Pointer to variable list (see
SMC_NCReadNCFile2)piStartPositionSMC_PosInfostart position (see
SMC_NCInterpreter)aSubProgramDirsARRAY [0..4] OF STRING(174)
An array of up to 5 directories where subprograms are searched (see
SMC_ReadNCFile2)bParenthesesAsCommentsBOOLTRUE
If parenthesis should be considered as comments (See
SMC_ReadNCFile2)bEnableSyntaxChecksBOOLTRUE
bEnableSyntaxChecks (see
SMC_NCInterpreter)bStepSuppressBOOLWhen this input is
TRUE, lines of the CNC program starting with ‚/’ will be ignored. Otherwise they will be processed.eOriConvSMC_ORI_CONVENTIONSMC_ORI_CONVENTION.ADDAXES
Defines the way the orientation in the A/B/C words is interpreted (See
SMC_NCInterpreter)precisionLREAL1
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
bDoneBOOLTRUE: FB completedbBusyBOOLbErrorBOOLTRUE: error during operationiErrorIDSMC_ERRORError ID
vs3dtVisuStruct3DTrackTrack output. To be setup as input of the visu element
Path3D.