You are on page 1of 39

1

EX NO: 01
STUDY ON BASICS OF ROBOTS
DATE :

Objective:
To study the
Parts of the robot
Classification of robots


Description:
The industrial robots shown in fig 1.1 resemble an inverted human arm mounted on a base. The most
complex robotics system can be broken down into a few basic components.

The various components of the robots are,



Fig 1.1: Industrial robotic arm



Manipulator
End effector
Actuator
Sensors
Power supply
Means for programming


2






Fig 1.1: Basic components of a robot


Manipulator:
Manipulator is the main body of the robot and consists of the links, joints, and other structural elements of
the robot.

End Effector:
End effector is the last part attached the last joint of a manipulator which generally handles objects, makes
connection to other machines or performs the required tasks. Grippers, welding torch, point spray gun,
glue laying gun etc. are some of the examples of end effector.

Actuator:
An actuator is a motor or valve that converts power in to robot movements. There are two basic types of
actuators namely linear and rotary actuators. Linear actuators provide motion along a straight line. Rotary
actuators provide rotation, moving their loads in arc or circle.

Sensors:
Sensors are used to collect information about the internal state of the robot or to communicate with the
outside environment. Robots are often equipped with external sensory devices such as a vision system,
touch and tactile sensors, speech synthesizers etc., which enables the robot to communicate with the
outside world.

Power Supply:
Power supply provides the energy to drive the controller and actuators. It may convert ac voltage to the dc
voltage require by the robots internal circuits, or it may be a pump or compressor providing hydraulic or
pneumatic power. The three basic types or power supplies are electrical, hydraulic, and pneumatic.

3


Means for programming:
A robot may be programmed using any of several different methods. The teach pendant, also called a
teach box or hand held programmer. The teach pendant, also called a teach box or hand held programmer
shown in figure teaches a robot the movements required to perform a useful task. The operator uses a
teach pedant to move the robot through the series of points that describes its desired path. Offline
programming is one of the other methods where the programming is done on the computer using
simulation software without actually connecting it to the robot. After the successful simulation in the
software the robot can be loaded with the program.




Fig 1.1: Teach pendant



Classification of robot:
Robot can be classified in two types based on their mobility.
Mobile Robots
Non Mobile Robots


Mobile Robots:
Mobile Robots have the capability move from one place to another place in an environment. Usually a
mobile robots will have wheels attached to a platform and in some cases such as in humanoid robot or
other robot which resembles insect usually have legs for mobility. Other types of mobile robot are robots
which has the ability to fly like quadricopter. Few examples of mobile robot are show in the below figure
1.2 and 1.3.



4





Fig 1.2: ASIMO Humanoid robot developed by HONDA Fig 1.3: NASA s SPIRIT ROVER in planet MARS


Non-mobile Robot:
Industrial robotic arm is usually a non-mobile robot, which has a fixed base so it cannot move from one
place to another. The robot shown in fig 1.4 is a typical industrial robot developed by KUKA.



Fig 1.4 is a typical industrial robot developed by KUKA.







Conclusion:
By this above study experiment basic hardware components of robot and their classification based on their
mobility has been studied successfully.



5

EX NO: 02
INTRODUCTION TO DEGREES OF FREEDOM AND CLASSIFICATION OF ROBOTS
DATE :

Objective:

To study classification of robots based on workspace.
To study degrees of freedom of robots.
To study various robot joints.

Description:
Robots can be classified in various ways, depending on their components, configuration, and use. Three
common methods of classifying robots are by the shape of the work envelope, types of control system
used, , and the type of actuator drive used.

Based on work envelope:
Robots come in many sizes and shapes. The type of coordinate system used by the manipulator also varies.
Work envelopes vary from one manufacturer to another, depending on the exact design of the
manipulator arm. Combining different configurations in a single robot can result in another set of possible
work envelopes. Before choosing a particular robot configuration, the application must be studied carefully
to determine the precise work envelope requirements. Some work envelopes have a geometric shape;
others are irregular. One method of classifying a robot is by the configuration of its work envelope. Some
robots may be equipped for more than one configuration. The four major configurations are: Articulated,
Cartesian, cylindrical, and spherical. Each configuration is used for specific applications.

Cartesian Three linear movement
Cylindrical - two linear and one revolute joint
Spherical one linear and two revolute joint
Articulated - all three revolute (human arm)

Cartesian Configuration:
The arm movement of a robot using the Cartesian configuration can be described by three intersecting
perpendicular straight lines, referred to as the X, Y, and Z axes .Because movement can start and stop
simultaneously along all three axes, motion of the tool tip is smoother. This allows the robot to move
directly to its designated point, instead of following trajectories parallel to each axis. The rectangular work
envelope of a typical Cartesian configuration is illustrated in figure. One advantage of robots with a
Cartesian configuration is that their totally linear movement allows for simpler controls. They also have a
high degree of mechanical rigidity, accuracy, and repeatability. They can carry heavy loads, and this weight
lifting capacity does not vary at different locations within the work envelope. As to disadvantages,
Cartesian robots are generally limited in their movement to a small, rectangular work space. Typical
applications for Cartesian robots include the following:

Assembly
Machining operations

6


Adhesive application
Surface finishing
Inspection
Water jet cutting
Robotic X-ray and neutron radiography
Automated CNC lathe loading and operation
Remotely operated decontamination
Advanced munitions handling.



Fig 2.1 Cartesian configuration


Cylindrical Configuration
A cylindrical configuration consists of two orthogonal slides, placed at a 90 angle, mounted on a rotary
axis. Reach is accomplished as the arm of the robot moves in and out. For vertical movement, the carriage
moves up and down on a stationary post, or the post can move up and down in the base of the robot.
Movement along the three axes traces points on a cylinder.

A cylindrical configuration generally results in a larger work envelope than a Cartesian configuration. These
robots are ideally suited for pick-and place operations. However, cylindrical configurations have some
disadvantages. Their overall mechanical rigidity is reduced because robots with a rotary axis must
overcome the inertia of the object when rotating. Their repeatability and accuracy is also reduced in the
direction of rotary movement. The cylindrical configuration requires a more sophisticated control system
than the Cartesian configuration.






7


Typical applications for cylindrical configurations include the following:

Machine loading and unloading
Investment casting
Conveyor pallet transfers
Foundry and forging applications
General material handling
Meat packing
Coating applications
Assembly
Injection molding



Fig 2.2 Cylindrical configuration



Spherical Configuration (Polar)
The spherical configuration, sometimes referred to as the polar configuration, resembles the action
of the turret on a military tank. A pivot point gives the robot its vertical movement, and a telescoping
boom extends and retracts to provide reach. Rotary movement occurs around an axis perpendicular to the
base. Fig illustrates the work envelope profile of a typical spherical configuration robot. The spherical
configuration generally provides a larger work envelope than the Cartesian or cylindrical configurations.



8


The design is simple and provides good weight lifting capabilities. This configuration is suited to
applications where a small amount of vertical movement is adequate, such as loading and unloading a
punch press. Its disadvantages include reduced mechanical rigidity and the need for a more sophisticated
control system than either the Cartesian or cylindrical configurations. The same problems occur with
inertia and accuracy in this configuration as they do in the cylindrical configuration. Vertical movement is
limited, as well.




Fig 2.3 Spherical configuration

Typical applications of spherical configurations include the following:

Machine tool loading
Heat treating
Glass handling
Parts cleaning
Dip coating
Press loading
Material transfer
Stacking and un stacking



Revolute Configuration (Articulated)
The revolute configuration, or jointed-arm, is the most common. These robots are often referred to
as anthropomorphic because their movements closely resemble those of the human body. Rigid segments
resemble the human forearm and upper arm. Various joints mimic the action of the wrist, elbow, and
shoulder. A joint called the sweep represents the waist. A revolute coordinate robot performs in an
irregularly shaped work envelope. There are two basic revolute configurations: vertically articulated and
horizontally articulated. The vertically articulated configuration has five revolute (rotary) joints.
9


A vertically articulated robot is depicted. The jointed-arm, vertically articulated robot is useful for painting
applications because of the long reach this configuration allows. The horizontally articulated configuration
generally has one vertical (linear) and two revolute joints. Also called the SCARA (selective compliance
assembly robot arm) configuration, it was designed by Professor Makino of Yamanashi University, Japan.
The primary objective was a configuration that would be fairly yielding in horizontal motions and rather
rigid in vertical motions. The basic SCARA configuration, is an adaptation of the cylindrical configuration.
The SCARA robot is designed for clean-room applications, such as wafer and disk handling in the
electronics industry. SCARA robots are ideally suited for operations in which the vertical motion
requirements are small compared to the horizontal motion requirements. Such an application would be
assembly work where parts are picked up from a parts holder and moved along a nearly horizontal path to
the unit being assembled.

The revolute configuration has several advantages. It is, by far, the most versatile configuration and
provides a larger work envelope than the Cartesian, cylindrical, or spherical configurations. It also offers a
more flexible reach than the other configurations, making it ideally suited to welding and spray painting
operations. However, there are also disadvantages to the revolute configuration. It requires a very
sophisticated controller, and programming is more complex than for the other three configurations.
Different locations in the work envelope. can affect accuracy, load-carrying capacity, dynamics, and the
robots ability to repeat a movement accurately. This configuration also becomes less stable as the arm
approaches its maximum reach.
Typical applications of revolute configurations include the following:

Automatic assembly
Parts and material handling
In-process inspection
Palletizing
Machine loading and unloading
Machine vision
Material cutting
Material removal
Thermal coating
Paint and adhesive application
Welding
Die casting

Degrees of Freedom
Although robots have a certain amount of dexterity, it does not compare to human dexterity. The
movements of the human hand are controlled by 35 muscles. Fifteen of these muscles are located in the
forearm. The arrangement of muscles in the hand provides great strength to the fingers and thumb for
grasping objects. Each finger can act alone or together with the thumb. This enables the hand to do many
intricate and delicate tasks. In addition, the human hand has 27 bones. Figure shows the bones found in
the hand and wrist. This bone, joint, and muscle arrangement gives the hand its dexterity. Degrees of
freedom (DOF) are a term used to describe a robots freedom of motion in three-dimensional space
10

