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

Subversion Repositories modular_oscilloscope

[/] [modular_oscilloscope/] [trunk/] [hdl/] [epp/] [eppwbn_pkg.vhd] - Blame information for rev 14

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 11 budinero
--|-----------------------------------------------------------------------------
2
--| UNSL - Modular Oscilloscope
3
--|
4
--| File: eppwbn_wbn_side.vhd
5
--| Version: 0.10
6
--| Targeted device: Actel A3PE1500 
7
--|-----------------------------------------------------------------------------
8
--| Description:
9
--|   EPP - Wishbone bridge. 
10 14 budinero
--|       Package for instantiate all EPP-WBN modules.
11 11 budinero
--------------------------------------------------------------------------------
12
--| File history:
13 14 budinero
--|   0.01  | dic-2008 | First release
14
--|   0.10  | jan-2008 | Added testing memory
15 11 budinero
--------------------------------------------------------------------------------
16 14 budinero
--| Copyright ® 2008, Facundo Aguilera.
17
--|
18
--| This VHDL design file is an open design; you can redistribute it and/or
19
--| modify it and/or implement it after contacting the author.
20 11 budinero
 
21
 
22
-- Bloque completo
23
library IEEE;
24
use IEEE.STD_LOGIC_1164.ALL;
25
 
26
package eppwbn_pgk is
27
        ------------------------------------------------------------------------------
28
        -- Componentes  
29 14 budinero
 
30
  -- Bridge control
31 11 budinero
  component eppwbn_ctrl is
32
    port(
33 14 budinero
      nStrobe:      in std_logic;
34 11 budinero
 
35 14 budinero
      Data:         in std_logic_vector (7 downto 0);
36
      nAck:         out std_logic;
37
      PError:       out std_logic;
38
      Sel:          out std_logic;
39
      nAutoFd:      in std_logic;
40 11 budinero
      PeriphLogicH: out std_logic;
41 14 budinero
      nInit:        in std_logic;
42
      nFault:       out std_logic;
43
      nSelectIn:    in std_logic;
44 11 budinero
 
45 14 budinero
      RST_I:        in std_logic;
46
      CLK_I:        in std_logic;
47 11 budinero
 
48 14 budinero
      rst_pp:       out std_logic;
49
      epp_mode:     out std_logic_vector (1 downto 0)
50 11 budinero
          );
51
        end component eppwbn_ctrl;
52
 
53 14 budinero
  -- Comunication with EPP interface
54 11 budinero
  component eppwbn_epp_side is
55
                port(
56
                        epp_mode: in std_logic_vector (1 downto 0);
57
 
58
                        ctr_nAck, ctr_PError, ctr_Sel, ctr_nFault:   in std_logic;
59
 
60
                        ctr_nAutoFd, ctr_nSelectIn, ctr_nStrobe:    out std_logic;
61
 
62
                        wb_Busy:       in std_logic;
63
                        wb_nAutoFd:    out std_logic;
64
                        wb_nSelectIn:  out std_logic;
65
                        wb_nStrobe:    out std_logic;
66
 
67
                        nAck, PError, Sel, nFault:   out std_logic;
68
 
69
                        Busy:      out std_logic;
70
                        nAutoFd:   in std_logic;
71
                        nSelectIn: in std_logic;
72
                        nStrobe:   in std_logic
73
                );
74
        end component eppwbn_epp_side;
75
 
76 14 budinero
        -- Comunication with WB interface
77
  component eppwbn_wbn_side is
78 11 budinero
                port(
79 14 budinero
                        inStrobe:     in std_logic;
80
                        iData:        inout std_logic_vector (7 downto 0);
81
                        iBusy:        out std_logic;
82
                        inAutoFd:     in std_logic;
83
                        inSelectIn:   in std_logic;
84 11 budinero
 
85
                        RST_I, CLK_I: in std_logic;
86 14 budinero
                        DAT_I:        in std_logic_vector (7 downto 0);
87
                        DAT_O:        out std_logic_vector (7 downto 0);
88
                        ADR_O:        out std_logic_vector (7 downto 0);
89 11 budinero
                        CYC_O, STB_O: out std_logic;
90 14 budinero
                        ACK_I:        in std_logic ;
91
                        WE_O:         out std_logic;
92 11 budinero
 
93 14 budinero
                        rst_pp:       in std_logic
94 11 budinero
                );
95
        end component eppwbn_wbn_side;
96
 
97 14 budinero
        -- Testing memory
98
  component mem_8bit_reset is
99
    generic ( --USE_RESET   : boolean   := false;  -- use system reset
100
 
101
              --USE_CS      : boolean   := false;  -- use chip select signal
102
 
103
              DEFAULT_OUT : std_logic := '0';  -- Default output
104
              --OPTION      : integer   := 1;  -- 1: Registered read Address(suitable
105
                                          -- for Altera's FPGAs
106
                                          -- 0: non registered read address
107
              ADD_WIDTH   : integer   := 8;
108
              WIDTH       : integer   := 8);
109
 
110
    port (
111
      cs       : in  std_logic;           -- chip select
112
      clk      : in  std_logic;           -- write clock
113
      reset    : in  std_logic;           -- System Reset
114
      add      : in  std_logic_vector(add_width -1 downto 0);   --  Address
115
      Data_In  : in  std_logic_vector(WIDTH -1 downto 0);       -- input data
116
      Data_Out : out std_logic_vector(WIDTH -1 downto 0);       -- Output Data
117
      WR       : in  std_logic);          -- Read Write Enable
118
  end component mem_8bit_reset;
119
 
120
  component eppwbn is
121
    port(
122
      -- Externo
123
      nStrobe:  in std_logic;                                                                                   -- Nomenclatura IEEE Std. 1284 
124
                                                  -- HostClk/nWrite 
125
      Data:     inout std_logic_vector (7 downto 0);     -- AD8..1 (Data1..Data8)
126
      nAck:     out std_logic;                                                                                          --  PtrClk/PeriphClk/Intr
127
      busy:     out std_logic;                                                                                          --  PtrBusy/PeriphAck/nWait
128
      PError:   out std_logic;                                                                                  --  AckData/nAckReverse
129
      Sel:      out std_logic;                                                                                          --  XFlag (Select)
130
      nAutoFd:  in std_logic;                                                                                   --  HostBusy/HostAck/nDStrb
131
      PeriphLogicH: out std_logic;                                                              --  (Periph Logic High)
132
      nInit:    in std_logic;                                                                                           --  nReverseRequest
133
      nFault:   out std_logic;                                                                                  --  nDataAvail/nPeriphRequest
134
      nSelectIn: in std_logic;                                                                          --  1284 Active/nAStrb
135
 
136
      --  Interno
137
      RST_I:  in std_logic;
138
      CLK_I:  in std_logic;
139
      DAT_I:  in std_logic_vector (7 downto 0);
140
      DAT_O:  out std_logic_vector (7 downto 0);
141
      ADR_O:  out std_logic_vector (7 downto 0);
142
      CYC_O:  out std_logic;
143
      STB_O:  out std_logic;
144
      ACK_I:  in std_logic ;
145
      WE_O:   out std_logic
146
      );
147
  end component eppwbn;
148
 
149 11 budinero
 
150
end package eppwbn_pgk;
151
 

powered by: WebSVN 2.1.0

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