FB_DriveEnable - General Information

Overview

Type:

Function block

Available as of:

V1.0.3.0

Inherits from:

-

Implements:

-

Versions:

Current version

Task

Switching the position control of an axis on and off.

Description

If the input i_xEnableDrive = TRUE, a power supply of the axis (if present) is enabled, then the axis is position-controlled. The state of the axis is monitored.

If the input i_xEnableDrive = FALSE, the position control of the axis is disabled. A power supply which might be connected to the axis is not affected.

Interface

Input

Data type

Description

i_xEnable

BOOL

A rising edge FALSE -> TRUE activates the POU, a falling edge TRUE -> FALSE deactivates the POU.

A deactivated POU does not execute any actions.

i_ifDrive

IF_Drive

Input for the axis that shall be controlled.

i_xEnableDrive

BOOL

TRUE: A power supply of the axis (if present) is enabled, then the axis is position-controlled.

i_xDiagQuit

BOOL

A rising edge FALSE -> TRUE acknowledges a pending diagnostic message (output q_etDiag <> ET_Diag.Ok).

Output

Data type

Description

q_xActive

BOOL

TRUE: The POU is active and has to be executed further.

FALSE: The POU is inactive.

q_xReady

BOOL

TRUE: The POU is ready to operate and can accept user commands.

FALSE: The function block is not ready to accept user commands.

q_etDiag

GD.ET_Diag

General library-independent statement on the diagnostic.

A value not equal to ET_Diag.Ok corresponds to an diagnostic message.

q_etDiagExt

ET_DiagExt

POU-specific output on the diagnostic.

q_etDiag = ET_Diag.Ok -> Status message

q_etDiag <> ET_Diag.Ok -> Diagnostic message

q_sMsg

STRING[80]

Event-triggered message which gives more detailed information on the diagnostic state.

q_xDriveEnabled

BOOL

TRUE: Axis is in position control.

Diagnostic Messages

q_etDiag

q_etDiagExt

Enumeration value

Description

OK

Disabled

9

The POU is disabled.

OK

DriveEnabled

146

The drive is enabled.

OK

Initializing

4

The POU is being initialized.

OK

WaitForEnableDrive

136

Waiting for the drive to be enabled.

OK

WaitUntilDriveDisabled

179

Waiting until the drive is deactivated.

OK

WaitUntilDriveEnabled

145

Waiting until the drive is enabled.

OK

WaitUntilPowerSupplyEnabled

143

Waiting until the power supply is enabled.

OK

WaitUntilPowerSupplyReady

140

Waiting until the power supply is ready.

DriveConditionInvalid

DriveNotReady

10

The drive is not ready for motion commands.

DriveConditionInvalid

InverterEnableOff

41

The InverterEnable signal is not present.

DriveConditionInvalid

TorqueEnableOff

15

The TorqueEnable signal is not present.

InputParameterInvalid

DriveInvalid

3

The connected drive is invalid.

InputParameterInvalid

PowerSupplyInvalid

139

The connected power supply is invalid.

InputParameterInvalid

PowerSupplyNotFound

138

The connected power supply was not found.

PowerSupplyConditionInvalid

PowerSupplyNotReady

144

The connected power supply is not ready.

SercosConditionInvalid

SercosNotInPhaseFour

19

The Sercos bus is not in phase 4.

UnexpectedProgramBehavior

UnknownState

2

The POU is in an undefined state.

Disabled

Enumeration name:

Disabled

Enumeration value:

9

Description:

The POU is disabled.

The function block is disabled and executes no actions whatsoever. i_xEnable and q_xActive are set to FALSE

DriveEnabled

Enumeration name:

DriveEnabled

Enumeration value:

146

Description:

The drive is enabled.

The position control of the axis is activated.

DriveInvalid

Enumeration name:

DriveInvalid

Enumeration value:

3

Description:

The connected drive is invalid.

Issue

Cause

Solution

-

