Search for notes by fellow students, in your own course and all over the country.

Browse our notes for titles which look like what you need, you can preview any of the notes via a sample of the contents. After you're happy these are the notes you're after simply pop them into your shopping cart.

My Basket

You have nothing in your shopping cart yet.

Title: Microcontroller lab manual
Description: The entire set of experiments using microcontroller

Document Preview

Extracts from the notes are below, to see the PDF you'll receive please use the links above


MICROCONTROLLER & EMBEDDED SYSTEM
Manual

CONTENTS
S
...
NO

1

FAMILIARIZATION OF 8051 MC

AIM: To familiarize the 8051MC Trainer Kit & Simulation software
...
Follow these steps to
simulate a program in Keil:
• Open Notepad and Save the default open file with the extension “*
...


• Close any existing project by clicking on:
o Project
o Close Project

• Click again on:
o Project
o New Project
o Save it with a proper name

o

Select “Atmel”

o

Click on “AT89C51”

o

Click “No” on the following Dialog box

• Click on “Target 1”
• Right Click on “Source Group 1”
• Click on “Add Files to Group “Source Group 1”

• Now locate the “ASM” file and click on Add

• Double Click the ASM file and start adding the code

• After completing the code, click on “Build Target” from “Debug” Menu or press F7
...


SIMULATION SOFTWARE PROCEDURE:

Keil Micro vision 2 is programming and simulation software for Microcontroller
...
asm”
• Now open the Keil uvision 2
...

• If there is no “Warning or Error”
• From Debug menu click on “Start/Stop Debug Session” or press“CTRL+F5”
• Now run the project either Step by Step by pressing F11 or at once by pressing F5
• Stop the Debug Session
• Save the Project and Exit
...


EX
...
0
LO:

RR A

D2E0
03

Rotate right
P0 ← A

001E

MOV P0,A

F580

0020

DJNZ R0,LO

D8FB

0022

MOV R1,#0X07

7907

R1 ← #0X07

23

Rotate Left
P0 ← A

0024

LO1:

RL A

0025

MOV P0,A

F580

0027

DJNZ R1,LO1

D9FB

0029

SJMP $

80D5

RESULT:
BEFORE EXECUTION
40H
FF
41h
FF
51H
0x00
52H
0x00
53H
0x00

AFTER EXECUTION
40H
FF
41h
FF
51H
0xFF
52H
0Xff
53H
0x00

HLT

EX
...
NO

4

WRITE A PROGRAM TO GENERATE SQUARE WAVEFORMS AND EXECUTE

AIM: Write a program to generate square waveforms and execute
EQUIPMENTS REQUIREMENT:

ALGORITHM:











Or

8051 MC Trainer Kit
CPU With Keil Simulation

Make off state
Transfer the data to port
Call delay
Make on state
...
NO

4

AIM :

WRITE A PROGRAM TO GENERATE TRIANGULAR WAVEFORMS AND EXECUTE

Write a program to generate triangular waveforms and execute

EQUIPMENTS REQUIREMENT:
 8051 MC Trainer Kit
 CPU With MPLABS Simulation

Or

ALGORITHM:








Make off state
Transfer the data to port
Call delay
Make on state
...
NO

4

WRITE A PROGRAM TO GENERATE A STAIRCASE WAVEFORMS AND EXECUTE

AIM: write a program to generate staircase waveforms and execute
EQUIPMENTS REQUIREMENT:



Or

8051 MC Trainer Kit
& PIC 16F887A Trainer Kit
CPU With Keil Simulation

ALGORITHM:








Make off state
Transfer the data to port
Call delay
Make on state
...
NO

WRITE A PROGRAM FOR 16 BIT ADDITION USING PIC MICROCONTROLLER

5

AIM: Write a program for 16bit addition using PIC microcontroller
...
NO

6

WRITE A PROGRAM FOR 16BIT SUBSTRACTION USING PIC MICROCONTROLLERS

AIM: Write a program for 16bit subtraction using pic microcontrollers
...
NO

0x05
0x02

WRITE A PROGRAM FOR LED INTERFACING

