Introduction to Robotics Jianwei Zhang - - PDF document

introduction to robotics
SMART_READER_LITE
LIVE PREVIEW

Introduction to Robotics Jianwei Zhang - - PDF document

MIN-Fakult at Department Informatik Universit at Hamburg - Introduction to Robotics Introduction to Robotics Jianwei Zhang zhang@informatik.uni-hamburg.de Universit at Hamburg Fakult at f ur Mathematik, Informatik und


slide-1
SLIDE 1

Universit¨ at Hamburg

MIN-Fakult¨ at Department Informatik

  • Introduction to Robotics

Introduction to Robotics

Jianwei Zhang

zhang@informatik.uni-hamburg.de

Universit¨ at Hamburg Fakult¨ at f¨ ur Mathematik, Informatik und Naturwissenschaften Department Informatik Technische Aspekte Multimodaler Systeme

  • 26. April 2013
  • J. Zhang

80

Universit¨ at Hamburg

MIN-Fakult¨ at Department Informatik Inverse kinematics for manipulators Introduction to Robotics

Outline

General Information Introduction Coordinates of a manipulator Kinematic equations Inverse kinematics for manipulators Analytical solvability of manipulator Example 1: a planar 3 DOF manipulator The algebraical solution using the example of PUMA 560 The solution for RPY angles Geometrical solution for PUMA 560 A Framework for robots under UNIX: RCCL

  • J. Zhang

81

slide-2
SLIDE 2

Universit¨ at Hamburg

MIN-Fakult¨ at Department Informatik Inverse kinematics for manipulators Introduction to Robotics

Inverse kinematics for manipulators

Set of problems:

◮ The control of robot manipulators take place in the majority of

cases in joint space,

◮ The information about objects are mostly given in the cartesian

space. To achieve a one specific tool frame T related to the world, the joint values θ(t) = (θ1(t), θ2(t), ..., θn(t))T should be calculated in two steps:

  • 1. Calculation of T6 = Z −1BGE −1;
  • 2. Calculation of θ1, θ2, ..., θn over T6.

⇒: In this case the inverse kinematics is more important then the forward kinematics.

  • J. Zhang

82

Universit¨ at Hamburg

MIN-Fakult¨ at Department Informatik Inverse kinematics for manipulators Introduction to Robotics

The solution using the example of PUMA 560 - I

T6 = T ′T ′′ =     nx

  • x

ax px ny

  • y

ay py nz

  • z

az pz 1     where

  • J. Zhang

83

slide-3
SLIDE 3

Universit¨ at Hamburg

MIN-Fakult¨ at Department Informatik Inverse kinematics for manipulators Introduction to Robotics

The solution using the example of PUMA 560 - II