specifically, the ability to move forward and backward, up and down, and to the left and to the right. For
each degree of freedom, a joint is required. A robot requires six degrees of freedom to be completely
versatile. Its movements are clumsier than those of a human hand, which has 22 degrees of freedom. The
number of degrees of freedom defines the robots configuration.
For example, many simple applications require movement along three axes: X, Y, and Z. These tasks require
three joints, or three degrees of freedom. The three degrees of freedom in the robot arm are the
rotational traverse, the radial traverse, and the vertical traverse. The rotational traverse is movement on a
vertical axis. This is the side-to-side swivel of the robots arm on its base. The radial traverse is the
extension and retraction of the arm, creating in-and-out motion relative to the base. The vertical traverse
provides up-and-down motion. For applications that require more freedom, additional degrees can be
obtained from the wrist, which gives the end effecter its flexibility. The three degrees of freedom in the
wrist have aeronautical names: pitch, yaw, and roll. The pitch, or bend, is the up-and-down movement of
the wrist. The yaw is the side-to-side movement, and the roll, or swivel, involves rotation.
A robot requires a total of six degrees of freedom to locate and orient its hand at any point in its work
envelope. Although six degrees of freedom are required for maximum flexibility, most applications require
only three to five. When more degrees of freedom are required, the robots motions and controller design
become more complex. Some industrial robots have seven or eight degrees of freedom. These additional
degrees are achieved by mounting the robot on a track or moving base.



Fig 2.4 Joint and links of human arm Fig 2.5 Degrees of freedom







11

Robot Joints

Fig 2.6 Joint type

The joints in robots are categorized into two types. They are,
linear and
rotary

Linear joints provide motion along a straight line; they extend or retract their attached loads.
Rotary Joints provide rotation, moving their loads in an arc or circle. Rotary motion can be converted into
linear motion using a lead screw or other mechanical means of conversion. These types of actuators are
also used outside the robot to move work pieces and provide other kinds of motion within the work
envelope.












Conclusion:
Thus the classification of robots based on work space, degrees of freedom of robots and Robot
joints were studied.

12

EX NO: 03
STUDY ON KINEMATICS OF ROBOTIC ARM
DATE :

Objective:
To study the
Forward kinematics of Robots
Inverse kinematics of robots


Description:

Forward Kinematics of Robots
Forward kinematics is the method for determining the orientation and position of the end effector, given
the joint angles and link length of the robotic arm. For forward kinematics, we will have to develop a set of
equations that relate to the particular configuration of a robot such that by substituting the joint and link
variables in these equations, the position and orientation of the robot can be calculated.

A robot manipulator is composed of a set of links connected together by various joints. The joints can
either be very simple, such as revolute joints or prismatic joints.

Cartesian coordinates
There will be a three linear movements along the three major x,y,z axes. In this type of a robot, all
actuators are linear, and the positioning of the hand of the robot is accomplished by moving the three
linear joints along the three axes. A gantry robot is basically a Cartesian coordinate robot, except that the
robot is usually attached to a rectangular frame upside down.



Fig 3.1 Cartesian configuration and transformation matrix

Of course, since there are no rotations, the transformation matrix representation this motion to point p is
a simple translation transformation matrix, as shown next. Please note that here we are only referring to
the position of the origin of the frame, and not its orientation. The transformation matrix representing the
forward kinematic equation of the position of the hand of the robot in a Cartesian coordinates system will
be by the three transformations that relates the origin of the hand frame can be found by pre multiplying
by each matrix as follows


T
1 0 0 P
x
0 1 0 P
y
0 0 1 P
z
0 0 0 1

13


Cylindrical coordinates:















Fig 3.2 Cylindrical coordinates

T
1 0 0 0
0 1 0 0
0 0 1 l
0 0 0 1

C S 0 0
S C 0 0
0 0 1 0
0 0 0 1

1 0 0 r
0 1 0 0
0 0 1 0
0 0 0 1



T
C S 0 rC
S C 0 rS
0 0 1 l
0 0 0 1



A Cylindrical coordinate system includes two linear translations and one rotation. The sequence is a
translation of r along the axis, a rotation of about the z axis, and a translation of l along the z axis, as
shown in fig. Since these transformation are all relative to the axes of the universe reference frame, the
total transformation caused The first three columns represent the orientation of the frame after this series
of transformations. However, at this point, we are only interested in the position of the origin of the frame,
or the last column. Obviously, in cylindrical coordinate movements, due to the rotation about the z axis,
the orientation of the moving frame will change. This orientation change will be discussed later.

Spherical coordinates.
Spherical coordinate system consists of one linear motion and two rotations. The sequence is a translation
of r along the z axis, a rotation of about the y axis, and a rotation of about the z axis as shown in fig.
Since these transformation are all relative to the axes of the universe reference frame, the total
transformation caused by the three transformations that relates the origin of the hand frame can be found
by pre multiplying by each matrix as follows
n
o
a

X
Y
Z
P
14




T
C S 0 0
S C 0 0
0 0 1 l
0 0 0 1

C 0 S 0
0 1 0 0
S 0 C 0
0 0 0 1

1 0 0 0
0 1 0 0
0 0 1 r
0 0 0 1



T
C .C S S .C rS .C
C .S C S .S rS .S
0 0 C rC
0 0 0 1



The first three columns represent the orientation of the frame after this series of transformations. While
the last column is the position of the origin.

Articulated coordinates.
Articulated coordinates consist of three rotations. Forward kinematic equation for articulated arm can be
represented by using DENAVIT HARTENBERG representation.

Fig: 3.3 DENAVIT HARTENBERG


Each joint is assigned a coordinate frame. Using the Denavit-Hartenberg notation, you need 4 parameters
to describe how a frame (i) relates to a previous frame ( i -1 ).

1) a
(i-1)

