0% found this document useful (0 votes)
32 views2 pages

Lab2 - 2 Eng

This document provides the objectives, references, and experiments for a lab on communicating with 7-segment LED displays and LED matrices. The objectives are to communicate with a 7-segment LED display and an LED matrix. Experiment 1 involves using timers to display numbers on 7-segment LEDs at 50 Hz. Experiment 2 displays the value of a port multiplied by 9 on the 7-segment LEDs. Experiment 3 involves using a timer to display the letter A on a matrix LED at scanning frequencies of 25 Hz and 125 Hz. The student is to complete the experiments and answer questions in a lab report.
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)
32 views2 pages

Lab2 - 2 Eng

This document provides the objectives, references, and experiments for a lab on communicating with 7-segment LED displays and LED matrices. The objectives are to communicate with a 7-segment LED display and an LED matrix. Experiment 1 involves using timers to display numbers on 7-segment LEDs at 50 Hz. Experiment 2 displays the value of a port multiplied by 9 on the 7-segment LEDs. Experiment 3 involves using a timer to display the letter A on a matrix LED at scanning frequencies of 25 Hz and 125 Hz. The student is to complete the experiments and answer questions in a lab report.
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/ 2

LAB 2-2

COMMUNICATE WITH 7-SEGMENT LED AND LED


MATRIX

OBJECTIVE:

• Communicate with a 7-segment LED display.


• Communicate with a matrix LED display.

REFERENCES:

• Lab manual chapter 4


• Atmel-2505-Setup-and-Use-of-AVR-Timers_ApplicationNote_AVR130.pdf

EXPERIMENT 1:

a) Connect one AVR port to header J34. Connect two other port pins to signals nLE0 and
nLE1 on header J82. Set jumpers to power the 7-segment LED display.
b) Use sample programs from the experiment guide to write a program that displays the
numbers 0, 1, 2, and 3 on the 4 7-segment LED displays. Use Timer 0 to scan the LEDs at
a scanning frequency of 50 Hz.

EXPERIMENT 2:

a) Connect an AVR port to a dip switch, assuming it's PORTA.


b) Write a program to display the value of PORTA * 9 on the 4 7-segment LED displays.
c) Change the dip switch value and observe the results.

EXPERIMENT 3:

a) Connect the necessary signals to control the matrix LED display.


b) Use the provided sample program, modify it if necessary, to display the letter 'A' on the
matrix LED display. Scan the matrix LED display using a timer to create a delay with a
scanning frequency of 25 Hz.
c) Modify the program to achieve a scanning frequency of 125 Hz.

https://doe.dee.hcmut.edu.vn/
LAB REPORT
Group:
Class group: Subject:

EXPERIMENT 1:

1. Answer the following questions:


a. To have a scanning frequency of 50 Hz, how long does one LED stay
lit?
b. How do you configure the timer to achieve this delay?
2. Provide the source code with comments.
........................................................................................................................

EXPERIMENT 2:

1. Answer the following questions:


a. How many bits is the value of PORTA * 9?
b. How can you display each digit on the 4 7-segment LEDs?
2. Provide the source code with comments.
........................................................................................................................

EXPERIMENT 3:

1. Answer the following questions:


a. How many bits is the value of PORTA * 9?
b. How can you display each digit on the 4 7-segment LEDs?
2. Provide the source code with comments.
........................................................................................................................

https://doe.dee.hcmut.edu.vn/

You might also like