0% found this document useful (0 votes)
10 views29 pages

Lecture3

The document discusses the principles of controlling mobile robots, focusing on the need for a controller that can adapt to dynamic environments through a 'divide and conquer' approach using behaviors like go-to-goal and obstacle avoidance. It details the modeling of differential drive robots, the use of sensors for state estimation, and the implementation of behavior-based robotics for navigation. Additionally, it explores arbitration mechanisms for blending behaviors in response to environmental changes.

Uploaded by

pangunpark
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
10 views29 pages

Lecture3

The document discusses the principles of controlling mobile robots, focusing on the need for a controller that can adapt to dynamic environments through a 'divide and conquer' approach using behaviors like go-to-goal and obstacle avoidance. It details the modeling of differential drive robots, the use of sensors for state estimation, and the implementation of behavior-based robotics for navigation. Additionally, it explores arbitration mechanisms for blending behaviors in response to environmental changes.

Uploaded by

pangunpark
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 29

Cyber Physical Computing Systems

Mobile Robots

Pangun Park

Chungnam National University

[email protected]

Pangun Park (CNU) 1 / 29


Driving Robots Around?

What does it take to drive a robot from point A to point B?

controller

sensors
robot model

Pangun Park (CNU) 2 / 29


Divide and Conquer

The world is dynamic and fundamentally unknown

The controller must be able to respond to environmental conditions

Instead of building one complicated controller divide and conquer: Behaviors


Go-to-goal
Avoid-obstacles
Follow-wall
Track-target

Pangun Park (CNU) 3 / 29


Behaviors

Pangun Park (CNU) 4 / 29


Differential Drive Robots

In order to control mobile robots, we need models

Differential drive wheeled robots a very common type

Pangun Park (CNU) 5 / 29


Model 1.0

vℓ vr
R
φ

(x, y)
L  R
 ẋ = (v + v ) cos φ

R
ẋ
 = 2
(vr + vl ) cos φ
R
ẏ = 2
(vr + vl ) sin φ
R

φ̇ = (v − vl )

L r

Pangun Park (CNU) 6 / 29


The “Unicycle” Model

But it is not very natural to “think” in terms of wheel velocities

Go directly for translational and angular velocities

Inputs:

v
ω

Dynamics:
φ 
ẋ
 = v cos φ
ẏ = v sin φ
(x, y) 
φ̇ =ω

Pangun Park (CNU) 7 / 29


Model 2.0

Design for this model!


ẋ
 = v cos φ R 2v
v= (vr + vl ) → = vr + vl
ẏ = v sin φ 2 R
R ωL

φ̇ =ω

ω = (vr − vl ) → = vr − vl
L R

Implement this model!


R
ẋ
 = 2
(vr + vl ) cos φ 2v + ωL
R vr =
ẏ = 2
(vr + vl ) sin φ 2R
R 2v − ωL

φ̇ = (vr − vl )

L vl =
2R

Pangun Park (CNU) 8 / 29


Odometry

The state of the robot is (x, y , φ)

How do we obtain this state information?

Two possibilities:
External sensors
Internal sensors
Orientation: Compass, ...
Position: Accelerometers, Gyroscopes, ...
Wheel Encoders

Pangun Park (CNU) 9 / 29


Wheel Encoders

Wheel encoders give the distance moved by each wheel

Assume the wheels are following an arc (short time scale)

Dr

Dc Dl + Dr
Dc =
2
Dℓ


ẋ
 = x + Dc cos φ
ẏ = y + Dc sin φ
= φ + Dr −D

l
φ̇

L

Pangun Park (CNU) 10 / 29


Wheel Encoders

But how do we know how far each wheel has moved?

Dr • Assume each wheel has N “ticks”


per revolution
Dc
• Most wheel encoders give the total
Dℓ
tick count since the beginning

For both wheels:

∆tick = tick′ − tick


∆tick
D = 2πR
N

Pangun Park (CNU) 11 / 29


A Major Disclaimer

DRIFT!!!

Pangun Park (CNU) 12 / 29


Sensors

Robots need to know what the world around them looks like

The standard sensor suite includes a “skirt” of range sensors:


IR, Ultra-Sound, LIDAR, ...

Other standard external sensors include


Vision
Tactile
“GPS”

Pangun Park (CNU) 13 / 29


Range-Sensor Skirts

We will mainly deal with range-sensors

Pangun Park (CNU) 14 / 29


The Disk Abstraction

Instead of worrying about the resolution of the sensors, assume we know the distance and
direction to all obstacles around us (that are close enough)

(d2 , φ2 ) Angles are relative to


the robot’s heading

(d1 , φ1 )

Pangun Park (CNU) 15 / 29


The Disk Abstraction

Instead of worrying about the resolution of the sensors, assume we know the distance and
direction to all obstacles around us (that are close enough)

• If we know our own poseknow our own pose (position


If we
(d2 , φ2 ) (position and orientation):
and orientation):

(d1 , φ1 )
x1 = x + d1 cos(φ1 + φ)
y1 = y + d1 sin(φ1 + φ)

Pangun Park (CNU) 16 / 29


Example: Rendezvous

Pangun Park (CNU) 17 / 29


Behavior-Based Robotics

The world is fundamentally


unknown and changing

Does not make sense to over-plan

Key idea: Develop a library of


useful controllers (=behaviors)

Switch among controllers in


response to environmental changes

Pangun Park (CNU) 18 / 29


Building a Behavior v.1

Assume we have a differential-drive, wheeled mobile robot driving at a constant speed



ẋ = v0 cos φ

ẏ = v0 sin φ

φ̇ = ω

φd • Want to drive in a desired heading

φ ω =???

Pangun Park (CNU) 19 / 29


Building a Behavior v.1

We have a reference, a model, a control input, and a tracking error:

r = φd , e = φd − φ, φ̇ = ω

Why not use PID?


Z
ω = kP e + kI edτ + kD ė

Pangun Park (CNU) 20 / 29


Dealing with Angles

This typically will not work since we are dealing with angles:

φd = 0, φ = 100π → e = −100π

Solution: Ensure that e ∈ [−π, π]

Standard trick is to use atan2

e ′ = atan2(sin(e), cos(e)) ∈ [−π, π]

Pangun Park (CNU) 21 / 29


Example: Navigation

Problem: Go to a goal location without bumping in to obstacles:


obstacles:

At a minimum, we need two behaviors: Go-to-goal and Avoid- obstacles

Pangun Park (CNU) 22 / 29


Go-To-Goal

How drive a robot to a goal location?



ẋ = v0 cos φ

ẏ = v0 sin φ
 e = φd − φ, ω = PID(e)
φ̇ = ω

(xg , yg )
! "
yg − y
φd = arctan
xg − x
(x, y)

Pangun Park (CNU) 23 / 29


Attempt 1

ω = K (φd − φ)

ANGLES!!!

Pangun Park (CNU) 24 / 29


Attempt 2

“ω = K (φd − φ)”

GAIN TOO LOW!!!

Pangun Park (CNU) 25 / 29


Attempt 3

“ω = Kbig (φd − φ)”


big

JUST RIGHT!!!

Pangun Park (CNU) 26 / 29


Obstacle-Avoidance

How avoid driving into obstacles?

We can use the same idea by defining a desired heading

(xo , yo )

(x, y) There is no obvious


“correct” answer

Pangun Park (CNU) 27 / 29


Where to Go?

Choice depends on direction to goal.

Not “pure” but “blended”

π
φ2 = φobst ±
2
φ3 = φgoal
Pure go-to-goal
φ4 = F (φobst , φgoal )
Blended
φ1 = φobst + π
This is “pure” avoidance

Pangun Park (CNU) 28 / 29


Arbitration Mechanisms

This example illustrate two fundamentally different “arbitration mechanisms”


Winner takes all = Hard switches
Blending = Combined behaviors

Both approaches have merit in different situations


Performance?
Analysis?

We will see how to design systematic behaviors and arbitration mechanisms

Pangun Park (CNU) 29 / 29

You might also like