L_MK1P_AddAxisToKinematic
This FB can be used to connect an axis (AXIS_REF) with a single-axis kinematic as a main or following axis. The input wIdentInKinematic can be used to select the position in the kinematic at which the connected axis is to be inserted. For the gantry axis, this is possible as a main axis (wIdentInKinematic = 1) and follwoig axis (wIdentInKinematic = 2). The function block is commanded via a positive edge at xExecute.
|
|
|
|
L_MK1P_AddAxisToKinematic |
|
|
|
|
|---|---|---|---|---|---|---|---|
|
AXIS_REF |
- |
|
Axis |
xDone |
|
- |
BOOL |
|
L_MK1P_IConfigureKinematicAxis |
- |
|
Kinematic |
xBusy |
|
- |
BOOL |
|
BOOL |
- |
|
xExecute |
xError |
|
- |
BOOL |
|
WORD |
|
|
wIdentInKinematic |
eErrorID |
|
- |
L_IE1P_Error |
Inputs
|
Name Data type |
Info/setting options |
|
|---|---|---|
|
xExecute BOOL |
Execution of the FB |
|
|
Axis AXIS_REF |
Motion axis to be used in the kinematics. |
|
|
Kinematic L_MK1P_IConfigureKinematicAxis |
Interface to the kinematic with which the axis should be connected. (e.g. gantry L_MK1P_Gantry) |
|
|
wIdentInKinematic WORD (L_MK1P_IdentInKinematic) |
Assignment of which link should be connected in the kinematic. Example gantry: 1: Main axis 2: Secondary axis |
|
Outputs
|
Name Data type |
Value/meaning |
|
|---|---|---|
|
xDone BOOL |
Motion axis was successfully connected with the kinematics |
|
|
xBusy BOOL |
New connection is being configured |
|
|
xError BOOL |
An error has occurred. |
|
|
eErrorId L_IE1P_Error |
Error ID |
|
Example call
---------------------------------------------------------------
//Declaration
VAR
AddAxis: L_MK1P_AddAxisToKinematic;
xAddAxis: BOOL;
END_VAR
---------------------------------------------------------------
// Instance call (here axis "GantryAxis_re" in the kinematics "Gantry" as // main axis)
AddAxis(Axis := GantryAxis_re,Kinematic := Gantry, wIdentInKinematic := 1, xExecute:= xAddAxis);
---------------------------------------------------------------