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

Subversion Repositories freq_div

[/] [freq_div/] [trunk/] [rtl/] [divider.v] - Diff between revs 2 and 3

Go to most recent revision | Show entire file | Details | Blame | View Log

Rev 2 Rev 3
Line 9... Line 9...
        output out;
        output out;
 
 
        wire out_odd;
        wire out_odd;
        wire out_even;
        wire out_even;
        wire not_zero;
        wire not_zero;
 
        wire enable_even;
 
        wire enable_odd;
 
 
        assign not_zero = | P[`SIZE-1:1];
        assign not_zero = | P[`SIZE-1:1];
 
 
        assign out = (out_odd & P[0] & not_zero) | (out_even & !P[0]);
        assign out = (out_odd & P[0] & not_zero) | (out_even & !P[0]);
 
        //assign out = out_odd | out_even;
 
        assign enable_odd = P[0] & not_zero;
 
        assign enable_even = !P[0];
 
 
        even even_0(in, out_even, P, reset, not_zero);
        even even_0(in, out_even, P, reset, not_zero, enable_even);
        odd odd_0(in, out_odd, P, reset);
        odd odd_0(in, out_odd, P, reset, enable_odd);
 
 
endmodule //divider
endmodule //divider
 
 
 No newline at end of file
 No newline at end of file

powered by: WebSVN 2.1.0

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