![]() |
|
![]() |
|
Answers Database
Foundation F1.3/F1.4 XVHDL: Using Input/Output latches
Record #2962
Product Family: Software component ILD -- component declaration port (D: in STD_LOGIC; G: in STD_LOGIC; Q: out STD_LOGIC); end component; begin U1: ILD port map (d_in, g_in, q_out); --instantiation end in_lat_arch; Solution 2: For XC4000EX/XL devices, the i/o latch may be instantiated as described in resolution #1, OR, the latch may be behaviorally described in the VHDL code. If the latch is behaviorally described, the XVHDL compiler will infer a regular CLB latch, but the MAP phase of the implementation flow has the capability to then merge the latch into the IOB. If this method of implementation is desired, one of the following MAP options must be used when implementing the design with the Xilinx Design Manager: MAP -pr i <indicates merging into "input" latches> MAP -pr o <indicates merging into "output" latches> MAP -pr b <indicates merging into "input" or "output latches> To tell MAP to run with this command-line switch, use the Template Manager to "customize" the Implementation Template. For detailed instructions on how to do this, refer to (Xilinx Solution 1227). Below is an example of VHDL code which would infer a latch which could then be merged into an IOB by MAP: --The IEEE standard 1164 package, daclares std_logic, rising_edge(), etc. library IEEE; use IEEE.std_logic_1164.all; entity d_latch is port (GATE, DATA: in std_logic; Q: out std_logic); end d_latch; architecture BEHAV of d_latch is begin process (GATE, DATA) begin if (GATE ='1') then Q <= DATA; end if; end process; end BEHAV; End of Record #2962 - Last Modified: 01/03/00 11:02 |
| For the latest news, design tips, and patch information on the Xilinx design environment, check out the Technical Tips! |