Thanks to visit codestin.com
Credit goes to www.scribd.com

0% found this document useful (0 votes)
100 views1 page

Microprocessor Programming Tasks

The document contains 6 programming assignments for a microprocessor and microcontroller course. Assignment 1 requires writing a program to read an 8-bit pattern from Port 1 and output it to different ports based on whether the number is odd or even. Assignment 2 requires writing a program to compute the average of 10 bytes of data from RAM and store the result in memory. It also asks for the code size and time needed assuming an 11.0592 MHz crystal.

Uploaded by

Tarun Gupta
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
100 views1 page

Microprocessor Programming Tasks

The document contains 6 programming assignments for a microprocessor and microcontroller course. Assignment 1 requires writing a program to read an 8-bit pattern from Port 1 and output it to different ports based on whether the number is odd or even. Assignment 2 requires writing a program to compute the average of 10 bytes of data from RAM and store the result in memory. It also asks for the code size and time needed assuming an 11.0592 MHz crystal.

Uploaded by

Tarun Gupta
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 1

EEE4001 Microprocessor and Microcontroller

Assignment II

1) Write a program to read an 8-bit pattern from Port 1 and output it to Port 2 if the
number is odd, to Port 3 if the number is even.

2) Assume 10 bytes of data are stored from RAM locations 50H. Write a program to
compute the average of these numbers and store the result at memory location 40H.
For the code fragment, compute the size and the time needed assuming 11.0592 MHz
crystal.

3) Assuming that XTAL=16MHz, show a program to generate a 0.25 second time delay.
Use any timer you want.

4) How is the TMOD register modified to make each of the timers operate as counters?

5) Program Timer 0 to be an event counter. Use mode 2 and display the binary count
on P2 continuously. Set the initial count to 20.

6) Assuming that clock pulses are fed into pin Tl, write a program for counter 1 in
mode 2 to count the pulses and display the state of the TL1 count on P2.

You might also like