shamieh
- 538
- 0
Draw out the circuit diagram for the following 2 output circuit specified in the following Verilog module (AND - &, Or - |, Not - ~). Use AND, OR and Inverter Gates.
Module test1(f,g,x,y,z);
input x,y,z;
output f,g;
assign g = f(~y&~x);
assign f = x&y | ~x&z;
endmodule;
Here is my solution:
View attachment 1449
Module test1(f,g,x,y,z);
input x,y,z;
output f,g;
assign g = f(~y&~x);
assign f = x&y | ~x&z;
endmodule;
Here is my solution:
View attachment 1449
, but I don't understand "f(~y&~x)". Since there is no operator between f and (~y&~x), it looks like a function application, but f has not been declared a function (this requires the "function" keyword). I tried to compile this code on