SMC_ReadNCQueue (FB)¶
FUNCTION_BLOCK SMC_ReadNCQueue
This FB is used for files created with Codesys V2.3; To write the queue to a file or to read the queue from a file: the FBs SMC_WriteQueueToFile and SMC_ReadQueueFromFile from SM3_Debug library can be used. This function block will read an SMC_OUTQUEUE file, which has been created by the CNC editor, from the PLC file system and provide an OutQueue structure, which typically is processed by the decoder.
- InOut:
Scope
Name
Type
Initial
Comment
Input
bExecuteBOOLFALSE
Rising edge: Starts execution. While
TRUE, the function block stays activesFileNameSTRING(255)‘’
File path
pBufferPOINTER TO BYTE
Pointer on a sufficiently large, free data area (buffer) that is allocated in the IEC application.
dwBufferSizeDWORD0
Size of the buffer in byte
Output
bDoneBOOLFALSE
TRUE, if execution finished sucessfully.bBusyBOOLFALSE
TRUE, while execution of function block is not finishedbErrorBOOLFALSE
Signals, that an error has occurred within the function block
ErrorIDSMC_ERROR0
Error identification
poqDataOutPOINTER TO SMC_OUTQUEUE
Pointer on queue that has been read in.
iObjectsReadUDINT0
Number of SMC_GEOINFO objects, which have been read and written to the queue up to now.
Structure: