data/full_repos/permissive/146618947/gray_tarea8/contador_gray_cond.v
data/verilator_xmls/005cdd78-e832-4a9f-8afa-c8d03386bdb7.xml
module contador_gray_cond (
                           input        clk,
                           input        reset_L,
                           input        enable,
                           output [4:0] data_out
                           );

   reg [4:0]                                count;

   always @ (posedge clk) begin
     if (!reset_L) begin
       count <= 0;
     end else if (enable) begin
       count <= count + 1;
     end
   end

   assign data_out = { count[4],
                       (count[4] ^ count[3]),
                       (count[3] ^ count[2]),
                       (count[2] ^ count[1]),
                       (count[1] ^ count[0]) };
endmodule
module contador_gray_cond (
                           input        clk,
                           input        reset_L,
                           input        enable,
                           output [4:0] data_out
                           );


   reg [4:0]                                count;

   always @ (posedge clk) begin
     if (!reset_L) begin
       count <= 0;
     end else if (enable) begin
       count <= count + 1;
     end
   end

   assign data_out = { count[4],
                       (count[4] ^ count[3]),
                       (count[3] ^ count[2]),
                       (count[2] ^ count[1]),
                       (count[1] ^ count[0]) };
endmodule