data/full_repos/permissive/180640075/Basys3_Camera_Driver.srcs/sources_1/new/Top.v
1: b"%Error: data/full_repos/permissive/180640075/Basys3_Camera_Driver.srcs/sources_1/new/Top.v:43: Cannot find file containing module: 'vga640x480'\nvga640x480 display (\n^~~~~~~~~~\n        ... Looked in:\n             data/full_repos/permissive/180640075/Basys3_Camera_Driver.srcs/sources_1/new,data/full_repos/permissive/180640075/vga640x480\n             data/full_repos/permissive/180640075/Basys3_Camera_Driver.srcs/sources_1/new,data/full_repos/permissive/180640075/vga640x480.v\n             data/full_repos/permissive/180640075/Basys3_Camera_Driver.srcs/sources_1/new,data/full_repos/permissive/180640075/vga640x480.sv\n             vga640x480\n             vga640x480.v\n             vga640x480.sv\n             obj_dir/vga640x480\n             obj_dir/vga640x480.v\n             obj_dir/vga640x480.sv\n%Error: data/full_repos/permissive/180640075/Basys3_Camera_Driver.srcs/sources_1/new/Top.v:66: Cannot find file containing module: 'sram'\n    sram #(\n    ^~~~\n%Error: data/full_repos/permissive/180640075/Basys3_Camera_Driver.srcs/sources_1/new/Top.v:80: Cannot find file containing module: 'Cam_In'\n Cam_In camera (\n ^~~~~~\n%Error: Exiting due to 3 error(s)\n"
module Top(
    input wire CLK,
    input wire IO_BTN_C,
    input wire [7:0] JA,
    output wire VGA_Hsync,
    output wire VGA_Vsync,
    output wire [3:0] vgaRed,
    output wire [3:0] vgaBlue,
    output wire [3:0] vgaGreen
    );
    


reg [15:0] cnt;
reg pix_stb; 
always @(posedge CLK) begin
    {pix_stb, cnt} <= cnt + 16'h4073;
end

wire rst = IO_BTN_C;
wire [9:0] x;
wire [8:0] y;
wire animate;
vga640x480 display (
        .i_clk(CLK),
        .i_pix_stb(pix_stb),
        .i_rst(rst),
        .o_hs(VGA_Hsync), 
        .o_vs(VGA_Vsync), 
        .o_x(x), 
        .o_y(y)
    );


    localparam SCREEN_WIDTH = 640;
    localparam SCREEN_HEIGHT = 360;
    localparam VRAM_DEPTH = SCREEN_WIDTH * SCREEN_HEIGHT; 
    localparam VRAM_A_WIDTH = 18;
    localparam VRAM_D_WIDTH = 6;

    reg [VRAM_A_WIDTH-1:0] address;
    reg [VRAM_D_WIDTH-1:0] datain;
    wire [VRAM_D_WIDTH-1:0] dataout;
    reg we = 0;


    sram #(
        .ADDR_WIDTH(VRAM_A_WIDTH), 
        .DATA_WIDTH(VRAM_D_WIDTH), 
        .DEPTH(VRAM_DEPTH), 
        .MEMFILE("")) 
        vram (
        .i_addr(address), 
        .i_clk(CLK), 
        .i_write(we),
        .i_data(datain), 
        .o_data(dataout)
    );

 reg [7:0] Cam_Data;
 Cam_In camera (
        .JA(JA),
        .Cam_Data(Cam_Data)
    );


endmodule
module Top(
    input wire CLK,
    input wire IO_BTN_C,
    input wire [7:0] JA,
    output wire VGA_Hsync,
    output wire VGA_Vsync,
    output wire [3:0] vgaRed,
    output wire [3:0] vgaBlue,
    output wire [3:0] vgaGreen
    );

    


reg [15:0] cnt;
reg pix_stb; 
always @(posedge CLK) begin
    {pix_stb, cnt} <= cnt + 16'h4073;
end

wire rst = IO_BTN_C;
wire [9:0] x;
wire [8:0] y;
wire animate;
vga640x480 display (
        .i_clk(CLK),
        .i_pix_stb(pix_stb),
        .i_rst(rst),
        .o_hs(VGA_Hsync), 
        .o_vs(VGA_Vsync), 
        .o_x(x), 
        .o_y(y)
    );


    localparam SCREEN_WIDTH = 640;
    localparam SCREEN_HEIGHT = 360;
    localparam VRAM_DEPTH = SCREEN_WIDTH * SCREEN_HEIGHT; 
    localparam VRAM_A_WIDTH = 18;
    localparam VRAM_D_WIDTH = 6;

    reg [VRAM_A_WIDTH-1:0] address;
    reg [VRAM_D_WIDTH-1:0] datain;
    wire [VRAM_D_WIDTH-1:0] dataout;
    reg we = 0;


    sram #(
        .ADDR_WIDTH(VRAM_A_WIDTH), 
        .DATA_WIDTH(VRAM_D_WIDTH), 
        .DEPTH(VRAM_DEPTH), 
        .MEMFILE("")) 
        vram (
        .i_addr(address), 
        .i_clk(CLK), 
        .i_write(we),
        .i_data(datain), 
        .o_data(dataout)
    );

 reg [7:0] Cam_Data;
 Cam_In camera (
        .JA(JA),
        .Cam_Data(Cam_Data)
    );


endmodule