Robotino Motion Control
Robotino Motion Control
Experiment P-03
Short description
Change Log
Time requirements
Setup 30 Minutes
Installation 30 Minutes
Performance 3 Hours
Introduction to Robotino
This section provides a general information about the commercial mobile robot “Robotino”,
which is manufactured by FESTO. It also introduces its main components and its kine-
matic equations.
Robotino
• Robotino can be programmed using its own programming software which is called
Robotino View and other software applications: C, C++, Java, .NET, MAT-
LAB, Simulink, Labview and Microsoft Robotics Developer Studio.
• The Structure: Referring to Figures B.1 and B.2, Robotino is equipped with
a display screen that allows access into the internal PC of the robot and other
functions. Below the display unit the controller board is located (1) which is
connected to an input/output interface board (2). Each wheel is driven by an
• What Software?
In this exercise two softwares are used to program and control Robotino:
The kinematic model of an omnidirectional drive mobile robot can be derived according
to Equation C.1
ẊI
ξ˙I = ẎI = R(θ) · J−1 · ω. (C.1)
θ̇
In this equation:
• ξ˙I is the velocity vector in the inertial frame.
• ẊI and ẎI are the translational velocities in [m/s] along the corresponding axis
and in the inertial coordinate system.
• θ̇ is the rotational velocity of Robotino in [rad/s].
• R(θ) is the rotation matrix from body coordinates {B} to inertial coordinates {I}.
By substituting the rotation matrix R(θ) and the constraint matrix J one gets
− √r3 √r
ẊI cos(θ) − sin(θ) 0 0 3
ω1
ξ˙I = ẎI = sin(θ) cos(θ) 0 · 3r − 2r r · f ω2 . (C.2)
3 3
θ̇ 0 0 1 r r r ω3
3L 3L 3L
Setup
Required parts
• One Robotino
• One Notebook, Beaufort.
• Two optical diffuse sensors attached to Robotino.
• Screw driver for sensor calibration (available in Robotino toolbox).
• Metallic base for mounting Robotino.
• Tape.
Required software
Preparations
• Robotino View and MATLAB toolbox must be installed prior to the experi-
ment.
• The batteries on board Robotino must be charged.
• Robotino may be moved or lifted up only by using the handles, see Figure E.5.
• All programs must be tested first, while Robotino is jacked up on its base.
• Switch on Robotino by pressing the On/Off button until the LED lights up.
• The display switches on.
• The PC of Robotino boots up.
• After 30 seconds, the start display appears.
• Connect your Notebook to the wireless network called Robotino 2.225, for example.
• The display on Robotino in shown in Figure E.6.
Testing Robotino
A few tests should be implemented before carrying out the exercises. These tests are
necessary in order to make sure that the WLAN network is established correctly and
Robotino’s motors and other hardware function properly.
One can test the WLAN connection using a simple DOS command which is the ping IP
address.
• Start the MS-DOS prompt, which is in the start menu under Programs⁄Accessories.
Click onto Prompt.
• Enter the ping command in the prompt, together with the displayed IP address
on Robotino display, e.g. “ ping 172.26.1.100”.
• If a WLAN connection exists, the following message is received
Timeout of request.
Timeout of request.
Timeout of request.
Timeout of request.
Ping statistics for 172.26.1.100:
Packages sent = 4, received = 0, lost = 4 (100loss),
In order to test the functionality of Robotino and its motors perform the following test.
Robotino must be jacked up on its base.
• Press the Enter key of the touch - sensitive keyboard in order to access the main
menu. The main menu contains the following items:
– Languages.
– State of Charge.
– DEMOs.
– Network.
• Using the up and down arrows of the touch - sensitive key board, move the left
arrow on the display down to the item DEMOs and press the Enter key in order
to recall this menu.
• Move the left arrow down until the Demo called Circle or Forward, press Enter.
• The wheels should start rotating according to the chosen demo. If this happens,
then your Robotino functions properly and is ready to be used. The demo program
runs for about 10 seconds or can be terminated by pressing any button on the touch
- sensitive keyboard.
• All menus can be exited to the next higher ones by pressing the left arrow key.
Questions
In this section there are two types of questions. The Pre-Lab Questions, are to
be answered before doing the experiment. Experiment Questions can be answered
during the experimental work.
Pre-Lab Questions
Pr.2 What are the omnidirectional wheels and what type of omnidirectional wheels are
attached to Robotino?
Pr.4 The rotational velocities of the motors are ω1 = 500 RPM, ω2 = −1000 RPM and
ω3 = 500 RPM. Calculate the resulting speed of Robotino, and specify in which
direction it moves.
Experiment Questions
Ex.1 Exercise 1; steps number 12, 13 and 14: copy the signal of the best achieved
performance at your oscilloscope by pressing the copy button. Then paste your
image in a separate word document.
Ex.1.a Write down what is the effect of increasing or decreasing the Kp parameter
on the motor’s rotational velocity.
Ex.1.b In Exercise 1 step number 13. Write down your remarks about the effect of
the Ki parameter.
Ex.1.c In Exercise 1 step number 14. Write down your remarks about the effect of
the Kd parameter.
Ex.2.a Exercise 2; step number 5: Write down your observations. Does Robotino move
in the same direction as expected? Why?
Ex.2.b Exercise 2; step number 11: Explain what is the main function of the omnidrive
block?
Ex.3 Copy and paste your plot of Exercise 3 step number 18 in a word document and
comment on your results.
Ex.4 Exercise 4; step number 7: measure the distance between the obstacle and
Robotino. Is it 15 cm? If not explain what are the reasons.
Remarks:
• Print out your results and submit them along with your answers.
Robotino has three motors controlling its wheels. These motors are controlled by internal
PID controllers. One can improve the performance of the motors by tuning the PID
parameters. In this exercise the main objective is to tune these parameters in order to
achieve a modified motor behavior. The testing procedure sets a value of the speed for
each of the three motors and then the actual speed of the motors are monitored and
modified by further tuning the PID parameters of the motor’s controllers.
1. This exercise will be carried out while Robotino is jacked up on its base, i.e. it has
no contact with the ground. Make sure that Robotino is well placed on its metallic
base, and the front inductive sensor and the wheels are free and not touching the
supports of the base.
2. Start Robotino View and open a new project.
3. When Robotino View is started, a blank workspace is opened up. The workspace
is divided into three main parts, refer to Figure H.7. These parts are:
• Area for the display of the function block diagram, see (11).
• List of constants, see (10).
• Parameter display of function blocks used in the program, see (8).
• Other components are listed in Table H.1.
4. Drag and drop the following components from the function block library to the
right:
block represents the collision detection sensor. Drag and drop an exit block from
sequence control. Connect the output of the bumper to the input of the exit
block. This is a safety precaution and it terminates the current program running
on Robotino if a collision occurred. The diagram is provided by Figure H.11.
9. Insert the displayed Robotino address into the IP address slot and press connect.
Make sure that the connection is successful by checking the displayed remark at
the left bottom corner of your screen. Refer to Figure H.12.
In this exercise you move the robot along its xy-plane with specified velocities.
1. Open a new project on Robotino View and insert the three motors, assign their
addresses and insert the PID parameter values which you have identified in Exer-
cise 1.
2. Insert the collision safety blocks.
3. Insert three constant sources from the function block library ⁄Generators. Dou-
ble click on the constant sources and insert the calculated rotational velocities
in question Pr.3, then connect each source to its corresponding motor. Insert 3
oscilloscopes from fucntion block library ⁄Display.
4. Connect each pair of the desired speed provided by the constant sources and the
actual speed of the motors to one oscilloscopes. Your project diagram should look
like Figure H.13. You can visualize the data from the menu View⁄show data.
5. Connect to Robotino and run your program first in the jacked up position. If
everything in your program is correct place the Robotino on the ground and run
your program again. Answer question Ex.2.
6. Stop the program and change the rotational speeds according to ω1 = 500 RPM,
ω2 = 0 RPM, and ω3 = 500 RPM. In which direction does Robotino move?
7. Stop the program and change the rotational speeds according to ω1 = 500 RPM,
ω2 = −1000 RPM, and ω3 = 500 RPM and test your program.
8. Stop your program and modify your project according to the below steps.
9. Disconnect the three constant sources from the motors and insert the omnidrive
block from the function block library ⁄Robotino Hardware. Then connect the three
motors and the three constant sources to the omnidrive block according to Figure
H.14. The omnidrive block has three inputs on the left side for the ẊI in [mm/s],
ẎI in [mm/s] and φ̇ in [degree/s], respectively. Three outputs are on the right side
for ω1 , ω2 and ω3 in [RPM], respectively.
10. Test your program by inserting several test velocities and then observe the output.
Your test velocities must not exceed 600 mm/s!
11. Stop your program and connect the actual velocity port of each motor to the
its corresponding port at the upper side of the omnidrive block according to
Figure H.15. Switch on show data. Observe the values at the lower side of the
omnidrive. Answer question Ex.2.b.
In this exercise you are going to use Robotino toolbox in MATLAB/Simulink. The main
goal of the exercise is to use sensor data in order to perform several tasks such as path
tracking and obstacle detection.
1. You need to connect the two diffuse sensors at the front of Robotino to the in-
put/output interface board according to Figure H.16. The sensors are provided
by the instructor.
3. Type in the command window startup in order to add the “ toolbox ” and the “
blockset ” to the search path, see Figure H.17.
4. In the blockset folder to the right you can find all function blocks of Robotino that
you already used in Robotino View.
5. Double click on the “ blockset ” folder then double click on lib_robotinohardware
.mdl.
6. Open a new Simulink model and familiarize yourself with the various function
blocks of Robotino provided in lib_robotinohardware.mdl.
7. Insert eight digital inputs from the lib_robotinohardware.mdl to your Simulink
Model and assign their addresses between (0 - 7), by double clicking on each one
of them. Connect each digital input to a display from sinks/display according to
Figure H.18.
8. Each function block of Robotino toolbox must be connected to a com object. This
object establishes the connection to Robotino with the specified address. Insert
the displayed Robotino address into your com object, see Figure H.18.
9. Run your Simulink model and observe the displayed values. In order to determine
the real address of your connected diffuse sensors perform the following test. You
need a white piece of paper with a line of a black tape on it. Place the black side
of the paper under one of the diffuse sensors and observe the values of the digital
inputs on Simulink. Then place the white side of the paper under the same sensor
and observe the values again. You need to find out which digital input switches
from zero to one upon transition from the black to the white side of the paper.
Write down the address of that digital input.
10. Do the same test for the second sensor. Assign each address to the specified sensor.
11. You might have noticed that both diffuse sensors output 0 when they are above a
black surface and output 1 when they are above a white surface. If this is not the
case then you need to calibrate the sensor using a screw driver, see Figure H.19.
12. Using the above knowledge about the diffuse sensors you need to design a program
that makes the Robotino to travel forward along a straight path of a black tape.
The main idea of the program should be based on detecting the black path i.e.
both diffuse sensors read 0, if one of the sensors reads 1, then Robotino must
rotate to the opposite direction. Use the hints in Figure H.20.
13. Before testing your program insert the collision safety blocks.
14. Your test velocity should not be more than 300 mm/s.
15. In order to determine the real distance that the Robotino travels during the
test, you need to insert the Odometry block from lib_robotinohardware.mdl.
Odometry means the calculation of the vehicle’s actual position based on previous
rotation of the wheels. The Odometry block has four inputs and three outputs
according to Figure H.21. Every time you need to test your program you have to
reset the Odometry block.
16. Connect the output of the Odometry block to Sinks ⁄To Workspace then right
click to change it into a structure with time.
17. Run your Simulink program for the first time at the jacked up position in order to
make sure that everything is working correctly. Then test it on the ground with a
black tape which is 1.2 meters long.
18. Plot the distance traveled by Robotino along both the X and Y axes versus time.
Answer question Ex.3.
In this exercise you will perform obstacle detection using infrared sensors.
1. Open a new Simulink model and insert nine Distance Sensor blocks from
lib_robotinohardware.mdl.
2. Assign addresses for each of the sensors between (0 - 8) and then connect them all
to a com object with the specified address of Robotino, see Figure H.22.
3. These function blocks are connected to nine infrared sensors located at 40 degrees
from each other on the circular circumference of Robotino. The sensors are used
as distance sensors and consist of emitters which emit infrared light and receivers
with an evaluation unit. The receivers detect the reflected light beams from an
object and the evaluation unit provides an analogue voltage signal representing the
distance of the object.
4. Run your Simulink model and determine the address of the two infrared distance
sensors located at the front side of Robotino. Use a piece of paper as an obstacle
and place in front of Robotino then move it backward and forward.
5. Determine the voltage provided by both front sensors if the paper is located at a
distance of 15 cm directly in front of Robotino.
6. Update your model of Exercise 3 so that the Robotino stops at a distance of 15
cm from any obstacle located directly in front of it. Use this obstacle to define the
end point of your path.
7. Test your program and answer question Ex.4.
Remember: Do not run Robotino at speeds higher than 300 mm/s.
References