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

Subversion Repositories w11

[/] [w11/] [tags/] [w11a_V0.7/] [rtl/] [ibus/] [ibdlib.vhd] - Blame information for rev 36

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

Line No. Rev Author Line
1 31 wfjm
-- $Id: ibdlib.vhd 682 2015-05-15 18:35:29Z mueller $
2 2 wfjm
--
3 31 wfjm
-- Copyright 2008-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
-- Package Name:   ibdlib
16
-- Description:    Definitions for ibus devices
17
--
18
-- Dependencies:   -
19 29 wfjm
-- Tool versions:  ise 8.2-14.7; viv 2014.4; ghdl 0.18-0.31
20 2 wfjm
-- Revision History: 
21
-- Date         Rev Version  Comment
22 30 wfjm
-- 2015-05-09   676   1.3    start/stop/suspend overhaul
23
-- 2015-03-13   658   1.2.1  add rprm declaration (later renaned to rhrp)
24 25 wfjm
-- 2014-06-08   561   1.2    fix rl11 declaration
25 13 wfjm
-- 2011-11-18   427   1.1.2  now numeric_std clean
26 8 wfjm
-- 2010-10-23   335   1.1.1  rename RRI_LAM->RB_LAM;
27 2 wfjm
-- 2010-06-11   303   1.1    use IB_MREQ.racc instead of RRI_REQ
28
-- 2009-07-12   233   1.0.5  add RESET, CE_USEC to _dl11, CE_USEC to _minisys
29
-- 2009-06-07   224   1.0.4  add iist_mreq and iist_sreq;
30
-- 2009-06-01   221   1.0.3  add RESET to kw11l; add iist;
31
-- 2009-05-30   220   1.0.2  add most additional device def's
32
-- 2009-05-24   219   1.0.1  add CE_MSEC to _rk11; add _maxisys
33
-- 2008-08-22   161   1.0    Initial version (extracted from pdp11.vhd)
34
------------------------------------------------------------------------------
35
 
36
library ieee;
37
use ieee.std_logic_1164.all;
38 13 wfjm
use ieee.numeric_std.all;
39 2 wfjm
 
40
use work.slvtypes.all;
41
use work.iblib.all;
42
 
43
package ibdlib is
44
 
45
type iist_line_type is record         -- iist line
46
  dcf : slbit;                        -- disconnect flag
47
  req : slbit;                        -- request
48
  stf : slbit;                        -- sanity timer flag
49
  imask : slv4;                       -- interrupt mask
50
  bmask : slv4;                       -- boot mask
51
  par : slbit;                        -- parity (odd)
52
  frm : slbit;                        -- frame error flag
53
end record iist_line_type;
54
 
55
constant iist_line_init : iist_line_type := ('1','0','0',"0000","0000",'0','0');
56
 
57
type iist_bus_type is array (3 downto 0) of iist_line_type;
58
constant iist_bus_init : iist_bus_type := (others=>iist_line_init);
59
 
60
type iist_mreq_type is record         -- iist->cpu requests
61
  lock : slbit;                       -- lock-up CPU
62
  boot : slbit;                       -- boot-up CPU
63
end record iist_mreq_type;
64
 
65
constant iist_mreq_init : iist_mreq_type := ('0','0');
66
 
67
type iist_sres_type is record         -- cpu->iist responses
68
  ack_lock : slbit;                   -- release lock 
69
  ack_boot : slbit;                   -- boot started
70
end record iist_sres_type;
71
 
72
constant iist_sres_init : iist_sres_type := ('0','0');
73
 
