data/full_repos/permissive/116468596/redRectangle.v
1: b'%Warning-WIDTH: data/full_repos/permissive/116468596/redRectangle.v:42: Operator ASSIGNW expects 1 bits on the Assign RHS, but Assign RHS\'s ADD generates 10 bits.\n                                                                      : ... In instance redRectangle\n    wire bottomLength = yPos+recLength; \n                      ^\n                ... Use "/* verilator lint_off WIDTH */" and lint_on around source to disable this message.\n%Error: data/full_repos/permissive/116468596/redRectangle.v:43: Cannot find file containing module: \'rectangleSM\'\n    rectangleSM rectSM (.clk(clk), .btnC(btnC), .hit(hit), .timeOut(timeOut), .loadTime(loadTime), .allHit(allHit), .startState(startState), .returnHit(returnHit), .activeRed(activeRed), .flash(flash), .go(go), .resetState(resetState) ); \n    ^~~~~~~~~~~\n        ... Looked in:\n             data/full_repos/permissive/116468596,data/full_repos/permissive/116468596/rectangleSM\n             data/full_repos/permissive/116468596,data/full_repos/permissive/116468596/rectangleSM.v\n             data/full_repos/permissive/116468596,data/full_repos/permissive/116468596/rectangleSM.sv\n             rectangleSM\n             rectangleSM.v\n             rectangleSM.sv\n             obj_dir/rectangleSM\n             obj_dir/rectangleSM.v\n             obj_dir/rectangleSM.sv\n%Error: data/full_repos/permissive/116468596/redRectangle.v:45: Cannot find file containing module: \'tenBitCount\'\n    tenBitCount vertical (.clk(clk), .reset(resetState | startState), .enable(go & frame & doneCount), .up(1\'b1), .down(1\'b0),\n    ^~~~~~~~~~~\n%Error: Exiting due to 2 error(s), 1 warning(s)\n'
module redRectangle(
    input syncFlash, timeOut,
    input hit, allHit,
    input [15:0] sw,
    input [9:0] hOutQ,
    input [9:0] vOutQ,
    input [9:0] horizontalPosition,
    input clk, frame, doneCount,
    input btnC,
    output redRect, flash, startState, loadTime,
    output [9:0] yPos,
    output outOfAR, outOfTopAR,
    output resetState, activeRed,
    output returnHit
    );
    wire topWall, leftWall, rightWall, bottomWall;
    wire  go;
    wire activeRegion;
    wire [9:0] recLength;
    wire bottomLength = yPos+recLength; 
    rectangleSM rectSM (.clk(clk), .btnC(btnC), .hit(hit), .timeOut(timeOut), .loadTime(loadTime), .allHit(allHit), .startState(startState), .returnHit(returnHit), .activeRed(activeRed), .flash(flash), .go(go), .resetState(resetState) ); 

    tenBitCount vertical (.clk(clk), .reset(resetState | startState), .enable(go & frame & doneCount), .up(1'b1), .down(1'b0),
     .LD(1'b0), .outQ(yPos) );
    
    assign activeRegion = ( (hOutQ > 10'd8) & (hOutQ < 10'd631) & (vOutQ > 10'd8) & (vOutQ < 10'd471) );

    assign outOfAR = ( yPos == 10'd4 );
    assign recLength = ( 10'd16 + sw[6:4]*10'd32 );


    assign redRect = (activeRed | (syncFlash & flash)) & ~(yPos < 10'd9) & ~startState & doneCount & activeRegion & 
    ((hOutQ >= horizontalPosition-10'd4) & (hOutQ <= horizontalPosition+10'd4)) & ((vOutQ >= yPos) & (vOutQ <= yPos+recLength)); 
    
endmodule
module redRectangle(
    input syncFlash, timeOut,
    input hit, allHit,
    input [15:0] sw,
    input [9:0] hOutQ,
    input [9:0] vOutQ,
    input [9:0] horizontalPosition,
    input clk, frame, doneCount,
    input btnC,
    output redRect, flash, startState, loadTime,
    output [9:0] yPos,
    output outOfAR, outOfTopAR,
    output resetState, activeRed,
    output returnHit
    );

    wire topWall, leftWall, rightWall, bottomWall;
    wire  go;
    wire activeRegion;
    wire [9:0] recLength;
    wire bottomLength = yPos+recLength; 
    rectangleSM rectSM (.clk(clk), .btnC(btnC), .hit(hit), .timeOut(timeOut), .loadTime(loadTime), .allHit(allHit), .startState(startState), .returnHit(returnHit), .activeRed(activeRed), .flash(flash), .go(go), .resetState(resetState) ); 

    tenBitCount vertical (.clk(clk), .reset(resetState | startState), .enable(go & frame & doneCount), .up(1'b1), .down(1'b0),
     .LD(1'b0), .outQ(yPos) );
    
    assign activeRegion = ( (hOutQ > 10'd8) & (hOutQ < 10'd631) & (vOutQ > 10'd8) & (vOutQ < 10'd471) );

    assign outOfAR = ( yPos == 10'd4 );
    assign recLength = ( 10'd16 + sw[6:4]*10'd32 );


    assign redRect = (activeRed | (syncFlash & flash)) & ~(yPos < 10'd9) & ~startState & doneCount & activeRegion & 
    ((hOutQ >= horizontalPosition-10'd4) & (hOutQ <= horizontalPosition+10'd4)) & ((vOutQ >= yPos) & (vOutQ <= yPos+recLength)); 
    
endmodule