PVT – TML Programming Details

In the PVT motion mode the load/motor is controlled in position. The built-in reference generator computes a positioning path using a series of points. Each point specifies the desired Position, Velocity and Time, i.e. contains a PVT data. Between the PVT points the reference generator performs a 3rd order interpolation.

The PVT Interpolated mode is typically used together with a host, which sends PVT points via a communication channel. Due to the 3rd order interpolation, the PVT mode offers the possibility to describe complex position contours using a reduced number of points. It is particularly useful when the motion reference is computed on the fly by the host like for example in vision systems.  By reducing the number of points, both the computation power and the communication bandwidth needed are substantially reduced optimizing the costs. When the PVT motion mode is used simultaneously with several drives/motors having the time synchronization mechanism activated, the result is a very powerful multi-axis system that can execute complex synchronized moves.

A key factor for getting a correct positioning path in PVT mode is to set correctly the distance in time between the points. Typically this is 10-20ms, the shorter the better. If the distance in time between the PVT points is too big, the 3rd order interpolation may lead to important variations compared with the desired path.

The PVT motion mode can be started only when the previous motion is complete. However, you can switch at any moment to another motion mode. The PVT mode can be relative (following a CPR command) or absolute (following a CPA command). In the absolute mode, each PVT point specifies the position to reach. The initial position may be either the current position reference TPOS or a preset value read from the TML parameter PVTPOS0. In the relative mode, each PVT point specifies the position increment relative to the previous point. In both cases, the time is relative to the previous point i.e. represents the duration of a PVT segment. For the first PVT point, the time is measured from the starting of the PVT mode.

Each time when a new PVT point is read from a TML program or received via a communication channel, it is saved into the PVT buffer. The reference generator empties the buffer as the PVT points are executed. The PVT buffer is of type FIFO (first in, first out). The default length of the PVT buffer is 7 PVT points. Each entry in the buffer is made up of 9 words, so the default length of the PVT buffer in terms of how much memory space is reserved is 63 (3Fh) words. The drive/motor automatically sends messages to the host when the buffer is full, low or empty.  The messages contain the PVT status (TML variable PVTSTS). The host address is taken from the TML parameter MASTERID. The buffer full condition occurs when the number of PVT points in the buffer is equal with the buffer size. The buffer low condition occurs when the number of PVT points in the buffer is less or equal with a programmable value – the low level. The buffer empty condition occurs when the buffer is empty and the execution of the last PVT point is over. When the PVT buffer becomes empty the drive/motor:

Remains in PVT mode if the velocity of last PVT point executed is zero and waits for new points to receive
Enters in quick stop mode if the velocity of last PVT point executed is not zero

Therefore, a correct PVT sequence must always end with a last PVT point having velocity zero.

Remarks:

The PVT and PT modes share the same buffer. Therefore the TML parameters and variables associated with the buffer management are the same.
Before activating the PVT mode, you must place at least one PVT point in the buffer
The buffer low condition is set by default when the last PVT point from the buffer is read and starts to be executed
Both the PVT buffer size and its start address are programmable via TML parameters PVTBUFBEGIN and PVTBUFLEN. Therefore if needed, the PVT buffer size can be substantially increased.

 

Each PVT point also includes a 7-bit integrity counter. The integrity counter value must be incremented by the host by one, each time a new PVT point is sent to the drive/motor. If the integrity counter error checking is activated, the drive compares its internally computed integrity counter value with the one sent with the PVT point (i.e. with the PVTP command). This comparison is done every time a PVTP instruction is received. If the values of the two integrity counters do not match, the integrity check error is triggered, the drive/motor sends the PVTSTS to the host with PVTSTS.12 =1 and the received PVT point is discarded. Each time a PVT point is accepted (the integrity counters match or the integrity counter error checking is disabled), the drive automatically increments its internal integrity counter. The default value of the internal integrity counter after power up is 0. Its current value can be read from the TML variable PVTSTS (bits 6..0). The integrity counter can also be set to any value using TML command SETPVT.

See also:

PVT – Related TML Instructions and Data

TML Description