Technical Definition: a
(i-1)
is the length of the perpendicular between the joint axes. The joint axes is the
axes around which revolution takes place which are the Z
(i-1)
and

Z
(i)
axes. These two axes can be viewed as
Z
(i - 1)

X
(i -1)

Y
(i -1)

un
( i
- 1)

a
(i - 1
)

Z
i

Y
i

X
i

a
i

d
i

U
i

15

lines in space. The common perpendicular is the shortest line between the two axis-lines and is
perpendicular to both axis-lines.

Visual Approach - A way to visualize the link parameter a
(i-1)
is to imagine an expanding cylinder whose
axis is the Z
(i-1)
axis - when the cylinder just touches the joint axis i the radius of the cylinder is equal to a
(i-
1).
(Manipulator Kinematics)

Its Usually on the Diagram Approach - If the diagram already specifies the various coordinate frames,
then the common perpendicular is usually the X
(i-1)
axis. So a
(i-1)
is just the displacement along the X
(i-1)
to
move from the (i-1) frame to the i frame.
If the link is prismatic, then a
(i-1)
is a variable, not a parameter.

2) a
(i-1)

Technical Definition: Amount of rotation around the common perpendicular so that the joint axes are
parallel.i.e. How much you have to rotate around the X
(i-1)
axis so that the Z
(i-1)
is pointing in the same
direction as the Z
i
axis. Positive rotation follows the right hand rule.

3) d
(i-1)

Technical Definition: The displacement along the Z
i
axis needed to align the a
(i-1)
common perpendicular to
the a
i
common perpendicular.
In other words, displacement along the Z
i
to align the X
(i-1)
and X
i
axes.

4) U
i

Amount of rotation around the Z
i
axis needed to align the

X
(i-1)
axis with the X
i
axis.

The Denavit-Hartenberg Matrix









Conclusion:
Thus the forward and inverse kinematics of robotic arm has been studied successfully .

1 0 0 0
cos cos sin cos sin sin
sin sin cos cos cos sin
0 sin cos
i 1) (i 1) (i 1) (i i 1) (i i
i 1) (i 1) (i 1) (i i 1) (i i
1) (i i i
d
d
a
16

EX NO: 04
STUDY ON MOBILE ROBOTS
DATE :


Objective:
To study the
Applications of the robots
Mechanics of the robots


Description:
Robot:
Robot is a reprogrammable multi functional manipulator; Which Follows programmed paths to
fulfill a large variety of tasks. For example, material handling.

Classification:
Basically robots are classified into two types based on their behavior. They are mobile and non
mobile robots.

Mobile robots:
These mobile robots will be having a Platform with a large mobility within its environment (air, land,
underwater) with the following functional characteristics:

Mobility: total mobility relative to the environment
A certain level of autonomy: limited human interaction
Perception ability: sensing and reacting in the environment

The robots have potential application in areas where a vehicle or a mechanic automatic system may exist.
Applications of Mobile Robots :

MEDICAL SERVICES as Service Robots
o Transportation of food, medication, medical exams,
o Automation of pharmacy service

AUTOMATIC CLEANING of (large) areas
o Supermarkets, airports, industrial sites
o Glass cleaning
o Domestic vacuum-cleaner

CLIENT SUPPORT
o Museum tours, exhibitions guides

AGRICULTURAL
o Fruit and vegetable picking, fertilization, planting
17



FORESTS
o Cleaning, fire preventing, tree cutting

HAZARD ENVIRONMENTS
o Inspection of hazard environments (catastrophic areas, volcanoes, nuclear power plants, oil
tanks)
o Inspection of gas or oil pipes, and power transmission lines
o Oil tank cleaning

SPACE
o Space exploration
o Remote inspection of space stations

MILITARY
o Surveillance vehicles
o Monitoring vehicles

MATERIAL HANDLING
o AGVs, SGVs, LGVs

ENTERTAINMENT
o Robot Dog
o Aibo Robot dog from Sony
o Tele presence

Components of a Mobile Robot
A mobile robot is a combination of various physical (hardware) and computational (software)
components.

In terms of hardware components, a mobile robot can be considered as a collection of subsystems for:

Locomotion (how the robot moves through its environment)
Sensing (how the robot measures properties of itself and its environment)
Reasoning (how the robot maps the measurements into actions)
Communication how the robot communicates with an outside Operator)

In terms of software components, sets of subsystems are responsible for:

Planning (To plan its various aspect)



18

YouBot Hardware Descriptions And Kinematics
Youbot is basically a mobile platform with a 5 axes serial kinematic arm and two-finger gripper. It is an
open platform, which means it can be controlled using open source simulation software such as VREP,
OpenRAVE, Webots [7]. The hardware and kinematics has been described in two separate parts, arm
manipulator and mobile platform to get better understanding since algorithm for path plan has been
developed separately based on their hardware and kinematics.

Mecanum Wheels
In general there are two types of wheels, conventional wheel with a steering system and other is an
omnidirectional wheel. Youbot is an omnidirectional platform with Mecanum wheel, which can be driven
in any direction without any requirement of steering wheel.




Fig 1 -Mobile Platform (source KUKA Youbot Store)

As shown in Fig 1 each wheel has six rollers arranged on the surface of the wheels. The angle between the
roller and the center of the wheel axis is arranged at 45. When the wheel rotates part of the force is in
the direction of rotation and other part is normal to directional of the wheel. This makes the wheel to
move in any direction with minimum friction hence the platform have 3 degrees of freedom. The wheel
motion can be divided into passive and active direction. Active direction is the axis in which the roller is in
contact with the ground and passive is perpendicular to roller axis.