7

AIM: Write a program for LED interfacing

EQUIPMENTS REQUIREMENT:



8051 MC Trainer Kit
& PIC 16F887A Trainer Kit
CPU With Keil Simulation

ALGORITHM:
 Load the data to acc





Transfer the acc content to Port 0
Complement the data & transfer the data to port 0
Repeat the execution
Halt the program

PROGRAM:

ADDRESS

LABEL

MNEMONICS

OPCODE

COMMENT

0000

BACK

BACK:CPL A

F4

Cpl a

0001

MOV P1,A

F590

A to p1

0003

ACALL DELAY

1107

delay

0005

SJMP BACK

80F9

Repeat the process

0007

DELAY

MOV R0,#03H

7803

I:#03h to R0

0009

IN1:

MOV R1,#00H

7900

I:#00h to R1

000B

IN2:

MOV R2,#00H

7A00

I:#00h to R2

000D

DJNZ R2,WAIT

DAFE

000F

DJNZ R1,IN2

D9FA

0011

DJNZ R0,IN1

D8F6

RET

22

0013

WAIT

STOP

INTERFACING DIAGRAM:

RESULT:
Interfacing LED with Microcontroller as per data LED will be blinking
...
NO

7

WRITE A PROGRAM TO INTERFACE SEVEN SEGMENT DISPLAY

AIM: Write a program to interface seven segment display
...


EX
...
To make sure that the preceding key has been released, 0s are output to all rows at once, and the
columns are read and checked repeatedly until all the columns are high
When all columns are found to be high, the program waits for a short amount of time before it goes
to the next stage of waiting for a key to be pressed
...
To see if any key is pressed, the columns are scanned over and over in an infinite loop until one of
them has a 0 on it
Remember that the output latches connected to rows still have their initial zeros (provided in stage
1), making them grounded
After the key press detection, it waits 20 ms for the bounce and then scans the columns again
(a) It ensures that the first key press detection was not an erroneous one due a spike noise
(b) The key press
...
To detect which row key press belongs to, it grounds one row at a time, reading the columns each
time
If it finds that all columns are high, this means that the key press cannot belong to that row
– Therefore, it grounds the next row and continues until it finds the row the key press belongs to

Upon finding the row that the key press belongs to, it sets up the starting address for the look-up
table holding the scan codes (or ASCII) for that row
4
...


EX
...
NO

10

LCD Interface

AIM: To write program & execute LCD interfacing operation

EQUIPMENTS REQUIREMENT:
 8051 MC Trainer Kit
 LCD interfacing module
 CPU With Keil Simulation
ALGORITHM:


Initialized the input comments



Load the inputs



Get the data from MC for display



Repeat the process



Halt the program

Or

PROGRAM:
ADDRESS
0000
0003
0005
0007
0009
000B
000D
000F
0011
0013
0015
0017
0019
001B
001D
001F
0021
0023
0025
0027
0029
002B
002D

LABEL

AGAIN:
COMNWRT:

MNUEMONICS

ORG
MOV A,#38H
ACALL COMNWRT
ACALL DELAY
MOV A,#0EH
ACALL COMNWRT
ACALL DELAY
MOV A,#01
ACALL COMNWRT
ACALL DELAY
MOV A,#06H
ACALL COMNWRT
ACALL DELAY
MOV A,#84H
ACALL COMNWRT
ACALL DELAY
MOV A,#’N’
ACALL DATAWRT
ACALL DELAY
MOV A,#’O’
ACALL DATAWRT
SJMP AGAIN

OPCODE
000000
7438
112D
1143
740E
112D
1143
7401
112D
1143
7406
112D
1143
7484
1100
1143
7400
1138
1143
7400
1138
80FE

COMMENT

002D
002F
0031
0033
0035
0037
0038
0038

MOV P1,A
CLR P2
...
2
CLR P2
...
0

003C
003E
0040
0042
0043
0045
0047
0049
004B
004C

CLR P2
...
2
CLR P2
Title: Microcontroller lab manual
Description: The entire set of experiments using microcontroller