Path Control in Robotics ME 4135 Lecture series 8 Richard R. Lindeke, Ph. D.
Motion Types of Interest
Point – to – Point Motion:
All Axes start and end simultaneously All Geometry is computed for targets and relevant t changes which are then forced to be followed during program execution
Path or Trajectory Controller Motion
Here the motion is performed through a time sequence of intermediate configurations computed ahead of time (like above but without stop-start operation) or in real time Paths are “Space Curves” for the n-Frame to follow This motion is a continuous scheme to move the T from one location to the next along a desired (straight or curved) line under direct operational control
Path Control and Motion Types:
We will explore the following types of Motion:
Lead Through Path Creation (Cubic) Polynomial Paths w/ Via Points Minimum Time Trajectory w/ controlled Acceleration Lower order Path-Poly Control
LSPB Paths Craig’s Method for acceleration smoothing Strict Velocity Control
t Interpolated Control Full Cartesian Control
Lead Through Path Creation
Basically this was a technique whereby a skilled operator took a robot arm (for welding or painting) and used it like his/her weld tool or paint sprayer and performed the required process at reasonable speed
The robot is equipped with a position recording device and memorizes a large number of points during the teaching session These learned points then would be “played back” to replicate the skilled operators motions
Lead Through Path Creation
Advantages:
Simple way to create complex paths All points are sure to be physically attainable Playback speed can be controlled by an external device
Disadvantages:
Precision placements are required (program must be replayed at exactly the initial placement) Major concern with operator safety: robot is powered and operator is physically touching it (OSHA rules it unsafe practice!)
Modern Path Control: (Lets look at a simple example)
Dr. D’s new ‘Self-powered Automated Coffee Drinker’ Robot It is a simple cantilevered Cartesian device equipped with a spherical wrist that responds to eye movement and thoughts to help the overworked design engineer get coffee while deg and drafting & typing of Reports It follows a straight line path from the cup’s point on a table to the worker’s mouth in ½ second
Lets look at a simple example:
Lets look at a simple example:
We see that the ‘Bot must travel a space path of 16.45” which can be decomposed into a movement of 9.5” along each of the prismatic ts
For ‘accuracy’ lets divide each of the these t paths into 100 segments
From Physics: Vt d/ t = (9.5/100)/(.5/100) = 19in/second (a reasonable speed!)
Lets look at a simple example:
During the 1st Step then:
t 1 starts at 0 and moves to 0.095” Moves there in 0.005 seconds How will it do it? Of course by Accelerating from a stop to 19 in/sec in 0.005 seconds Compute Accreqr V/t Darn – this says that the acceleration is 3800in/sec2 – this is 10G!!!!!
Lets look at a simple example:
So this will certainly be difficult to accomplish! (more likely it will not work) OSHA would be just as upset as when we had the worker holding on to the powered robot – what should we do? I think our approach is too naïve! If we examine the Pos vs. Time, Vel Vs. Time and Acc vs. Time plots we may see why:
Look at a simple example’s Trajectory Curves:
This is Physically Impossible (or rather ‘very energy intensive’)
Can we build a reasonable solution that keeps the acceleration to an achievable level? What this would mean is we wouldn’t “instantly” – in one time step – go from stopped to full speed This can be achieved with a “time polynomial” model of motion
Building a ‘Path Polynomial’ Motion Set q t a0 a1t a2t a3t L 2
3
dq 2 q& t a1 2a2t 3a3t L dt 2 d q & t 2 2a2 6a3t L q& dt These are the ‘trajectory’ equations for a t (Position, Velocity and Acceleration)
Solving the ‘Path Polynomial’ is a matter of finding ai’s for SPECIFIC PATHS
We would have “boundary” conditions for position and velocity at both ends of the path We would have the desired total time of travel Using these conditions we can solve for a0, a1, a2 and a3 to build a 3rd order path polynomial for the required motion
Solving the ‘Path Polynomial’ is a matter of finding ai’s for specific paths
q0 a0 a1t0 a t a t 2 2 0
3 3 0
q&0 a1 2a2t0 3a t
2 3 0
q f a0 a1t f a t a t 2 2 f
3 3 f
q&f a1 2a2t f 3a t
2 3 f
‘Poly’s’ holding at starting time and position
‘Poly’s’ holding at ending time and position
Solving the ‘Path Polynomial’ is a matter of finding ai’s for specific paths
Writing these as Matrix Forms:
1 t0 0 1 1 tf 0 1
2 0
t 2t0 2 tf 2t f
t q0 a0 q& a1 3t 0 q f a2 t & q a 3t 3 f 3 0 2 0 3 f 2 f
Solving the ‘Path Polynomial’ is a matter of finding ai’s for specific paths
If we set t0 = 0 (starting time is when we start counting motion!) then:
1 0 0 1 1 tf 0 1
0 0 2 tf 2t f
0 a0 0 a 1 3 tf a2 2 3t f a3
q0 q& 0
qf q&f
By examination, a0 = q0 & a1 = q0(dot)
Solving the ‘Path Polynomial’ is a matter of finding ai’s for specific paths
Completing the solution consists of forming relationships for: a2 & a3
Done by substituting a0 & a1 values and solving the last two equation simultaneously:
Be Careful and note the order of the positions and velocities!
a2
3 q
a3
2 q
f
0
q0 t f 2q&0 q&f
q f t f q&f q&0
t 2f
t 3f
Applying it to the Coffee ‘Bot
Start: X = 0; v = 0 @ time = 0 End: X = 9.5”; v = 0 @ time = .5 sec a0 = 0 ; a1 = 0 a2 = (3 * 9.5)/(0.52) = 114 a3 = (2 *(- 9.5))/(0.53) = -152
Applying it to the Coffee ‘Bot
Here (specifically):
qi 0 0ti 114t (152)t 2 i
q&i 0 2(114)ti 3(152)t & q& 2(114) 6( 152) t i i
2 i
3 i
Applying it to the Coffee ‘Bot
Simplifying:
qi 114t 152t 2 i
3 i
q&i 228ti 456t & q& 228 912 t i i
2 i
Applying it to the Coffee ‘Bot: Position Position vs. Time
Applying it to the Coffee ‘Bot: Velocity
t Velocity Vs. Time
Applying it to the Coffee ‘Bot: Acceleration
Acceleration Vs. Time
Applying it to the Coffee ‘Bot
Using the Path Polynomial Approach: Max Velocity is: 28.5 in/sec (compares to 19 in/sec) Max Acceleration is: 228 in/sec2 (.6 g) compared to 10 g But, in this method, I require a 100% duty cycle motor since throughout the entire path, the motor is accelerating (either with positive or negative orientation) Can we make a path solution where we accelerate Turns out we can and for only part of the path? we will call it LSPB!
Studying the LSPB model
In this model, we will carry forward with a ‘parabolic model’ In this model, we will determine a time where we will blend from startup until we reach a constant velocity – (and its greater than 1/100 of the total time!) Here we will see an acceleration followed by a period of “coasting” and then deceleration (often called a trapezoidal velocity model)
Model Building:
We must define an acceleration constraint (minimum value) such that the acceleration guaranteed to be completed within half of the allocated time period of the travel: qB q A 4 qB q A & & qmin 2 2 t t 2 based on solving: This assures that there is & &2 Pos 1 qt 2 no overlap for the ‘BLEND at: t t (half time) 2
qB q A we want: Pos = 2
Regions’
Looking at the motion over the various regions:
During Region 1 (while the t is Accelerating) (time interval 0 to tblend [tb]) the t moves: q = (V/2)*tb
tb is the acceleration time
During the region of ‘Constant Velocity’ the t moves: q = V*(t – 2tb)
During Region 3 -- while the t is decelerating the t moves: q = (V/2)*tb
Total travel distance is qB - qA
Writing a motion equation: qB q A q0tb qtb t tb q t tb t qB q A V tb V t 2tb V tb 2 2 qB q A Vt 2Vtb Vtb Vt Vtb BUT : & &b V qt
Substituting and Isolating the Unknown (blend time):
& & tb qt & & qB q A qt
2 b
reforming:
& & qt & & tb qB q A 0 qt 2 b
This is a quadratic equation in tb
Solving for tb: & & qt t
& & qt
b
tb t 2
& & qt
2
& q A qB 4q&
& 2q& 2
& qB q A 4q& & 2q&
Note: Acceleration is subject to above constraint
Applying it to the Coffee ‘Bot
Acceleration constraint: gg 4 9.5 0 2 q 152 in / sec 0.4 g 2 .5 gg
lets ' pick ' q 175in / sec 2
Blend time:tb .25
.25 175
2
4 175 9.5
2 175
1006.25 .25 .25 0.091 350 tb .25 0.091 .159sec
Applying it to the Coffee ‘Bot
tlinear=.5 – 2*0.159 = 0.181 s
Linear Velocity:
Positions: By t , t moves: (27.89/2)*.159 = 2.222 in b During linear velocity t moves: 0.181*27.89 = 5.055 in (thus the pos = 7.277”) During deceleration t travels 2.222 in Adding them gives full travel distance: 2.222 + 5.055 + 2.222 in 9.5in
& tb 175 .159 27.89 in/sec Vlin q&
Plotting the Path trajectory:
Notice: the accelerator is ‘off’ during the linear travel segment
The 2 Previous Path Control Methods focused on Start/Stopping Approaches
What can we do if we desire to travel by ‘G12’ methods – continuing along a path w/o stopping?
Here we will focus on a method called ‘dog-tracking’ after the lead and follow techniques employed in dog racing
Essentially we would have a situation where the path is laid out (as a series of Via Points) and the ts smoothly maneuver through and between them
Craig’s Dog Tracking Method
Craig’s Dog Tracking Method
Upon Examination of the motion, we find that there are three ‘regimes’ in the motion These are:
Start up regime Intermediate regimes Stopping regime
Starting and Stopping are similar to LSPB in the way they compute blend time and acceleration During an Intermediate regime we compute acceleration by comparing incoming and outgoing velocities about each point
Craig’s Dog Tracking Method
Starting regime Equations:
& SGN & & & 1 2 1 global t1 td 12 t
2 d 12
2 2 1 & & 1
2 1 td 12 .5 t1 tl12 td 12 t1 .5 t2
& 12
Start Acceleration
Start Blend Time
Linear Velocity 1→2 Time @ linear Velocity
Craig’s Dog Tracking Method Stopping Equation: & SGN & & & n n 1 n global
tn td n1 n t
& n 1 n
2 d n 1 n
2 n n1 & & n
n n1 td n1 n .5 tn
tl n1 n td n1 n tn .5 tn1
Stop ‘acceleration’
Stop Blend Time
L. Velocity to stop
Time @ L. Velocity
Craig’s Dog Tracking Method
Intermediate Equations:
& jk
k
j
tdjk
& SGN & & & & & k kl jk global tk
& & kl
jk
& & k tljk tdjk .5 t j .5 tk
Linear Velocity
Acceleration
Blend time
Time @ L. Velocity
Craig’s Dog Tracking Method
Upon examination of the set of equation on the previous 3 slides several point should be noted:
Start and Stop are essentially the same but very important differences must be noted One can’t complete any of the regimes without looking ahead – actually looking ahead to the 2 nd point beyond to see if a t is stopping or continuing Start/Stop require position/time relationships Intermediate regimes require velocity/time relationships
Craig’s Dog Tracking Method
Step 1: Calculate Global ‘usable’ acceleration (magnitude) constraint based on LSPB model applied Pairwise (1→2; 2→3; etc)
Step 2: Focus on Start and Stop Segments
Step 3: Complete the table of accelerations, blend times, linear velocity and time at linear velocity
4 q & q& i j
t
2 dij
Lets Expand on Dr. D’s Coffee Drinker ‘Bot: Point Name
Position Delta (inch) Position (inch)
Arrival Time (sec)
Delta Time (sec)
A
0
0
---
----
B
9.5
9.5
0.5
.5
C
11
1.5
3.5
3
D
9.5
-1.5
6.5
3
E
0
-9.5
7.5
1
Lets Expand on Dr. D’s Coffee Drinker ‘Bot:
Step 1: Global Acc. Constraint 4 9.5 2 &AB q& 152 in / s .52 4 1.5 2 & q& 0.67 in / s BC 32 4 1.5 2 & & qCD .67 in / s 32 4 9.5 2 & q& 38 in / s DE 12
This is largest – should work globally – but lets make sure it doesn’t miss so choose 200ips2 ‘ cause it’s easier to calculate and is only about .6g
Lets Expand on Dr. D’s Coffee Drinker ‘Bot:
Next we focus on the start & stop equations: q&&A SGN (9.5 0) 200 200ips 2
Starting
t A .5 .52 2 9.5 q&AB 9.5
200
.5 .5 .106
0.106 s
21.3ips
2 & q& E SGN 9.5 0 200 200ips
Stopping
t E 1 12
q&DE
2 0 9.5
0 9.5
200
1 .5 0.049
0.049 s
9.74ips
NOTE: can’t compute tlij yet – we lack the data!
Lets Expand on Dr. D’s Coffee Drinker ‘Bot:
Considering Intermediate B→C: qC qB
1.5 q&BC 0.5ips tdBC 3 g g 2 & q& SGN q q 200 200 ips BC AB B g g q q BC AB .5 21.25 tB .103s & q& 200 B Now to finish the 1st segment:
tlAB tdAB t A .5 t B .5 .106 .5 .103 .342 s
Lets Expand on Dr. D’s Coffee Drinker ‘Bot:
q&CD
On to “C→D” Segment
qD qC
tdCD
0.5ips
2 & & & q& SGN q q 200 200 ips C CD BC
tC
q&CD q&BC
1 .005 s & q& 200 C
back to finish B--C Segment
tlBC tdBC .5t B .5tC 3 .5(.103) .5(.005) 2.946 s
Lets Expand on Dr. D’s Coffee Drinker ‘Bot:
Now for Segment D→E:
q&DE earlier !
E (is stop point!) 9.74ips
2 & & & q& SGN q q 200 SGN 9.74 ( .5) 200 200 ips D DE CD
tD
q&DE q&CD
0.049 s & q& D
Completing Seg. C--D
tlCD 3 .5tC .5t D 2.974s Seg D--E
tlDE 1 .5t D t E 0.928s
Summarizing Pt
POS
T. Time POS
A
0
0
B C
9.5 11
.5 3.5
----9.5 1.5
time
Ti (blend )
----
.106
.5 3
.103 .005
Acc
L. Vel
Time @L. Vel
+20 0
21.3
.342
.5
2.94 6
-.5
2.97 4
-200 -200
D
9.5
6.5
-1.5
3
.046
-200 -9.74 .928
E
0
7.5
-9.5
1
.049
+20 0
A Final Thought on DogTracking: But if we must travel over a certain point, we can define ‘Pseudo-Via’ points that flank the desired target and force the arm to the ‘pseudos’ and drive right over the original desired target point
Looking at Velocity Control
Desired Path Achievable Path
With this “Velocity Control”
The acceleration is set and the new velocity for an segment is inserted at the appropriate time (place)
Over the segment, the arm (ts) lags the desired path
We extend the next path velocity curve to intersect the actual achievable path (to a point that is earlier in time than when we would have expected to change) this will mean that the t can ‘catch up’ to the desired plan for the travel as it ‘blends’ to the new velocity