|
00.v |
testbench00.v |
|
module gate00(a,b,c); input a,b; output c; assign c=a&b; endmodule |
`timescale 1ms/1ms module testbench00; reg x,y; wire z0; gate00 g00(x,y,z0); initial begin $dumpfile("tmp.vcd"); $dumpvars(); $monitor("%t %b %b %b",$time,x,y,z0); #0 x=1’b0; y=1’b0; #100 x=1’b0; y=1’b1; #100 x=1’b1; y=1’b0; #100 x=1’b1; y=1’b1; #100 x=1’b0; y=1’b0; #100 $finish; end endmodule |
編集後はファイルを保存
(エディタは終了しないのが吉)