Pipe Blocks Description
-
-
Click a Pipe Block icon in the figure below to display its description.
Master
PURPOSE
In contrast to the independent axes approach, synchronized axes must have something to put them in synchronization. This is the main goal of the Master pipe block which contains a TMP "Trapezoidal Motion Profile" This pipe block is a source block that frequently serves as a virtual master for a system composed of several pipes. Generally, a trapezoidal motion profile generator is used to generate a flow of values with a first derivative which produces a trapezoidal trajectory (Trapezoidal Motion Profile) generator, which gives the cadence to the machine. It starts, stops and runs the machine at the desired speed.
The TMP Generator provides linear acceleration and deceleration, and also constant speed operation. These values are pure logical values, with generally no direct physical representation. It is a source block which frequently serves as a virtual master for a system comprised of several pipes.
A TMP Generator may be commanded to produce a movement of specified length (distance), or to accelerate to setpoint Setpoint is the target value that an automatic control system, for example PID controller, will aim to reach rate and operate at that rate until commanded to operate at a different rate. Acceleration and deceleration rates are also specified by the application.
PARAMETERS
Parameter | Description |
---|---|
Sampling Period | Sampling period of the generator expressed according to the cycle (e.g. 2.0 means the sampling is done once every 2 cycles) |
Mode | The available modes are Modulo and "No Modulo" |
Modulo Position | Modulo Position for cyclic motion systems expressed in user logical units |
Travel Speed | Travel speed value expressed in user position units per second. The travel speed value is used to set the constant speed part of the trapezoidal motion profile |
Acceleration | Acceleration value expressed in user position units per second squared. The acceleration value is always used to generate the first part of the trapezoidal motion profile |
Deceleration | Deceleration value expressed in user position units per second squared. The deceleration value is always used to generate the last part of the trapezoidal motion profile |
Initial Position | Initial position value expressed in user position units. Used only at the pipe activation to initialize the position starting point |
ASSOCIATED DATA
- OutputValue: output value of the data flows
- IsReady: Boolean set to TRUE when the pipe block is ready
MOTION FUNCTIONS
To access the motion functions associated to this pipe block, Motion Library - Master
PMP
PURPOSE
PMP (Parabolic Motion Profile) pipe block generates a flow of values with a second derivative (acceleration) which produces a trapezoidal trajectory. The PMP Generator is similar to the TMP Generator. However, it is useful in applications where jerk In physics, jerk is the rate of change of acceleration; more precisely, the derivative of acceleration with respect to time (third derivative of the motion) limiting is necessary. Although you can specify the maximum instantaneous rate of change of acceleration.
USES
The PMP Generator is utilized as a virtual master to generate a simple point-to-point profile in machinery where large masses are being rotated or delicate webs (used in industry) are being processed. In fact, it is used in any application where jerk must be limited.
The PMP Generator is also capable of producing forward-backward motions with a non-stop, jerk-free transition through zero speed (see the figure below). This feature is frequently used for linear axes which must make a quick back-and-forth motion without any pause at one end.
Figure 5-15: PMP Generator forward & backward motion profile
PARAMETERS
Parameter | Description |
---|---|
Sampling Period | Sampling period of the generator expressed in seconds |
Modulo Position | Modulo Position for cyclic motion systems expressed in user logical units |
First Travel Speed and Last Travel Speed | Travel speed values expressed in user position units per second. The travel speed values are always used to set the constant speed part of the motion profile |
Acceleration | Acceleration value expressed in user position units per second squared. The acceleration value (subject to constraints imposed by the JERK parameter) is always used to generate the portions of the motion profile where velocity is changing |
Jerk In physics, jerk is the rate of change of acceleration; more precisely, the derivative of acceleration with respect to time | Jerk value expressed in user position units per second cubed. The jerk value is used to generate rounded part of the speed motion profile. Jerk is the derivative of the acceleration, so it specifies the acceleration ramp |
Initial Position | Initial position value expressed in user position units, used only at the pipe activation to initialize the position starting point |
ASSOCIATED DATA
- OutputValue: output value of the data flows
- IsReady: Boolean set to TRUE when the pipe block is ready
MOTION FUNCTIONS
To access the motion functions associated to this pipe block, Motion Library - PMP
Sampler
PURPOSE
The purpose of the sampler block is to periodically sample and place into a pipe some output of a source object. The sampled output might typically be the POSITION or SPEED of the source object measured by a resolver, an encoder or some other types of sensor A sensor is a type of transducer that converts one type of energy into another for various purposes including measurement or information transfer.
The sampler implements a logical connection between an external master (source object outside the KAS system) and one or more pipes for the purpose of slaving the motion of the KAS system to the external master by placing the sampled values into the pipes.
PARAMETERS
ASSOCIATED DATA
- OutputValue: output value of the data flows
- IsReady: Boolean set to TRUE when the pipe block is ready
MOTION FUNCTIONS
To access the motion functions associated to this pipe block, Motion Library - Sampler
Derivator
PURPOSE
The Derivator is a general pipe block whose purpose is to calculate the first derivative of its input values with respect to time.
It is usually used to change incoming position into velocity. It often works together with the GEAR block as gearing in velocity to avoid jumps when suddenly changing the position.
Figure 5-25: Derivator - "No Modulo" Mode
Figure 5-26: Derivator - Modulo Mode
PARAMETERS
Parameter | Description |
---|---|
Input Modulo Position |
Value of the period of a cyclic system expressed in user units.
|
INITIAL BEHAVIOR
The first calculation of a Derivator pipe block just after the pipe installation indicates zero regardless of the initial input value.
ASSOCIATED DATA
- OutputValue: output value of the data flows
- IsReady: Boolean set to TRUE when the pipe block is ready
MOTION FUNCTIONS
To access the motion functions associated to this pipe block, Motion Library - Derivator
Integrator
PURPOSE
Integrates the input data flow.
Usually used to change velocity to position, and the output is the starting point from where the integration starts.
Figure 5-27: Integrator - "No Modulo" Mode
Figure 5-28: Integrator - Modulo Mode
PARAMETERS
Parameter | Description |
---|---|
Mode | The available modes are Modulo and "No Modulo" |
Output Modulo Position | When mode is set to Modulo, integrate the input values with respect to time. "OUTPUT_MODULO_POSITION" is defined to correctly manage the periodicity (modulo) of the output values |
ASSOCIATED DATA
- OutputValue: output value of the data flows
- IsReady: Boolean set to TRUE when the pipe block is ready
MOTION FUNCTIONS
To access the motion functions associated to this pipe block, ssMotion Library - Integrator
Adder
PURPOSE
Adds two data flows (the output is the algebraic sum of the two inputs).
Before being added, input values may be amplified and shifted (multiplication factor and offset are individually defined for each input).
PARAMETERS
Parameter | Description |
---|---|
Ratio | Multipliers for the input data flows |
Offset | Offset values for the input data flows |
Output = (Ratio_1 * Input_1 + Offset_1) + (Ratio_2 * Input_2 + Offset_2)
RULES
-
-
Important! The two following rules apply to the Adder pipe block
Rule 1: The pipe blocks connected to the Adder inputs (e.g. a Cam and a Gear
Rule 2: The modulo position of the pipe blocks connected to the Adder inputs must have the same value (or a multiple) as the modulo position of the pipe block connected to the output of the Adder.
ASSOCIATED DATA
- OutputValue: output value of the data flows
- Entry1: input value 1
- Entry2: input value 2
MOTION FUNCTIONS
To access the motion functions associated to this pipe block, idMotion Library - Adder
Synchronizer
PURPOSE
The Synchronizer provides the capability to de-synchronize and re-synchronize an axis to an internal or external master like a mechanical clutch / brake. It is used where a slave axis must be stopped and, when restarted, achieve perfect, jerk-free re-synchronization with the master. The ramping distance (increment of slave axis motion within which ramp up or ramp down occurs) and the slave axis resting position are adjustable.
PARAMETERS
Such a pipe block can be used, for instance, when an item is missing on a conveyor.
Figure below illustrates the application of a Synchronizer which enables a slave axis to be stopped, started and re-synchronized to an external master.
Figure 5-29: Synchronizer Pipe Block to Start, Stop and Re-synchronize a Slave Axis
ASSOCIATED DATA
- OutputValue: output value of the data flows
- IsReady: Boolean set to TRUE when the pipe block is ready
MOTION FUNCTIONS
To access the motion functions associated to this pipe block, Motion Library - Synchronizer
Delay
PURPOSE
Delay the data flow a number of cycles.
PARAMETERS
Parameter | Description |
---|---|
Cycle Delay | Number of cycles for postponement |
ASSOCIATED DATA
- OutputValue: output value of the data flows
- IsReady: Boolean set to TRUE when the pipe block is ready
MOTION FUNCTIONS
To access the motion functions associated to this pipe block, Motion Library - Delay
Comparator
PURPOSE
A Comparator monitors the flow of pipe data and causes a specified action when the flow of values at its input crosses a specified reference value. A Comparator is often used for synchronizing the operation of an actuator A mechanical device for moving or controlling a mechanism or system. An actuator typically is a mechanical device which transforms an input signal (usually an electrical signal) into motion to the position of a product or axis in a machine cycle. The Comparator block does not modify flow values and has no effect on the axis and its periodicity.
PARAMETERS
The necessity to use the through zero reference mode is illustrated with the following example. Assume that the system is a periodic system with a Modulo Position of 500. The system is running in the positive direction (pipe flow values increase). Imagine that the position of the system is now 400 and you want to wait for the system to reach 326 again. If you ask for the Comparator to detect the 326 reference in normal mode, it will immediately set the ready flag at true (400 > 326) but this is not what you want. If you ask for the Comparator to detect the 326 value in through zero reference mode, it will wait for the system to cross one zero reference (cross the position value = 0) and then will trigger the application when the correct condition is fulfilled.
There is a big difference in response time when using a Boolean equation to compare a value with a reference, versus using a Comparator pipe block do to the same processing. With the Boolean equation, KAS periodically performs the comparison, ignoring any dynamics taking place between successive comparisons, which could result in delays in triggering sequences, and possible loss of information when the pipe-flow value crosses the reference momentarily between comparisons. With a Comparator, the value of the ready flag is intrinsically updated each time a new pipe-flow value is computed. Therefore, it is impossible to lose any transitions.
The figure below illustrates an application of the Comparator. In this example, an output valve controlled by a Comparator is added to the filling mechanism from the example in the Cam pipe block. When cam position crosses the value "Trigger 1", the Comparator initiates the "Open Routine" which, in turn, opens the output valve. Next, the Comparator is set to the value "Trigger 2". When the cam position crosses the "Trigger 2" value, the Comparator initiates the "Close Routine" and the valve is closed. The Comparator is again set to the value of "Trigger 1" and the cycle restarts. A user output resident in the Drive operates the valve.
Figure 5-30: Comparator Used to Control a Valve on a Filler Mechanism
ASSOCIATED DATA
- OutputValue: output value of the data flows
- IsReady: Boolean set to TRUE when the pipe block is ready
Trigger
PURPOSE
Computes the local pipe value from the timestamp A timestamp is a sequence of characters, denoting the date and/or time at which a certain event occurred of a Fast Input time event . Pipe input values are passed through to the block output with no influence on the flow of pipe values.
Typical application is for PLCopen Registration.
Figure 5-31: Trigger Extrapolates Output Value Based on Fast Input Timestamp
-
- There are network and mechanical delays in systems that will make capturing a correct pipe position difficult. To remove the delays, you should use a sampler block to capture the actual position of an axis. The following shows how this works.
The sampler block above is configured to capture the actual position of axis 1. The conversion and axis blocks are only needed to terminate the pipe. MLTrigWriteDelay may still be needed to compensate for sensor delay.
If you need to calculate the master pipe value corresponding to the captured axis position, you need to add the difference between the axis command position and the master pipe value.
PARAMETERS
ASSOCIATED DATA
- OutputValue: output value of the data flows
- TRIG_POS: interpolated position calculated when the time event was triggered (reserved for debugging purposes)
- TRIG_TIME: time when the event was triggered (reserved for debugging purposes)
- DELTA_TRIG_TIME: reserved for debugging purposes
MOTION FUNCTIONS
To access the motion functions associated to this pipe block, Motion Library - Trigger
See Fast Inputs with Pipe Network Motion for more details.
Gear
PURPOSE
The purpose of the Gear block is to amplify/attenuate (with a ratio) and shift (with an offset) the flow of values. A Gear may have a ratio and offset less or greater than one, or even zero. Ratio and offset may be changed dynamically during application execution. A slope may be specified to limit the rate at which step changes in ratio and offset are implemented.
PARAMETERS
Parameter | Description |
Ratio | Ratio coefficient |
Offset | The input offset value |
Ratio and Offset Slope | Sets the maximum rate of change at the pipe block output resulting from changes in RATIO or OFFSET parameters. When set to the MAX (which is the default setting), the slope is infinite. Units are user units per second for OFFSET SLOPE and 1/second for RATIO SLOPE |
Modulo |
When set to TRUE, adapts the output values according to the periodicity (modulo) |
Output = Ratio * Input + Offset
ASSOCIATED DATA
- OutputValue: output value of the data flows
- IsReady: Boolean set to TRUE when the pipe block is ready
- INPOS: reserved for debugging purposes
MOTION FUNCTIONS
To access the motion functions associated to this pipe block, Motion Library - Gear
Cam
PURPOSE
The Cam block is used to generate motion profiles of any shape. The profile generally represents the position transformation.
-
-
To avoid jerk in the pipe network (which ultimately may cause a jerk in motor motion when a cam block is applied to the upstream pipe network positions) the potential position offset between the cam's first point and the input to the cam block must be taken care of in the application program by setting a cam offset or another method.
DECLARATIONS
Separating the declaration of the Cam and profile parameters for the Cam pipe block provides the capability to declare and prepare several different cam profiles, and then apply one of these dynamically to the Cam pipe block. Profile switching may be done on the fly, without losing the synchronization and with no dead time.
In addition, the periodicity of the cam output values can be specified when used with a periodic system.
PARAMETERS
Parameter | Description |
---|---|
Profile Name | Name of the current profile assigned to the cam. It must be a declared profile object |
Output Modulo Position | Value of the period of the cam output values expressed in user units, for a cyclic system |
SHAPE SPECIFICATION
The shape of the cam profile must be processed by the Cam Profile Editor utility before it is usable by the PipeNetwork Editor.
The shape of the profile is represented by a table of numerical values. These values can be generated using software tools such as spreadsheets or specialized cam software.
The KAS Cam Editor software tool provides the capability to visualize, analyze, edit and smooth profiles.
Cam blocks have gain as well as offset adjustment capabilities. Axis position is usually the profile variable; however, velocity or torque Torque is the tendency of a force to rotate an object about an axis. Just as a force is a push or a pull, a torque can be thought of as a twist profiles may also be generated.
The mathematical relationship of the cam output as a function of the input and the cam parameters is as follows:
If Oin ≤ Xi ≤ Oin + Ain then Yi = Oout + (fct((Xi - Oin)/Ain) * Aout)
Within the stated limits, the following functions apply:
If Xi < Oin then Yi = Oout + (fct(0.0) * Aout) If Xi > Oin + Ain then Yi = Oout + (fct(1.0) * Aout)
With:
Parameter | Definition |
---|---|
Xi | Input value |
Oi | Input offset |
Ain | Input amplitude |
fct | the function defining the shape |
Yi | Output value |
Oout | Output offset |
Aout | Output amplitude |
The figure below illustrates the use of the Cam blocks in a three-axes container filler mechanism. The cam profile for axis 1 controls the volume of liquid dispensed and the fill rate; Axis 2 raises and lowers the container; and Axis 3 indexes containers under the filling mechanism. All three axes track the main machine motion profile produced by a TMP Generator.
Figure 5-33: Cam Blocks Control Operation of a Three Axis Filling Mechanism
ASSOCIATED DATA
- OutputValue: output value of the data flows
- IsReady: Boolean set to TRUE when the pipe block is ready
MOTION FUNCTIONS
To access the motion functions associated to this pipe block, Motion Library - Cam Profile
Phaser
PURPOSE
A Phaser produces a flow of output values which are offset (phase shifted) a specified amount from its input. A typical application of a Phaser is to provide independent phase adjustment capability on an axis.
The Phaser has some similarities with the gear pipe block, however its intended use is quite different. The typical application for a Phaser pipe block is to drive a periodic system: that
is to say, a machine where the axes are globally increasing (or decreasing) their position. On the other hand, the gear pipe block, with OFFSET and RATIO parameters, is intended for bounded applications (applications where the integral of speed on a
complete cycle is zero). Using the wrong one at the wrong place will cause unnecessary complications.
In addition, you must always consider the position as the input value (and not the speed).
PARAMETERS
Parameter | Description |
---|---|
Output Modulo Position | Defined to correctly manage the periodicity (modulo) of the output values. Expressed in user units |
Phase | Magnitude of the number added to the input value. Phase value may also be negative. A negative phase value is subtracted from the input value. Phase is expressed in user logical units |
Phase Slope Type |
You can choose among two modes to define the slope:
|
Phase Slope | Rate at which phase changes are implemented, expressed in user logical units per second. A slow rate parameter is provided to limit the implementation of step changes of phase |
Standby Value | Value assumed by the phaser output when the phaser is in "stopped" condition, expressed in user logical units |
ASSOCIATED DATA
- OutputValue: output value of the data flows
- IsReady: Boolean set to TRUE when the pipe block is ready
MOTION FUNCTIONS
To access the motion functions associated to this pipe block, Motion Library - Phaser
Convertor
PURPOSE
The convertor block is necessary to define the connection between a pipe and a destination object. Depending on convertor mode, the incoming numerical values are converted to POSITION or SPEED setpoints with no periodicity.
This conversion has no effect on the axis units and their periodicity.
This block must be present at the end of a pipe, typically right before an axis block.
Figure 5-34: Convertor - Position Mode "No Modulo"
Note that Output position values are identical to input values when inputs in position mode (by range)
Figure 5-35: Convertor - Position Mode (Modulo)
Figure 5-36: Convertor - Speed Mode
PARAMETERS
Parameter | Description |
---|---|
Mode |
The available modes are:
|
ASSOCIATED DATA
- OutputValue: output value of the data flows
- IslinkedToAxis: Boolean set to TRUE when the Convertor pipe block is linked to an axis block
MOTION FUNCTIONS
To access the motion functions associated to this pipe block, Motion Library - Convertor
Axis
PURPOSE
Models the link from the Pipe Network to a physical axis.
Gives access (through the fieldbus) to remote drive's functions and parameters.
Automatically updates the image of the remote drive's status and error information.
PARAMETERS
Parameter | Description |
---|---|
Position Unit |
This field sets the units (see UNIT Parameters ) used by the drive axis. When the axis is defined as an AKD2G, the units and value will be synchronized with the drive.
|
User Units Per Revolution |
To divide the current axis into graduations adapted to your project, you must define the unit that is equivalent to one revolution of the physical motor. (E.g. 3600 means that you define the user unit to be tenth of a degree) You can rely on expression to define values. See example with expressions
Gear factor 1:3 and 1000.0 User Units per one gear shaft revolution // user units per revolution calculation example #define DEF_BandGear 3.0 // gearbox ratio #define DEF_BandUnit 1000.0 // user units for 1 mechanical turn #set DEF_BandUUperRev DEF_BandUnit/DEF_BandGear
Figure 5-37: Define Value with Expressions For more details on Definitions, refer to Use the Defines List |
Unit Label | Specify the type of units being used. This is used for display purposes. |
Travel Speed | Travel speed value expressed in user length units per second. The travel speed value is used to set the constant speed part of the trapezoidal motion profile |
Acceleration | Acceleration value expressed in user length units per second squared. The acceleration value is always used to generate the first part of the trapezoidal motion profile |
Deceleration | Deceleration value expressed in user length units per second squared. The deceleration value is always used to generate the last part of the trapezoidal motion profile |
Mode |
The available modes are Modulo and "No Modulo" See more details on Modulo or "No Modulo" axis
Depending on the type of the moving object the axis acts on, you can define the MODULO_POSITION parameter or not. Moving objects, performing a never ending cyclical motion are called periodic (e.g. printing cylinder, cutting wheel). In the following example, if a user unit = 0.1 mm has been chosen, a Modulo Position = 2000 Units could be selected for this transportation system.
No Modulo Objects always moving within a certain position range (forward/backwards) can be called linear or range axes (e.g. lift axis, moving tables). In the following example, if a user unit = 0.1 mm has been chosen, a position range = 0 to 10'000 Units could be selected for this moving table.
|
Rollover Position | Modulo Position for cyclic motion systems expressed in user logical units |
Motion Bus | Select in the drop-down menu the type of motion bus associated to the axis. This is only available when using an imported ENI file. |
Address | Specify the address number depending on the motion bus. This is only available when using an imported ENI file. |
Drive Axis Number | This is only available when using an imported ENI file. |
Drive Units per Revolution | Number of units associated to the Drive for one revolution of the physical motor. This is only available when using an imported ENI file. |
Associated data on Positions
The following data are illustrated in the figure below.
-
-
All positions are in user units with modulo applied if active, unless specified.
Position / Offset | Description |
---|---|
Actual Position |
Actual Position refers to the actual position of the underlying axis as reported by the drive. It is the sum of the feedback value (Position actual value) returned from the communication link to the drive and any zero-offset due to an MLWritePos function block (MLAxisWritePipPos, MLAxisWritePos). ActualPos := FeedbackPos + ZeroOffset |
Feedback Position | Feedback Position is the current position the drive reports for an axis, scaled to user units. It does not take into account the value of the Zero Offset or axis modulo. |
Generator Position | Generator Position is the summation of all previous commands (i.e. calls to functions which perform motion such as MLAxisAbs, MLAxisMoveVel, and MLAxisRel) to the Axis internal motion generator. It is modified by MLAxisWritePos in order to insure no jumps in the Reference Position command. It also accumulates changes in pipe position due to activate and deactivation of the pipe the Axis block is associated with. |
Pipe Position | The output of the convertor block is written into the Pipe Position value whenever the Convertor block is connected to the axis and the pipe is active. |
Reference Position |
Reference Position is the commanded axis position sent to the drive. It is the summation of Pipe Position and Generator Position. ReferencePosition = Pipe Position + Generator Position |
Zero Offset | The Zero Offset adjusts the coordinate system so that the Actual Position reports correct values after homing or using MLAxisWritePos. |
MOTION FUNCTIONS
To access the motion functions associated to this pipe block, Motion Library - Axis