74 13 wfjm
-- ise 13.1 xst can bug check if generic defaults in a package are defined via 
75
-- 'slv(to_unsigned())'. The conv_ construct prior to numeric_std was ok.
76
-- As workaround the ibus default addresses are defined here as constant.
77
constant ibaddr_dz11 : slv16 := slv(to_unsigned(8#160100#,16));
78
constant ibaddr_dl11 : slv16 := slv(to_unsigned(8#177560#,16));
79
 
80 2 wfjm
component ibd_iist is                   -- ibus dev(loc): IIST
81
                                        -- fixed address: 177500
82
  generic (
83
    SID : slv2 := "00");                -- self id
84
  port (
85
    CLK : in slbit;                     -- clock
86
    CE_USEC : in slbit;                 -- usec pulse
87
    RESET : in slbit;                   -- system reset
88
    BRESET : in slbit;                  -- ibus reset
89
    IB_MREQ : in ib_mreq_type;          -- ibus request
90
    IB_SRES : out ib_sres_type;         -- ibus response
91
    EI_REQ : out slbit;                 -- interrupt request
92
    EI_ACK : in slbit;                  -- interrupt acknowledge
93
    IIST_BUS : in iist_bus_type;        -- iist bus (input from all iist's)
94
    IIST_OUT : out iist_line_type;      -- iist output
95
    IIST_MREQ : out iist_mreq_type;     -- iist->cpu requests
96
    IIST_SRES : in iist_sres_type       -- cpu->iist responses
97
  );
98
end component;
99
 
100 30 wfjm
component ibd_kw11p is                  -- ibus dev(loc): KW11-P (prog clock)
101 2 wfjm
                                        -- fixed address: 172540
102
  port (
103
    CLK : in slbit;                     -- clock
104
    CE_USEC : in slbit;                 -- usec pulse
105
    CE_MSEC : in slbit;                 -- msec pulse
106
    RESET : in slbit;                   -- system reset
107
    BRESET : in slbit;                  -- ibus reset
108 30 wfjm
    CPUSUSP : in slbit;                 -- cpu suspended
109 2 wfjm
    IB_MREQ : in ib_mreq_type;          -- ibus request
110
    IB_SRES : out ib_sres_type;         -- ibus response
111
    EI_REQ : out slbit;                 -- interrupt request
112
    EI_ACK : in slbit                   -- interrupt acknowledge
113
  );
114
end component;
115
 
116
component ibd_kw11l is                  -- ibus dev(loc): KW11-L (line clock)
117
                                        -- fixed address: 177546
118
  port (
119
    CLK : in slbit;                     -- clock
120
    CE_MSEC : in slbit;                 -- msec pulse
121
    RESET : in slbit;                   -- system reset
122
    BRESET : in slbit;                  -- ibus reset
123 30 wfjm
    CPUSUSP : in slbit;                 -- cpu suspended
124 2 wfjm
    IB_MREQ : in ib_mreq_type;          -- ibus request
125
    IB_SRES : out ib_sres_type;         -- ibus response
126
    EI_REQ : out slbit;                 -- interrupt request
127
    EI_ACK : in slbit                   -- interrupt acknowledge
128
  );
129
end component;
130
 
131 30 wfjm
component ibdr_rhrp is                  -- ibus dev(rem): RH+RP
132
                                        -- fixed address: 174400
133
  port (
134
    CLK : in slbit;                     -- clock
135
    CE_USEC : in slbit;                 -- usec pulse
136
    BRESET : in slbit;                  -- ibus reset
137
    ITIMER : in slbit;                  -- instruction timer
138
    RB_LAM : out slbit;                 -- remote attention
139
    IB_MREQ : in ib_mreq_type;          -- ibus request
140
    IB_SRES : out ib_sres_type;         -- ibus response
141
    EI_REQ : out slbit;                 -- interrupt request
142
    EI_ACK : in slbit                   -- interrupt acknowledge
143
  );
144
end component;
145
 
146 2 wfjm
component ibdr_rl11 is                  -- ibus dev(rem): RL11
147
                                        -- fixed address: 174400
148
  port (
149
    CLK : in slbit;                     -- clock
150 25 wfjm
    CE_MSEC : in slbit;                 -- msec pulse
151 2 wfjm
    BRESET : in slbit;                  -- ibus reset
152 8 wfjm
    RB_LAM : out slbit;                 -- remote attention
153 2 wfjm
    IB_MREQ : in ib_mreq_type;          -- ibus request
154
    IB_SRES : out ib_sres_type;         -- ibus response
155
    EI_REQ : out slbit;                 -- interrupt request
156
    EI_ACK : in slbit                   -- interrupt acknowledge
157
  );
158
end component;
159
 
160
component ibdr_rk11 is                  -- ibus dev(rem): RK11
161
                                        -- fixed address: 177400
162
  port (
163
    CLK : in slbit;                     -- clock
164
    CE_MSEC : in slbit;                 -- msec pulse
165
    BRESET : in slbit;                  -- ibus reset
166 8 wfjm
    RB_LAM : out slbit;                 -- remote attention
167 2 wfjm
    IB_MREQ : in ib_mreq_type;          -- ibus request
168
    IB_SRES : out ib_sres_type;         -- ibus response
169
    EI_REQ : out slbit;                 -- interrupt request
170
    EI_ACK : in slbit                   -- interrupt acknowledge
171
  );
172
end component;
173
 
174
component ibdr_tm11 is                  -- ibus dev(rem): TM11
175
                                        -- fixed address: 172520
176
  port (
177
    CLK : in slbit;                     -- clock
178
    BRESET : in slbit;                  -- ibus reset
179 8 wfjm
    RB_LAM : out slbit;                 -- remote attention
180 2 wfjm
    IB_MREQ : in ib_mreq_type;          -- ibus request
181
    IB_SRES : out ib_sres_type;         -- ibus response
182
    EI_REQ : out slbit;                 -- interrupt request
183
    EI_ACK : in slbit                   -- interrupt acknowledge
184
  );
185
end component;
186
 
187
component ibdr_dz11 is                  -- ibus dev(rem): DZ11
188
  generic (
189 13 wfjm
    IB_ADDR : slv16 := ibaddr_dz11);
190 2 wfjm
  port (
191
    CLK : in slbit;                     -- clock
192
    RESET : in slbit;                   -- system reset
193
    BRESET : in slbit;                  -- ibus reset
194 8 wfjm
    RB_LAM : out slbit;                 -- remote attention
195 2 wfjm
    IB_MREQ : in ib_mreq_type;          -- ibus request
196
    IB_SRES : out ib_sres_type;         -- ibus response
197
    EI_REQ_RX : out slbit;              -- interrupt request, receiver
198
    EI_REQ_TX : out slbit;              -- interrupt request, transmitter
199
    EI_ACK_RX : in slbit;               -- interrupt acknowledge, receiver
200
    EI_ACK_TX : in slbit                -- interrupt acknowledge, transmitter
201
  );
202
end component;
203
 
204
component ibdr_dl11 is                  -- ibus dev(rem): DL11-A/B
205
  generic (
206 13 wfjm
    IB_ADDR : slv16 := ibaddr_dl11);
207 2 wfjm
  port (
208
    CLK : in slbit;                     -- clock
209
    CE_USEC : in slbit;                 -- usec pulse
210
    RESET : in slbit;                   -- system reset
211
    BRESET : in slbit;                  -- ibus reset
212 8 wfjm
    RB_LAM : out slbit;                 -- remote attention
213 2 wfjm
    IB_MREQ : in ib_mreq_type;          -- ibus request
214
    IB_SRES : out ib_sres_type;         -- ibus response
215
    EI_REQ_RX : out slbit;              -- interrupt request, receiver
216
    EI_REQ_TX : out slbit;              -- interrupt request, transmitter
217
    EI_ACK_RX : in slbit;               -- interrupt acknowledge, receiver
218
    EI_ACK_TX : in slbit                -- interrupt acknowledge, transmitter
219
  );
220
end component;
221
 
222
component ibdr_pc11 is                  -- ibus dev(rem): PC11
223
                                        -- fixed address: 177550
224
  port (
225
    CLK : in slbit;                     -- clock
226
    RESET : in slbit;                   -- system reset
227
    BRESET : in slbit;                  -- ibus reset
228 8 wfjm
    RB_LAM : out slbit;                 -- remote attention
229 2 wfjm
    IB_MREQ : in ib_mreq_type;          -- ibus request
230
    IB_SRES : out ib_sres_type;         -- ibus response
231
    EI_REQ_PTR : out slbit;             -- interrupt request, reader
232
    EI_REQ_PTP : out slbit;             -- interrupt request, punch
233
    EI_ACK_PTR : in slbit;              -- interrupt acknowledge, reader
234
    EI_ACK_PTP : in slbit               -- interrupt acknowledge, punch
235
  );
236
end component;
237
 
238
component ibdr_lp11 is                  -- ibus dev(rem): LP11
239
                                        -- fixed address: 177514
240
  port (
241
    CLK : in slbit;                     -- clock
242
    RESET : in slbit;                   -- system reset
243
    BRESET : in slbit;                  -- ibus reset
244 8 wfjm
    RB_LAM : out slbit;                 -- remote attention
245 2 wfjm
    IB_MREQ : in ib_mreq_type;          -- ibus request
246
    IB_SRES : out ib_sres_type;         -- ibus response
247
    EI_REQ : out slbit;                 -- interrupt request
248
    EI_ACK : in slbit                   -- interrupt acknowledge
249
  );
250
end component;
251
 
252
component ibdr_sdreg is                 -- ibus dev(rem): Switch/Display regs
253
                                        -- fixed address: 177570
254
  port (
255
    CLK : in slbit;                     -- clock
256
    RESET : in slbit;                   -- reset
257
    IB_MREQ : in ib_mreq_type;          -- ibus request
258
    IB_SRES : out ib_sres_type;         -- ibus response
259
    DISPREG : out slv16                 -- display register
260
  );
261
end component;
262
 
263
component ibdr_minisys is               -- ibus(rem) minimal sys:SDR+KW+DL+RK
264
  port (
265
    CLK : in slbit;                     -- clock
266
    CE_USEC : in slbit;                 -- usec pulse
267
    CE_MSEC : in slbit;                 -- msec pulse
268
    RESET : in slbit;                   -- reset
269
    BRESET : in slbit;                  -- ibus reset
270 8 wfjm
    RB_LAM : out slv16_1;               -- remote attention vector
271 2 wfjm
    IB_MREQ : in ib_mreq_type;          -- ibus request
272
    IB_SRES : out ib_sres_type;         -- ibus response
273
    EI_ACKM : in slbit;                 -- interrupt acknowledge (from master)
274
    EI_PRI : out slv3;                  -- interrupt priority (to cpu)
275
    EI_VECT : out slv9_2;               -- interrupt vector   (to cpu)
276
    DISPREG : out slv16                 -- display register
277
  );
278
end component;
279
 
280
component ibdr_maxisys is               -- ibus(rem) full system
281
  port (
282
    CLK : in slbit;                     -- clock
283
    CE_USEC : in slbit;                 -- usec pulse
284
    CE_MSEC : in slbit;                 -- msec pulse
285
    RESET : in slbit;                   -- reset
286
    BRESET : in slbit;                  -- ibus reset
287 30 wfjm
    ITIMER : in slbit;                  -- instruction timer
288
    CPUSUSP : in slbit;                 -- cpu suspended
289 8 wfjm
    RB_LAM : out slv16_1;               -- remote attention vector
290 2 wfjm
    IB_MREQ : in ib_mreq_type;          -- ibus request
291
    IB_SRES : out ib_sres_type;         -- ibus response
292
    EI_ACKM : in slbit;                 -- interrupt acknowledge (from master)
293
    EI_PRI : out slv3;                  -- interrupt priority (to cpu)
294
    EI_VECT : out slv9_2;               -- interrupt vector   (to cpu)
295
    DISPREG : out slv16                 -- display register
296
  );
297
end component;
298
 
299
end package ibdlib;

powered by: WebSVN 2.1.0

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