Kinematics Of Omni Directional Platform
Fig 2 shows that mobile platform has four mecanum wheels, which are arranged at four corners of the
rectangular platform. The platform has been developed with following movements namely (forward,
backward, left, right) translational movement and rotational movement.

represents the velocity in x-axis

represents the velocity in y-axis


Wz signifies the angular velocity

and

represents distance between the wheel axis and the center of Youbot in x and y axis respectively.




19




Fig 2-Kinematics of Mobile Platform

The traversing direction of the platform can be determined using a force vector that is calculated by the
resulting combination of part of the force along the direction of rotation of each wheel and the force
perpendicular to the direction of the each wheel rotation. Kinematics can be explained using the forward
kinematics and inverse kinematics equation as given below.

Forward Kinematics
In forward kinematics, the resultant velocity of the platform can be calculated if the velocity of each wheel
is known. The equation (2) for calculating the forward kinematics is give below.








Where,
R is the radius of the wheel,
K = l1 +l2

Inverse Kinematics
In inverse kinematics, the velocity of the platform is known and so velocity for each wheel has to be calculated. This
is done by inverse kinematics equation (2)







= R/4
Vx
Vy
Wz
1
2
3

1 1 1 1

1 -1 -1 1
= 1/ R
1 1 1 1

1 -1 -1 1
1
2
3

Vx
Vy
Wz
20

Where,
R is the radius of wheel, K = l1 +l2

Motion Dynamics
Below tables describes the different motion dynamics of Youbot mobile platform.






















Table shows different combination of wheel rotation results in a motion of mobile platform in different
direction. By the Table it is clear that four, three and two wheel rotation is possible. Due to the presence of
rollers in the wheels it is not necessary that always four wheels have to be rotated in order to move in a
particular direction. Wheel velocities can be calculated by using inverse kinematics equation as explained
earlier. This will be later used in the motion planning of the mobile platform.







Conclusion:
By this above study experiment applications of robots and mechanics of mobile robot (Kuka Youbot) has
been studied successfully.


Direction Front Right
Wheel
Front Left
Wheel
Rear Right
Wheel
Rear Left
Wheel
90 Clockwise
Clockwise
Zero
Clockwise
Clockwise
Zero
Clockwise
Zero
Clockwise
Clockwise
Zero
Clockwise
270 Anticlockwise
Anticlockwise
Zero
Anticlockwise
Anticlockwise
Zero
Anticlockwise
Zero
Anticlockwise
Anticlockwise
Zero
Anticlockwise
0

Anticlockwise
Anticlockwise
Zero
Clockwise
Zero
Clockwise
Anticlockwise
Zero
Anticlockwise
Clockwise
Clockwise
Zero
180 Clockwise
Clockwise
Zero
Anticlockwise
Zero
Anticlockwise
Clockwise
Zero
Clockwise
Anticlockwise
Anticlockwise
Zero
45 Zero Clockwise Zero Clockwise
315 Zero Anticlockwise Zero Anticlockwise
135 Clockwise Zero Clockwise Zero
225 Anticlockwise Zero Anticlockwise Zero
21

EX NO: 05
STUDY ON VREP SOFTWARE PACKAGE
DATE :

Objective:
To study the
VREP software package
Programming tool interface


Description:

VREP Simulation Environment
The software used to simulate the path planning of Youbot is VREP (Virtual Robot Experimentation
Platform), version 3.0.4. It has a 3 dimensional simulation environment, which can be interfaced with
various programming tools such as C++, Matlab, JAVA, Lua script, Urbi and Python.

User Interface






Fig 1 VREP User Interface

Fig 1 shows user interface of VREP simulation tool and has six components, which are toolbar, model
browser, scene, menu bar and scene hierarchy. Toolbar has all the functional part necessary to run the
simulation and change simulation settings based on user requirements.

Model browser displays the list of all the default models available in the simulation tool. A scene acts as a 3
dimensional space where single or several models can be placed and scene hierarchy displays the list of
models and their object present in the current scene.

Toolbar Model browser Scene hierarchy Scene Menu bar Toolbar
22



Fig 2 Scene Object types (source - VREP tutorial)


Model And Scene Objects
A model is a sub element of a scene and each model has collection of objects. A model acts as single entity.
One of the objects of the model is flagged as base object to which all the other objects are attached. The
base object is the parent and the other entire object in the base is a child. Selecting one of the objects
under this base object selects the entire model as single entity.Each model can have several object types as
shown in Fig 2. The object types whose properties are modified in this thesis are shape, joint, dummy, and
graph.

A shape is a geometrical structure of an object. A joint is an actuator, which is used for mobility or to do
some task which involves movement. There are several joints such as revolute joint, prismatic joint and
spherical joints. Revolute joint reflects the motor in simulation and prismatic joint for sliding movement
such as gripper. Dummy is an important object type, which is simply a point in space with a co-ordinate
frame of its own, attached to it. These dummies are very important for moving the arm to a goal position
or to move a robot towards a goal position. A graph is used to generate 2d or 3d graph while the
simulation is running whose properties can be modified to suit the needs of our requirement.

