Prog 3

You might also like

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

Microprocessors & Interfacing

Fall 2001
Programming Assignment #3

Name:________________ Student ID: ____________________

1. Using the instructions of Chapter 7 write a program to do the following:

- There are 10 16-bit numbers stored in memory starting from location


A000H. Each 16-bit number is stored in two consecutive memory
locations.
- So, the upper half of the first number is stored in A000H and the
lower half is stored in A001H.
- Add all the 16-bit numbers add save the result in memory locations
B000H, B001H, and B002H.
- WARNING, the result of the addition will be 24-bits.
- The highest 8-bits of the result should be saved in B000H, the
middle 8-bits in B001H, and the lowest 8-bits in B002H.

You can use the simulator to test your program.

Microprocessors & Interfacing Fall 2001 Dr. Bassel Soudan 1

You might also like