4 bit microprocessor design using vhdl

Upload: sanjana-mazumder

Post on 23-Feb-2018

246 views

Category:

Documents


0 download

TRANSCRIPT

  • 7/24/2019 4 Bit Microprocessor Design Using Vhdl

    1/46

    A Project Report on

    4 BIT MICROPROCESSOR DESIGN

    USING VHDL

    In partial fullment of the requirement for the award of the degreeofBachelor of Technologyin

    Information TechnologySubmitted by

    Sanjona Mazumder Registration No.: 111001101!0 Roll No.:1000"110!

    #rof. $ajari Sur

    Department of Information TechnologyAcademic Year !""#!"$

    Institute of %ngineering & Management%uru&ul' Y#"' (loc& #)P' Sector#*' Salt +a&e )lectronic, -omple.

    /ol&ata # 0!! !1"' 2e,t (engal' India3

    A4liated to

    'est Bengal (ni)ersity of Technology(5#"6' (idhannagar' Sector# I' /ol&ata#0!!!76' 2e,t (engal' India3

    Page 8 "

  • 7/24/2019 4 Bit Microprocessor Design Using Vhdl

    2/46

    IN*%+

    S.No. To,ic #g.No.

    1. Introduction...............6

    1.1 A brief history.........................6

    1.2 Components of a Microprocessor....8

    1.3 Objecties....................82. Oerie! of Microprocessor..."

    2.1 Microprocessor# A brief oerie!.."

    2.2 $asic e%ements of a Microprocessor11

    2.2.1 Arithmetic &o'ic (nit.11

    2.2.2 )e'ister Array.12

    2.2.3 Contro% (nit... 13

    2.3 More microprocessor sub*components...1+

    2.3.1 Memory...1+

    2.3.2 Input,Output -orts..16

    2.3.3 ystem $us.... 16

    2.3./ Address $us... 162.3.+ 0ata $us.1

    2.3.6 Contro% $us....1

    3. Oerie! of i%in and 450&. ... 18

    3.1 i%in. 18

    3.2 450& 1"

    3.2.1 Adanta'es.2

    3.2.2 $enefits of usin' 450&21

    /. /*bit Microprocessor 0esi'n..2/

    /.1. Introduction2/

    /.2. 7unction of b%ocs of 4M... 2+

    /.2.1 -ro'ram Counter2+/.2.2. -ro'ram memory... 2+

    /.2.3 Accumu%ator...2

    /.2./. )e'ister...... 28

    /.2.+. A&(... 31

    /.3 Instructions 9ab%e.. 3/

    +. )esu%ts and 0iscussion.. 3+

    6. Conc%usion. //

    Page 8

  • 7/24/2019 4 Bit Microprocessor Design Using Vhdl

    3/46

    -$N/'%*%M%NT

    I !ou%d %ie to epress my heartiest 'ratitude to my project superisor

    -rofessor 0r. Mohuya Charaborty and -rof. :ajari ur for their ina%uab%e adices

    and consecutie support !hich made the !ho%e !or possib%e. 9hey tau'ht and

    'uided me on ho! to approach a difficu%t project topic !ith simp%e and neat !ays.

    I !ish to epress my sincere thans to a%% my teachers and my c%assmates for

    proidin' necessary information !heneer re;uired. It is a%so a 'reat p%easure to

    than a%% the members of 0epartment of Information 9echno%o'y< Institute of

    =n'ineerin' and Mana'ement< >est $en'a% (niersity of 9echno%o'y.

    Page 8 9

  • 7/24/2019 4 Bit Microprocessor Design Using Vhdl

    4/46

    -BSTR-T

    9he main objectie of this project is to understand the basic architecture of

    microprocessor by desi'nin' a /*bit microprocessor. Microprocessor is basica%%y an

    e%ectronic deice that consists of arithmetic and %o'ic unit ?A&(@ and contro% circuitry

    !hich are re;uired to function as computers C-(. Microprocessor is an inte'rated

    circuit that interprets and eecutes the pro'ram instructions and behaes inte%%i'ent%y.

    9he processor operates at a speed of the interna% c%oc and the speed of the c%oc

    depends upon the no. of pu%ses per second. >ith each c%oc pu%se< the processor

    performs the function that corresponds to the instruction.

    Page 8 6

  • 7/24/2019 4 Bit Microprocessor Design Using Vhdl

    5/46

    9he po!er of the processor can be ca%cu%ated by no. of instructions eecuted

    per second. 0urin' the eecution of instructions< data are stored temporari%y in

    memory units ca%%ed re'isters. 9he contro% si'na% is the e%ectronic si'na%s used for

    communication amon' arious processor units durin' the eecution of the instruction.

    >ith the adancement in inte'rated circuit techno%o'y the po!er of the processor has

    increased tremendous%y.

    Microprocessors are !ide%y used in the embedded sector based on 'enera%

    purpose app%ication and specia% purpose app%ication. Microprocessors are used in

    instruments to mae it inte%%i'ent usin' behaiora% codin'.

    9he eistin' microprocessors< name%y< Inte% 886,888 and 8186,8286< Bi%o'

    B81,B82< 0i'ita% =;uipment &I 11< Motoro%a 68< nationa% emiconductors

    16 are ery comp%e in desi'n and understandin' the basic functiona%ity is a

    'reat cha%%en'e. In order to understand the basic no!ho! of the microprocessor

    architecture< a simp%ified approach has been adopted by desi'nin' a /*bit

    microprocessor.

    9he soft!are used for desi'nin' and simu%atin' is i%in .1i usin' 450&. A%%

    the sub*circuits are connected to'ether and tested and simu%ated. 450& is a hard!are

    description %an'ua'e. It is a %an'ua'e specifica%%y dee%oped to describe di'ita%

    e%ectronic hard!are and its attributes. It is a f%eib%e %an'ua'e and can be app%ied to

    many different desi'n situations. 0i'ita% circuits captured usin' 450& can be easi%y

    simu%ated are more %ie%y to be synthesiDab%e into mu%tip%e tar'et techno%o'ies and can

    be archied for %ater modification and reuse. 450& is common%y used to !rite tet

    mode%s that describe a %o'ic circuit.

    A sincere effort has been made throu'h this project to understand the

    functionin' of a microprocessor. $y adoptin' this approach< a foundation for bui%din'

    comp%e microprocessors !ith etended instruction set and a more po!erfu%

    Arithmetic &o'ic Circuit in order to bui%d a more attractie and sophisticated

    microprocessor.

    Page 8 $

  • 7/24/2019 4 Bit Microprocessor Design Using Vhdl

    6/46

    2-#T%R 1

    INTR/*(TI/N

    1.1 A brief history

    =ar%y computers !ere made possib%e by the inention of the transistor in 1"/.

    9he transistor transferred information to other transistors oer a net!or of chemica%s

    embedded in si%icon. 9hese connected circuits< or inte'rated circuit< !ere the

    techno%o'y re;uired for the eentua% creation of the microprocessor. As manufacturin'

    techno%o'y eo%ed< more and more transistors cou%d be p%aced on a sin'%e si%icon

    Page 8 7

  • 7/24/2019 4 Bit Microprocessor Design Using Vhdl

    7/46

    !afer< and each transistorEs function ** !hether it !as a simp%e 'ate for informationorp%ace@< an output conso%e ?9ranscript@< and a

    processes tree ?-rocesses@.

    9he 0esi'n hierarchy consists of desi'n fi%es ?modu%es@< !hose dependencies

    are interpreted by the I= and disp%ayed as a tree structure.7or sin'%e*chip desi'ns

    there may be one main modu%e< !ith other modu%es inc%uded by the main modu%ee hae a%ready mentioned that< !e hae

    used 450& for our project. 450& !as first dee%oped in 1"8 at (< to describe

    structure and function of an IC. 9hen it !as adopted and dee%oped by I===.

    450& has main%y four sty%es for codin'#*

    0ataf%o!

    $ehaiora%

    tructura%

    Mied

    3.2.1 A"vantages

    iS 9he ey adanta'e of 450&< !hen used for systems desi'n< is that it a%%o!s the

    behaior of the re;uired system to be described ?mode%%ed@ and erified ?simu%ated@

    before synthesis too%s can trans%ate the desi'n into hard!are.

    Page 8 !

  • 7/24/2019 4 Bit Microprocessor Design Using Vhdl

    21/46

    iiS Another benefit is that 450& a%%o!s the description of a concurrent system.

    450& is a dataf%o! %an'ua'e< un%ie procedura% computin' %an'ua'es such as

    $AIC< C< and assemb%y code< !hich a%% run se;uentia%%y< one instruction at a time.

    iiiS 450& project is mu%tipurpose. $ein' created once< a ca%cu%ation b%oc can be

    used in many other projects. A%so< many formationa% and functiona% b%oc parameters

    can be tuned ?capacity parameters< memory siDe< e%ement base< b%oc composition and

    interconnection structure@.

    iS 450& project is portab%e. $ein' created for one e%ement base< a computin' deice

    project can be ported on another e%ement base< for eamp%e 4&I !ith arious

    techno%o'ies.

    3.2.2 Benefits of +sing -%

    450& is a 'enera%*purpose pro'rammin' %an'ua'e optimiDed for e%ectronic

    circuit desi'n. As such< there are many points in the oera%% desi'n process at !hich

    450& can he%p.

    For "esign specification

    9his is particu%ar%y usefu% for %ar'e projects ino%in' many team members.

    (sin' a top*do!n approach to desi'n< a system desi'ner may define the interface to

    each component in the system< and describe the acceptance re;uirements of those

    components in the form of a hi'h %ee% test bench. 9he interface definition ?typica%%y

    epressed as a 450& entity dec%aration@ and hi'h*%ee% performance specification ?the

    test bench@ can then be passed on to other team members for comp%etion or

    refinement.

    Page 8 "

  • 7/24/2019 4 Bit Microprocessor Design Using Vhdl

    22/46

    For "esign capt+re

    0esi'n capture is that phase in !hich the detai%s of the system are entered

    ?captured@ in a computer*based desi'n system. In this phase< desi'n may be epressed

    as schematics ?either board*%ee% or pure%y functiona%@ or usin' 450& descriptions.

    9he desi'n capture phase may inc%ude too%s and desi'n entry methods other than

    450&. In many cases< desi'n descriptions !ritten in 450& are combined !ith other

    representations< such as schematics< to form the comp%ete system.

    For "esign sim+ation

    Once entered into a computer*based desi'n system< if someone !ant to

    simu%ate the operation of the circuit to find out if it !i%% meet the functiona% and timin'

    re;uirements dee%oped durin' the specification process. If one or more test benches

    are created as a part of the desi'n specification< then a simu%ator is used to app%y the

    test bench to the desi'n as it is !ritten for synthesis ?a functiona% simu%ation@ and

    possib%y usin' the post*synthesis ersion of the desi'n as !e%%.

    For "esign "oc+mentation

    9he structured pro'rammin' features of 450&< coup%ed !ith its confi'uration

    mana'ement features< mae 450& a natura% form in !hich to document a %ar'e and

    comp%e circuit. 9he a%ue of usin' a hi'h*%ee% %an'ua'e such as 450& for desi'n

    documentation is pointed out by the fact that the (.. 0epartment of 0efense no!

    re;uires 450& as the standard format for communicatin' desi'n re;uirements

    bet!een 'oernment subcontractors.

    As an aternative to schematics

    chematics hae %on' been a part of e%ectronic system desi'n< and it is un%ie%y

    that they !i%% become etinct anytime soon. chematics hae their adanta'es