nx = C1[C23(C4C5C6 − S4S6) − S23S5C6] − S1(S4C5C6 + C4S6) (2) ny = S1[C23(C4C5C6 − S4S6 − S23S5S6] + C1(S4C5C6 + C4S6) (3) nz = −S23[C4C5C6 − S4S6] − C23S5C6 (4)

  • x = ...

(5)

  • y = ...

(6)

  • z = ...

(7) ax = ... (8) ay = ... (9) az = ... (10)

  • J. Zhang

84

Universit¨ at Hamburg

MIN-Fakult¨ at Department Informatik Inverse kinematics for manipulators Introduction to Robotics

The solution using the example of PUMA 560 - III

px = C1[d6(C23C4S5 + S23C5) + S23d4 + a3C23 + a2C2] − S1(d6S4S5 + d2) (11) py = S1[d6(C23C4S5 + S23C5) + S23d4 + s3C23 + a2C2] + C1(d6S4S5 + d2) (12) pz = d6(C23C5 − S23C4S5) + C23d4 − a3S23 − a2S2 (13)

  • J. Zhang

85

slide-4
SLIDE 4

Universit¨ at Hamburg

MIN-Fakult¨ at Department Informatik Inverse kinematics for manipulators Introduction to Robotics

Remark

◮ Non-linear equations ◮ Existence of solutions: Workspace: the volume of space

that is recheable for the tool of manipulator.

◮ ”dextrous workspace” ◮ ”reachable workspace”

◮ Many joint positions that produce the similar TCP

position using the example of PUMA 560:

◮ Ambiguity of solutions for θ1, θ2, θ3 related to given p. ◮ For each solution of θ4, θ5, θ6 exist the alternative solution:

  • J. Zhang

86

Universit¨ at Hamburg

MIN-Fakult¨ at Department Informatik Inverse kinematics for manipulators Introduction to Robotics

Remark

θ′

4 = θ4 + 180◦

θ′

5 = −θ5

θ′

6 = θ6 + 180◦ ◮ Different solution strategy: closed solutions vs.

numerical solutions

  • J. Zhang

87

slide-5
SLIDE 5

Universit¨ at Hamburg

MIN-Fakult¨ at Department Informatik Inverse kinematics for manipulators Introduction to Robotics

Different methods for solution finding

Closed form:

◮ algebraic solution

+ : accurate solution over the equations, − : solution is not geometrical representative.

◮ geometrical solution

+ : case-by-case analysis of the possible robot configurations, − : robot specific.

Numerical form:

◮ iterative methods

+ : the methods are transferable, − : computationally intensive, for several exceptions the convergence can not be guaranteed.

  • J. Zhang

88

Universit¨ at Hamburg

MIN-Fakult¨ at Department Informatik Inverse kinematics for manipulators Introduction to Robotics

Methods for solution finding

”The inverse kinematics for all systems with 6 DOF (translational

  • r rotational joints) in a simple serial chain is always numerical

solvable.”

  • J. Zhang

89

slide-6
SLIDE 6

Universit¨ at Hamburg

MIN-Fakult¨ at Department Informatik Inverse kinematics for manipulators - Analytical solvability of manipulator Introduction to Robotics

Analytical solvability of manipulator

The closed solution exists if a specific conditions (sufficient conditions) for the arm geometry are given:

◮ If 3 sequent axis intersect in a given point, ◮ Or: 3 sequent axis are parallel to each other.

It’s important to design a manipulator in the way that the closed solution exists. Almost all manipulators are conceptualized in this way. An example for PUMA 560: The axis 4, 5 and 6 intersect in one point.

  • J. Zhang

90

Universit¨ at Hamburg

MIN-Fakult¨ at Department Informatik Inverse kinematics for manipulators - Example 1: a planar 3 DOF manipulator Introduction to Robotics

Example 1: a planar 3 DOF manipulator

  • J. Zhang

91

slide-7
SLIDE 7

Universit¨ at Hamburg

MIN-Fakult¨ at Department Informatik Inverse kinematics for manipulators - Example 1: a planar 3 DOF manipulator Introduction to Robotics

Example 1: a planar 3 DOF manipulator

Joint αi−1 ai−1 di θi 1 θ1 2 l1 θ2 3 l2 θ3

0T3 =

    C123 −S123 l1C1 + l2C12 S123 C123 l1S1 + l2S12 1 1    

  • J. Zhang

92

Universit¨ at Hamburg

MIN-Fakult¨ at Department Informatik Inverse kinematics for manipulators - Example 1: a planar 3 DOF manipulator Introduction to Robotics

The algebraical solution for the example 1 - I

Specification for the TCP: (x, y, φ). For this such kind of vektors applies:

0T3 =

    Cφ −Sφ x Sφ Cφ y 1 1     Resultant four equations can be derived: Cφ = C123 (14) Sφ = S123 (15) x = l1C1 + l2C12 (16) y = l1S1 + l2S12 (17)

  • J. Zhang

93

slide-8
SLIDE 8

Universit¨ at Hamburg

MIN-Fakult¨ at Department Informatik Inverse kinematics for manipulators - Example 1: a planar 3 DOF manipulator Introduction to Robotics

The algebraical solution for the example 1 - II

(Derivative) The function atan2 is define as:

θ = atan2(y, x) =                        for x = 0, y = 0 π/2 for x = 0, y > 0 3 ∗ π/2 for x = 0, y < 0 atan(y, x) for +x and +y 2π − atan(y, x) for +x und -y π − atan(y, x) for -x und +y π + atan(y, x) for -x und -y

The solution: θ2 = atan2(S2, C2)

  • J. Zhang

94

Universit¨ at Hamburg

MIN-Fakult¨ at Department Informatik Inverse kinematics for manipulators - Example 1: a planar 3 DOF manipulator Introduction to Robotics

The algebraical solution for the example 1 - II

where S2 = ±

  • 1 − C 2

2 , and C2 = x2+y2−l2

1 −l2 2

2l1l2

. θ1 = atan2(y, x) − atan2(k2, k1) where k1 = l1 + l2C2 and k2 = l2S2. θ3 can be calculated as follow: θ1 + θ2 + θ3 = atan2(Sφ, Cφ) = φ

  • J. Zhang

95

slide-9
SLIDE 9

Universit¨ at Hamburg

MIN-Fakult¨ at Department Informatik Inverse kinematics for manipulators - Example 1: a planar 3 DOF manipulator Introduction to Robotics

The geometrical solution for the example 1 - I

Calculate θ2 over “law of cosines”: x2 + y 2 = l2

1 + l2 2 − 2l1l2 cos(180 + θ2)

The solution: θ2 = ±cos−1 x2 + y 2 − l2

1 − l2 2

2l1l2 θ1 = β ± ψ where: β = atan2(y, x), cos ψ = x2 + y 2 − l2

1 − l2 2

2l1

  • x2 + y 2

For θ1, θ2, θ3 applies: θ1 + θ2 + θ3 = φ

  • J. Zhang

96

Universit¨ at Hamburg

MIN-Fakult¨ at Department Informatik Inverse kinematics for manipulators - Example 1: a planar 3 DOF manipulator Introduction to Robotics

Algebraical solution with the help of polynomial conversion

The following substitutions are used for the polynomial conversion of transcendental equations: u = tanθ 2 cos θ = 1 − u2 1 + u2 sin θ = 2u 1 + u2

  • J. Zhang

97

slide-10
SLIDE 10

Universit¨ at Hamburg

MIN-Fakult¨ at Department Informatik Inverse kinematics for manipulators - Example 1: a planar 3 DOF manipulator Introduction to Robotics

Algebraical solution with the help of polynomial conversion

Example: The following transcendental equation is given: a cos θ + b sin θ = c After the polynomial conversion: a(1 − u2) + 2bu = c(1 + u2) The solution for u: u = b ± √ b2 − a2 − c2 a + c Then: θ = 2tan−1(b ± √ b2 − a2 − c2 a + c )

  • J. Zhang

98

Universit¨ at Hamburg

MIN-Fakult¨ at Department Informatik Inverse kinematics for manipulators - The algebraical solution using the example of PUMA 560 Introduction to Robotics

The algebraical solution using the example of PUMA 560 - I

Calculation of θ1, θ2, θ3: The first three joint angle θ1, θ2, θ3 affect the position of TCP (px, py, pz)T (in case d6 = 0). px = C1[S23d4 + a3C23 + a2C2] − S1d2 (18) py = S1[S23d4 + a3C23 + a2C2] + C1d2 (19) pz = C23d4 − a3S23 − a2S2 (20) The outcome of this is: θ1 = tan−1( ∓py

  • p2

x + p2 y − d2 2 − pxd2

∓px

  • p2

x + p2 y − d2 2 + pyd2

)

  • J. Zhang

99

slide-11
SLIDE 11

Universit¨ at Hamburg

MIN-Fakult¨ at Department Informatik Inverse kinematics for manipulators - The algebraical solution using the example of PUMA 560 Introduction to Robotics

The algebraical solution using the example of PUMA 560 - II

θ3 = tan−1( ∓A3

  • A2

3 + B2 3 − D2 3 + B3D3

∓B3

  • A2

3 + B2 3 − D2 3 + A3D3

) where A3 = 2a2a3 B3 = 2a2d4 D3 = p2

x + p2 y + p2 z − a2 2 − a2 3 − d2 2 − d2 4

  • J. Zhang

100

Universit¨ at Hamburg

MIN-Fakult¨ at Department Informatik Inverse kinematics for manipulators - The algebraical solution using the example of PUMA 560 Introduction to Robotics

The algebraical solution using the example of PUMA 560 - II

and θ2 = tan−1( ∓B2

  • p2

x + p2 y − d2 2 + A2pz

∓A2

  • p2

x + p2 y − d2 2 + B2pz

) where A2 = d4C3 − a3S3 B2 = −a3C3 − d4S3 − a2

  • J. Zhang

101

slide-12
SLIDE 12

Universit¨ at Hamburg

MIN-Fakult¨ at Department Informatik Inverse kinematics for manipulators - The solution for RPY angles Introduction to Robotics

The solution for RPY angles

(RPY: Roll, Pitch, Yaw) T = Rz,φRy,θRx,ψ The solution for following equation is sought: R−1

z,φT = Ry,θRx,ψ

    f11(n) f11(o) f11(a) f12(n) f12(o) f12(a) f13(n) f13(o) f13(a) 1     =     Cθ SθSψ SθCψ Cψ −Sψ −Sθ CθSψ CθCψ 1     where

  • J. Zhang

102

Universit¨ at Hamburg

MIN-Fakult¨ at Department Informatik Inverse kinematics for manipulators - The solution for RPY angles Introduction to Robotics

The solution for RPY angles

f11 = Cφx + Sφy f12 = −Sψx + Cφy f13 = z The equation for f12(n) leads to: −Sφnx + Cφny = 0 ⇒: φ = atan2(ny, nx) and φ = φ + 180◦ The solution with the elements 1,3 and 1,1 are as appropriate: −Sθ = nz

  • J. Zhang

103

slide-13
SLIDE 13

Universit¨ at Hamburg

MIN-Fakult¨ at Department Informatik Inverse kinematics for manipulators - The solution for RPY angles Introduction to Robotics

The solution for RPY angles

and Cθ = Cφnx + Sφny ⇒: θ = atan2(−nz, Cφnx + Sφay) The solution with the elements 2,3 and 2,2 are as appropriate: −Sψ = −Sφax + Cφay Cψ = −Sφox + Cφoy ⇒: ψ = atan2(Sφax − Cφay, −Sφox + Cφoy)

  • J. Zhang

104

Universit¨ at Hamburg

MIN-Fakult¨ at Department Informatik Inverse kinematics for manipulators - Geometrical solution for PUMA 560 Introduction to Robotics

Geometrical solution for PUMA 560 - I

Definition of different arm configurations: For shoulder: RIGHT-arm, LEFT-arm For elbow: ABOVE-arm, BELOW-arm For wrist: WRIST-DOWN, WRIST-UP Adapted from this following variable can be defined: ARM =

  • +1

RIGHT-arm −1 LEFT-arm

  • J. Zhang

105

slide-14
SLIDE 14

Universit¨ at Hamburg

MIN-Fakult¨ at Department Informatik Inverse kinematics for manipulators - Geometrical solution for PUMA 560 Introduction to Robotics

Geometrical solution for PUMA 560 - I

ELBOW =

  • +1

ABOVE-arm −1 BELOW-arm WRIST =

  • +1

WRIST-DOWN −1 WRIST-UP The complete solution for the inverse kinematics can be achieved

  • ver analysis of such arm configurations.
  • J. Zhang

106

Universit¨ at Hamburg

MIN-Fakult¨ at Department Informatik Inverse kinematics for manipulators - Geometrical solution for PUMA 560 Introduction to Robotics

Technical difficulties during the development of control software

◮ Until now the development of control software was maked only

for specified robot.

◮ Each robot had special software, that used exactly skills of this

model range.

◮ ⇒ Consequently, the extensibility and portability were really

difficult ant took a lot of time.

  • J. Zhang

107

slide-15
SLIDE 15

Universit¨ at Hamburg

MIN-Fakult¨ at Department Informatik Inverse kinematics for manipulators - Geometrical solution for PUMA 560 Introduction to Robotics

Technical difficulties during the development of control software

The idea was to create a universal cotrol software, that achieve following aims:

◮ Possibility to control of low-level hardware properties; ◮ Maximum portability to different platforms; ◮ Maximum flexibility to fast programming of an applications.

  • J. Zhang

108

Universit¨ at Hamburg

MIN-Fakult¨ at Department Informatik Inverse kinematics for manipulators - A Framework for robots under UNIX: RCCL Introduction to Robotics

A Framework for robots under UNIX: RCCL

RCCL: Robot Control C Library

  • J. Zhang

109

slide-16
SLIDE 16

Universit¨ at Hamburg

MIN-Fakult¨ at Department Informatik Inverse kinematics for manipulators - A Framework for robots under UNIX: RCCL Introduction to Robotics

The system architecture

  • J. Zhang

110

Universit¨ at Hamburg

MIN-Fakult¨ at Department Informatik Inverse kinematics for manipulators - A Framework for robots under UNIX: RCCL Introduction to Robotics

Possibility to control of multiple robots

  • J. Zhang

111

slide-17
SLIDE 17

Universit¨ at Hamburg

MIN-Fakult¨ at Department Informatik Inverse kinematics for manipulators - A Framework for robots under UNIX: RCCL Introduction to Robotics

Motion description with position equations

  • J. Zhang

112

Universit¨ at Hamburg

MIN-Fakult¨ at Department Informatik Inverse kinematics for manipulators - A Framework for robots under UNIX: RCCL Introduction to Robotics

Motion description with position equations

  • J. Zhang

113

slide-18
SLIDE 18

Universit¨ at Hamburg

MIN-Fakult¨ at Department Informatik Inverse kinematics for manipulators - A Framework for robots under UNIX: RCCL Introduction to Robotics

An example for program to control of a robot

#include <rccl.h> #include "manex .560.h" main () { TRSF_PTR p, t; /*#1*/ POS_PTR pos; /*#2*/ MANIP *mnp; /*#3*/ JNTS rcclpark; /*#4*/ char *robotName; /*#5*/ rcclSetOptions ( RCCL_ERROR_EXIT ); /*#6*/ robotName = getDefaultRobot (); /*#7*/ if (! getRobotPosition (rcclpark.v, "rcclpark", robotName )) { printf (’’position ’rcclpark ’ not defined for robot\n’’); exit ( -1); } /*#8*/ t = allocTransXyz ("T", UNDEF ,

  • 300.0, 0.0, 75.0);

p = allocTransRot ("P", UNDEF , P_X , P_Y , P_Z , xunit , 180.0); pos = makePosition ("pos", T6 , EQ , p, t, NULL ); /*#9*/

  • J. Zhang

114

Universit¨ at Hamburg

MIN-Fakult¨ at Department Informatik Inverse kinematics for manipulators - A Framework for robots under UNIX: RCCL Introduction to Robotics

An example for program to control of a robot

mnp = rcclCreate (robotName , 0); /* #10 */ rcclStart (); movej (mnp , &rcclpark ); /* #11 */ setMod (mnp , ’c’); /* #12 */ move (mnp , pos ); /* #13 */ stop (mnp , 1000.0); movej (mnp , &rcclpark ); /* #14 */ stop (mnp , 1000.0); waitForCompleted (mnp ); /* #15 */ rcclRelease (YES ); /* #16 */ }

  • J. Zhang

115

slide-19
SLIDE 19

Universit¨ at Hamburg

MIN-Fakult¨ at Department Informatik Inverse kinematics for manipulators - A Framework for robots under UNIX: RCCL Introduction to Robotics

An example for program to control of a robot

  • J. Zhang

116