![]() |
|
![]() |
|
Answers Database
SYNPLIFY: How to use OSC5, OSC52, and CK_DIV cells for the XC5200 in HDL?
Record #3584
Product Family: Software module BUFG (O, I) /* synthesis black_box */; output O; input I; endmodule Solution 2: library IEEE; use IEEE.std_logic_1164.all; use IEEE.std_logic_unsigned.all; entity osc5_ex is port ( A : in STD_LOGIC_VECTOR (1 downto 0); Q : out STD_LOGIC_VECTOR (1 downto 0) ); end osc5_ex; architecture xilinx of osc5_ex is attribute black_box : boolean; attribute xc_props: string; component OSC5 port ( OSC1, OSC2 : out STD_LOGIC); end component; attribute xc_props of OSC5 : component is "DIVIDE1_BY=4,DIVIDE2_BY=2"; attribute black_box of OSC5 : component is true; component BUFG port( O : out STD_LOGIC; I : in STD_LOGIC); end component; attribute black_box of BUFG : component is true; signal clk1_in, clk1_out : STD_LOGIC; signal clk2_in, clk2_out : STD_LOGIC; begin U0: BUFG port map (I => clk1_in, O => clk1_out); U1: BUFG port map (I => clk2_in, O => clk2_out); U2: OSC5 port map (OSC1 => clk1_in, OSC2 => clk2_in); process (clk1_out) begin if (clk1_out'event and clk1_out = '1') then Q(0) <= A(0); end if; end process; process (clk2_out) begin if (clk2_out'event and clk2_out = '1') then Q(1) <= A(1); end if; end process; end xilinx; End of Record #3584 - Last Modified: 05/25/99 09:39 |
| For the latest news, design tips, and patch information on the Xilinx design environment, check out the Technical Tips! |