Scene Objects Properties
Each scene object has certain properties based on the object type and the properties can be modified
using scene object property dialog as shown in Fig 3. This dialog mainly has two divisions, which are
common and object specific property. Object specific properties are based on the object types for e.g. if
the object type is shape then it has shape as specific property, if the object type is joint then it has joint as
specific property in which joint mode and joint dynamic parameter can be modified.


23




Fig 3 VREP Scene object property dialog



Fig 4 VREP Scene object/item/position/orientation dialog

The common property is the general property of the object, which shows whether it is selectable or not,
visibility etc. The common property part also has some special property option such as whether the object
is collidable, measurable, cuttable, detectable etc. The important property that is modified in this thesis is
joint mode. Joint mode has several options such as force or torque mode, inverse kinematic mode, passive
mode, motion dependent mode, and motion independent mode. In force or torque mode a joint position
control is disabled and only velocity can be controlled. In inverse kinematic mode the joint can modified by
using the inverse kinematic calculation module, which will be, described later. The other properties, which
can be changed, are position and orientation of an object using object/item position/orientation dialog as
shown in Fig 4.
24


Calculation Modules
VREP has calculation modules as shown in Fig 5 which are default algorithm embedded in the simulation
tool for path planning, distance calculation, inverse kinematics, motion planning, dynamics and collision
detection. The module, which used in this thesis is inverse kinematics module for calculating the joint
values if the gripper position is known.



Fig 5 VREP Calculation Modules

Programming Tool Interface
VREP communicates with programming tool using application programing interface or commonly known as
API. VREP supports regular API AND remote API.VREP has embedded programming tool which supports Lua
scripting language. Regular API represents the communication of application engine with embedded script
of the VREP. Remote API supports communication between VREP and external programming tool or
hardware. In this thesis VREP is interfaced with MATLAB as remote API client server connection. VREP
acts as a server and MATLAB program as a client.

VREP has embedded main script, which handles all the communication and execution of the child script.
Child script is an embedded script associated with the scene objects and there can be several child script in
the model. VREP calls client through the child script associated with base object.

The client application can also communicate with child script by sending string or integer signal. By this, the
control can also be coordinated between embedded child script and the client script. Finally Matlab ends
communication by calling a remote API function, which terminates the communication between client and
server.

Conclusion:
By this above study experiment VREP software package and there programming tool interface has been
studied successfully.

25

EX NO: 06
STUDY ON PROGRAMMING OF ROBOTS
DATE :

Objective:
To study the
Programming in MATLAB
Programming in LUA script

Description:
VREP and Matlab are connected as server-client interface. Matlab act as client application, which
communicates with VREP via socket communication. Initially the client should be successfully connected
to the server for the execution of program in Matlab. VREP on the server side is initiated using the
following function -1 in Lua Script associated with base object.



Client Main Function
The main function is the main client function, which establish communication with server application for
the entirety of the simulation run. All the other function in Matlab is called from this function. The client
side starts the communication by following function -2.

[client ID]=simxStart(Address,connectionPort,booleanwait,booleanReconnect,timeOut,ThreadCycle)

Remote API Function 2
Matlab is connected to VREP using remote API functions. The function, which call server, is the main
function under which all the subsequent function are added to it. Once communication has been
established any commands can be given from Matlab to VREP to control Youbot.

If the communication is lost for some reason the simulation software execute last sent command. There
are some Remote API functions to overcome the error and to properly terminate communication. All
remote API functions have error codes and these codes are integers. Based on this integer the interface
problem can be identified and can be rectified easily.

Client Main Function
The main function is the main client function, which establish communication with server application for
the entirety of the simulation run. All the other function in Matlab is called from this function. The client
side starts the communication by following function -2.

Address is a string name and connection port is a port number to connect. If Boolean Reconnect is true
then it means if once communication with VREP has been terminated it will not try to reconnect. Time out
is maximum time limit in milliseconds for trying to establish a communication. Thread cycle is the
frequency of data packets sent and received between VREP and Matlab.
Once the simulation run has finished, client should end communication by calling the following function-3.
SimExtRemoteApiStart (portAddress)

Remote API Function 1

26


SimxFinish (client ID)
Remote API Function 3

Basic Control Functions
The client Matlab program has declaration stage in which all the object handles has to be obtained in
separate variables in order to send control commands to a specific object. For example to send a velocity
value to a wheel the wheel handle should be first obtained.

[ErrorCode, number handle]=simxGetObjectHandle(clientID,objectName,operationMode)
Remote API Function 4

Function-4 shown above is to obtain handles of the object.
Specific operation modes are required for each remote API function.

Simx_opmode_oneshot_wait
Operation mode 1
Operation mode 1 is a blocking mode, which sends request to server and waits for the actual server
reply. If the reply is not obtained then an error code is generated after specified time. There is one other
mode which is used less frequently is
Simx_opmode_oneshot
Operation mode 2
Operation mode 2 is a non-blocking mode, which does not wait for the actual reply from the server but
sends back previous replies. Once object handles has been retrieved all necessary data with respect to the
particular object can be obtained and control commands can be sent to modify the object.
The position values for an object can be obtained by Function -5

[ErrorCode,array]=simxGetObjectPosition(clientID,objectHandle,relativeObjectHandle,operationMode)
Remote API Function 5

Velocity of an object can be set by Function -6

[ErrorCode]=simxSetJointTargetVelocity(clientID,jointHandle,targetVelocity,operationMode)
Remote API Function 6

Target velocity is a one-dimensional value. Velocity can be either angular velocity value or linear velocity
depending on the joint type.

[ErrorCode,array]=simxGetObjectPosition(clientID,objectHandle,relativeObjectHandle,operationMode)
Remote API Function 7

The gripper target dummy position is obtained by calling Function -7. Then the target dummy can be given
a new position by using the Function-8.

27



[ErrorCode]=simxSetObjectPosition(clientID,objectHandle,relativeObjectHandle,position,operationMode)
Remote API Function 8


It sets an object position, which is a array of position value in each axis. Based on the new position value of
the gripper target dummy the IK module computes inverse kinematics calculations and respective joint
values are set for each joints and then gripper tip dummy follows the target dummy. Similarly orientation
can also be obtained.

Gripper Control
The primary goal is to grab or drop the object after reaching the goal position. There are several ways to
implement gripper control either directly from client or by sending signal from client to child script of the
gripper.

The child script continuously checks for the signal, if the signal is sent then it unpacks the data packets. The
data packet sent is a Boolean variable. If it is true then gripper joints closes until it touches an object. By
default the gripper joint always stays open until a string signal is sent.

packed Data=simxPackInts(array integer values)
Remote API Function 9

The Function 9 packs the array of integer values.

[ErrorCode]=simxAppendStringSignal(clientID,signalname,arrayinteger value,operationMode)
Remote API Function 10

Function 10 sends the packed value under signal name and it is sent to the child script in VREP simulation
environment. The child script closes or opens the gripper based on the value sent.

PROGRAMMING IN LUA SCRIPT
BASIC COMMANDS
GET OBJECT HANDLE
Syntax
number objectHandle=simGetObjectHandle
Description
Retrieves an object handle based on its name.

GET OBJECT POSITION
Syntax
table_3 position=simGetObjectPosition
Description
Retrieves the position of an object.
28


SET OBJECT POSITION
Syntax
number result=simSetObjectPosition
Description
Sets the position (x, y and z-coordinates) of an object. Dynamically simulated objects will implicitely be
reset before the command is applied.

SET TRAJECTORY VELOCITY
Syntax
number result=simSetJointTargetVelocity
Description
Sets the intrinsic target velocity of a non-spherical joint. This command makes only sense when the joint
mode is: (a) motion mode: the joint's motion handling feature must be enabled, (b) torque/force mode:
the dynamics functionality and the joint motor have to be enabled.

GET TRAJECTORY VELOCITY
Syntax
number targetVelocity=simGetJointTargetVelocity
Description
Retrieves the intrinsic target velocity of a non-spherical joint.

HANDLE IK GROUP
Syntax
number calculationCountOrResult=simHandleIkGroup
Description
Handles (solves) a registered IK group. IK groups can be registered while editing a scene.













Conclusion:
By this above study experiment programming of a robot in VREP using LUA script and MATLAB has been
studied successfully.


29

EX NO: 07
MOTION PLANNING OF MOBILE ROBOT (KUKA YOUBOT)
DATE :

Objective:
The objective of this exercise is to write a program to move the Youbot from its start position to
goal position using the Lua script in VREP simulation software.

Description:

Open a new scene from the file menu of VREP simulation software.
From the model browser open folder named mobile.
Drag down the model browser and pick up the KUKA YOUBOT and place it in the simulation
environment.
Now select the child script of YOUBOT and delete all the program codes
Define the goal point by creating a dummy and placing it in the specific location (reference frame).
Now develop your own algorithm to move the Youbot from start to goal position
Calculate the shortest distance from the start to goal point by the distance formula.
Now define your own logic to give velocity to each wheel and make the robot to stop near the goal.


Pseudo code

if (simGetScriptExecutionCount()==0) then

Get all necessary objects handle

simHandleChildScript(sim_handle_all_except_explicit)

Define start and goal point

Calculate shortest distance

Give velocity for each wheel

Stop the robot at goal

end







30







Fig 7- Model motion of Youbot to reach goal position






















Result:

Thus successful simulation of movement of Youbot from a specific start point to a goal point has
completed

31

EX NO: 8
Motion planning of Robotic Arm in circular path
DATE :

Objective:

The objective of this exercise is to write a program to make the Youbarm to follow a circular path.


Description:

Open a new scene from the file menu of VREP simulation software.
From the model browser open folder named mobile.
Drag down the model browser and pick up the KUKA YOUBOT and place it in the simulation environment.
Now select the child script of YOUBOT and delete all the program codes
Define at least 10 points by creating a dummy and placing it in the specific location to form a circular (reference frame).
Now develop your own algorithm to make the Youbot arm to follow the predefined path.



Pseudo code

if (simGetScriptExecutionCount()==0) then

Get all necessary objects handle

simHandleChildScript(sim_handle_all_except_explicit)

Define the set of points to be followed

Set target position points to gripper

Call inverse Kinematics algorithm

Give incremental position to the gripper

Stop the gripper at the goal

End




Result:

Thus successful simulation of movement of Youbot arm to follow a specific path has been successfully done







32

EX NO: 9
Motion planning of Robotic Arm in straight line path
DATE :

Objective:

The objective of this exercise is to write a program to move the Youbot arm from its start position to goal position such that it
follows a straight-line trajectory using the Lua script and create successful simulation in VREP simulation software.


Description:

