AVSI – Smooth trajectory interpolation
Block SymbolLicensing group: ADVANCED
Function Description
The functional block AVSI - Acceleration (A), Velocity (V ), Distance (S) Interpolation (I) -
is designed for signal interpolation, especially in motion control applications. Its
main purpose is to generate smooth sequences of position (distance), velocity, and
acceleration based on discrete input values. This block is inspired by the functionality of
RM_AxisSpline and offers similar interpolation methods.
The AVSI block accepts inputs sn (position), vn (velocity), and an (acceleration), which are generated by an external function (outside this block) with a certain period defined by the RemTs parameter. The values at the block’s input are updated on the rising edge of the SET signal.
Interpolation between individual inputs is carried out with the aim of creating smooth transitions and ensuring continuous motion control or other applications requiring signal regulation and its derivatives. The block supports various interpolation methods determined by the Mode parameter, corresponding to the options in RM_AxisSpline. The supported methods include:
- linear: Position is interpolated linearly, velocity as the derivative of position, acceleration is 0 (i.e., velocity is a piecewise constant function with jumps).
- cubic spline: Position is a 3rd order polynomial calculated based on the position and velocity at the beginning and end of the interval; velocity is the derivative of position, acceleration is the derivative of velocity.
- quintic spline: Position is a 5th order polynomial calculated based on the position, velocity, and acceleration at the beginning and end of the interval; velocity is the derivative of position, acceleration is the derivative of velocity.
- cubic aproximation (B-spline): Position is a 3rd order polynomial calculated based on two positions before and two positions after the current interval; the interpolated function may not exactly pass through the given points; velocity is the derivative of position, acceleration is the derivative of velocity.
- quintic aproximation (B-spline): Position is a 5th order polynomial calculated based on three positions before and three positions after the current interval; the interpolated function may not exactly pass through the given points; velocity is the derivative of position, acceleration is the derivative of velocity.
- all linear: Position, velocity, and acceleration are independently interpolated linearly, i.e., velocity does not precisely correspond to the derivative of position, and acceleration does not precisely correspond to the derivative of velocity.
- all cubic: Both position and velocity are interpolated by a 3rd order polynomial independently, i.e., velocity does not exactly correspond to the derivative of position.
- reserved for future use.
- reserved for future use.
Due to its operating principle, the AVSI block introduces signal delay, where active generation of values begins only after two complete RemTs periods from the first rising edge of the SET signal. For B-spline interpolation methods, a larger number of samples is required to start interpolation.
The AVSI block is primarily intended for motion control applications but can also be used for other types of signals and their derivatives. Its implementation allows for more efficient and smoother transitions between individual state values without the need for complex external control.
When using it, it is important to correctly set the RemTs period corresponding to the input value generator and choose the appropriate Mode for the desired type of interpolation.
This block propagates the signal quality. More information can be found in the 1.4 section.
Input
an | Next (remote) period acceleration [m/s^2] | Double (F64) |
vn | Next (remote) period velocity [m/s] | Double (F64) |
sn | Next (remote) period position [m] | Double (F64) |
SET | Accept input on rising edge | Bool |
R1 | Block reset | Bool |
dm | Maximal allowed deceleration in case of error[m/s^2] | Double (F64) |
Parameter
RemTs | Remote signal generator period 0.0 | Double (F64) |
Mode | Algorithm for interpolation 9 | Long (I32) |
|
|
|
Output
a | Acceleration [m/s^2] | Double (F64) |
v | Velocity [m/s] | Double (F64) |
s | Position [m] | Double (F64) |
RDY | Outputs valid (ready flag) | Bool |
iE | Error code | Bool |
[Previous] [Back to top] [Up] [Next]
2024 © REX Controls s.r.o., www.rexygen.com