OpenCores
URL https://opencores.org/ocsvn/openhmc/openhmc/trunk

Subversion Repositories openhmc

[/] [openhmc/] [trunk/] [openHMC/] [rtl/] [hmc_controller/] [tx/] [tx_run_length_limiter.v] - Diff between revs 11 and 15

Show entire file | Details | Blame | View Log

Rev 11 Rev 15
Line 130... Line 130...
assign bit_flip = count_top > (RUN_LIMIT - (GRANULARITY-1) - (REM_BITS ? REM_BITS-1 : GRANULARITY-1));
assign bit_flip = count_top > (RUN_LIMIT - (GRANULARITY-1) - (REM_BITS ? REM_BITS-1 : GRANULARITY-1));
 
 
`ifdef ASYNC_RES
`ifdef ASYNC_RES
always @(posedge clk or negedge res_n)  begin `else
always @(posedge clk or negedge res_n)  begin `else
always @(posedge clk)  begin `endif
always @(posedge clk)  begin `endif
 
 
 
    `ifdef RESET_ALL
 
        if(!res_n) begin
 
            data_out <= {DWIDTH {1'b0}};
 
        end else
 
    `endif
 
    begin
 
        if (enable && bit_flip) begin
 
            data_out    <= {data_in[LANE_WIDTH-1:1], ~data_in[0]};
 
        end else begin
 
            data_out    <= data_in;
 
        end
 
    end
    if (!res_n) begin
    if (!res_n) begin
        count_bottom_d1   <= { COUNT_BITS {1'b0}};
        count_bottom_d1   <= { COUNT_BITS {1'b0}};
        no_flip_bottom_d1 <= 1'b0;
        no_flip_bottom_d1 <= 1'b0;
        data_in_bottom_d1 <= 1'b0;
        data_in_bottom_d1 <= 1'b0;
        rf_bit_flip       <= 1'b0;
        rf_bit_flip       <= 1'b0;
        data_out          <= {LANE_WIDTH{1'b0}};
 
    end else begin
    end else begin
        count_bottom_d1   <= count_bottom;
        count_bottom_d1   <= count_bottom;
        no_flip_bottom_d1 <= no_flip[NUM_CHUNKS-1];
        no_flip_bottom_d1 <= no_flip[NUM_CHUNKS-1];
        data_in_bottom_d1 <= data_in[LANE_WIDTH-1];
        data_in_bottom_d1 <= data_in[LANE_WIDTH-1];
 
 
        if (enable && bit_flip) begin
        if (enable && bit_flip) begin
            data_out    <= {data_in[LANE_WIDTH-1:1], ~data_in[0]};
 
            rf_bit_flip <= bit_flip;
            rf_bit_flip <= bit_flip;
        end else begin
 
            data_out    <= data_in;
 
        end
        end
    end
    end
end
end
 
 
endmodule
endmodule

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.