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

Subversion Repositories w11

[/] [w11/] [tags/] [w11a_V0.61/] [rtl/] [sys_gen/] [tst_snhumanio/] [nexys3/] [sys_tst_snhumanio_n3.vhd] - Blame information for rev 40

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

Line No. Rev Author Line
1 15 wfjm
-- $Id: sys_tst_snhumanio_n3.vhd 433 2011-11-27 22:04:39Z mueller $
2
--
3
-- Copyright 2011- 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:    sys_tst_snhumanio_n3 - syn
16
-- Description:    snhumanio tester design for nexys3
17
--
18
-- Dependencies:   vlib/genlib/clkdivce
19
--                 bplib/bpgen/sn_humanio
20
--                 tst_snhumanio
21
--                 vlib/nxcramlib/nx_cram_dummy
22
--
23
-- Test bench:     -
24
--
25
-- Target Devices: generic
26
-- Tool versions:  xst 13.1; ghdl 0.29
27
--
28
-- Synthesized (xst):
29
-- Date         Rev  ise         Target      flop lutl lutm slic t peri
30
-- 2011-11-27   433 13.1    O40d xc3s1200e-4  151  195    -   65 t  6.1
31
--
32
-- Revision History: 
33
-- Date         Rev Version  Comment
34
-- 2011-11-27   433   1.0    Initial version
35
------------------------------------------------------------------------------
36
-- Usage of Nexys 2 Switches, Buttons, LEDs:
37
--
38
 
39
library ieee;
40
use ieee.std_logic_1164.all;
41
 
42
use work.slvtypes.all;
43
use work.genlib.all;
44
use work.bpgenlib.all;
45
use work.nxcramlib.all;
46
use work.sys_conf.all;
47
 
48
-- ----------------------------------------------------------------------------
49
 
50
entity sys_tst_snhumanio_n3 is          -- top level
51
                                        -- implements nexys3_aif
52
  port (
53
    I_CLK100 : in slbit;                -- 100  MHz clock
54
    I_RXD : in slbit;                   -- receive data (board view)
55
    O_TXD : out slbit;                  -- transmit data (board view)
56
    I_SWI : in slv8;                    -- n3 switches
57
    I_BTN : in slv5;                    -- n3 buttons
58
    O_LED : out slv8;                   -- n3 leds
59
    O_ANO_N : out slv4;                 -- 7 segment disp: anodes   (act.low)
60
    O_SEG_N : out slv8;                 -- 7 segment disp: segments (act.low)
61
    O_MEM_CE_N : out slbit;             -- cram: chip enable   (act.low)
62
    O_MEM_BE_N : out slv2;              -- cram: byte enables  (act.low)
63
    O_MEM_WE_N : out slbit;             -- cram: write enable  (act.low)
64
    O_MEM_OE_N : out slbit;             -- cram: output enable (act.low)
65
    O_MEM_ADV_N  : out slbit;           -- cram: address valid (act.low)
66
    O_MEM_CLK : out slbit;              -- cram: clock
67
    O_MEM_CRE : out slbit;              -- cram: command register enable
68
    I_MEM_WAIT : in slbit;              -- cram: mem wait
69
    O_MEM_ADDR  : out slv23;            -- cram: address lines
70
    IO_MEM_DATA : inout slv16;          -- cram: data lines
71
    O_PPCM_CE_N : out slbit;            -- ppcm: ...
72
    O_PPCM_RST_N : out slbit            -- ppcm: ...
73
  );
74
end sys_tst_snhumanio_n3;
75
 
76
architecture syn of sys_tst_snhumanio_n3 is
77
 
78
  signal CLK :   slbit := '0';
79
 
80
  signal SWI     : slv8  := (others=>'0');
81
  signal BTN     : slv5  := (others=>'0');
82
  signal LED     : slv8  := (others=>'0');
83
  signal DSP_DAT : slv16 := (others=>'0');
84
  signal DSP_DP  : slv4  := (others=>'0');
85
 
86
  signal RESET   : slbit := '0';
87
  signal CE_MSEC : slbit := '0';
88
 
89
begin
90
 
91
  RESET <= '0';                         -- so far not used
92
 
93
  CLK <= I_CLK100;
94
 
95
  CLKDIV : clkdivce
96
    generic map (
97
      CDUWIDTH => 7,
98
      USECDIV  => 100,
99
      MSECDIV  => 1000)
100
    port map (
101
      CLK     => CLK,
102
      CE_USEC => open,
103
      CE_MSEC => CE_MSEC
104
    );
105
 
106
  HIO : sn_humanio
107
    generic map (
108
      BWIDTH   => 5,
109
      DEBOUNCE => sys_conf_hio_debounce)
110
    port map (
111
      CLK     => CLK,
112
      RESET   => RESET,
113
      CE_MSEC => CE_MSEC,
114
      SWI     => SWI,
115
      BTN     => BTN,
116
      LED     => LED,
117
      DSP_DAT => DSP_DAT,
118
      DSP_DP  => DSP_DP,
119
      I_SWI   => I_SWI,
120
      I_BTN   => I_BTN,
121
      O_LED   => O_LED,
122
      O_ANO_N => O_ANO_N,
123
      O_SEG_N => O_SEG_N
124
    );
125
 
126
  HIOTEST : entity work.tst_snhumanio
127
    generic map (
128
      BWIDTH => 5)
129
    port map (
130
      CLK     => CLK,
131
      RESET   => RESET,
132
      CE_MSEC => CE_MSEC,
133
      SWI     => SWI,
134
      BTN     => BTN,
135
      LED     => LED,
136
      DSP_DAT => DSP_DAT,
137
      DSP_DP  => DSP_DP
138
    );
139
 
140
  O_TXD <= I_RXD;
141
 
142
  SRAM_PROT : nx_cram_dummy            -- connect CRAM to protection dummy
143
    port map (
144
      O_MEM_CE_N  => O_MEM_CE_N,
145
      O_MEM_BE_N  => O_MEM_BE_N,
146
      O_MEM_WE_N  => O_MEM_WE_N,
147
      O_MEM_OE_N  => O_MEM_OE_N,
148
      O_MEM_ADV_N => O_MEM_ADV_N,
149
      O_MEM_CLK   => O_MEM_CLK,
150
      O_MEM_CRE   => O_MEM_CRE,
151
      I_MEM_WAIT  => I_MEM_WAIT,
152
      O_MEM_ADDR  => O_MEM_ADDR,
153
      IO_MEM_DATA => IO_MEM_DATA
154
    );
155
 
156
  O_PPCM_CE_N  <= '1';                  -- keep parallel PCM memory disabled
157
  O_PPCM_RST_N <= '1';                  --
158
 
159
end syn;

powered by: WebSVN 2.1.0

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