SMC_AxisDiagnosticLog (FB)¶
FUNCTION_BLOCK SMC_AxisDiagnosticLog
This function block is designed for writing cyclically a set of parameter values belonging to one axis to a file.
This output file is ideal for diagnosis purposes.
As the writing of data on a data medium usually needs some time, this module stores the collected data in a buffer
of size 10 kByte and the data will not be written until module action WriteToFile is called.
This action call should be placed in a slower (ca. 50 ms) task of lower priority, in order to prevent the actual
motion task as well as the motion itself from being disturbed. As soon as the buffer is exceeded, the module will
create an error output.
- InOut:
Scope
Name
Type
Initial
Comment
Inout
AxisInput
bExecuteBOOLRising edge: Starts the execution of the function block.
bCloseFileBOOLThe module closes the file as soon as this input gets TRUE.
sFileNameSTRING(255)File name (preceded by path).
bSetPositionBOOLTRUE: The associated value of the axis to be written to the file.bActPositionBOOLTRUE: The associated value of the axis to be written to the file.bSetVelocityBOOLTRUE: The associated value of the axis to be written to the file.bActVelocityBOOLTRUE: The associated value of the axis to be written to the file.bSetAccelerationBOOLTRUE: The associated value of the axis to be written to the file.bActAccelerationBOOLTRUE: The associated value of the axis to be written to the file.bySeparatorCharBYTE9
ASCII-Code of the letter, which is to be written between two values of same date.
sRecordSeparatorStringSTRING(3)‘$R$N’
String to be written at the end of a date.
eModeLOG_CONTINUOUS
LOG_CONTINUOUS: Continuous logging into file.LOG_AT_CLOSE: Continuous logging into buffer (10kByte). WhenbCloseFileis set, the buffer content is written to file.Output
bDoneBOOLTRUE: Logging has been terminated and file is closed.bBusyBOOLFALSE
TRUE: Execution of function block has not been finished.bErrorBOOLTRUE: Error has occurred within the function block.ErrorIDSMC_ERRORError identification
bRecordingBOOLFALSE
TRUE: Module records.
Structure: