01 EE6612 MPMC Lab Manual

Download as pdf or txt
Download as pdf or txt
You are on page 1of 110

Vision

Will strive continuously in pursuit of creativity, innovations and ethics in the field of Electrical and Electronics
Engineering to blossom into Centre of Excellence.

Mission
• To impart total quality education through broader exposure, value additions and effective teaching
learning process.

• To mould students to meet professional challenges and to become outstanding Engineers and
Technocrats.

• To pursue research in the field of Electrical and Electronics Engineering to serve the needs of the
industry, scientific community and society.

Program Educational Objectives (PEOs)

The Program Educational Objectives (PEOs) of Electrical and Electronics Engineering (EEE) represent major
accomplishments that the graduates are expected to achieve after three to five years of graduation.
The Graduates of Electrical and Electronics Engineering will
PEO1: Impart strong foundation in electrical engineering concepts and encourage application of
academic learning to solve real time engineering problems.
PEO2: Inculcate professional ethics & effective communication skills and create an ability to
address societal issues by leveraging one’s engineering knowledge.
PEO3: Develop technical skills through hands on experience and provide exposure to industrial
practices.
PEO4: Provide an academic environment to cultivate multidisciplinary approach, encourage
continuous learning for effective leadership to flourish.

Program Specific Outcome(PSOs)

Graduates of Electrical and Electronics Engineering will be able to

PSO1: Create awareness & provide solution for Energy Security and Environmental Concern in the
area of Renewable Energy to meet out the Country’s Energy demand.

PSO2: Apply the knowledge of academic learning’s to solve real life Engineering problems and find
solutions for contemporary issues faced by society at large.
PROGRAM OUTCOMES(POs)

1. Engineering knowledge: Apply the knowledge of mathematics, science, engineering fundamentals, and an
engineering specialization to the solution of complex engineering problems.
2. Problem analysis: Identify, formulate, review research literature, and analyze complex engineering
problems reaching substantiated conclusions using first principles of mathematics, natural sciences, and
engineering sciences.
3. Design/development of solutions: Design solutions for complex engineering problems and design system
components or processes that meet the specified needs with appropriate consideration for the public health and
safety, and the cultural, societal, and environmental considerations.
4. Conduct investigations of complex problems: Use research-based knowledge and research methods
including design of experiments, analysis and interpretation of data, and synthesis of the information to
provide valid conclusions.
5. Modern tool usage: Create, select, and apply appropriate techniques, resources, and modern engineering
and IT tools including prediction and modeling to complex engineering activities with an understanding of the
limitations.
6. The engineer and society: Apply reasoning informed by the contextual knowledge to assess societal,
health, safety, legal and cultural issues and the consequent responsibilities relevant to the professional
engineering practice.
7. Environment and sustainability: Understand the impact of the professional engineering solutions in
societal and environmental contexts, and demonstrate the knowledge of, and need for sustainable development.
8. Ethics: Apply ethical principles and commit to professional ethics and responsibilities and norms of the
engineering practice.
9. Individual and team work: Function effectively as an individual, and as a member or leader in diverse
teams, and in multidisciplinary settings.
10. Communication: Communicate effectively on complex engineering activities with the engineering
community and with society at large, such as, being able to comprehend and write effective reports and design
documentation, make effective presentations, and give and receive clear instructions.
11. Project management and finance: Demonstrate knowledge and understanding of the engineering and
management principles and apply these to one’s own work, as a member and leader in a team, to manage
projects and in multidisciplinary environments.
12. Life-long learning: Recognize the need for, and have the preparation and ability to engage in independent
and life-long learning in the broadest context of technological change.
Program Specific Outcomes(PSOs)

1. Comprehend and demonstrate the principles and concepts of Semiconductor theory, Signal
Processing & Embedded systems in the fields of Consumer Electronics, Medical Electronics and
Defense Electronics.

2. Analyze and design modules and systems for applications including Signal Processing,
Communication, Networking and RF & Microwave Engineering.
SYLLABUS

EE6612 MICROPROCESSORS AND MICROCONTROLLERS LABORATORY


LT P C
0032
OBJECTIVES:
To provide training on programming of microprocessors and microcontrollers and understand
the interface requirements.

LIST OF EXPERIMENTS:
1. Simple arithmetic operations: addition / subtraction / multiplication / division.
2. Programming with control instructions:
(i) Ascending / Descending order, Maximum / Minimum of numbers
(ii) Programs using Rotate instructions
(iii) Hex / ASCII / BCD code conversions.
3. Interface Experiments: with 8085
(i) A/D Interfacing. & D/A Interfacing.
4. Traffic light controller.
5. I/O Port / Serial communication
6. Programming Practices with Simulators/Emulators/open source
7. Read a key ,interface display
8. Demonstration of basic instructions with 8051 Micro controller execution, including:
(i) Conditional jumps, looping
(ii) Calling Subroutines
9.Programming I/O Port 8051
(i) Study on interface with A/D & D/A
(ii) Study on interface with DC & AC motor .
10. Mini project development with processors.

TOTAL: 45 PERIODS
COURSE OUTCOMES

C317 SUBJECT CODE:EE6612 SUBJECT TITLE:MICROPROCESSOR AND


MICROCONTROLLER LABORATORY
Apply the basic arithmetic and logical operations using 8085 microprocessor with the help of
C317.1
assembly language programming.
Analyze the performance of different weighted and non weighted codes, its conversions with logic
C317.2
diagram using 8085 microprocessor.
Illustrate the interfacing of 8085 with various peripheral devices for serial and parallel
C317.3
communication of data.
Demonstrate the basic instructions with 8051 microcontroller execution including conditional jumps,
C317.4
looping and calling subroutines.
Make use of the basic conversion techniques of ADC and DAC to interface it with 8085 processor
C317.5
and 8051 microcontroller.
Develop a model using processor to understand and apply computing platform and software for
C317.6
engineering problems.

CO-PO mapping
C317-EE6612:MICROPROCESSOR AND MICROCONTROLLER LABORATORY
COs PO PO PO PO PO PO PO PO PO PO PO PO PSO PSO
1 2 3 4 5 6 7 8 9 10 11 12 1 2
C317.1 3 2 2 2 2 1 - 2 2 2 2 2 2 2
C317.2 3 2 2 2 2 1 - 2 2 2 2 2 2 2
C317.3 2 2 2 2 2 1 - 2 2 2 2 2 2 2
C317.4 3 2 2 2 2 1 - 2 2 2 2 2 2 2
C317.5 3 2 2 2 2 1 - 2 2 2 2 2 2 2
C317.6 3 2 2 2 2 1 - 2 2 2 2 2 2 2
INDEX
S.NO DATE EXPERIMENT NAME PAGE MARK SIGN
PROGRAMMNING WITH 8085
8 BIT ARITHMETIC OPERATION
a) ADDITION
b) SUBTRACTION
c) MULTIPLICATION
d) DIVISION
16 BIT ARITHMETIC OPERATION
a) ADDITION
b) SUBTRACTION
c) MULTIPLICATION
d) DIVISION
SORTING AND SEARCHING OPERATION USING 8085
a) ASCENDING /DESCENDING ORDER
b) MAXIMUM AND MINIMUM OF AN ARRAY

CODE CONVERSION
a) HEX TO ASCII
b) ASCII TO HEX
c) BCD TO HEX
d) HEX TO BCD

INTERFACING 8255 WITH 8085

INTERFACING KEYBOARD DISPLAY WITH 8085

INTERFACING DAC WITH 8085

TRAFFIC LIGHT CONTROLLER WITH 8085

SERIAL COMMUNICATION USING 8085

PROGRAMMING WITH 8085 SIMULATOR


S.NO DATE EXPERIMENT NAME PAGE MARK SIGN

PROGRAMMING WITH 8051

8051 ARITHMETIC OPERATION AND LOGICAL


OPERATION
a) ADDITION
. b) SUBTRACTION
c) MULTIPLICATION
d) DIVISION
e) LOGICAL OPERATION

INTERFACING DAC WITH 8051

INTERFACING STEPPER MOTOR WITH 8051

FIBONACCI SERIES (CBS)


8 BIT ARITHMETIC OPERATION

EXNO: ADDITION OF TWO 8-BIT NUMBERS


DATE:

AIM:

To write an assembly language program for adding two 8 bit numbers by using 8085
microprocessor kit.

APPARATUS REQUIRED:
8085 microprocessor kit
Power Supply
ALGORITHM:

1) Start

2) One data is loaded in accumulator and content of accumulator is moved to register B.

3) The second data is loaded in accumulator.

4) Initialize C register with 00H.

5) The content of register B is added with the content of accumulator.

6) A conditional jump instruction is used. If no carry occurs, the result is stored in any address.

If carry occurs, the content of C register is incremented by 1.

7) Content of C register is moved to accumulator and stored in any address.

8) Stop.
FLOWCHART:

INPUT OUTPUT
ADDRESS DATA ADDRESS DATA

MANUAL CALCULATION:
PROGRAM
8 BIT ADDITION
OPCODE
LABEL ADDRESS MNEMONICS COMMENTS
B1 B2 B3
EX NO: SUBTRACTION OF TWO 8-BIT NUMBERS

AIM:

To write a assembly language program for subtracting two 8 bit numbers by using- 8085
microprocessor kit.

APPARATUS REQUIRED:

8085 microprocessor kit


Power Supply
ALGORITHM:

1) Start

2) One data is loaded in accumulator and content of accumulator is moved to register B.

3) The second data is loaded in accumulator.

4) Initialize C register with 00H.

5) The content of register B is subtracted from the content of accumulator.

6) A conditional jump instruction is used. If no carry occurs, the result is stored in any address.

If carry occurs, the content of C register is incremented by 1.

7) Content of C register is moved to accumulator and stored in any address.

8) Stop.
FLOWCHART:

INPUT OUTPUT
ADDRESS DATA ADDRESS DATA

MANUAL CALCULATION:
PROGRAM
8 BIT SUBTRACTION
OPCODE
LABEL ADDRESS MNEMONICS COMMENTS
B1 B2 B3
EXNO: MULTIPLICATION OF TWO 8-BIT NUMBERS
:

AIM:

To write an assembly language program for multiplication of two 8 bit numbers by using-
8085 microprocessor kit.

APPARATUS REQUIRED:

8085 microprocessor kit


Power Supply
ALGORITHM:

1) Start

2) Load the two data’s in B and D register.

3) Clear the accumulator and C register.

4) Add the content of B register with accumulator.

5) If carry occurs, C register content is incremented by 1.

6) Decrement D register content & check for zero flag. If no zero occurs, go to step 4.

7) Otherwise store the accumulator & C register content in separate memory

locations.

8) Stop
FLOWCHART

INPUT OUTPUT
ADDRESS DATA ADDRESS DATA

MANUAL CALCULATION:
PROGRAM
8 BIT MULTIPLICATION USING 8085
OPCODE
LABEL ADDRESS MNEMONICS COMMENTS
B1 B2 B3
EX NO: DIVISION OF TWO 8-BIT NUMBERS

AIM:

To write an assembly language program for division of two 8 bit numbers by using- 8085
microprocessor kit.

APPARATUS REQUIRED:

8085 microprocessor kit


Power Supply
ALGORITHM:
1. Load the dividend in accumulator & divisor in B register.

2. Clear C register content.

3. Compare accumulator & B register content.

4. If carry occurs, go to step 8.

5. Subtract B register value from Accumulator.

6. Increment C register value (Quotient).

7. GO to step 3.

8. Store the accumulator & C register value in separate memory

locations.

9. Stop.
FLOW CHART:
8 BIT DIVISION

INPUT OUTPUT
ADDRESS DATA ADDRESS DATA

MANUAL CALCULATION:
PROGRAM

8 BIT DIVISION USING 8085


OPCODE
LABEL ADDRESS MNEMONICS COMMENTS
B1 B2 B3

Result:
16 BIT ARITHMETIC OPERATION

EXNO: ADDITION OF TWO 16-BIT NUMBERS


DATE:

AIM:

To write an assembly language program for addition of two 16 bit numbers by using- 8085
microprocessor kit.

APPARATUS REQUIRED:

8085 microprocessor kit


Power Supply
ALGORITHM:
1) Load the first data in HL register pair

2) Exchange the content of HL register pair with DE register pair

3) Load the second data in DE register pair

4) Add the content of DE and HL register pair and the result will be in HL register pair

5) If the result has the carry, increment the carry register by one else store the content of HL

register in two consecutive memory locations

6) Move the content of carry register to accumulator content is stored in next memory

location

7) End of the program


FLOW CHART:
16 BIT ADDITION

INPUT OUTPUT
ADDRESS DATA ADDRESS DATA

MANUAL CALCULATION:
PROGRAM

16 BIT ADDITION
OPCODE
LABEL ADDRESS MNEMONICS COMMENTS
B1 B2 B3
EX NO: SUBTRACTION OF TWO 16-BIT NUMBERS

AIM:

To write an assembly language program for subtraction of two 16 bit numbers by using- 8085
microprocessor kit.

APPARATUS REQUIRED:

8085 microprocessor kit


Power Suppl y
ALGORITHM:
1) Load the first data in HL register pair

2) Exchange the content of HL register pair with DE register pair

3) Load the second data in DE register pair

4) Subtract the content of two lower order registers and then the higher order

registers

5) Check for borrow, if there is a borrow, increment the content of borrow register

6) Store the result and borrow in successive memory location

7) End of the program


FLOW CHART:
16 BIT SUBTRACTION

INPUT OUTPUT
ADDRESS DATA ADDRESS DATA

MANUAL CALCULATION:
PROGRAM

I6 BIT SUBTRACTION
OPCODE
LABEL ADDRESS MNEMONICS COMMENTS
B1 B2 B3
EX NO: MULTIPLICATION OF TWO 16-BIT NUMBERS

AIM:

To write an assembly language program for multiplication of two 16 bit numbers by using-
8085 microprocessor kit.

APPARATUS REQUIRED:

8085 microprocessor kit


Power Supply
ALGORITHM:
1) Load the two 16 bit data’s in BC and SP register pair.

2) Clear HL and DE register pair.

3) Add HL and SP register pair value.

4) If carry occurs, increment DE register pair value.

5) Otherwise, decrement BC register pair value & check for zero flag.

6) If no zero occurs, go to step 3.

7) If zero occurs, store the HL & DE register pair value in separate memory locations.

8) Stop.
FLOW CHART:
16 BIT MULTIPLICATION

INPUT OUTPUT
ADDRESS DATA ADDRESS DATA

MANUAL CALCULATION:
PROGRAM

16 BIT MULTIPLICATION
OPCODE
LABEL ADDRESS MNEMONICS COMMENTS
B1 B2 B3
EX NO: DIVISION OF TWO 16-BIT NUMBERS

AIM:

To write an assembly language program for division of two 16 bit numbers by using- 8085
microprocessor kit.

APPARATUS REQUIRED:

8085 microprocessor kit


Power Supply
ALGORITHM:
1) Load the dividend in one register and divisor in another register pair

2) Initialize DE register pair for quotient

3) Check whether division is possible. Compare the two data, if there is no carry

subtraction is performed and remaining value is stored in one register pair

4) If there is a carry, quotient will be zero and remainder will be dividend

5) For each subtraction increment the content of quotient register pait

6) The quotient and remainder are stored in successive memory locations

7) End of the program


FLOW CHART:
16 BIT DIVISION

INPUT OUTPUT
ADDRESS DATA ADDRESS DATA

MANUAL CALCULATION:
PROGRAM

I6 BIT DIVISION
OPCODE
LABEL ADDRESS MNEMONICS COMMENTS
B1 B2 B3

Result:
SORTING AND SEARCHING OPERATION USING 8085

EXNO: ASCENDING / DESCENDING


DATE:

AIM:

To write an assembly language program to sort an array of data in ascending order and
descending order

APPARATUS REQUIRED:

8085 microprocessor kit


Power Supply
ALGORITHM:

ASCENDING ORDER
1. Get the desired number of data using HL register pair
2. Initialize number of interactions and number of computations.
3. Compare the first two values in HL.
4. If carry exists, go to decrement the number of computations.
5. Move the value in A to M and decrement H.
6. .Move the value in B to M and decrement H.
7. Perform this operation until the number of data becomes zero.

DESCENDING ORDER

1. Get the number of data using HL register pair


2. Initialize the number of iterations and computations
3. Perform comparison of two numbers and if carry exists get out of the loop.
4. Perform descending order operation by rearranging the data.
5. Perform this process until the number of data reduced to zero.
FLOWCHART: ASCENDING

ORDER

INPUT OUTPUT
ADDRESS DATA ADDRESS DATA

MANUAL CALCULATION:
PROGRAM
ASCENDING ORDER
OPCODE
LABEL ADDRESS MNEMONICS COMMENTS
B1 B2 B3
FLOWCHART:

DESCENDING ORDER:

INPUT OUTPUT
ADDRESS DATA ADDRESS DATA

MANUAL CALCULATION:
EX NO: MAXIMUM AND MINIMUM NUMBER IN AN ARRAY

AIM
To write an assembly language program to search the smallest and largest data in an
array

APPARATUS REQUIRED
8085 microprocessor kit
+5 v power supply

ALGORITHM:
SMALLEST NUMBER IN AN ARRAY

1. Get the desired number of data using HL pair.


2. The first location specifies number of data in array.
3. Compare the accumulator data with memory.
4. If carry exists, decrement the B register.
5. Repeat until it becomes zero.
6. Store the result.

LARGEST NUMBER IN AN ARRAY

1. Get the desired number of data using HL pair.


2. The first location specifies number of data in array.
3. Compare the accumulator data with memory.
4. If carry does not exists, decrement the B register.
5. Repeat until it becomes zero.
6. Store the result.
FLOWCHART: MINIMUM NUMBER IN AN ARRAY

INPUT OUTPUT
ADDRESS DATA ADDRESS DATA

MANUAL CALCULATION
PROGRAM

MINIMUM OF AN ARRAY
OPCODE
LABEL ADDRESS MNEMONICS COMMENTS
B1 B2 B3
FLOWCHART: MAXIMUM NUMBER IN AN ARRAY

INPUT OUTPUT
ADDRESS DATA ADDRESS DATA

MANUAL CALCULATION:
PROGRAM

MAXIMUM OF AN ARRAY
OPCODE
LABEL ADDRESS MNEMONICS COMMENTS
B1 B2 B3

RESULT:
EXNO: CODE CONVERSION
DATE:

AIM:

To write an assembly language program to perform following convert HEX code to ASCII
code

APPARATUS REQUIRED:

8085 microprocessor kit


Power Supply
ALGORITHM:
ASCII TO HEXADECIMAL CONVERSION
1) Transfer the data to A register
2) Clear the carry flag
3) Subtract 30H from accumulator
4) If the result is less than 0AH , store the result in the address given by DPTR
5) Else subtract 07H ,store the result in the address given by DPTR
6) Long jump to memory location

HEXADECIMAL TO ASCII CONVERSION


1) Transfer the data to A register
2) If the DATA is less than 0AH, add 30H.
3) Else add 37H to the data
4) Store the result in the address given by DPTR
5) Long jump to memory location

BCD TO HEX
1) Get BCD number as input
2) Get unit place, tens place of BCD to perform AND ing with 0F and F0 respectively
3) Rotate tens place digit 4 times using RRC
4) Multiply rotate data with 0A
5) Add unit place data with product
6) Store result
HEX TO BCD
1) Get data in accumulator, initialize register to store number in tens and hundreds
2) Compare accumulator with 64 H ; If no carry , subtract 64 H and increment hundred register
repeat step 2
3) Compare ACC with 0A H; if no carry subtract 0A H from acc and increment tens register
repeat step 3
4) Store the result
5) stop
FLOW CHART:

HEX TO ASCII

NPUT OUTPUT
ADDRESS DATA ADDRESS DATA

MANUAL CALCULATION:
HEX TO ASCII
OPCODE
LABEL ADDRESS MNEMONICS COMMENTS
B1 B2 B3
FLOW CHART: ASCII TO HEX

NPUT OUTPUT
ADDRESS DATA ADDRESS DATA

MANUAL CALCULATION:
Program

ASCII TO HEX
OPCODE
LABEL ADDRESS MNEMONICS COMMENTS
B1 B2 B3
FLOW CHART: BCD TO HEX

INPUT OUTPUT
ADDRESS DATA ADDRESS DATA

MANUAL CALCULATION:
PROGRAM

BCD TO HEX

LABEL OPCODE
ADDRESS MNEMONICS COMMENTS
B1 B2 B3
FLOW CHART: HEX TO BCD

INPUT OUTPUT
ADDRESS DATA ADDRESS DATA

MANUAL CALCULATION:
PROGRAM
HEX TO BCD
OPCODE
LABEL ADDRESS MNEMONICS COMMENTS
B1 B2 B3

RESULT:
Ex. No: INTERFACING 8255 WITH 8085
DATE:

AIM:

To write an assembly language program to interfacing 8255 with 8085 microprocessor to


operate in I/O mode and BSR mode

APPARATUS REQUIRED:

8085 microprocessor kit


Power Supply
8255 kit Interfacing cable

FLOW CHART:
I/O MODE PORT A AS INPUT – MODE 0

COMMAND WORD:
PORT A AS INPUT PORT – MODE 0

I/O MA MA PA PCU MB PB PCL


90 H 1 0 0 1 x x x x

INPUT:

OUTPUT:
PROGRAM:
8255 – PORT ‘A’ AS INPUT PORT – I/O MODE
OPCODE
LABEL ADDRESS MNEMONICS COMMENTS
FLOW CHART:
BSR MODE: PC5 SHOULD ON AND AFTER SOMETIME IT SHOULD TURN OFF

COMMAND WORD: SET PC5

I/O MA MA PA PCU MB PB PCL


0B H

0 X X X 1 0 1 1

RESET PC5

I/O MA MA PA PCU MB PB PCL


0A H 0 X X X 1 0 1 0
BSR MODE – PC5 SHOULD ON AND AFTER SOMETIME IT TURN OFF
OPCODE
LABEL ADDRESS MNEMONICS COMMENTS

RESULT:
EXNO: INTERFACING 8279 WITH 8085
DATE:

AIM:

To write an assembly language program to perform rolling display. To write


ALP to perform scan a hex key and display it.

APPARATUS REQUIRED:

8085 microprocessor kit


Power Supply
8279 kit Interfacing cable

FLOW CHART:

7 SEGMENT DISPLAY
Letter d c b a dp g f e data
H 0 1 1 0 0 1 1 1 67 H
A 0 1 1 1 0 1 1 1 77 H
1 0 1 1 0 0 0 0 0 60 H
C 1 0 0 1 0 0 1 1 93 H
E 1 0 0 1 0 1 1 1 97 H
COMMAND WORD KEY BOARD
DISPLAY

0 0 0 D D K K K
00 H 0 0 0 0 0 0 0 0

DD - DISPLAY MODE
00 8 8 BIT CHARACTER DISPLAY – LEFT ENTRY
01 16 8 BIT CHARACTER DISPLAY – LEFT ENTRY
10 8 8 BIT CHARACTER DISPLAY – RIGHT ENTRY
11 16 8 BIT CHARACTER DISPLAY – RIGHT ENTRY
KKK – KEYBOARD MODE
1 – ENCODED SCAN KEYBOARD – 2 KEY LOCKOUT
2 – DECODED SCAN KEYBOARD – 2 KEY LOCK OUT
10 – ENCODED SCAN KEYBOARD – N KEY ROLL OVER
11 – DECODED SCAN KEYBOARD – N KEY ROLL OVER
100 – ENCODED SCAN SENSOR MATRIX
101 – DECODED SCAN SENSOR MATRIX
110 – STROBED INPUT. ENCODED DISPLAY SCAN
111 – STROBED INPUT. DECODED DISPLAY SCAN

READ FIFO

40 H
0 1 0 A1 X A A A

X – DON’T CARE
A1 – AUTO INCREMENT FLAG AAA – RAM

ADDR BIT WRITE DISPLAY RAM

90 H

1 0 0 1 0 0 0 0
READ A KEY AND DISPLAY IT
CMD_PORT EQU 81 H
DATA_PORT EQU 80 H
OPCODE
LABEL ADDRESS MNEMONICS COMMENTS
RESULT:
INTERFACING DAC- WAVEFORM GENERATION WITH 8085

EX NO:
DATE:

AIM:

To write an assembly language program to generate saw tooth wave, triangular wave, and
square wave using 8085 microprocessor

APPARATUS REQUIRED:

8085 microprocessor kit Power supply


DAC kit Connecting cable
CRO & CRO probe
FLOWCHART: Square wave

Model Graph
PROGRAM
Square waveform generation
OPCODE
LABEL ADDRESS MNEMONICS COMMENTS
Triangular

Model Graph
PROGRAM

Triangular waveform generation


OPCODE
LABEL ADDRESS MNEMONICS COMMENTS
SAW TOOTH

Model Graph
PROGRAM

Saw tooth waveform generation


OPCODE
LABEL ADDRESS MNEMONICS COMMENTS

RESULT:
Ex no: Traffic light Controller
Date:

AIM:
To write an ALP to interface traffic light controller with 8085 microprocessor.
APPARATUS REQUIRED:
8085 microprocessor kit, power supply, interfacing cord
FLOWCHART:
PROGRAM

TRAFFIC LIGHT CONTROLLER

OPCODE
LABEL ADDRESS MNEMONICS COMMENTS
B1 B2 B3
Address Data

RESULT
Ex no: Interfacing8251 with 8085
Date:

AIM:

To write an assembly language program to interface 8251 (serial communication) using 8085
microprocessor.

APPARATUS REQUIRED:

8085 microprocessor kits


Power supply
Connecting cables (RS232)
FLOWCHART: Transmitter
8251 Interface- Transmitter
OPCODE
LABEL ADDRESS MNEMONICS COMMENTS
Receiver
Serial communication-Receiver
OPCODE
LABEL ADDRESS MNEMONICS COMMENTS

Address Data Transmitted Data Recieved

RESULT:
Ex No: Programming using 8085 simulator
Date:

Aim:
To have introduction in programming skills using 8085 simulator
Apparatus required:
PC, 8085 simulator
Procedure:
1. Click on the 8085 simulator icon
2. In the editor window , type the assembler program .
3. Then press the ASSEMBLE button. Simulator assembles the program and opcode along with
addresses are generated.
4. Then press RUN ALL AT A TIME button to perform complete execution of program
5. Else press STEP BY STEP and FORWARD to perform single step execution .
6. The outputs can be viewed in memory space. If I/O ports are used view the outputs in IO
space.
7. Then save the file in .asm format
SNAP SHOT of 8085 simulator workspace

Result :
ARITHMETIC & LOGICAL OPERATION USING 8051 MICROCONTROLLER

Ex. No:
Date:

AIM
To perform arithmetic & Logical operations using 8051 microcontroller
APPARATUS REQUIRED
8051 microcontroller Kit, RS-232 cable, power supply, PC FLOWCHART:
Addition:

