Skip to content

Commit cfd59db

Browse files
committed
refactor: Fix bug with input feature loading and missing initialization in Conv.v
1 parent b34155b commit cfd59db

File tree

1 file changed

+6
-13
lines changed

1 file changed

+6
-13
lines changed

code/Conv.v

Lines changed: 6 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -42,19 +42,6 @@ initial begin
4242
end
4343
////////////////////////////////////////////////////////////////////
4444

45-
////////////////////////////////initial/////////////////////////////
46-
initial begin
47-
start_conv <= 1'b0;
48-
load_data_status <= 1'b0;
49-
data_counter <= 6'b000000;
50-
line <= 3'b000;
51-
row <= 3'b000;
52-
cycle <= 1'b0;
53-
out_st <= 1'b0;
54-
output_counter <= 6'b000000;
55-
output_data_status <= 1'b0;
56-
end
57-
////////////////////////////////////////////////////////////////////
5845

5946
always @(posedge clk) begin
6047

@@ -82,6 +69,11 @@ always @(posedge clk) begin
8269
end
8370
else if ( in_st == 1'b1 ) begin // start loading data
8471
load_data_status <= 1'b1;
72+
start_conv <= 1'b0;
73+
data_counter <= 6'b000000;
74+
line <= 3'b000;
75+
row <= 3'b000;
76+
cycle <= 1'b0;
8577
end
8678

8779

@@ -104,6 +96,7 @@ always @ (posedge clk) begin
10496
start_conv <= 1'b0;
10597
out_st <= 1'b1;
10698
output_data_status <= 1'b1;
99+
output_counter <= 6'b000000;
107100
end
108101
end
109102
cycle <= 0;

0 commit comments

Comments
 (0)