TB_DriveState

Representation in FBD

General Information

The TB_DriveState function module makes available all required information on the status of the drive.

This function module reads the drive status, i.e. all relevant information, such as hardware inputs, status word, errors and warnings. Using this information, it is possible to check whether the drive is ready to be switched on before switching on with MC_PowerOn, for example. In addition, constant checking of whether errors or warnings arise can be carried out.

Recommended task: CYCLIC
Libraries used: MOTION_CONTROL_30bd00 or greater
Additional data type definitions: ...
Use of Static-Variables: ...

InOut Parameter

none

Input Parameter

Marking: Data type: Default: Data range: Description:
x_Enable BOOL ... ... TRUE: Enabling of the module.
_Axis AXIS_REF ... ... The Motion Control axis is connected to _Axis.

Output Parameter

Marking: Data type: Description:
x_DriveRdy BOOL TRUE: Communication to the drive is ready. Here it is checked whether both the demand data communication and the cyclical communication (incl. UserMapping) are ready. Both local and field bus axes are checked.
x_DriveComRdy BOOL TRUE: Drive is ready for switch-on.
This output is a link from all relevant states.

x_DriveRdy:= x_Enable
AND x_DriveComRsy
AND NOT x_Error
AND x_LinkVolt
AND x_HW_PulsEnable
AND x_HW_QuickStop
AND NOT x_HW_SafetyRelais;
w_Statusword WORD Status word of the drive (P301).
i_Status INT Drive status corresponding to the status machine of the drive and displayed at the drive display. States 0 to 5 and 15/F are indicated; states 6 to 7 and 14/E are not indicated.
0: Not ready for switch-on
1: Switch-on block
2: Ready for switch-on
3: Switched on
4: Operation enabled
15/F: Fault
x_Error BOOL TRUE: Movement execution is started. The axis is coupled to the master value.
x_Warning BOOL TRUE: Drive warning
x_LinkVolt BOOL TRUE: System voltage/Intermediate circuit voltage is applied
x_HW_PulsEnable BOOL TRUE: Pulse enable input at drive is closed
x_HW_Quickstop BOOL TRUE: Quick stop input at drive is closed.
x_HW_SafetyRelais BOOL TRUE: Undervoltage in safety relay.
x_ComError BOOL TRUE: Demand data communication error of the internally used BM_ReadPar function module. Using the demand data communication, the states of the drive not supplied via the AXIS_REF structure are read.
_Axis AXIS_REF Motion Control axis.