Robotic Arm Control Using Pc
-
Upload
molla-ayenew -
Category
Documents
-
view
226 -
download
0
Transcript of Robotic Arm Control Using Pc
-
8/16/2019 Robotic Arm Control Using Pc
1/29
INTRODUCTION OF ROBOTIC ARM USING PC
The advent of new high-speed technology and the growing computer capacity
provided realistic opportunity for new robot controls and realization of new methods of
control theory. This technical improvement together with the need for high performance
robots created faster, more accurate and more intelligent robots using new robots control
devices, new drives and advanced control algorithms.
This project describes a new economical solution of robot control systems. The
presented robot control system can be used for different sophisticated robot applications.
The control system consists of a PC, a microcontroller that collects data from the PC and
control the robot.
The controlling of the robot is done by sending commands from the PCs Hyper
terminal. Capturing of locations videos can also be done if we connect the wireless
camera, and the same things can be monitored on the PC.
-
8/16/2019 Robotic Arm Control Using Pc
2/29
2. INTRODUCTION TO EMBEDDED SYSTEMS
2.1 EMBEDDED SYSTEM
!n embedded system is a combination of computer hardware and software, either
fi"ed in capability or programmable, that is specifically designed for a particular #ind of
application device. $t is a special-purpose computer system designed to perform one or a
few dedicated functions, sometimes with real-time computing constraints. $t is usually
embedded as part of a complete device including hardware and mechanical parts.
%mbedded systems have become very important today as they control many of
the common devices we use. &ince the embedded system is dedicated to specific tas#s,
design engineers can optimize it, reducing the size and cost of the product, or increasing
the reliability and performance.
!n embedded system is some combination of computer hardware and software,
either fi"ed in capability or programmable, that is specifically designed for a particular #ind of application device. $ndustrial machines, automobiles, medical e'uipment,
cameras, household appliances, airplanes, vending machines, and toys (as well as the
more obvious cellular phone and P)!* are among the myriad possible hosts of an
embedded system. %mbedded systems that are programmable are provided with a
programming interface, and embedded systems programming is a specialized occupation.
+
-
8/16/2019 Robotic Arm Control Using Pc
3/29
2.2 APPLICATIONS OF EMBEDDED SYSTEMS
!ny fast applications which ma#e you believe in your basic survival are just because
of these embedded systems. ur daily life depends on the proper functioning of many
gadgets li#e Television, adio, C) player, Card readers, !ccess Controllers etc. $f we go
in detail, we can use these embedded systems in,
ilitary and !erospace &oftware applications/
The 0yn"&-12 T& for software certification, based on the TC! )-123
standard, assists developers in gaining certification for their mission- and safety-critical
systems.
Communications !pplications/
0ynu" wor#s 4umpstart for Communications pac#age enables %s to rapidly
develop mission-critical communications e'uipment, with pre-integrated, state-of-the-art,
data networ#ing and porting software components5including source code for easy
customization.
$ndustrial !utomation and Process Control/
)esigners of industrial and process control systems #now from e"perience that
0ynu"6or#s operating systems provide the security and reliability that their industrial
applications re'uire.
7rom $& 899 certification to fault-tolerance, P&$: conformance, secure partitioning
and high availability, we;ve got it all. Ta#e advantage of our +9 years of e"perience.
-
8/16/2019 Robotic Arm Control Using Pc
4/29
3. AT89S52 MICROCONTROLLERS
3.1 INTRODUCTION
The !T28&=+ is a low-power, high-performance C& 2-bit microcontroller with 2>
bytes of in-system programmable 7lash memory. The device is manufactured using
!tmel?s high-density nonvolatile memory technology and is compatible with the $ndus-
try-standard 29C= instruction set and pin out. The on-chip 7lash allows the program
memory to be reprogrammed in-system or by a conventional nonvolatile memory pro-
grammer. 3y combining a versatile 2-bit CP@ with in-system programmable 7lash on a
monolithic chip, the !tmel !T28&=+ is a powerful microcontroller which provides a
highly-fle"ible and cost-effective solution to many embedded control applications. The
!T28&=+ provides the following standard features/ 2> bytes of 7lash, +=A bytes of !,
-
8/16/2019 Robotic Arm Control Using Pc
5/29
3.3 BLOC! DIAGRAM
7$H@%
-
8/16/2019 Robotic Arm Control Using Pc
6/29
3." PIN DIAGRAM
7$H@%
-
8/16/2019 Robotic Arm Control Using Pc
7/29
PORT *) Port 9 is an 2-bit open drain bidirectional $B port. !s an output
port, each pin can sin# eight TT0 inputs. 6hen s are written to port 9 pins, the pins can be
used as high-impedance input.
PORT 1/ Port is an 2-bit bidirectional $B port with internal pull-ups. The
Port output buffers can sin#Bsource four TT0 inputs.
PORT 2/ Port + uses strong internal pull-ups when emitting s. $t emits the
high-order address byte during fetches from e"ternal program memory and during accesses to
e"ternal data memory that use A-bit addresses.
PORT 3) Port < receives some control signals for 7lash programming and
verification
RST) eset input. ! high on this pin for two machine cycles while the
oscillator is running resets the device. This pin drives high for 82 oscillator periods after the
6atchdog times out.
ALE+PROG) !ddress 0atch %nable (!0%* is an output pulse for latching the
low byte of the address during accesses to e"ternal memory. This pin is also the program
pulse input (P* during 7lash programming.
PSEN) Program &tore %nable (P&%I* is the read strobe to e"ternal program
memory. 6hen the !T28&=+ is e"ecuting code from e"ternal program memory, P&%I is
activated twice each machine cycle, e"cept that two P&%I activations are s#ipped during
each access to e"ternal data memory.
EA+(PP) %"ternal !ccess %nable. %! must be strapped to I) in order to
enable the device to fetch code from e"ternal program memory locations starting at
9999H up to 7777H.
1
-
8/16/2019 Robotic Arm Control Using Pc
8/29
,TAL1) $nput to the inverting oscillator amplifier and input to the internal cloc#
operating circuit.
,TAL2) utput from the inverting oscillator amplifier.
-at%/'0 T#er O$et#e E$a4e/ 6#t Reet'ut7
The 6)T is intended as a recovery method in situations where the CP@ may be
subjected to software upsets. The 6)T consists of a F-bit counter and the 6atchdog
Timer eset (6)T&T* &7. The 6)T is defaulted to disable from e"iting reset. To
enable the 6)T, a user must write 9%H and 9%H in se'uence to the 6)T&T register
(&7 location 9!AH*.
U#$0 te -DT)
To enable the 6)T, a user must write 9%H and 9%H in se'uence to the 6)T&T
register (&7 location 9!AH*. 6hen the 6)T is enabled, the user needs to service it by
writing 9%H and 9%H to 6)T&T to avoid a 6)T overflow.
-DT /ur#$0 P'6er/'6$ a$/ I/e)
$n Power-down mode the oscillator stops, which means the 6)T also stops. 6hile in
Power-down mode, the user does not need to service the 6)T. There are two methods of
e"iting Power-down mode/ by a hardware reset or via a level-activated e"ternal interrupt
which is enabled prior to entering Power-down mode.
UART) The @!T in the !T28&=+ operates the same way as the @!T in the
!T28&=+ and !T28C=+.
T#er * a$/ 1/ Timer 9 and Timer in the !T28&=+ operate the same way as
Timer 9 and Timer in the !T28&=+ and !T28C=+.
T#er 2) Timer + is a A-bit TimerBCounter that can operate as either a timer or an
event counter. The type of operation is selected by bit CBT+ in the &7 T+CI.
2
-
8/16/2019 Robotic Arm Control Using Pc
9/29
Ser#a Pr'0ra#$0 A0'r#t) To program and verify the !T28&=+ in the
serial programming mode, the following se'uence is recommended/ . Power-up
se'uence/ a. !pply power between GCC and I) pins. !t the end of a programming
session, &T can be set low to commence normal device operation .
Pr'0ra (er#) $f loc# bits 03 and 03+ have not been programmed, the
programmed code data can be read bac# via the address and data lines for verification.
Pr'0ra#$0 te Fa : Parae M'/e/ The !T28&=+ is shipped with
the on-chip 7lash memory array ready to be programmed. The programming interface
needs a high-voltage (+-volt* program enable signal and is compatible with conventional
third-party 7lash or %P programmers. The !T28&=+ code memory array is
programmed byte-by-byte.
C#& Erae) $n the parallel programming mode, a chip erase operation is initiated by
using the proper combination of control signals and by pulsing !0%BP low for
duration of +99 ns - =99 ns. $n the serial programming mode, a chip erase operation is
initiated by issuing the Chip %rase instruction. Programming the 7lash E &erial ode the
Code memory array can be programmed using the serial $&P interface while &T is
pulled to GCC.
8
-
8/16/2019 Robotic Arm Control Using Pc
10/29
". RS232PROTOCOL; MA,232; MOTOR
".1 RS232 er#a &'rt7) &-+
-
8/16/2019 Robotic Arm Control Using Pc
11/29
5. -OR!ING FLO- OF T
SC
-
8/16/2019 Robotic Arm Control Using Pc
12/29
5.3 S%eat#% D#a0ra >
-
8/16/2019 Robotic Arm Control Using Pc
13/29
5." CIRCUIT FEATURES
3rief description of operation/ Hives out well regulated M=G output, output current
capability of 99 m!Circuit protection/ 3uilt-in overheating protection shuts down output when
regulator $C gets too hot
Circuit comple"ity/ Gery simple and easy to build
Circuit performance/ Gery stable M=G output voltage, reliable operation
!vailability of components/ %asy to get, uses only very common basic components
!pplications/ Part of electronics devices, small laboratory power supply
Power supply voltage/ @nregulated )C 2-2G power supply
Power supply current/ Ieeded output current M = m!
Component costs/ 7ew dollars for the electronics components M the input
transformer cost
5.5 BLOC! DIAGRAM
7$H@% =.<
-
8/16/2019 Robotic Arm Control Using Pc
14/29
5.? SC
-
8/16/2019 Robotic Arm Control Using Pc
15/29
7$H@% =.F
?. SOURCE CODE
N include O29=.h
void &erial$nit(void*
Q
T) R 9"+9J
TH R 9"fdJ
&CI R 9"=9J
T R J
S
void serial9(* interrupt F
Q
if($ RR *
Q
"Ch R &3@7J
$ R 9J
=
-
8/16/2019 Robotic Arm Control Using Pc
16/29
S
S
void main(void*
Q
unsigned int i R 9,
j R 9,
uc!ddrCounter R 9J
while(*
Q
if("chRR;;*
Q
BB I%C> G%%IT C0C>6$&%
P+ R 9"9
-
8/16/2019 Robotic Arm Control Using Pc
17/29
for(j R 9J j O J jMM*
for(i R 9J i O 99J iMM*J
P+ R 9"9AJ
for(j R 9J j OJ jMM*
for(i R 9J i O 999J iMM*J
S
if("chRR;+;*
Q
BB I%C> G%%IT !IT$ C0C>6$&%
P+ R 9"98J
for(j R 9J j OJ jMM*
for(i R 9J i O 99J iMM*J
P+ R 9"9
-
8/16/2019 Robotic Arm Control Using Pc
18/29
for(j R 9J j O J jMM*
for(i R 9J i O 99J iMM*J
S
if("chRR;6$&%
P+ R 9"
-
8/16/2019 Robotic Arm Control Using Pc
19/29
-
8/16/2019 Robotic Arm Control Using Pc
20/29
S
@. !EIL SOFT-ARE
. Clic# on the >eil vision $con on )es#top.
+. The following fig will appear
-
8/16/2019 Robotic Arm Control Using Pc
21/29
=. &ave the Project by typing suitable project name with no e"tension in u r own
folder sited in either C/U or )/U
A. Then Clic# on save button above.
1. &elect the component for u r project. $.e. PhilipsVV
2. Clic# on the M &ymbol beside of Philips.
8. &elect !T28&=+ as shown below
+
-
8/16/2019 Robotic Arm Control Using Pc
22/29
9. Then Clic# on W>X
. The 7ollowing fig will appear
+. Then Clic# either K%& or IVVVmostly WIX.
-
8/16/2019 Robotic Arm Control Using Pc
23/29
=. Clic# on the file option from menu bar and select WnewX.
A. The ne"t screen will be as shown in ne"t page, and just ma"imize it by double
clic#ing on its blue boarder.
1. Iow start writing program in either in WCX or W!&X.
2. 7or a program written in !ssembly, then save it with e"tension W. asmX and
for WCX based program save it with e"tension W .CX
8. Iow right clic# on &ource group and clic# on W!dd files to roup &ourceX
+9.
+
-
8/16/2019 Robotic Arm Control Using Pc
24/29
+. Iow you will get another window, on which by default WCX files will appear.
++. Iow select as per your file e"tension given while saving the file
+X
+F
-
8/16/2019 Robotic Arm Control Using Pc
25/29
+2. Iow Clic# on the Peripherals from menu bar, and chec# your re'uired port as
shown in fig below
+8. )rag the port a side and clic# in the program file.
-
8/16/2019 Robotic Arm Control Using Pc
26/29
8. RESULT
INPUT) !ny #eyword from PC (personal Computer*
OUTPUT) The motors will rotate left and then with another #eyword it will rotateright.
+A
-
8/16/2019 Robotic Arm Control Using Pc
27/29
9. CONCLUSION
The project W3T ! CIT0 @&$I PCX has been successfully
designed and tested.
$t has been developed by integrating features of all the hardware components
used. Presence of every module has been reasoned out and placed carefully thus
contributing to the best wor#ing of the unit.
&econdly, using highly advanced $C?s and with the help of growing technology
the project has been successfully implemented.
+1
-
8/16/2019 Robotic Arm Control Using Pc
28/29
1*. BIBLIOGRAPenneth 4.!yala
7undamentals of icro processors and icro computers
-3.am
icro processor !rchitecture, Programming
Y !pplications
-amesh &.aon#ar
%lectronic Components
-).G.Prasad
6ireless Communications - Theodore &. appaport
obile Tele Communications- 6illiam C.K. 0ee
Reere$%e '$ te -e4)
www.national.comwww.n"p.com
www.29=+.com
+2
http://www.national.com/http://www.nxp.com/http://www.8052.com/http://www.national.com/http://www.nxp.com/http://www.8052.com/
-
8/16/2019 Robotic Arm Control Using Pc
29/29
www.microsoftsearch.com
www.geocities.com
http://www.microsoftsearch.com/http://www.geocities.com/http://www.microsoftsearch.com/http://www.geocities.com/