Produce a hierarchical design using verilog submodules

Assignment Help Other Engineering
Reference no: EM131218688

Lab: Value Display in Hex and Decimal

Objectives

• Produce a hierarchical design using Verilog submodules
• Develop a testbench for a module
• Implement a design on the DE2 board Constraints

Overview

In this lab you will extend the adder you developed in Lab to display the operands and sum on the 7-segment displays of the DE2 board.

Details

As your first steps in using the DE2 board, you will implement the adder you developed in Lab 1 by taking input from switches and displaying the operands and result on 7-segment displays. Your design should be entirely combinational, so as the user toggles the switches the display should change to match.

You are free to use any modeling technique that you determine is appropriate for the design. You may reuse your adder from Lab 1, you may recreate or modify your adder to match the Lab 2 requirements, or you may implement Lab 2 without a separate adder module.

In addition to implementing the adder, you will also develop a testbench for one submodule.

A blank project is provided for you on Learn, which includes the top-level module definition. Do not change the top-level module deftnition. To open the project for the first time, download the file to your system, open Quartus II, select Restore Archived Project from the Project menu, and select project file in the Archive Name field. After you have restored the project, you can open it through the normal process to open a project.

To help debug your system, the blank project includes a testbench for the top-level module. You can run the simulation by selecting Tools→Run Simulation Tool→RTL Simulation. If the waveform appears correct and you receive a message in the Transcript window (you may have to scroll up) that there are no errors, then your lab likely works correctly.

After your system passes the testbench, you will want to program the design into the DE2. Ensure you create the appropriate pin constraints so your design uses the correct FPGA pins. The DE2 User Manual lists all pinout information for the DE2 board.

Input

The operands to add together will come from the switches on the DE2 board. Each operand will be an 8-bit value with SW[16:9] producing one operand and SW[7:0] producing the other operand. SW[8] and SW[17] will not be used.

7- Segment Display

Use the following representations for values displayed on the 7-segment displays. While there are other valid representations, the testbench provided to you expects these formats. Note that 1 should appear on the right vertical segments.

1568_7-Segment Display.jpg

Operand Display

The operands should be displayed to the user on the 7-segment displays HEX7 through HEX4 in hexadecimal. The operand specified by SW[16:9] should be displayed on HEX7 and HEX6, with HEX7 the more significant digit. Similarly, the operand from SW[7:0] should be displayed on HEX5 and HEX4, with HEX5 the more significant digit.

Result Display

The result of the addition should be displayed on the 7-segment displays HEX3 through HEX0 in decimal. HEX3 is the most significant digit and HEX0 is the least significant digit. In order to display the result in decimal, you will need a BCD converter. A BCD converter appropriate for this lab is provided for you to use. Since your operands are each of 8 bits, your result must be of 9 bits to account for the carry that might occur.

Testbench

Testbenches provide a powerful mechanism for testing module functionality. Your task is to create a testbench for the BCD converter module provided to you. Your testbench should provide an exhaustive (all possible inputs) test of the BCD converter and display useful messages. You are encouraged, but not required, to create testbenches for other modules as well.

Name your testbench for the BCD converter bcd_converter_tb. Create a Test Bench entry in your project for the BCD converter testbench that you create.

When creating your BCD converter testbench, remember that Verilog has many useful mathematical operators, such as modulus.

Reference no: EM131218688

Questions Cloud

Why do you think this is the case : Most of the carbon offsets traded globally are being bought by corporations, many of which are not currently subject to emission restrictions. Why do you think this is the case?
How did the court answer the issues presented : List the issue or issues presented to the court for determination. All issues should be narrowly focused and stated in the form of a question. If more than one issue exists, number the issues and state them separately.
Operations to reduce economic exposure : Discuss the various ways an MNC could restructure operations to reduce economic exposure.
Profit-maximizing businessman : Why is it that a profit-maximizing businessman would always raise prices when facing an inelastic demand curve, but might or might not raise prices when facing an elastic demand curve? Explain and justify your answers in detail.
Produce a hierarchical design using verilog submodules : Produce a hierarchical design using Verilog submodules. Develop a testbench for a module. Implement a design on the DE2 board Constraints. In addition to implementing the adder, you will also develop a testbench for one submodule.
Horizontal axis and other recreational activities : Illustrate Mick's consumption choice in a diagram with health club usage on the horizontal axis and other recreational activities on the vertical axis.
How did impact of the media coverage about the crime rate : What strategies could police employ to ensure an accurate picture of the citizens, crime problem, and solutions for addressing the crime problem in the Anonymous Community are communicated to the media?
What is the effective interest rate : A bond has semiannual interest payments at a nominal annual rate of 12%. It has a life of 10 years and a face value of $5000. If it is currently selling for $4270, what is the effective interest rate? Please provide steps.
Locate and review information on the mission : Select a business and visit its homepage. - Locate and review information on the mission and vision statements pertaining to the company's diversity philosophy and practices.

Reviews

Write a Review

Other Engineering Questions & Answers

  Pseudoplastic and a newtonian fluid please

A Bingham plastic, a dilatant, a pseudoplastic and a Newtonian fluid Please?

  Find required value of c and minimum required value of gm

Design the cross-coupled LC oscillator of Fig. to operate at ω0 = 20 Grad/s. The IC inductors available have L = 5 nH and Q = 10. If the transistor ro = 5 kΩ, find the required value of C and the minimum required value of gm at which Q1 and Q2 ar..

  What is the assumed soil resilient modulus

A section of this road is to be replaced (due to different subgrade characteristics) with a flexible pavement having a structural number of 4 and is expected to last the same number of years as the rigid pavement. What is the assumed soil resilien..

  What address in hex is required on the address bus

What address, in HEX, is required on the address bus in order to read the switches? (RD)‾ and (MEMRQ)‾ are control lines from the CPU. What must their logic state be in order to read the switches?

  What is the total vehicle delay for signal cycle

The arrival rate is constant and the process is D/D/1. If the effective red is known to be less than 40 seconds, what is the total vehicle delay for this signal cycle?

  Analysis of the design options and impact on condenser

The circulating water system components include three pumps in parallel to provide the design flow, and the associated piping and valves to supply the water to the condenser. The water is drawn from a captive lake and is returned to the lake.

  Enmin 5120 tunnelling and mine development a continuous

a continuous miner has the following specifications ltbrgtcutter drum width 3.2m ltbrgtdrum diameter across the picks

  Dfi of real sequences with odd harmonics

DFI of real sequences with odd harmonics only Let x(n) be an N-point real sequence with N-point DFT X(k) (N even). In addition, x(n) satisfied the following symmetry property:

  Find the maximum value of rg

The metallic case is connected through the ground wire of a three-terminal power outlet to power-system ground. The resistance of the ground wire is Rg. The resistance of the worker s body is Rw = 500 Ω. Due to faulty insulation in the drill, a cur..

  Problem regarding the material handling

Shown in the figure below is a layout of an existing warehouse. One-way aisles are 8ft wide, while two-wayaisles are 16 ft wide (Direction of one-way aisles are depicted with arrows).

  Determine the maximum output current

A logic gate drives a load, which has a resistance of 1 kΩ and a capacitance of 20 pF. The printed circuit track connecting the gate to its load has an 40 pF capacitance to ground. The output changes state from 2.5 V to 0 V in 200 ps. Determine th..

  Velocities at the inlet and the exit

Water enters a pump steadily at 100 kPa at a rate of 35 L/s and leaves at 800 kPa. The flow velocities at the inlet and the exit are the same, but the pump exit where the discharge pressure is measured is 6.1 m above the inlet section. The minimum..

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd