8 LED custom animation

You might also like

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

Digital Electronics

8 LED Custom
Animaton
By Group 3 :
Zizi Aulia Azzahra (160122024)
Felipe Ariel Christnawan (160122012)
Bagas Rizky Utomo (16012208)
Tools and requirment

Discussion
Concept

Point Overview

How it work?
Key topics covered
in this presentation
The Process

Results
Hardware and
Software
Requirements
Altera Board Quartus II
Sofrtware
The Altera Board was chosen for
several reasons:
High-performance FPGA
The Quartus II software was chosen
technology
for the following reasons:
Flexible and versatile for various
Powerful and user-friendly design
applications
environment
Good support and documentation
Extensive libraries and IP cores for
from the manufacturer
easy implementation
Compatibility with Altera Board
8 LED Custom Animation
What is it?

In this project, we are tasked with creating a program that can run 8 LED
animations on the Althera board. To execute this program, a clock are
needed for adjusting the operating speed of a module. and a selector
are needed to choose which animation to display.
Overview
CLK

Animation 1 Animation 2 Animation 3

Switch Selector
Step-by-Step Process
Step 4: Step 5:
Step 1: Step 2: Step 3:
Making block Testing and
Clock Divider Selector Animation
diagram Debugging

First, we create a Second, create a Third, create the Creating a block Test the LED
VHDL program for VHDL program for VHDL program diagram to animation by
the clock divider, the selector to for the LED enable the running the code
which is necessary enable the display animation. overall execution on the Altera
to regulate the of the desired of the program. Board. If there
speed of the LED animation. are any issues or
animation. errors, debug the
code and make
necessary
adjustments to
ensure the
animation works
correctly.
VHDL Program
CLOCK DIVIDER

We are using the program


from module 7.

The program implements a


clock generator with a
frequency set by generic
parameters and an
adjustable duty cycle.
Essentially, it creates a
clock signal with a
predefined frequency and
duty cycle.
When run
animation
without clock
divider
VHDL Program
ANIMATION 1
The program creates a simple animation effect
where LEDs move forward and backward
continuously with each rising clock edge.

If the animation is moving forward (led_direction


= '0'), the LED value is shifted one position to the
left. If the last LED is lit, the animation reverses
direction and returns to the first LED. If the
animation is moving backward (led_direction =
'1'), the LED value is shifted one position to the
right. If the first LED is lit, the animation reverses
direction and returns to the last LED."
VHDL Program
ANIMATION 2
The program creates an animation effect where
two sets of LEDs move from opposite directions
and meet in the middle.

The process is triggered on the rising edge of the


clock signal (clk). leds_array1 is shifted one
position to the left, and if the last LED is lit, reset the
value of leds_array1 to '00000001'. leds_array2 is
shifted one position to the right, and if the first LED
is lit, reset the value of leds_array2 to '10000000'.
The output leds is set by combining the values of
leds_array1 and leds_array2 using OR.
VHDL Program
ANIMATION 3
The program is relatively simple and is used to
provide a visual effect by controlling the LED
status according to the changing state of the
blink signal at each rising edge of the clock.

The process is activated on the rising edge of the


clock signal (clk). The blink signal is toggled
(inverted) each time the clock rises (via not
blink). If the blink value is '1', then all LEDs are set to
light up (leds <= (others => '1')). If the blink value
is '0', then all LEDs are set to turn off (leds <=
(others => '0')).
VHDL Program
ANIMATION 4
There are three types of LED effect
patterns. First, all LEDs light up for 1
second, then the LEDs illuminate in a
left-to-right pattern for 1 second.
Second, they light up in a pattern
moving both from left to right and
right to left for 1 second. Third, the
LEDs return to the initial pattern with
all LEDs turned off for 1 second.

The animation involves the use of


"blink" signals to control the
alternating brightness of the LEDs
and a "counter" signal to control the
number of times each effect pattern
is applied.
VHDL Program
SELECTOR
This is VHDL code for the Selector entity
that has four animation inputs and
one output. The code includes a
process that determines the value of
the output based on the value of the
selector switch. The VHDL code defines
an 8-bit multiplexer with a 3-bit
selector signal. The multiplexer selects
one of the four 8-bit input signals
based on the value of the selector
signal and passes it through to the
output signal.
BLOCK DIAGRAM
Do you have
any questions?
We hope you learned something new.

You might also like