At the input i_ifDrive, no drive was applied.

At the input i_ifDrive, a valid drive must be transferred.

-

The connected drive does not support all required functionalities.

Establish which functionalities are not supported by the drive by means of output q_sMsg.

Use a drive which supports all required functionalities.

DriveNotReady

Enumeration name:

DriveNotReady

Enumeration value:

10

Description:

The drive is not ready for motion commands.

Issue

Cause

Solution

-

The axis is not in position control.

Verify the state of the axis.

Initializing

Enumeration name:

Initializing

Enumeration value:

4

Description:

The POU is being initialized.

The function block is being initialized and thus is not yet ready to receive commands at its inputs.

The function block will signalize that it is ready for operation with the signal q_xReady = TRUE.

InverterEnableOff

Enumeration name:

InverterEnableOff

Enumeration value:

41

Description:

The InverterEnable signal is not present.

Issue

Cause

Solution

-

The InverterEnable signal of the axis is not enabled.

Verify the wiring of the InverterEnable signal.

PowerSupplyInvalid

Enumeration name:

PowerSupplyInvalid

Enumeration value:

139

Description:

The connected power supply is invalid.

Issue

Cause

Solution

-

The connected power supply is not supported.

Please contact the support team.

PowerSupplyNotFound

Enumeration name:

PowerSupplyNotFound

Enumeration value:

138

Description:

The connected power supply was not found.

Issue

Cause

Solution

-

No power supply has been applied.

Add a power supply in the PLC configuration.

-

No power supply has been connected.

Connect the power supply to the axis.

PowerSupplyNotReady

Enumeration name:

PowerSupplyNotReady

Enumeration value:

144

Description:

The connected power supply is not ready.

Issue

Cause

Solution

-

The connected power supply is not ready.

Verify the state of the PowerSupply for errors.

SercosNotInPhaseFour

Enumeration name:

SercosNotInPhaseFour

Enumeration value:

19

Description:

The Sercos bus is not in phase 4.

Issue

Cause

Solution

-

The parameter State of the Sercos bus is not 4.

Set the Sercos bus parameter PhaseSet to 4.

Verify the Sercos bus for errors.

TorqueEnableOff

Enumeration name:

TorqueEnableOff

Enumeration value:

15

Description:

The TorqueEnable signal is not present.

Issue

Cause

Solution

-

The TorqueEnable signal of the axis is not enabled.

Verify the hard-/software wiring of the TorqueEnable signal.

UnknownState

Enumeration name:

UnknownState

Enumeration value:

2

Description:

The POU is in an undefined state.

Issue

Cause

Solution

-

An error occurred in the internal execution.

Please inform the support team about this error.

WaitForEnableDrive

Enumeration name:

WaitForEnableDrive

Enumeration value:

136

Description:

Waiting for the drive to be enabled.

The initialization of the function block is complete. Via the input i_xEnableDrive, it is now possible to enable the position control for the axis.

WaitUntilDriveDisabled

Enumeration name:

WaitUntilDriveDisabled

Enumeration value:

179

Description:

Waiting until the drive is deactivated.

The function block awaits the disabling of the axis.

WaitUntilDriveEnabled

Enumeration name:

WaitUntilDriveEnabled

Enumeration value:

145

Description:

Waiting until the drive is enabled.

The axis is being enabled.

WaitUntilPowerSupplyEnabled

Enumeration name:

WaitUntilPowerSupplyEnabled

Enumeration value:

143

Description:

Waiting until the power supply is enabled.

The function block waits for the connected power supply to switch over to a GroupState >= 3.

WaitUntilPowerSupplyReady

Enumeration name:

WaitUntilPowerSupplyReady

Enumeration value:

140

Description:

Waiting until the power supply is ready.

The function block waits for the connected power supply to switch over to a GroupState >= 2.

Methods

Name

Description

RegisterLoggerPoint

Registering the logger points of the POU in the Application Logger