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

Subversion Repositories w11

[/] [w11/] [tags/] [w11a_V0.74/] [rtl/] [vlib/] [rlink/] [tb/] [tbu_rlink_sp1c.vhd] - Blame information for rev 38

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 30 wfjm
-- $Id: tbu_rlink_sp1c.vhd 666 2015-04-12 21:17:54Z mueller $
2 2 wfjm
--
3 30 wfjm
-- Copyright 2007-2015 by Walter F.J. Mueller <W.F.J.Mueller@gsi.de>
4 2 wfjm
--
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 16 wfjm
-- Module Name:    tbu_rlink_sp1c - syn
16
-- Description:    Wrapper for rlink_sp1c to avoid records.
17 9 wfjm
--                 It has a port interface which will not be modified by xst
18 2 wfjm
--                 synthesis (no records, no generic port).
19
--
20 16 wfjm
-- Dependencies:   rlink_sp1c
21 2 wfjm
--
22 16 wfjm
-- To test:        rlink_sp1c
23 2 wfjm
--
24
-- Target Devices: generic
25
--
26
-- Synthesized (xst):
27
-- Date         Rev  ise         Target      flop lutl lutm slic t peri
28 16 wfjm
-- 2011-12-22   442  13.1   O40d xc3s1000-4   348  704   64  473 s 9.08
29 2 wfjm
-- 2010-04-03   274  11.4   L68  xc3s1000-4   278  588   18  366 s 9.83
30
-- 2007-10-27    92  9.2.02 J39  xc3s1000-4   273  547   18    - t 9.65
31
-- 2007-10-27    92  9.1    J30  xc3s1000-4   273  545   18    - t 9.65
32
-- 2007-10-27    92  8.2.03 I34  xc3s1000-4   283  594   18  323 s 10.3
33
-- 2007-10-27    92  8.1.03 I27  xc3s1000-4   285  596   18    - s 9.32
34
--
35 27 wfjm
-- Tool versions:  xst 8.2-14.7; ghdl 0.18-0.31
36 9 wfjm
--
37 2 wfjm
-- Revision History: 
38
-- Date         Rev Version  Comment
39 30 wfjm
-- 2015-04-11   666   4.1    rename ENAESC->ESCFILL
40 27 wfjm
-- 2014-08-31   590   4.0    now full rlink v4 iface, 4 bit STAT
41
-- 2014-08-15   583   3.5    rb_mreq addr now 16 bit
42 16 wfjm
-- 2011-12-22   442   3.2    renamed and retargeted to test rlink_sp1c
43 13 wfjm
-- 2011-11-19   427   3.1.2  now numeric_std clean
44 9 wfjm
-- 2010-12-28   350   3.1.1  use CLKDIV/CDINIT=0;
45
-- 2010-12-26   348   3.1    use rlink_base now; add RTS/CTS ports
46
-- 2010-12-24   347   3.0.1  rename: CP_*->RL->*
47
-- 2010-12-05   343   3.0    rri->rlink renames; port to rbus V3 protocol;
48 2 wfjm
-- 2010-06-03   300   2.2.3  use default FAWIDTH for rri_core_serport
49
-- 2010-05-02   287   2.2.2  ren CE_XSEC->CE_INT,RP_STAT->RB_STAT,AP_LAM->RB_LAM
50
--                           drop RP_IINT from interfaces; drop RTSFLUSH generic
51
-- 2010-04-18   279   2.2.1  drop RTSFBUF generic for rri_serport
52
-- 2010-04-03   274   2.2    add CP_FLUSH, add rri_serport handshake logic
53
-- 2009-03-14   197   2.1    remove records in interface to allow _ssim usage
54
-- 2008-08-24   162   2.0    with new rb_mreq/rb_sres interface
55
-- 2007-11-24    98   1.1    added RP_IINT support
56
-- 2007-07-02    63   1.0    Initial version 
57
------------------------------------------------------------------------------
58
 
59
library ieee;
60
use ieee.std_logic_1164.all;
61 13 wfjm
use ieee.numeric_std.all;
62 2 wfjm
 
63
use work.slvtypes.all;
64 9 wfjm
use work.rblib.all;
65
use work.rlinklib.all;
66 2 wfjm
 
