Current location - Trademark Inquiry Complete Network - Tian Tian Fund - Quartus counter and frequency divider program
Quartus counter and frequency divider program
Write according to this, this is a frequency division procedure I often use, 50 frequency division, please adopt it.

Process (clock)

Variable count: natural range 0 to 24: = 24;

begin

If the clk event and clk =' 1', then

If count =24, then

Count: = 0;

Scl<= not SCL.

other

Count: = Count+1;

End if;

End if;

End the process;