Question: For the following Verilog code, assume that D changes to 1 at time 5 ns. Give the values of A, B, C, D, E, and

For the following Verilog code, assume that D changes to 1 at time 5 ns. Give the values of A, B, C, D, E, and F each time a change occurs. That is, give the values at time 5 ns, 5 + D, 5 + 2D, and so forth. Carry this out until 20 steps have occurred, until no further change occurs, or until a repetitive pattern emerges.

module prob(D);
inout D;
wire A, C;
reg B,E,F,temp_D;
initial begin
B = 1'b0;
E = 1'b0;
F = 1'b0;
temp_D = 1'b0;
end

assign C = A;
assign A = (B & !E) | D;
assign D = temp_D;
always @(A)
begin
B = A;
end
always  

begin
wait(A)
E <= #5 B;
temp_D <= 1'b0;
F <= E;
end
endmodule

Step by Step Solution

3.52 Rating (155 Votes )

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

ns 0 05510 5 a b d 0 0 0 0 0 ... View full answer

blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Digital Systems Design Questions!