Design a Fibonacci number generator that accepts as input a number n on the port numberIn...
Fantastic news! We've Found the answer you've been seeking!
Question:
Transcribed Image Text:
Design a Fibonacci number generator that accepts as input a number n on the port numberIn and output the nth Fibonacci number on the output port numberOut. The nth Fibonacci number is the sum of the (n - 1) and (n-2) Fibonacci numbers, and the first two numbers in the sequence are 0 and 1. So the Fibonacci sequence is: 0, 1, 1, 2, 3, 5, 8, 13, 21,... Your design should accept the input value of n on the port numberIn when a start signal called go is high. The reset signal is active low and should be asyn- chronous. The output consists of the nth Fibonacci number on the port number Out and a done signal of 1 for one clock cycle indicating that the output is valid. The maximum number of n is 24 and hence the 24th Fibonacci number is 46, 368. The Fibonacci numbers generator algorithm can be described in the following C- code: unsigned int fibonacci (int n) { unsigned int previous = 0; unsigned int current = 1; unsigned int tmp; unsigned int count = 1; while (count n) { tmp = current; current = current + previous; previous tmp; count count + 1; return current; } } Your Design You should follow all design steps. Start with the top-level block diagram and identify all external (primary) input and output signals for the whole design. Divide your design into two units: Data Path unit and Control Unit. Identify all the signals to the data path and control unit. . Show the design of the Data Path Unit: Identify the required blocks (i.e., storage elements, functional units, and interconnects) and design them. Show the design of the Control Unit: Identify the required control signals, design the Control Unit, and connect it to the data path. Write Verilog modules for both data path and control unit. Write Verilog module for the whole design. Write a test unit (test bench) to test and simulate your design. Design a Fibonacci number generator that accepts as input a number n on the port numberIn and output the nth Fibonacci number on the output port numberOut. The nth Fibonacci number is the sum of the (n - 1) and (n-2) Fibonacci numbers, and the first two numbers in the sequence are 0 and 1. So the Fibonacci sequence is: 0, 1, 1, 2, 3, 5, 8, 13, 21,... Your design should accept the input value of n on the port numberIn when a start signal called go is high. The reset signal is active low and should be asyn- chronous. The output consists of the nth Fibonacci number on the port number Out and a done signal of 1 for one clock cycle indicating that the output is valid. The maximum number of n is 24 and hence the 24th Fibonacci number is 46, 368. The Fibonacci numbers generator algorithm can be described in the following C- code: unsigned int fibonacci (int n) { unsigned int previous = 0; unsigned int current = 1; unsigned int tmp; unsigned int count = 1; while (count n) { tmp = current; current = current + previous; previous tmp; count count + 1; return current; } } Your Design You should follow all design steps. Start with the top-level block diagram and identify all external (primary) input and output signals for the whole design. Divide your design into two units: Data Path unit and Control Unit. Identify all the signals to the data path and control unit. . Show the design of the Data Path Unit: Identify the required blocks (i.e., storage elements, functional units, and interconnects) and design them. Show the design of the Control Unit: Identify the required control signals, design the Control Unit, and connect it to the data path. Write Verilog modules for both data path and control unit. Write Verilog module for the whole design. Write a test unit (test bench) to test and simulate your design.
Expert Answer:
Related Book For
Java An Introduction To Problem Solving And Programming
ISBN: 9780134462035
8th Edition
Authors: Walter Savitch
Posted Date:
Students also viewed these programming questions
-
can someone solve this Modern workstations typically have memory systems that incorporate two or three levels of caching. Explain why they are designed like this. [4 marks] In order to investigate...
-
CANMNMM January of this year. (a) Each item will be held in a record. Describe all the data structures that must refer to these records to implement the required functionality. Describe all the...
-
A thermocouple Type K is calibrated in lab condition at 50% relative humidity (RH) prior to outdoor operation. After 12-month in outdoor installation, the thermocouple is again tested at 75% RH. Both...
-
A Cepheid variable star is a star whose brightness alternately increases and decreases. The most easily visible such star is Delta Cephei, for which the interval between times of maxi - mum...
-
Bramble Company has two classes of capital stock outstanding: 8%, $20 par preferred and $5 par common. At December 31, 2025, the following accounts were included in stockholders' equity. Preferred...
-
Water at \(60^{\circ} \mathrm{F}\) is flowing through the 2 -in. steel pipe shown in Fig. P5.82 at the rate of \(90 \mathrm{gal} / \mathrm{min}\). Determine the torque developed at the base where the...
-
A hot fluid passes through circular channels of a cast iron platen (A) of thickness LA = 30 mm which is in poor contact with the cover plates (B) of thickness L B = 7.5 mm. The channels are of...
-
addi x2, x0, 16 slli x2, x2, 4 What is the value of x2 in decimal after the execution?
-
A coupon bond with face value $100, pays out annual coupons of $19. The present value is 132. The yield is 30%. With a strike price of 134, what would be the present value of a put option on this...
-
Name three guidelines to follow when choosing or designing a slide template. What are verbal tics? Provide two examples. What three things should you do when answering a question in a presentation?...
-
If the Production Manager is instructed to reduce costs, what would be a logical step to take? Increase sales Reduce the selling price of the products Opt not to buy market research Increase the...
-
1. Comparison of living in town or in the county? Which is the best home for you, and why is that important?
-
At the end of the month, Herbicida calculated equivalent units of production in the Mixing Department as shown below: UNITS Units accounted for Equivalent Units Direct Materials Costs Equivalent...
-
Based on your knowledge of macroeconomics, do you believe that the government should have bailed out AIG, the auto industry in providing guaranteed loans to GM and Chrysler. What is your opinion?...
-
Look at some scriptures that talk about peace and what different kinds of peace. Write a paper in which you address the following: What do you think of when you think of peace? Is it a world without...
-
What is an access control list?
-
(a) Draw the elementary magnets inside a bar magnet and a horseshoe magnet, using the half-filled-circle format shown in Figures 27.8 and 27.9. (b) How many poles does the magnetized ring in Figure...
-
(a) What is the effect of the north pole of the bar magnet on the compass needle in Figure 27.11a? (b) What is the combined effect of the bar magnet's north and south poles on the needle? (c) A...
-
(a) Which end of a compass needle is a north pole: the end that points toward Earth's North Pole or the other end? (b) If you place a compass near the north pole of a magnet, what happens to the...
Study smarter with the SolutionInn App