Published in: VHDL
Slow the clock to 1 dHz.
library ieee; use ieee.std_logic_1164.all; use ieee.std_logic_unsigned.all; entity divider160m is port( clk : in std_logic; clkout : out std_logic ); end divider160m; architecture main of divider160m is signal cnt: std_logic_vector(27 downto 0); begin process(clk) begin if(clk'event and clk = '1') then if cnt = 159999999 then cnt <= (others => '0'); else cnt <= cnt + 1; end if; end if; clkout <= cnt(27); end process; end main;
Comments
Subscribe to comments
- Posted By: Sadiq_meman on May 10, 2008
- Posted By: Sadiq_meman on May 10, 2008
You need to login to post a comment.