Open a new scene from the file menu of VREP simulation software.
From the model browser open folder named mobile.
Drag down the model browser and pick up the KUKA YOUBOT and place it in the simulation environment.
Now select the child script of YOUBOT and delete all the program codes
Define the goal point by creating a dummy and placing it in the specific location (reference frame).
Now develop your own algorithm to move the Youbot arm from start to goal position
Calculate the shortest distance from the start to goal point by the distance formula.
Now define your own logic to give velocity to each wheel and make the robot to stop near the goal.




Pseudo code

if (simGetScriptExecutionCount()==0) then

Get all necessary objects handle

simHandleChildScript(sim_handle_all_except_explicit)

Define start and goal point for the arm

Calculate shortest distance

Call inverse Kinematics algorithm

Give incremental position to the gripper

Stop the gripper at the goal

End






Result:

Thus successful simulation of movement of Youbot arm from a specific start point to a goal point has completed.



33

EX NO: 10
PICK AND PLACE OPERATION BY ROBOTIC ARM
DATE :

Objective:
The objective of this exercise is to write a program to up pick an object from the floor and place the object
in same position using the Lua script in VREP simulation software.


Description:

Open a new scene from the file menu of VREP simulation software.
From the model browser open folder named mobile.
Drag down the model browser and pick up the KUKA YOUBOT and place it in the simulation
environment.
Now right click on the mouse and select add primitive shape.
In primitive shape select cuboid and a window will open.
Now select pure shape in the window and create a cuboid of dimension 0.04
Now add a dummy similar to the steps for creating cuboid and place it in the center of the cuboid
Now make the dummy a child of the cuboid by right clicking the dummy and cuboid and selecting
the option last selected object a parent.
Select the cuboid and now select object/item shift from menubar, give position values such that
cuboid is placed in the platform of the YOUBOT.
Now select the child script of YOUBOT and delete all the program codes
Type the following command if (simGetScriptExecutionCount()==0) then in child script of Youbot
Now develop your own algorithm to pick up the object from the location and place it on the same
location using the Lua script functions.





Fig: 8.1 Model movement of the arm



34


Pseudo code

if (simGetScriptExecutionCount()==0) then

Get all necessary objects handle

simHandleChildScript(sim_handle_all_except_explicit)

Define start and goal point

Calculate intermediate points for the arm to follow

Set the arm to follow the points.
























Result:

Thus successful simulation of picking up an object and placing back in its own position using Lua script
programming tool has been done.


35

EX NO: 11
PICK AND PLACE OPERATION BY ROBOTIC ARM USING MATLAB
DATE :

Objective:
The objective of this exercise is to write a program to up pick an object from the floor and place the object
in same position using the MATLAB and interfacing it with VREP simulation software.


Description:

Open a new scene from the file menu of VREP simulation software.
From the model browser open folder named mobile.
Drag down the model browser and pick up the KUKA YOUBOT and place it in the simulation
environment.
Now right click on the mouse and select add primitive shape.
In primitive shape select cuboid and a window will open.
Now select pure shape in the window and create a cuboid of dimension 0.04
Now add a dummy similar to the steps for creating cuboid and place it in the center of the cuboid
Now make the dummy a child of the cuboid by right clicking the dummy and cuboid and selecting
the option last selected object a parent.
Select the cuboid and now select object/item shift from menubar, give position values such that
cuboid is placed in the platform of the YOUBOT.
Now select the child script of YOUBOT and delete all the program codes
Type the following command simExtRemoteApiStart(Portaddress) in child script of Youbot.
Now develop your own algorithm to pick up the object from the location and place it on the same
location using the Matlab functions.





Fig: 9.1 Model movement of the arm



36


Pseudo code

vrep=remApi('remoteApi','extApi.h'); (Call the library)

clientID=vrep.simxStart('127.0.0.1',8080,true,true,5000,5); (Initializing communication with VREP)

if (clientID>-1)

Get all necessary objects handle

Define start and goal point

Calculate intermediate points for the arm to follow

Set the arm to follow the points.

vrep.simxFinish(clientID);

vrep.delete();


















Result:

Thus successful simulation of picking up an object and placing back in its own position using Matlab
programming tool has been done.


37

EX NO: 12
MOTION PLANNING OF MOBILE PLATFORM (KUKA YOUBOT) USING MATLAB
DATE :

Objective:
The objective of this exercise is to write a program to move the Youbot from its start position to
goal position using the Matlab in VREP simulation software.

Description:

Open a new scene from the file menu of VREP simulation software.
From the model browser open folder named mobile.
Drag down the model browser and pick up the KUKA YOUBOT and place it in the simulation
environment.
Now select the child script of YOUBOT and delete all the program codes
Define the goal point by creating a dummy and placing it in the specific location (reference frame).
Type the following command simExtRemoteApiStart(Portaddress) in child script of Youbot.
Now develop your own algorithm in MATLAB to move the Youbot from start to goal position
Calculate the shortest distance from the start to goal point by the distance formula.
Now define your own logic to give velocity to each wheel and make the robot to stop near the goal.



Pseudo code

if (simGetScriptExecutionCount()==0) then

Get all necessary objects handle

simHandleChildScript(sim_handle_all_except_explicit)

Define start and goal point

Calculate shortest distance

Give velocity for each wheel

Stop the robot at goal

end





38







Fig 10.1- Model motion of Youbot to reach goal position






















Result:

Thus successful simulation of movement of Youbot from a specific start point to a goal point has
completed.

39

You might also like