Documentation: PVT Method


PVT is a position-velocity-time path algorithm for the SynqNet controller. As compared to other motion commands available in RapidCode such as MoveTrapezoidal (), MoveSCurve () to name a few, PVT allows the user continuous motion between different points without the axes having to stop since the point-time pairs are calculated in advance and are loaded into the SynqNet motion frames that create real-time command positions at each sample during time intervals between the point-time pairs.


PVT algorithm fits a Jerk (non-constant acceleration) profile between user specified ‘Position, Velocity and Time’ points. The PVT algorithm guarantees that the trajectory calculator will allow user to hit a specified position with the specified velocity at the specified time.


Below is a single axis example using PVT logic:

pvt1.jpg


As you can see from the above graph, the PVT algorithm calculates the Acceleration and Jerk values to hit the specified Position and Velocity at the next point. The equations for An and Jn, are derived from the standard kinematic equations:

pvt2.jpg


Let’s discuss a simple PVT Example:


A trapezoidal velocity profile motion could be generated using a list of three Position, Velocity and Time points:

pvt3.jpg


There are several methods to calculate the Velocities for PVT paths. Below are some common methods:


1. Calculate the change in distance between two points divided by time:

pvt4.jpg


This is a simple recommended method, with relatively smooth performance. Remember to add an extra final point to the list, setting the last velocity to zero.


2. Calculate a constant acceleration fit between points. From the kinematic equations (with Jerk = 0), we know:

pvt5.jpg


Substitute (b) into (a), and solve for Vn + 1

pvt6.jpg


There are several other methods used to calculate the velocities.


Bear in mind that it is very important to calculate the Velocities properly for the PVT paths otherwise users might get undesired results as explained below.


If the Position, Velocity and Time points are not matched properly then the PVT algorithm can produce a non desired result. The PVT algorithm simply calculates a Jerk profile between points to reach the specified point. As previously mentioned these profiles may not be the desired results but they will be accurate.


For example, take a look at the image above (trapezoidal motion). If the user enters small velocities at points 0 and 1 then the profile would stretch to cover the proper distance (area under the curve):

pvt7.jpg


PVT profile, velocities too low


If the velocities at points 0 and 1 were too big, the profile would shrink to cover the proper distance (area under the curve):

pvt8.jpg


PVT profile, velocities too high


Below is the RapidCode method for Single/Multi Axis PVT move:

  • void MovePVT(double* position, double* velocity, double* time, long pointCount, long emptyCount, bool retain, bool final)


The parameters used in MovePVT method are described as follows:

  • *position Array of positions.
  • *velocity Array of velocities.
  • *time Array of times.
  • pointCount The number of points.
  • emptyCount E-Stop generated if there aren't at least this many points loaded.
  • retain Points kept, or not kept.
  • final If True, this is the final point. If False, more points expected.


Please look at the two sample applications documentation for much better understanding.

  • The first sample application draws a straight line from coordinate (0, 0) at a user defined angle degree angle & length.
  • The second sample application draws a quad circle based on user defined points, radius & time slice.


Bibliography: Images and some theory taken from http://support.motioneng.com