Start

Initilaize a register for Carry and get the two 8 bit


numbers as input

Add the two 8 bit data

No
If CY==1

Yes

Increment carry register

Store the sum and carry in the address pointed by DPTR


register

Stop

INPUT OUTPUT
Reg/address Data Address Data
ADDITION

OPCODE
LABEL ADDRESS MNEMONICS COMMENTS
B1 B2 B3
Subtraction :

Start

Clear carry bit ,Initialize a register for Carry and get the
two 8 bit numbers as input

Subtract the two 8 bit data

No
If CY==1

Yes

Increment carry register

Store the difference and borrow in the address pointed by


DPTR register

Stop

INPUT OUTPUT
Reg/address Data Address Data
SUBTRACTION

OPCODE
LABEL ADDRESS MNEMONICS COMMENTS
B1 B2 B3
Multiplication/Division:

Start

Get two 8 bit numbers as input in Accumulator and B


register (SFR-F0)

M ultiply / divide two 8 bit data

Store the product / Quotient and remainder in the address


pointed by DPTR

Stop

INPUT OUTPUT
Reg/address Data Address Data

INPUT OUTPUT
Reg/address Data Address Data
MULTIPLICATION / DIVISION

OPCODE
LABEL ADDRESS MNEMONICS COMMENTS
B1 B2 B3
Logical operations:

Start

Get two 8 bit numbers as input in Accumulator and R0


register

AND / OR / XOR two 8 bit data

Store the result in the address pointed by DPTR

Stop

Input and Output table:


INPUT AND OUTPUT
Reg/Address DATA Address DATA

INPUT OR OUTPUT
Reg/Address DATA Address DATA

INPUT XOR OUTPUT


Reg/Address DATA Address DATA
LOGICAL OPERATION

OPCODE
LABEL ADDRESS MNEMONICS COMMENTS
B1 B2 B3

RESULT
INTERFACING DAC - WAVEFORM GENERATION WITH 8051
Microcontroller
Ex. No:
Date:

AIM:

To write an assembly language program to generate saw tooth wave, triangular wave using
8051 microcontroller

APPARATUS REQUIRED:

8051 microcontroller kit Power supply


DAC kit Connecting cable
CRO & CRO probe
FLOWCHART:
Triangular

MODEL GRAPH:
PROGRAM

TRIANGULAR WAVEFORM

OPCODE
LABEL ADDRESS MNEMONICS COMMENTS
B1 B2 B3
SAW TOOTH

MODEL GRAPH:
SAW TOOTH WAVEFORM

OPCODE
LABEL ADDRESS MNEMONICS COMMENTS
B1 B2 B3

RESULT:
INTERFACING STEPPER MOTOR WITH 8051 MICROCONTROLLER

Ex. No:
Date:

AIM:

To write an assembly language program to interface stepper motor with 8051

APPARATUS REQUIRED:

8051 microcontroller kit Power supply


Stepper motor kit Stepper motor
Interfacing wires

FLOWCHART:
SAW TOOTH WAVEFORM

OPCODE
LABEL ADDRESS MNEMONICS COMMENTS
B1 B2 B3

Result
CONTENT BEYOND SYLLABUS
FIBONACCI SERIES USING 8085
DATE:

AIM:

To write an assembly language program to generate Fibonacci series for a given limit using
8085

APPARATUS REQUIRED:

8085 microprocessor kit


Power Supply
ALGORITHM:
1) Initialize source array , destination array and counter
2) Get data from two memory location
3) Increment memory pointer.
4) Get next data from memory
5) Add the data and store in next memory location
6) Decrement the memory pointer and counter
7) If count is not equal to zero then go to step 2
8) Stop
FLOW CHART:

INPUT OUTPUT
ADDRESS DATA ADDRESS DATA

MANUAL CALCULATION:
PROGRAM

FIBONACCI SERIES
OPCODE
LABEL ADDRESS MNEMONICS COMMENTS
B1 B2 B3

RESULT:

You might also like