OpenCores
URL https://opencores.org/ocsvn/w11/w11/trunk

Subversion Repositories w11

[/] [w11/] [tags/] [w11a_V0.6/] [rtl/] [vlib/] [xlib/] [iob_reg_o_gen.vhd] - Blame information for rev 24

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 13 wfjm
-- $Id: iob_reg_o_gen.vhd 426 2011-11-18 18:14:08Z mueller $
2 2 wfjm
--
3
-- Copyright 2007- by Walter F.J. Mueller <W.F.J.Mueller@gsi.de>
4
--
5
-- This program is free software; you may redistribute and/or modify it under
6
-- the terms of the GNU General Public License as published by the Free
7
-- Software Foundation, either version 2, or at your option any later version.
8
--
9
-- This program is distributed in the hope that it will be useful, but
10
-- WITHOUT ANY WARRANTY, without even the implied warranty of MERCHANTABILITY
11
-- or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
12
-- for complete details.
13
--
14
------------------------------------------------------------------------------
15
-- Module Name:    iob_reg_o_gen - syn
16
-- Description:    Registered IOB, output only, vector
17
--
18
-- Dependencies:   -
19
-- Test bench:     -
20
-- Target Devices: generic Spartan, Virtex
21
-- Tool versions:  xst 8.1, 8.2, 9.1, 9.2; ghdl 0.18-0.25
22
-- Revision History: 
23
-- Date         Rev Version  Comment
24
-- 2007-12-16   101   1.0.1  add INIT generic port
25
-- 2007-12-08   100   1.0    Initial version 
26
------------------------------------------------------------------------------
27
 
28
library ieee;
29
use ieee.std_logic_1164.all;
30
 
31
use work.slvtypes.all;
32
use work.xlib.all;
33
 
34
entity iob_reg_o_gen is                 -- registered IOB, output, vector
35
  generic (
36
    DWIDTH : positive := 16;            -- data port width
37
    INIT : slbit := '0');               -- initial state
38
  port (
39
    CLK  : in slbit;                    -- clock
40
    CE   : in slbit := '1';             -- clock enable
41
    DO   : in slv(DWIDTH-1 downto 0);   -- output data
42
    PAD  : out slv(DWIDTH-1 downto 0)   -- i/o pad
43
  );
44
end iob_reg_o_gen;
45
 
46
 
47
architecture syn of iob_reg_o_gen is
48
 
49
  signal R_DO  : slv(DWIDTH-1 downto 0) := (others=>INIT);
50
 
51
  attribute iob : string;
52
  attribute iob of R_DO : signal is "true";
53
 
54
begin
55
 
56
  proc_regs: process (CLK)
57
  begin
58 13 wfjm
    if rising_edge(CLK) then
59 2 wfjm
      if CE = '1' then
60
        R_DO <= DO;
61
      end if;
62
    end if;
63
  end process proc_regs;
64
 
65
  PAD <= R_DO;
66
 
67
end syn;

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.