Robot Project Report Robotics
Robot Project Report Robotics
PIC n PLACE
ROBO
Prepared By
Gaurav Arora Himanshu Manik
[email protected] [email protected]
Ph- +919728084305 Ph- +919996903090
Aman Dua
[email protected]
Ph-+919728179191
This Project is the result of the dedication and encouragement of many individuals. My
sincere and heartfelt appreciation goes to all of them.
Firstly, I would like to thank Professor B.P. Arun , the most knowledgeable and
experienced person on the 8051 that I know. He is the one who introduced me to this
microcontroller and was always there, ready to discuss 8051 architecture and programming.
Also I would like to express my sincere thanks to Er. Manish who assist me althrough the
making of the robot.
-- Gaurav Arora
-- Himanshu Manik
-- Aman Dua
Project
PICK & PLACE ROBOT
Contents
Embedded design
Robotics & automation
Robot
Fabrication of robot
Major components of robot
H-bridge
Microcontroller
Programming
Input devices
Output devices
Power supply
Comparision between human and robot
Advantages of robot
Application of robot
Project report
Embedded design
The majority of computer systems in use today are embedded in other machinery,
such as automobiles, telephones, appliances, and peripherals for computer systems.
These are called embedded systems. While some embedded systems are very
sophisticated, many have minimal requirements for memory and program length, with
no operating system, and low software complexity. Typical input and output devices
include switches, relays, solenoids, LEDs, small or custom LCD displays, radio
frequency devices, and sensors for data such as temperature, humidity, light level etc.
Embedded systems usually have no keyboard, screen, disks, printers, or other
recognizable I/O devices of a personal computer, and may lack human interaction
devices of any kind.
Most embedded systems are time critical applications meaning that the embedded
system is working in an environment where timing is very important: the results of an
operation are only relevant if they take place in a specific time frame. An autopilot in
an aircraft is a time critical embedded system. If the autopilot detects that the plane
for some reason is going into a stall then it should take steps to correct this within
milliseconds or there would be catastrophic results
Robotics
Robotics is the science of dealing with the robotics and includes design, selection of
material of proper quality for the components. Fabrication, the study of various motors
( i.e. stepper or D.C. motors ) required for moving the components, design of electronic
circuits. Microcontroller/ computer & its programming & controls of Robots.
In other words Robotics involves various disciplines: Mechanical engineering, Material
sciences, Electronics , Computer sciences ,Computer engineering & control system.
What is robot?
Robot is a type of mechanical slave with great strength.
You can say it’s a reprogrammable, multifunctional, manipulator designed to move
material , parts ,tools or specialized . Devices through variable programmed motions for
the performance of a variety of task.
HOW A ROBOT IS FABRICATED?
SENSE ORGANS: Eye, Ear & Skin to provide valuable information to brain in
controlling the action of various parts
Analogously the Robot can be define into five
major components :-
• The Manipulator :-
It is just like a human arm. There are several joints and links for the No. of degree of
freedom.for the rotaion of X-axis,Y-axis & Z-axis.
• . The Endeffector ( Gripper )
It is same like that , end of the human arm i.e. Palm & Finger used to pick &
place things.The gripper has motor at the joint to open & close the claw. Hence
various objects can be hold between the fingers of claw.
-
• The Locomotive device ( Motor):-
This one is like the human muscles”, The power source for the movement of
Manipulator & Endeffector ( Gripper )
You take a battery; hook the positive side to one side of your DC motor. Then you
connect the negative side of the battery to the other motor lead. The motor spins forward.
If you swap the battery leads the motor spins in reverse.
Ok, that's basic. Now let’s say you want a Micro Controller Unit (MCU) to control the
motor, how would you do it? Well, for starters you get a device that would act like a solid
state switch, a transistor, and hook it up the motor. For this we use combination of
transistor switches known as H-BRIDGE.
Basic Theory:-
Let's start with the name, H-bridge. Sometimes called a "full bridge" the H-bridge is so
named because it has four switching elements at the "corners" of the H and the motor
forms the cross bar. The basic bridge is shown in the figure to the right.
Of course the letter H doesn't have the top and bottom joined together, but hopefully the
picture is clear.
The key fact to note is that there are, in theory, four switching elements within the bridge.
These four elements are often called, high side left, high side right, low side right, and
low side left (when traversing in clockwise order).
The switches are turned on in pairs, either high left and lower right, or lower left and high
right, but never both switches on the same "side" of the bridge. If both switches on one
side of a bridge are turned on it creates a short circuit between the battery plus and
battery minus terminals. This phenomena is called shoot through in the Switch-Mode
Power Supply (SMPS) literature. If the bridge is sufficiently powerful it will absorb that
load and your batteries will simply drain quickly. Usually however the switches in
question melt.
To power the motor, you turn on two switches that are diagonally opposed. In the picture
to the right, imagine that the high side left and low side right switches are turned on. The
current flow is shown in green.
The current flows and the motor begins to turn in a "positive" direction. What happens if
you turn on the high side right and low side left switches? You guessed it, current flows
the other direction through the motor and the motor turns in the opposite direction.
Actually it is just that simple, the tricky part comes in when you decide what to use for
switches. Anything that can carry a current will work, from four SPST switches, one
DPDT switch, relays, transistors, to enhancement mode power MOSFETs.
One more topic in the basic theory section, quadrants. If each switch can be controlled
independently then you can do some interesting things with the bridge, some folks call
such a bridge a "four quadrant device" (4QD get it?). If you built it out of a single DPDT
relay, you can really only control forward or reverse. You can build a small truth table
that tells you for each of the switch's states, what the bridge will do. As each switch has
one of two states, and there are four switches, there are 16 possible states. However, since
any state that turns both switches on one side on is "bad" (smoke issues forth), there are
in fact only four useful states (the four quadrants) where the transistors are turned on.
The last two rows describe a maneuver where you "short circuit" the motor which causes
the motors generator effect to work against itself. The turning motor generates a voltage
which tries to force the motor to turn the opposite direction. This causes the motor to
rapidly stop spinning and is called "braking" on a lot of H-bridge designs.
Of course there is also the state where all the transistors are turned off. In this case the
motor coasts if it was spinning and does nothing if it was doing nothing.
Semiconductor H-Bridges
We can better control our motor by using transistors or Field Effect Transistors (FETs).
Most of what we have discussed about the relays H-Bridge is true of these circuits. You
don't need diodes that were across the relay coils now. You should use diodes across your
transistors though. See the following diagram showing how they are connected.
These solid state circuits provide power and ground connections to the motor, as did the relay circuits. The
high side drivers need to be current "sources" which is what PNP transistors and P-channel FETs are good
at. The low side drivers need to be current "sinks" which is what NPN transistors and N-channel FETs are
good at.
If you turn on the two upper circuits, the motor resists turning, so you effectively have a breaking
mechanism. The same is true if you turn on both of the lower circuits. This is because the motor is a
generator and when it turns it generates a voltage. If the terminals of the motor are connected (shorted),
then the voltage generated counteracts the motors freedom to turn. It is as if you are applying a similar but
opposite voltage to the one generated by the motor being turned. Vis-ã-vis, it acts like a brake.
To be nice to your transistors, you should add diodes to catch the back voltage that is
generated by the motor's coil when the power is switched on and off. This flyback
voltage can be many times higher than the supply voltage! If you don't use diodes, you
could burn out your transistors.
Transistors, being a semiconductor device, will have some resistance, which causes them
to get hot when conducting much current. This is called not being able to sink or source
very much power, i.e.: Not able to provide much current from ground or from plus
voltage.
Mosfets are much more efficient, they can provide much more current and not get as hot.
They usually have the flyback diodes built in so you don't need the diodes anymore. This
helps guard against flyback voltage frying your MCU.
To use Mosfets in an H-Bridge, you need P-Channel Mosfets on top because they can
"source" power, and N-Channel Mosfets on the bottom because then can "sink" power.
N-Channel Mosfets are much cheaper than P-Channel Mosfets, but N-Channel Mosfets
used to source power require about 7 volts more than the supply voltage, to turn on. As a
result, some people manage to use N-Channel Mosfets, on top of the H-Bridge, by using
cleaver circuits to overcome the breakdown voltage.
It is important that the four quadrants of the H-Bridgecircuits be turned on and off
properly. When there is a path between the positive and ground side of the H-Bridge,
other than through the motor, a condition exists called "shoot through". This is basically a
direct short of the power supply and can cause semiconductors to become ballistic, in
circuits with large currents flowing. There are H-bridge chips available that are much
easier, and safer, to use than designing your own H-Bridge circuit.
Circuit diagram:-
H-bridge on PCB
8
1 2 3 4 5
Discussion:
The above h-bridge thus can be used for moving motors.thus the ‘Differential
Mechanism’ using two DC Motors is shown below.
DC DC
MOTOR 1 MOTOR 2
BASE
DC DC
MOTOR 1 MOTOR 2
BASE
• The Controller :-
Microcontroller
A microcontroller (also MCU or µC) is a functional computer system-on-a-chip. It
contains a processor core, memory, and programmable input/output peripherals.
Time Processing Unit or TPU for short. Is essentially just another timer, but more
sophisticated. In addition to counting down, the TPU can detect input events, generate
output events, and other useful operations.
Dedicated Pulse Width Modulation (PWM) block makes it possible for the CPU to
control power converters, resistive loads, motors etc.. without using lot's of CPU
resources in tight timer loops.
Universal Asynchronous Receiver/Transmitter (UART) block makes it possible to
receive and transmit data over a serial line with very little load on the CPU.
For those wanting ethernet one can use an external chip like Crystal Semiconductor
CS8900A, Realtek RTL8019, or Microchip ENC 28J60 (buggy). All of them
allows easy interfacing with low pin count.
Higher integration
In contrast to general-purpose CPUs, microcontrollers may not implement an external
address or data bus as they integrate RAM and non-volatile memory on the same chip
as the CPU. Using fewer pins, the chip can be placed in a much smaller, cheaper
package.
Integrating the memory and other peripherals on a single chip and testing them as a
unit increases the cost of that chip, but often results in decreased net cost of the
embedded system as a whole. Even if the cost of a CPU that has integrated
peripherals is slightly more than the cost of a CPU + external peripherals, having
fewer chips typically allows a smaller and cheaper circuit board, and reduces the
labor required to assemble and test the circuit board.
Central Processing Unit - ranging from small and simple 4-bit processors to
complex 32- or 64-bit processors
discrete input and output bits, allowing control or detection of the logic state
of an individual package pin
serial input/output such as serial ports (UARTs)
other serial communications interfaces like I²C, Serial Peripheral Interface
and Controller Area Network for system interconnect
peripherals such as timers, event counters, PWM generators, and
watchdog
volatile memory (RAM) for data storage
ROM, EPROM, EEPROM or Flash memory for program and operating
parameter storage
clock generator - often an oscillator for a quartz timing crystal, resonator or
RC circuit
many include analog-to-digital converters
in-circuit programming and debugging support
This integration drastically reduces the number of chips and the amount of wiring
and circuit board space that would be needed to produce equivalent systems using
separate chips. Furthermore, and on low pin count devices in particular, each pin may
interface to several internal peripherals, with the pin function selected by software.
This allows a part to be used in a wider variety of applications than if pins had
dedicated functions. Microcontrollers have proved to be highly popular in embedded
systems since their introduction in the 1970s.
Many microcontrollers are so quirky that they effectively require their own non-
standard dialects of C, such as SDCC for the 8051, which prevent using standard
tools (such as code libraries or static analysis tools) even for code unrelated to
hardware features. Interpreters are often used to hide such low level quirks.
Interpreter firmware is also available for some microcontrollers. For example, BASIC
on the early microcontrollers Intel 8052[3] and Zilog Z8 as well as some modern
devices. Typically these interpreters support interactive programming.
Recent microcontrollers are often integrated with on-chip debug circuitry that when
accessed by an In-circuit emulator via JTAG, allow debugging of the firmware with a
debugger.
1
3
2
2
1
5
3
4
1. Window 1 is the main window where the program is written.
2. Window 2 shows the output window, which on the execution of the program shows
the errors occurred, warnings encountered and other similar data. This is selected by
pointing to ‘view’-> ‘output’.
3. Window 3 shows the Registers used along with their values. For dynamic variation of
these values reflecting their values in the memory, one needs to ‘Simulate’ which will
be further explained at a later stage. This is selected by pointing to ‘view’->
‘Registers’.
4. Window 4 shows Port Window showing the values acquired by the ports. This
window is also useful when simulating. This is selected by pointing to ‘view’->
‘Ports’.
5. Window 5 shows the values of important internal variables including Timers, TMOD,
IE etc.
Simulation
ORG 0000H
MOV A,P1
• The Sensor:-
These can be compared with “The sense organs “ of human being. These sensor are
responsible for the artificial intelligence of Robot ,”The controller can’t perform
intelligent task without ‘The Sensor’. Sensors are nothing but they are measuring
instrument who provide the valuable data (i.e. Position , velocity, force, torque,
proximity, temperature etc.) to the Microcontroller or PC
Examples Of Sensors:-
Reed Switches
Load Cell
Microswitches
Proximity Sensor ( Metal, IR )
LDR( Light Emitting Diode)
Ultrasonic Sensor
Camera
Thermister
Electronic Compass
Microphone
Chemical Sensor
• I/P Devices:-
The input signals are given through the mobile phone. The mobile phone has Dual-Tone
Multi-Frequency (DTMF) technology which is perhaps the most widely known method
of Multi Frequency Shift Keying (MSFK) data transmission technique. DTMF was
developed by Bell Labs to be used in the telephone system. Most telephones today uses
DTMF dialing (or “tone” dialing).The mobile phone has encoder and decoder circuit
inbuilt.
DTMF Decoder is a very easy to use program to decode DTMF dial tones found on
telephone lines with touch tone phones.
DTMF Decoder is also used for receiving data transmissions over the air in amateur radio
frequency bands.
The following are the frequencies used for the DTMF (dual-tone, multi-frequency)
system, which is also referred to as tone dialling. The signal is encoded as a pair of
sinusoidal (sine wave) tones from the table below which are mixed with each other.
DTMF is used by most PSTN (public switched telephone networks) systems for number
dialling, and is also used for voice-response systems such as telephone banking and
sometimes over private radio networks to provide signalling and transferring of small
amounts of data.
• Power Supply:-
It provides the electric energy to the system. Li-ion battery, pencil cell, hydrade
ion battery etc. are some of the power supplies available for energizing the
electronic circuit electrically.
• Why Robots?
ROBOT HUMAN
Robot can wort for all week days & no Human being works only for 8
need for holiday at the week ends. hours need a holiday at the week
ADVANTAGES OF ROBOT
REDUCED COST OF PRODUCTION.
INCREASED PRODUCTION.
IMPROVED PRODUCTION QUALITY.
IT CAN WORK IN HAZARDOUS & HOSTILE ENVIRONMENT.
IMPROVED MGT. CONTROL.
IT MEETS OCCUPATION SAFETY & HEALTH ADMINISTRATION
STANDARDS.