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

Subversion Repositories funbase_ip_library

[/] [funbase_ip_library/] [trunk/] [TUT/] [ip.hwp.storage/] [fifos/] [synchronizer/] [1.0/] [vhd/] [aif_we_top.vhd] - Blame information for rev 145

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 145 lanttu
-------------------------------------------------------------------------------
2
-- Title      : 
3
-- Project    : 
4
-------------------------------------------------------------------------------
5
-- File       : 
6
-- Author     : 
7
-- Created    : 04.01.2006
8
-- Last update: 24.02.2006
9
-- Description: 
10
-------------------------------------------------------------------------------
11
-- Copyright (c) 2006 
12
-------------------------------------------------------------------------------
13
-- Revisions  :
14
-- Date        Version  Author  Description
15
-- 04.01.2006  1.0      AK      Created
16
-------------------------------------------------------------------------------
17
 
18
library ieee;
19
use ieee.std_logic_1164.all;
20
use ieee.std_logic_arith.all;
21
use ieee.std_logic_unsigned.all;
22
-------------------------------------------------------------------------------
23
 
24
entity aif_we_top is
25
  generic (
26
    data_width_g : integer := 32
27
    );
28
  port (
29
    tx_clk      : in  std_logic;
30
    tx_rst_n    : in  std_logic;
31
    tx_we_in    : in  std_logic;
32
    tx_data_in  : in  std_logic_vector(data_width_g-1 downto 0);
33
    tx_full_out : out std_logic;
34
 
35
    rx_clk     : in  std_logic;
36
    rx_rst_n   : in  std_logic;
37
    rx_full_in : in  std_logic;
38
    rx_we_out  : out std_logic;
39
    rx_data_out   : out std_logic_vector(data_width_g-1 downto 0)
40
 
41
    );
42
 
43
end aif_we_top;
44
 
45
-------------------------------------------------------------------------------
46
 
47
architecture structural of aif_we_top is
48
 
49
  component aif_we_out
50
    generic (
51
      data_width_g : integer := 32
52
      );
53
    port (
54
      clk      : in  std_logic;
55
      rst_n    : in  std_logic;
56
      a_we_in  : in  std_logic;
57
      ack_out  : out std_logic;
58
      we_out   : out std_logic;
59
      data_in  : in  std_logic_vector(data_width_g-1 downto 0);
60
      data_out : out std_logic_vector(data_width_g-1 downto 0);
61
      full_in  : in  std_logic);
62
  end component;
63
 
64
  -- component ports
65
  signal ack_from_rx  : std_logic;
66
--  signal we_from_rx   : std_logic;
67
--  signal data_from_rx : std_logic_vector(data_width_g-1 downto 0);
68
 
69
  component aif_we_in
70
    generic (
71
      data_width_g : integer);
72
    port (
73
      clk      : in  std_logic;
74
      rst_n    : in  std_logic;
75
      we_in    : in  std_logic;
76
      data_in  : in  std_logic_vector(data_width_g-1 downto 0);
77
      data_out : out std_logic_vector(data_width_g-1 downto 0);
78
      full_out : out std_logic;
79
      a_we_out : out std_logic;
80
      ack_in   : in  std_logic
81
      );
82
  end component;
83
 
84
  signal data_from_tx : std_logic_vector(data_width_g-1 downto 0);
85
--  signal full_from_tx : std_logic;
86
  signal a_we_from_tx : std_logic;
87
 
88
begin  -- structural
89
 
90
  -- component instantiation
91
  DUT : aif_we_out
92
    generic map (
93
      data_width_g => data_width_g)
94
    port map (
95
      clk      => rx_clk,
96
      rst_n    => rx_rst_n,
97
      a_we_in  => a_we_from_tx,
98
      ack_out  => ack_from_rx,
99
      data_in  => data_from_tx,
100
      data_out => rx_data_out,
101
      we_out   => rx_we_out,
102
      full_in  => rx_full_in
103
      );
104
 
105
  asynch_if_tx_1 : aif_we_in
106
    generic map (
107
      data_width_g => data_width_g)
108
    port map (
109
      clk      => tx_clk,
110
      rst_n    => tx_rst_n,
111
      we_in    => tx_we_in,
112
      data_in  => tx_data_in,
113
      data_out => data_from_tx,
114
      full_out => tx_full_out,
115
      a_we_out => a_we_from_tx,
116
      ack_in   => ack_from_rx
117
      );
118
 
119
 
120
end structural;
121
 
122
-------------------------------------------------------------------------------

powered by: WebSVN 2.1.0

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