Question

For this problem you will design a circular bit shifter in VHDL. These circuits are especially useful for aligning signals in

0 0
Add a comment Improve this question Transcribed image text
Answer #1

library ieee;
use ieee.std_logic_1164.all;

entity circular_bit_shifter is
   port(   din        : in std_logic_vector(3 downto 0);
       shift_amount   : in std_logic_vector(1 downto 0);
       dout       : out std_logic_vector(3 downto 0)
   );
end circular_bit_shifter;

architecture arch of circular_bit_shifter is

signal reg : std_logic_vector(3 downto 0);

begin

process (din, shift_amount)

begin

   case (shift_amount) is
       when "00"=> reg<=din;
       when "01"=> reg<=din(0)&din(3 downto 1);
       when "10"=> reg<=din(1 downto 0)&din(3 downto 2);
       when "11"=> reg<=din(2 downto 0)&din(3);
       when others=> null;
   end case;

end process;

dout <= reg;

end arch;

-----------------------------------------------------------------

M Model5im INTEL FPEA STARTER EDITION 10.5b File Edit View Compile Simulate Add Wave Tools Layout BookmarksWindow Help E Sear

Add a comment
Know the answer?
Add Answer to:
For this problem you will design a circular bit shifter in VHDL. These circuits are especially...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • Design a 4 bit sequential circuit that can either count up or perform a circular left...

    Design a 4 bit sequential circuit that can either count up or perform a circular left shift operation. You have to accept one input from the user, which decides if the counter is counting down or shifting. Note that the circuit should be able to change the operation from counting down and shifting without skipping any numbers. You can use at most 4 flip flops in the circuit. For example, the user can choose to count up from 0 to...

  • 2. Serial shift registers Draw missing connections to implement various shift registers 1. Shift right: All...

    2. Serial shift registers Draw missing connections to implement various shift registers 1. Shift right: All bits of the register move right by one position, and a new bit value from a serial input is stored in the most significant bit (leftmost flip-flop below). Serial input -02 az 02 a Do ao Serial indino 2. Shift left: All bits of the register move left by one position, and a new bit value from a serial input is stored in the...

  • Introduction: This experiment studies the design of an 8-bit adder/subtractor circuit using VHDL capture. The experiment...

    Introduction: This experiment studies the design of an 8-bit adder/subtractor circuit using VHDL capture. The experiment investigates the implementation of addition and subtraction operations with circuits. This lab uses the virtual simulation environment to validate the design practically in the FPGA board. Equipment: • This experiment requires Quartus Prime and the Intel's DE2-115 FPGA board. • All students should have the Intel QP and ModelSim-Intel-Starter-Edition softwares installed in personal computers. • VPN connection to UNB Network and remote desktop software...

  • Can you use Multisim or something similar. I got the truth table and design, but having...

    Can you use Multisim or something similar. I got the truth table and design, but having a hard time with the actual wiring. I  need to see where each cable and light bulb go. 3.4. Multiplexer Multiplexers are very useful components in digital systems. They transfer a large number of information units over a smaller number of channels, (usually one channel) under the control of selection signals. Fig. 3 is a 4-line to l-line MUX. In this circuit, lo, 11, 12,...

  • FIRST ACTIVITY: (100/100) . SIMPLE 4-BIT ARITHMETIC LOGIC UNIT (ALU): This circuit selects between arithmetic (absolute...

    FIRST ACTIVITY: (100/100) . SIMPLE 4-BIT ARITHMETIC LOGIC UNIT (ALU): This circuit selects between arithmetic (absolute value, addition) and logical (XOR, AND) operations. Only one result (hexadecimal value) can be shown on the 7-segment display This is selected by the input sel (1..0) B A-BI A+B A xnor B A nand B Input EN: If EN-1result appears on the 7 segment display. If EN=0 → all LEDs in the 7 segment display are off Arithmetic operations: The 4-bit inputs A...

  • please help question 2 2. Design a half-adder with the constraint that you can only use...

    please help question 2 2. Design a half-adder with the constraint that you can only use NAND and NOR gates. The circuit inputs are two bits I and y and the outputs are the sum bit s and carry bit c. Draw a circuit diagram and label each input and output. 3. The digital circuit below contains a latch and two flip-flops. Use the wave forms provided to find Qa. Qb, and Qe. Assume that all three states have initial...

  • 2. In this question, you are asked to design a synthesizable ALU in Verilog. This ALU...

    2. In this question, you are asked to design a synthesizable ALU in Verilog. This ALU gets two 9-bit signed inputs (A, B) in 2’s complement format, and a 4-bit select input (S) based on which decides about the operation that should be executed. The output is Q, and you determine the number of bits for Q in order to have a correct answer. What follows shows these operations: If S=0 Addition (i.e., A+B) If S=1 Subtraction (A-B) If S=2...

  • Some questions may require well bulum 1. HDL stands for? a. Hardware Design Language b. Hardware...

    Some questions may require well bulum 1. HDL stands for? a. Hardware Design Language b. Hardware Development Language c. Hardware Description language d. Hot Dry Land 2. What is the basic building unit of a VHDL design? a. Blocks b. Cubes c . Dices d. Bricks 3. What reserved word do all VHDL entities end with? a. entity b. use c. port d. end d. IEEE 4. Which block describes a design's interface? a. entity b. architecture c. library 5....

  • Discussion questions 1. What is the link between internal marketing and service quality in the ai...

    Discussion questions 1. What is the link between internal marketing and service quality in the airline industry? 2. What internal marketing programmes could British Airways put into place to avoid further internal unrest? What potential is there to extend auch programmes to external partners? 3. What challenges may BA face in implementing an internal marketing programme to deliver value to its customers? (1981)ǐn the context ofbank marketing ths theme has bon pururd by other, nashri oriented towards the identification of...

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT