Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Experiment 1 Part 1 : The following VHDL code for 1 - bit adder ( from lecture 1 ) . 1 - Create a new

Experiment 1 Part 1 :
The following VHDL code for 1-bit adder (from lecture 1).
1- Create a new project (fulladder1)
2- Add VHD file to the project then copy or print the above code
3- Compile your project
4- Add a waveform file to simulate the full adder.
Part 2: The following VHDL code for 4-bit adder built from 1-bit adder.
-- VHDL for a 4-bit adder built from 1-bit adders.
library ieee;
use ieee.std_logic_1164.all;
entity fulladder4 is
port (x,y : in std_logic_vector(3 downto 0);
cin : in std_logic;
sum : out std_logic_vector(3 downto 0);
cout : out std_logic);
end fulladder4; ...
architecture prototype of fulladder4 is
component fulladder1
port (a,b,c : in std_logic;
s,z : out std_logic);
end component;
signal c1, c2, c3 : std_logic; -- temporary signals needed in the
architecture.
begin
bit0: fulladder1
port map (a=>x(0),b=>y(0),c=> cin,s=> sum(0),z=> c1);
bit1: fulladder1
port map (a=>x(1),b=>y(1),c=> c1,s=> sum(1),z=> c2);
bit2: fulladder1
port map (a=>x(2),b=>y(2),c=> c2,s=> sum(2),z=> c3);
bit3: fulladder1
port map (a=>x(3),b=>y(3),c=> c3,s=> sum(3),z=> cout);
end prototype;
library ieee;
use ieee.std_logic_1164.all;
entity FullAdder1 is
port( a,b,c : in std_logic;
s,z : out std_logic);
end FullAdder1;
architecture prototype of FullAdder1 is
begin
s <= a xor b xor c; -- equation for s
z <=(a and b) or (a and c) or (b and c); -- equation for z
end prototype;
1- Create a new folder to save the new project in it. Lets name it fulladder4)
2- Copy FullAdder1.vhd fle (i prrt 1) pid psrte (rt (i rthe iew folder
3- Open Quartus software and create a new project (fulladder4)
- add FullAdder1.vhd file to the project
4- Add VHD file to the project then copy or print the code of fulladder4
5- Add an output to the entity to detect the overflow.
6- Compile your project
a. Determine the propagation delay from computational report -> Timing
analyzer
7- Add waveform file to simulate the 4 bit full adder.
a. Simulation (Simulate the fulladdre4 for different values of x and y)
b. Timing (Simulate the fulladdre4 for fixed value of x and y)
8- Check RTLview of your design
Part 3
1. Copy the folder of fulladder4 project
2. Modify the new copy of the project to design 8 bit full adder
3. Compile your project
a. Determine the propagation delay from computational report -> Timing
analyzer
4- Add waveform file to simulate the 4 bit full adder.
b. Simulation (Simulate the fulladdre4 for different values of x and y)
c. Timing (Simulate the fulladdre4 for fixed value of x and y)
5- Check RTLview of your design
Part 4
Add the necessary changes to the code to design 4-bit adder subtractor
- create a new project ( lets call it adder_sub4)
- Add the vhd files (fulladder1 and fulladder4 to the project)
- Change the entity name in fulladder4.vhd file to adder_sub4 then add the necessary
changes in the code

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Data And Information Quality Dimensions, Principles And Techniques

Authors: Carlo Batini, Monica Scannapieco

1st Edition

3319241060, 9783319241067

Students also viewed these Databases questions

Question

What is data mining? How do marketers use it?

Answered: 1 week ago

Question

Do you talk about them as if they are giving you gifts?

Answered: 1 week ago

Question

What is your organizations mind-set about complaints?

Answered: 1 week ago