I'm trying to create a testbench file for the sequential circuit in Modelsim (Verilog). But, I'm getting the following syntax error.
** Error: (vlog-13069) /Assignment_2x2_tb.v(6): near "initial": syntax error, unexpected initial, expecting ';' or ','.
Here's my code
module seq_circuit1_tb;
reg x,clk;
wire q;
seq_circuit1 seqct(x, clk, Q0, Q1)
//Module to generate clock with period 10 time units
initial begin
forever begin
clk=0;
#10
clk=1;
#10
clk=0;
end
end
initial begin
x=0;
#50
x=0;
#50
x=1;
#50
x=1;
#50
end
endmodule
Why am I getting this error?
You need a semicolon (;
) after the line seq_circuit1 seqct(x, clk, Q0, Q1)
.