FB_AX200X_Profibus
The FB_AX200X_Profibus function block combines the three previous function blocks. It offers the complete interface to the AX2000 with access to all functions (except parameters).
Inputs
VAR_INPUT
bInit : BOOL;(*Initialization*)
bMode_DigitalSpeed : BOOL;(*OP-Mode digital speed instead of Positioning*)
iDigitalSpeed : DWORD;(*digital speed if OP-Mode = digital speed*)
iVelocity : DWORD;(*Velocity*)
iPosition : DINT;(*Position*)
iRunningMode : BYTE;(*0:digital speed, 1: motiontask, 2: JogMode, 3: Calibration*)
imotion_tasknumber : WORD;(*number of EEPROM-saved motion-task*)
imotion_blocktype : WORD:=16#2000;(*optional Parameters of motion tasks, default:SI-values*)
iJogModeBasicValue : INT;(*BasicVelocity for JogMode*)
iCalVelo : WORD;(* basic velocity of Calibration*)
bSetRefPoint : BOOL;(* set Reference Point*)
bStart : BOOL;(*START*)
bStop : BOOL;(*STOP*)
bShortStop : BOOL;(* break of motion task*)
iSlaveAddress : BYTE;(* Station Address of the Slave *)
iFC310xDeviceId : WORD;(* Device-ID of the FCxxxx *)
bErrorResume : BOOL;(*Error resume*)
tTimeOut : TIME := DEFAULT_ADS_TIMEOUT;
END_VAR
Name | Type | Description |
---|---|---|
bInit | BOOL | Initialization of the drive. If bInit is TRUE then operation mode 2, "positioning", is set in the drive. |
bMode_DigitalSpeed | BOOL | This is set if the drive is to be set to ‘Digital speed’ operation mode during the initialization. |
iDigitalSpeed | DWORD | Speed in the ‘Digital speed’ operation mode. |
iVelocity | DWORD | The parameter contains the required velocity for a subsequent motion command, e.g. µm/s. |
iPosition | DINT | Target position |
iRunningMode | BYTE | 0: Digital speed, 1: Motiontask, 2: JogMode, 3: Calibration. |
imotion_tasknumber | WORD | Motion block number. This input can be used to select a motion block previously stored in the drive's memory. |
imotion_blocktype | WORD | Motion block type (optional). This input can be used to modify properties of a direct motion command. |
iJogModeBasicValue | INT | Basic velocity for jog mode; the actual velocity is derived from the basic velocity and the "v-jog mode" factor for the drive. |
iCalVelo | WORD | Basic velocity for homing. The final velocity is composed of the basic velocity and the "v-jog mode" factor for the drive. |
bSetRefPoint | BOOL | Setting the reference point |
bStart | BOOL | Starting the action, depending on the state of iRunningMode. |
bStop | BOOL | Stopping the action, depending on the state of iRunningMode. |
bShortStop | BOOL |
|
iSlaveAddress | BYTE | Station address |
iFC310xDeviceId | WORD | Device-ID |
bErrorResume | BOOL | An “AX200X error” is reset with a positive edge at this Boolean input (no TimeOut error). |
tTimeOut | BOOL | Maximum time allowed for the execution of the command. |
Inputs/outputs
VAR_IN_OUT
stPZDIN : ST_PZD_IN;
stPZDOUT : ST_PZD_OUT;
END_VAR
Name | Type | Description |
---|---|---|
stPZDIN | Data words from the drive to the PLC. | |
stPZDOUT | Data words from the PLC to the drive. |
Outputs
VAR_OUTPUT
bBusy : BOOL;
bError : BOOL;(*Errorstatus of Servo*)
iErrID : DWORD;
bTimeOutErr : BOOL;
bInitOK : BOOL;(*Initialization OK*)
iactPosition : DINT;(*actual Position SI-value*)
END_VAR
Name | Type | Description |
---|---|---|
bBusy | BOOL | This output remains TRUE until the function block has executed a command. While Busy = TRUE, no new command will be accepted at the inputs. Note that it is not the execution of the service that is monitored in terms of time, but only its acceptance. |
bError | BOOL | This output shows the error state. |
iErrID |
DWORD |
Contains the command-specific error code of the most recently executed command. Is reset to 0 by the execution of a command at the inputs. |
bTimeOutErr |
BOOL |
TimeOut error |
bInitOK |
BOOL |
Initialization state of the drive, bInit:= TRUE: Drive is initialized and in operation mode 2 'Positioning'. |
iactPosition |
DINT |
Current position display in RunningMode 1: Motiontask. |
Requirements
Development environment | Target platform | IO hardware | PLC libraries to be integrated (category group) |
---|---|---|---|
TwinCAT v3.1.0 | PC or CX (x86) | AX2000 Profibus box | Tc2_IoFunctions (IO) |