Contents

- 1 Introduction
- 2 What is the notion of Motion Profile Generation?
- 3 Architecture of SOLO’s Embedded Motion Profile Generator:
- 4 Conventional PVT methods versus Embedded Profile Generation Engine of SOLO
- 5 Embedded St-curve Position Profile Generation
- 6 Time-based versus Time-optimal Position Profile St-Curve
- 7 Embedded St-curve Velocity Profile Generation

## Introduction

## What is the notion of Motion Profile Generation?

*Figure 1 – Generic FOC control architecture for 3-phase Motors*

*Figure 2- Speed feedback of a PMSM in reaction to a 1000RPM step set-point*

*Figure 3- Speed feedback of a PMSM in reaction to a 1000RPM set-point generated by SOLO’s Embedded Time-based St-curve Generator*

*Figure 4- Position and Speed feedback shapes on step response of a PMSM in reaction to a +80,000 pulses as position set-point*

*Figure5 – Position and Speed feedback of a PMSM in reaction to a +80,000 pulses set-point using SOLO’s Time-optimal Embedded position profile generator *

## Architecture of SOLO’s Embedded Motion Profile Generator:

*Figure 6: St-curve Position Profile Generator Architecture for 3-phase Motors *

*Figure 7: St-curve Position Profile Generator Architecture for DC brushed Motors *

*Figure 8: St-curve Velocity Profile Generator Architecture for 3-phase Motors *

*Figure 9: St-curve Velocity Profile Generator Architecture for 3-phase Motors *

## Conventional PVT methods versus Embedded Profile Generation Engine of SOLO

### Conventional PVT methods

The conventional motion profile generation and controlling for servo-drives is known as “PVT” which stands for Position, Velocity and Time, in this method there are the following components work together as can be seen in Figure 10 below :

**1. The User:**

The user provides the final desired target position with some other constraints like timings or max values for inputs like velocity, acceleration, jerk and so on, and finally, as a result of all of these inputs, the host can compute for the whole system final target position, for instance, the final position for the end-effector of a robot.

**2. The Host:**

The Host, is usually a real-time system that has to compute and create the whole motion profile, this part of the system has to guarantee time determinism and it must work in a very stable fashion so that it can provide all the necessary points to the Servo Drive in a timely fashion without any interruption or considerable delay!

The Host has to locally compute the whole profile from the current position of the actuator to where it has to end up and has to fit a nice curve in between based on the algorithm that it uses ( St-curve, S-curve, Trapezoidal, …), we call this part PVT Encoding.

Once the Host computes and fits the curve, it has to send some of the computed points to the Servo drive with a reduced sampling rate, as can be seen in Figure 11, the main reason for this is the fact that sending all the computed points will occupy a huge portion of the data line and it consumes a lot of resources at the Host side or in many cases if the sampling rate is too high, it’s not feasible to send all these points in a timely fashion deterministically, so the Host has to reduce the samples for the Servo drive.

*Figure 10 – Architecture of a conventional PVT method from the user to the servo drive *

*Figure 11 – Computed Host curve versus the points sent to the Servo-drive *

**3. Servo Drive:**

The servo drive receives all the points one by one from the Host computer in real-time and interpolates between them through a third or fourth order equation, as for the fact that the servo drives’ internal control loop usually runs up to 10 times faster than the PVT feeding rate from the Host side, so the servo drive has to interpolated at least 10 times between each two points sent from the Host till receiving the new points again.

The interpolation no matter how accurate, still won’t be the same as the real points computed at the Host side and this might leave some errors and discrepancies between what has been computed on the Host and what has been achieved on the real motor.

### Embedded Profile Generation Engine of SOLO

The embedded profile Generation Engine in SOLO, is like a PVT Encoder that is placed locally inside the Main Control Unit (DSP), in other words, the whole profile fitting, generation, and execution is done locally inside SOLO’s Firmware with the same execution rate of the controllers ( Speed and Position) and this will have the following results:

– It Requires only the Target position from the user with no interpolation done between the points ( all points generated locally at run-time)

– Much less occupation of the Data lines ( one target point instead of hundreds)

– No special programming skills required at the user side! ( automatic profile generation)

*Figure 12 – SOLO Motion Profile Generation Engine diagram *

## Embedded St-curve Position Profile Generation

*Figure13- St-Curve Position Profile combined out of 7 separate segments *

## Time-based versus Time-optimal Position Profile St-Curve

SOLO offers two different methods for computing the St-curve profile for a given motion as below:

**Time-based St-curve:**

In Time-based St-curves, the user has to input the strict timings for each segment of the motion as an input to SOLO, these timings later will be used to create the St-curve profile locally.

**Time-Optimal St-curve:**

Once using Time optimal St-curve, the user has to provide motion constraints like maximum velocities, maximum accelerations and maximum jerks for the whole trajectory and the timings of each segment is internally computed based on these constraints at run-time in the firmware of SOLO.

The Time-based St-curve has an intuitive notion as it works directly with timings, however the Time-optimal St-curve has some considerations that we will discuss in detail in the next section.

### Time-Optimal Position Profile St-curve Constraints Validations

Maximum allowable jerk, acceleration, and velocity can be directly controlled, i.e. a time-optimal motion profile can be computed by providing maximum values of acceleration jerk J, deceleration jerk I, acceleration A, deceleration D, and velocity V. In this way, segments’ duration is not explicitly provided, but they are computed at runtime in SOLO’s firmware.

Given that t1, t2, t3, t4, and t5 must be greater than or equal to zero, the following inequality constraints must be satisfied:

**1 Velocity constraint**

*Equation 1 *

If desired maximum velocity does not satisfy this constraint, the maximum allowable velocity can be computed as:

*Equation 2 *

**2. Acceleration constraint**

*Equation 3*

If desired maximum acceleration does not satisfy this constraint, the maximum allowable acceleration can be computed as:

*Equation 4*

If desired maximum velocity does not satisfy this constraint, the maximum allowable velocity can be computed as:

**3.Deceleration constraint**

*Equation 5 *

If desired maximum deceleration does not satisfy this constraint, the maximum allowable deceleration can be computed as:

*Equation 6*

### St-curve Position Profile Tuning

*Figure 14: “Smooth” St-curve motion profile; t1=1s, t2=0.1s, t3=0.5s, t4=1s, t5=0.1s *

*Figure 15: “Fast” St-curve motion profile; t1=0.1s, t2=1s, t3=0.5s, t4=0.1s,t5=1s *

## Embedded St-curve Velocity Profile Generation

*Figure16- St-Curve Velocity Profile combined out of 3 separated segments *

### Time-based versus Time-optimal Velocity Profile St-Curve

SOLO offers two different methods for computing the St-curve profile for a given motion as below:

**Time-based St-curve:**

In Time-based St-curves, the user has to input the strict timings for each segment of the motion as an input to SOLO, these timings later will be used to create the St-curve profile locally.

**Time-Optimal St-curve:**

Once using Time optimal St-curve, the user has to provide motion constraints like maximum accelerations and maximum jerks along the velocity trajectory and the timings of each segment is internally computed based on these constraints at run-time between each two target points.

The Time-based St-curve has an intuitive notion as it works directly with timings, however, the Time-optimal St-curve has some considerations that we will discuss in detail in the next section.

### Time-Optimal Velocity Profile St-curve Constraints Validations

*Equation 7 *

*Equation 8 *

### St-Curve Velocity Profile Tuning

*Figure 17: “Smooth” velocity St-curve motion profile; t1,t3=1s, t2=0.1s *

*Figure 18: “Fast” velocity St-curve motion profile; t1,t3=0.1s, t2=1s *