Question: SHOW ALL 3 STEPS! Write a 4 bit ripple adder that uses instances of this fulladder FA shown below, A and B are inputs, Cin
SHOW ALL STEPS!
Write a bit ripple adder that uses instances of this fulladder FA shown below, A and B are inputs, Cin is thecarry in Sum is the output sum, Cout is the carry out, and OF indicates overflow which is determined by thecarryin to the last bit xor the carry out
module FA input A B Cin, output C Cout ;
assign C ABCin;
assign Cout A&B A&Cin B&Cin;
endmodule
this is you bit ripple adder, fill in your code using instances of FA
module FAinput : A B input Cin, output : Sum, output Cout, OF ;
Then, Write a : multiplexer module with bit inputs A B C D a select S and bit output F
And finally, Use an instance of this multiplexer and the ripple adder to make a bit ALU module. The ALU should do additionusing the ripple adder you wrote, subtraction using a s compliment and the ripple adder you wrote, multiplyusing and divide using This will require multiple instances of the ripple adder you wote.
ALU inputs should be bit A Bbit opcode, and output should be bit result. Cout and OF will be local andnot outputs of the ALU. The select bits of the multiplexer should be opcodes for each, so b should be add,b should be subtract, b should be multiply, and b should be divide.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
