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

MICROPROCESSORS AND

INTERFACING
ECX4236
LAB REPORT 01

NAME

: J.B.S.THYRIAR

REG. NO

: 211088830

GROUP NO

: CLE-04

DATE OF
PERFORMANCE

: 19/12/2014

EXPERIMENT: Study the components of the board AES-51 and experiencing the Assembly
Language using the MCU IDE.

AIMS AND OBJECTIVES

Study the components of the board AES-51


Checking the I/O ports of the board.
Studying the machine cycle and the execution process of the board.
Using AES-51 board with PC.

THEORY

Power Up:
The AES-51 board can be powered up by 7 to 15v AC-DC adaptor or 6v battery.
The AC adaptor output wire should be connected to the AES-51 such that the positive
terminal and negative terminal correspondingly.
Connect 15v AC to the adaptor. And then when the power switch is slide the system on
LED should light up. Then in LCD screen will output a message as AES Basic-52 1.0 system
ready.
Then we run the self-test as below.
- Do the self test
1. First press the test key. Then this will appear.

2. Again press the test key to proceed Test #01. If you want to do the same test
again press any other key except test key. This is the digital output channel test.
Four output LEDs turned on for a few seconds & turn off.

3. Then press the test key to proceed Test #02. Repeat procedure is same as
above for all occasions. After that ground the I1, I2 & I3 by connecting to a
GND using piece of wire respectively and repeat the Test #02. This is the
digital input channel test.

4. Again press the test -key to proceed Test #03. Then connect +5V to the A/D
input and repeat the Test #03. This is the analog I/O block test.

Then connect the +5v to the LED and repeat the test #3. The following will be displayed.

5. Then press the test key to proceed Test #04. This is the serial port test. Since
in this time there are no devices connect to the serial port we cant see any changeof the
display.

6. Finally by pressing the test key again we can end the self test.

7. In each step observe the output.

Enter the machine code programme and execute


1. Power-up the AES-51 board.
2. Enter and execute the machine code programme, according to the book and observe the
outputs.

Run the machine code programme with different memory ranges and observe the
output.

APPARATUS

AES-51 development board


Personal computer with a serial port
Serial connector cable
AC-DC power adapter
Piece of wire

PROCEDURE

1. Study and Identify the components of the board AES-51


2. When it is used in stand-alone mode the following are done.
3. Connect the DC power adapter to the board.
4. Do the self-test by going through the instructions given in the book according to the
theory.
5. Enter and execute the machine code program and check the outputs of accordingly.
6. Thereafter start using the AES-51 board with the PC by connecting via serial port
connector.
7. Connect the AES-51 board and the PC using a serial cable.
8. Power up the PC.
9. Double check whether the ASM.EXE and TX.EXE are available and power up the AES51 board.
10. Follow the instruction set in the theory and check the O/P accordingly.
11. Understand the machine cycles and the assembly language used to execute the
tasks.

OBSERVATIONS
By setting up the configuration which is given in the book we can run the programme and
execute our task.

1) Blinking a single LED


0094

1
2
3
4

P1_4 BIT

094H

ORG 0000H
5 MAIN: CLR P1_4
6
ACALL DELAY
7
SETB P1_4
8
ACALL DELAY
9
SJMP MAIN
10
11
000A 79FF
12 DELAY:MOV R1,#255
000C 7A02
13 LOOP3:MOV R2,#2
000E 7B2B
14 LOOP2:MOV R3,#43
0010 DBFE
15 LOOP1:DJNZ R3,LOOP1
0012 DAFA
16
DJNZ R2,LOOP2
0014 D9F6
17
DJNZ R1,LOOP3
0016 22
18
RET
19
END
ASSEMBLY COMPLETE, NO ERRORS FOUND, NO WARNINGS
0000 C294
0002 110A
0004 D294
0006 110A
0008 80F6

2) Blinking 4 LEDs in PORT 1


0094
0095
0096
0097

7000
7000 C294
7002 C295
7004 C296
7006 C297
7008 1116
700A D294
700C D295
700E D296
7010 D297
7012 1116
7014 80EA

7016 79FF

1 P1_4 BIT 094H


2 P1_5 BIT 095H
3 P1_6 BIT 096H
4 P1_7 BIT 097H
5
6
7
ORG 7000H
8 MAIN: CLR P1_4
9
CLR P1_5
10
CLR P1_6
11
CLR P1_7
12
ACALL DELAY
13
SETB P1_4
14
SETB P1_5
15
SETB P1_6
16
SETB P1_7
17
ACALL DELAY
18
SJMP MAIN
19
20
21 DELAY:MOV R1,#255

7018 7A02
701A 7B2B
701C DBFE
701E DAFA
7020 D9F6
7022 22

22 LOOP3:MOV R2,#2
23 LOOP2:MOV R3,#43
24 LOOP1:DJNZ R3,LOOP1
25 DJNZ R2,LOOP2
26 DJNZ R1,LOOP3
27 RET
28
END

VERSION 1.2h ASSEMBLY COMPLETE, 0 ERRORS FOUND


3) By using the MCU IDE simulating and observing the Seven Segment output for 0 to 9
numbers. The Delay programme is used.

0090
0091
0092
0093
0094
0095
0096
0097

0000 7590C0
0003 1134
0005 7590F9
0008 1134
000A 7590A4
000D 1134
000F 7590B0
0012 1134
0014 759099
0017 1134
0019 759092
001C 1134
001E 759082
0021 1134
0023 7590F8
0026 1134
0028 759080
002B 1134
002D 759098
0030 1134
0032 80CC

1
2
3
4
5
6
7
8
9
10
11

P1_0
P1_1
P1_2
P1_3
P1_4
P1_5
P1_6
P1_7

12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33

BIT
BIT
BIT
BIT
BIT
BIT
BIT
BIT

090H
091H
092H
093H
094H
095H
096H
097H

ORG 0000H
MAIN: MOV P1, #11000000B
ACALL DELAY
MOV P1, #11111001B
ACALL DELAY
MOV P1, #10100100B
ACALL DELAY
MOV P1, #10110000B
ACALL DELAY
MOV P1, #10011001B
ACALL DELAY
MOV P1, #10010010B
ACALL DELAY
MOV P1, #10000010B
ACALL DELAY
MOV P1, #11111000B
ACALL DELAY
MOV P1, #10000000B
ACALL DELAY
MOV P1, #10011000B
ACALL DELAY
SJMP MAIN

34
0034 7905
35 DELAY:MOV R1,#5
0036 7A05
36 LOOP3:MOV R2,#5
0038 7B05
37 LOOP2:MOV R3,#5
003A DBFE
38 LOOP1:DJNZ R3,LOOP1
003C DAFA
39
DJNZ R2,LOOP2
003E D9F6
40
DJNZ R1,LOOP3
0040 22
41
RET
42
END
ASSEMBLY COMPLETE, NO ERRORS FOUND, NO WARNINGS

Discussion

When it comes to microcontrollers it is a single task processor which have memory in them
and have programmable Input/Outut peripherals. Small amount of inbuilt ROM & RAM are
contained as program memory. Analog to Digital convertors and some other features are
there in the chip itself.

Microcontroller hacve some advantages comparing to microprocessors such as, easy to use,
cheap and user friendly. As a drawback they have only limited capacity. Microprocessors are
powerful than microcontrollers but for embedded applications microcontrollers are
commonly used.
When using the board AES-51 we came across so many basic ideas which clearly explains
the memory management of the microcontroller and it addressing techniques.
While using the MCU 8051-IDE for the simulation purpose we had to calculate the exact
values to move to R3, R2, R1 so that the delay value will match with excpected value exactly.
And when the origin of the program was given as 7000H and simulated it poped up an error
message saying the program memory of the board isnt enough to load the code. Then
thereafter the origin was set to 0000H and simulated with no errors.

When trying out a 7 segment diplay program the ports were addressed in binary so that all
the bits of a port can be clearly enabled or disabled accordng to the number which was
desired to output. This lessen the code enormerously and eased up the simulation.

You might also like