когда я запускаю код Verilog в терминале, и он говорит, что в первой строке моего кода есть ошибка.
и я не знаю в чем проблема ..
когда я бегу в терминале, он показывает ...
num_7seg_B.v:2: syntax error
Я сдаюсь.
module num_7seg_B SEG_B(out, w, x, y, z);
output out;
input w, x, y, z;
wire y1;
wire z1;
wire y_out;
wire z_out;
not G1 (y1, y);
not G2 (z1. z);
and G3 (y_out, x, y1);
and G4 (z_out, x, y, z1);
or G5 (out, z_out, y_out, w);
endmodule
and here is test base code
module TOP;</p>
<pre> wire w,x,y,z,out;
reg [3:0] num;
// instantiation of the module
num_7seg_B SEG_B(out,w,x,y,z);
// simulation ends at time 200
initial #200 $finish;
// num change from 0 to 15, incremented every 5 seconds
initial begin
num=0;
repeat (15)
#5 num=num+1;
end
// dump files
initial
begin
$dumpfile("h1_output.vcd");
$dumpvars;
end
// assignment of signals
assign w=num[3];
assign x=num[2];
assign y=num[1];
assign z=num[0];
endmodule