data/full_repos/permissive/187705377/Camera Reduced/single_frame_trigger.sv
[Errno 2] No such file or directory: 'preprocess.output'
1: b'%Error: Cannot find file containing module: Reduced,data/full_repos/permissive/187705377\n        ... Looked in:\n             data/full_repos/permissive/187705377/Camera/Reduced,data/full_repos/permissive/187705377\n             data/full_repos/permissive/187705377/Camera/Reduced,data/full_repos/permissive/187705377.v\n             data/full_repos/permissive/187705377/Camera/Reduced,data/full_repos/permissive/187705377.sv\n             Reduced,data/full_repos/permissive/187705377\n             Reduced,data/full_repos/permissive/187705377.v\n             Reduced,data/full_repos/permissive/187705377.sv\n             obj_dir/Reduced,data/full_repos/permissive/187705377\n             obj_dir/Reduced,data/full_repos/permissive/187705377.v\n             obj_dir/Reduced,data/full_repos/permissive/187705377.sv\n%Error: Cannot find file containing module: data/full_repos/permissive/187705377/Camera\n%Error: Cannot find file containing module: Reduced/single_frame_trigger.sv\n%Error: Exiting due to 3 error(s)\n'
module single_frame_trigger(
    input logic clk,
    input logic reset,
    input logic trigger,
    input logic VS,
    input logic HS,
    output logic capture
    );
    

    logic VS_old;
    

    enum {S_waiting_for_trigger, S_waiting_for_frame_start, S_in_frame} ns, ps;
    always_comb begin
        case(ps)
        S_waiting_for_trigger: begin
            ns = trigger ? S_waiting_for_frame_start : S_waiting_for_trigger;
            capture = 1'b0;
        end
        S_waiting_for_frame_start: begin
            ns = (!VS_old && VS) ? S_in_frame : S_waiting_for_frame_start;
            capture = 1'b0;
        end
        S_in_frame: begin
            ns = VS ? S_in_frame : S_waiting_for_trigger;
            capture = HS && VS;
        end
        default: begin
            ns = S_waiting_for_trigger;
            capture = 1'b0;
        end
        endcase
    end
    	 
    always_ff @(posedge clk) begin


        VS_old <= VS;


        if(reset)
            ps <= S_waiting_for_trigger;
        else
            ps <= ns;
    end
    
endmodule
module single_frame_trigger(
    input logic clk,
    input logic reset,
    input logic trigger,
    input logic VS,
    input logic HS,
    output logic capture
    );

    

    logic VS_old;
    

    enum {S_waiting_for_trigger, S_waiting_for_frame_start, S_in_frame} ns, ps;
    always_comb begin
        case(ps)
        S_waiting_for_trigger: begin
            ns = trigger ? S_waiting_for_frame_start : S_waiting_for_trigger;
            capture = 1'b0;
        end
        S_waiting_for_frame_start: begin
            ns = (!VS_old && VS) ? S_in_frame : S_waiting_for_frame_start;
            capture = 1'b0;
        end
        S_in_frame: begin
            ns = VS ? S_in_frame : S_waiting_for_trigger;
            capture = HS && VS;
        end
        default: begin
            ns = S_waiting_for_trigger;
            capture = 1'b0;
        end
        endcase
    end
    	 
    always_ff @(posedge clk) begin


        VS_old <= VS;


        if(reset)
            ps <= S_waiting_for_trigger;
        else
            ps <= ns;
    end
    
endmodule