67 16 wfjm
entity tbu_rlink_sp1c is                -- rlink core+serport combo
68 2 wfjm
  port (
69
    CLK  : in slbit;                    -- clock
70 9 wfjm
    CE_INT : in slbit;                  -- rlink ito time unit clock enable
71 2 wfjm
    CE_USEC : in slbit;                 -- 1 usec clock enable
72
    CE_MSEC : in slbit;                 -- 1 msec clock enable
73
    RESET  : in slbit;                  -- reset
74 9 wfjm
    RXSD : in slbit;                    -- receive serial data      (board view)
75
    TXSD : out slbit;                   -- transmit serial data     (board view)
76
    CTS_N : in slbit;                   -- clear to send   (act.low, board view)
77
    RTS_N : out slbit;                  -- request to send (act.low, board view)
78
    RB_MREQ_aval : out slbit;           -- rbus: request - aval
79
    RB_MREQ_re : out slbit;             -- rbus: request - re
80 2 wfjm
    RB_MREQ_we : out slbit;             -- rbus: request - we
81
    RB_MREQ_initt: out slbit;           -- rbus: request - init; avoid name coll
82 27 wfjm
    RB_MREQ_addr : out slv16;           -- rbus: request - addr
83 2 wfjm
    RB_MREQ_din : out slv16;            -- rbus: request - din
84
    RB_SRES_ack : in slbit;             -- rbus: response - ack
85
    RB_SRES_busy : in slbit;            -- rbus: response - busy
86
    RB_SRES_err : in slbit;             -- rbus: response - err
87
    RB_SRES_dout : in slv16;            -- rbus: response - dout
88
    RB_LAM : in slv16;                  -- rbus: look at me
89 27 wfjm
    RB_STAT : in slv4                   -- rbus: status flags
90 2 wfjm
  );
91 16 wfjm
end entity tbu_rlink_sp1c;
92 2 wfjm
 
93
 
94 16 wfjm
architecture syn of tbu_rlink_sp1c is
95 2 wfjm
 
96 9 wfjm
  constant CDWIDTH : positive := 13;
97 16 wfjm
  constant c_cdinit : natural := 0;   -- NOTE: change in tbd_rlink_sp1c !!
98 9 wfjm
 
99 2 wfjm
  signal RB_MREQ : rb_mreq_type := rb_mreq_init;
100
  signal RB_SRES : rb_sres_type := rb_sres_init;
101
 
102 9 wfjm
  signal RLB_DI : slv8 := (others=>'0');
103
  signal RLB_ENA : slbit := '0';
104
  signal RLB_BUSY : slbit := '0';
105
  signal RLB_DO : slv8 := (others=>'0');
106
  signal RLB_VAL : slbit := '0';
107
  signal RLB_HOLD : slbit := '0';
108 2 wfjm
 
109
begin
110
 
111 9 wfjm
  RB_MREQ_aval <= RB_MREQ.aval;
112
  RB_MREQ_re   <= RB_MREQ.re;
113 2 wfjm
  RB_MREQ_we   <= RB_MREQ.we;
114
  RB_MREQ_initt<= RB_MREQ.init;
115
  RB_MREQ_addr <= RB_MREQ.addr;
116
  RB_MREQ_din  <= RB_MREQ.din;
117
 
118
  RB_SRES.ack  <= RB_SRES_ack;
119
  RB_SRES.busy <= RB_SRES_busy;
120
  RB_SRES.err  <= RB_SRES_err;
121
  RB_SRES.dout <= RB_SRES_dout;
122 9 wfjm
 
123 16 wfjm
  RLINK : rlink_sp1c
124 9 wfjm
    generic map (
125 27 wfjm
      BTOWIDTH     =>  5,
126
      RTAWIDTH     => 11,
127
      SYSID        => x"76543210",
128 16 wfjm
      IFAWIDTH     => 5,
129
      OFAWIDTH     => 5,
130 27 wfjm
      ENAPIN_RLMON => sbcntl_sbf_rlmon,
131
      ENAPIN_RLBMON=> sbcntl_sbf_rlbmon,
132
      ENAPIN_RBMON => sbcntl_sbf_rbmon,
133 16 wfjm
      CDWIDTH      => 15,
134
      CDINIT       => c_cdinit)
135 2 wfjm
    port map (
136 16 wfjm
      CLK      => CLK,
137
      CE_USEC  => CE_USEC,
138
      CE_MSEC  => CE_MSEC,
139
      CE_INT   => CE_INT,
140
      RESET    => RESET,
141
      ENAXON   => '0',
142 30 wfjm
      ESCFILL  => '0',
143 16 wfjm
      RXSD     => RXSD,
144
      TXSD     => TXSD,
145
      CTS_N    => CTS_N,
146
      RTS_N    => RTS_N,
147
      RB_MREQ  => RB_MREQ,
148
      RB_SRES  => RB_SRES,
149
      RB_LAM   => RB_LAM,
150
      RB_STAT  => RB_STAT,
151
      RL_MONI  => open
152
  --  SER_MONI => open  -- ISE 13.1 err's when a second record is mapped open
153 2 wfjm
    );
154
 
155
end syn;

powered by: WebSVN 2.1.0

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