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

Subversion Repositories plb2wbbridge

[/] [plb2wbbridge/] [trunk/] [systems/] [EDK_Libs/] [WishboneIPLib/] [pcores/] [plb2wb_bridge_v1_00_a/] [hdl/] [vhdl/] [plb2wb_rbuf.vhd] - Blame information for rev 2

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 2 feddischso
----------------------------------------------------------------------
2
----                                                              ----
3
----  PLB2WB-Bridge                                               ----
4
----                                                              ----
5
----  This file is part of the PLB-to-WB-Bridge project           ----
6
----  http://opencores.org/project,plb2wbbridge                   ----
7
----                                                              ----
8
----  Description                                                 ----
9
----  Implementation of a PLB-to-WB-Bridge according to           ----
10
----  PLB-to-WB Bridge specification document.                    ----
11
----                                                              ----
12
----  To Do:                                                      ----
13
----   Nothing                                                    ----
14
----                                                              ----
15
----  Author(s):                                                  ----
16
----      - Christian Haettich                                    ----
17
----        feddischson@opencores.org                             ----
18
----                                                              ----
19
----------------------------------------------------------------------
20
----                                                              ----
21
---- Copyright (C) 2010 Authors                                   ----
22
----                                                              ----
23
---- This source file may be used and distributed without         ----
24
---- restriction provided that this copyright statement is not    ----
25
---- removed from the file and that any derivative work contains  ----
26
---- the original copyright notice and the associated disclaimer. ----
27
----                                                              ----
28
---- This source file is free software; you can redistribute it   ----
29
---- and/or modify it under the terms of the GNU Lesser General   ----
30
---- Public License as published by the Free Software Foundation; ----
31
---- either version 2.1 of the License, or (at your option) any   ----
32
---- later version.                                               ----
33
----                                                              ----
34
---- This source is distributed in the hope that it will be       ----
35
---- useful, but WITHOUT ANY WARRANTY; without even the implied   ----
36
---- warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR      ----
37
---- PURPOSE.  See the GNU Lesser General Public License for more ----
38
---- details.                                                     ----
39
----                                                              ----
40
---- You should have received a copy of the GNU Lesser General    ----
41
---- Public License along with this source; if not, download it   ----
42
---- from http://www.opencores.org/lgpl.shtml                     ----
43
----                                                              ----
44
----------------------------------------------------------------------
45
 
46
 
47
library ieee;
48
use ieee.std_logic_1164.all;
49
use ieee.numeric_std.all;
50
use ieee.std_logic_unsigned.all;
51
 
52
library plb2wb_bridge_v1_00_a;
53
 
54
 
55
 
56
 
57
entity plb2wb_rbuf is
58
   generic(
59
      SYNCHRONY                     : boolean := true;
60
      WB_DWIDTH                     : integer := 32
61
   );
62
   port(
63
 
64
      wb_clk_i                      : IN  std_logic;
65
      SPLB_Clk                      : IN  std_logic;
66
      plb2wb_rst                      : IN  std_logic;
67
 
68
      wb_dat_i                      : IN  std_logic_vector( WB_DWIDTH-1 downto 0 );
69
 
70
      RBF_rBus                      : out std_logic_vector( WB_DWIDTH-1 downto 0 );
71
      RBF_empty                     : out std_logic;
72
      RBF_almostEmpty               : out std_logic;
73
      RBF_full                      : out std_logic;
74
 
75
      RBF_rdErrOut                  : out std_logic;
76
      RBF_rdErrIn                   : in  std_logic;
77
 
78
      TCU_rbufWEn                   : in  std_logic;
79
      TCU_rbufREn                   : in  std_logic
80
   );
81
end entity plb2wb_rbuf;
82
 
83
 
84
 
85
architecture IMP_32 of plb2wb_rbuf is
86
 
87
 
88
   signal rbuf_dout     : std_logic_vector( WB_DWIDTH+1-1 downto 0 );
89
   signal rbuf_din      : std_logic_vector( WB_DWIDTH+1-1 downto 0 );
90
   signal pre_load_reg  : std_logic_vector( WB_DWIDTH+1-1 downto 0 );
91
   signal rd_en         : std_logic;
92
begin
93
 
94
 
95
   rbuf_din <= RBF_rdErrIn & wb_dat_i;
96
 
97
   rd_en          <= TCU_rbufREn;
98
   RBF_rBus       <= rbuf_dout( WB_DWIDTH-1 downto 0 );
99
 
100
   RBF_rdErrOut   <= rbuf_dout(32);
101
 
102
 
103
 
104
   rbuf : entity plb2wb_bridge_v1_00_a.fifo_rdat( IMP )
105
   generic map(
106
      SYNCHRONY      => SYNCHRONY,
107
      WB_DWIDTH      => WB_DWIDTH
108
   )
109
   port map(
110
      rd_en          => rd_en,
111
      wr_en          => TCU_rbufWEn,
112
      full           => RBF_full,
113
      empty          => RBF_empty,
114
      almost_empty   => RBF_almostEmpty,
115
      wr_clk         => wb_clk_i,
116
      rst            => plb2wb_rst,
117
      rd_clk         => SPLB_Clk,
118
      dout           => rbuf_dout,
119
      din            => rbuf_din
120
   );
121
 
122
 
123
 
124
 
125
end architecture IMP_32;
126
 

powered by: WebSVN 2.1.0

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