📄 dcm_dsgn.vhd
字号:
library IEEE;use IEEE.STD_LOGIC_1164.ALL;use IEEE.STD_LOGIC_ARITH.ALL;use IEEE.STD_LOGIC_UNSIGNED.ALL;-- FILL IN LIBRARY STATEMENTS HERE
Library UNISIM;use UNISIM.vcomponents.all;entity dcm_dsgn is Port ( clk_33 : in std_logic; clk_25 : in std_logic; reset : in std_logic; dcm_reset : in std_logic; dcm_lock : out std_logic; din_clk33 : in std_logic; din_clk25 : in std_logic; dout_clk33 : out std_logic; dout_clk25 : out std_logic; pot_bist : in std_logic);end dcm_dsgn;
architecture Behavioral of dcm_dsgn is-- The following clocks are the output clocks from the DCMssignal clk_33to25_dcm, clk_25_dcm : std_logic;-- The following clocks are the output clocks from the BUFG and BUFGMUXsignal clk_33_buf, clk_25_buf : std_logic;signal d0_clk33, d0_clk25, d1_clk33, d1_clk25 : std_logic;-- FILL IN COMPONENT DECLARATIONS HERE
COMPONENT dcm_33 PORT( CLKIN_IN : IN std_logic; CLKIN_IBUFG_OUT : OUT std_logic; clk_33to25_dcm : OUT std_logic; CLK0_OUT : OUT std_logic );END COMPONENT;
COMPONENT dcm_25 PORT( CLKIN_IN : IN std_logic; RST_IN : IN std_logic; CLKIN_IBUFG_OUT : OUT std_logic; clk_25_dcm : OUT std_logic; LOCKED_OUT : OUT std_logic );
END COMPONENT;
begin-- DCM and BUFGMUX instantiations-- FILL IN COMPONENT INSTANTIATIONS HERE
Inst_dcm_33: dcm_33 PORT MAP( CLKIN_IN => clk_33, CLKIN_IBUFG_OUT => open, clk_33to25_dcm => clk_33to25_dcm, CLK0_OUT => clk_33_buf );
Inst_dcm_25: dcm_25 PORT MAP( CLKIN_IN => clk_25, RST_IN => dcm_reset, CLKIN_IBUFG_OUT => open, clk_25_dcm => clk_25_dcm, LOCKED_OUT => dcm_lock );
BUFGMUX_inst : BUFGMUX port map ( O => clk_25_buf, -- Clock MUX output I0 => clk_25_dcm, -- Clock0 input I1 => clk_33to25_dcm, -- Clock1 input S => pot_bist -- Clock select input );
-- Dummy registers on each clock networkprocess (clk_33_buf, reset)begin if (reset = '1') then d0_clk33 <= '0'; d1_clk33 <= '0'; dout_clk33 <= '0'; elsif (clk_33_buf'event and clk_33_buf = '1') then d0_clk33 <= din_clk33; d1_clk33 <= d0_clk33; dout_clk33 <= d1_clk33; end if;end process;process (clk_25_buf, reset)begin if (reset = '1') then d0_clk25 <= '0'; d1_clk25 <= '0'; dout_clk25 <= '0'; elsif (clk_25_buf'event and clk_25_buf = '1') then d0_clk25 <= din_clk25; d1_clk25 <= d0_clk25; dout_clk25 <= d1_clk25; end if;end process;end Behavioral;
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -