MC_GearInFloat
The function block MC_GearInFloat activates a linear master-slave coupling (gear coupling). The block accepts a fixed gear ratio in a LREAL format. Alternatively the blocks MC_GearIn with a numerator-denominator gear ratio and MC_GearInDyn with a dynamically changeable gear ratio are available.
Note:
The coupling can be activated only in standstill. The inputs Acceleration, Deceleration and Jerk are not used.
Moving axes can be coupled using the optional Flying Saw functionality (MC_GearInPos, MC_GearInVelo).
VAR_INPUT
VAR_INPUT
Execute : BOOL;
GearRatio : LREAL;
Acceleration : LREAL;
Deceleration : LREAL;
Jerk : LREAL;
END_VAR
Execute : The command is executed with rising edge.
GearRatio : Gearing factor.
Acceleration : Acceleration (not used)
Deceleration : Deceleration (not used)
Jerk : Jerk (not used)
VAR_OUTPUT
VAR_OUTPUT
InGear : BOOL;
CommandAborted : BOOL;
Error : BOOL;
ErrorID : UDINT;
END_VAR
InGear : Becomes TRUE, if the coupling was successful.
CommandAborted : Becomes TRUE, if the coupling could not be carried out.
Error: Becomes TRUE, as soon as an error occurs.
ErrorID : Supplies the error number when the Error output is set
VAR_IN_OUT
VAR_IN_OUT
Master : NCTOPLC_AXLESTRUCT;
Slave : NCTOPLC_AXLESTRUCT;
END_VAR
Master : Axis structure of the master.
Slave : Axis structure of the slave.
Requirements
Development environment | Target system type | PLC libraries to be linked |
---|---|---|
TwinCAT v2.8 | PC (i386) | TcMC.Lib |