w11 - vhd
0.794
W11 CPU core and support modules
Loading...
Searching...
No Matches
pdp11_statleds.vhd
Go to the documentation of this file.
1
-- $Id: pdp11_statleds.vhd 1181 2019-07-08 17:00:50Z mueller $
2
-- SPDX-License-Identifier: GPL-3.0-or-later
3
-- Copyright 2015-2018 by Walter F.J. Mueller <W.F.J.Mueller@gsi.de>
4
--
5
------------------------------------------------------------------------------
6
-- Module Name: pdp11_statleds - syn
7
-- Description: pdp11: status leds
8
--
9
-- Dependencies: -
10
-- Test bench: -
11
-- Target Devices: generic
12
-- Tool versions: ise 14.7; viv 2018.2; ghdl 0.31-0.34
13
--
14
-- Revision History:
15
-- Date Rev Version Comment
16
-- 2018-10-07 1054 1.1 use DM_STAT_EXP instead of DM_STAT_DP
17
-- 2015-02-20 649 1.0 Initial version
18
------------------------------------------------------------------------------
19
-- LED (7) MEM_ACT_W
20
-- (6) MEM_ACT_R
21
-- (5) cmdbusy (all rlink access, mostly rdma)
22
-- (4:0) if cpugo=1 show cpu mode activity
23
-- (4) kernel mode, pri>0
24
-- (3) kernel mode, pri=0
25
-- (2) kernel mode, wait
26
-- (1) supervisor mode
27
-- (0) user mode
28
-- if cpugo=0 shows cpurust
29
-- (4) '1'
30
-- (3:0) cpurust code
31
32
library
ieee
;
33
use
ieee.std_logic_1164.
all
;
34
use
ieee.numeric_std.
all
;
35
36
use
work.
slvtypes
.
all
;
37
use
work.
pdp11
.
all
;
38
39
-- ----------------------------------------------------------------------------
40
41
entity
pdp11_statleds
is
-- status leds
42
port
(
43
MEM_ACT_R
:
in
slbit
;
-- memory active read
44
MEM_ACT_W
:
in
slbit
;
-- memory active write
45
CP_STAT
:
in
cp_stat_type
;
-- console port status
46
DM_STAT_EXP
:
in
dm_stat_exp_type
;
-- debug and monitor - exports
47
STATLEDS
:
out
slv8
-- 8 bit CPU status
48
)
;
49
end
pdp11_statleds
;
50
51
architecture
syn
of
pdp11_statleds
is
52
53
begin
54
55
proc_led:
process
(
MEM_ACT_W
,
MEM_ACT_R
,
CP_STAT
,
DM_STAT_EXP
.dp_psw)
56
variable
iled
:
slv8
:=
(
others
=
>
'
0
'
)
;
57
begin
58
iled
:=
(
others
=
>
'
0
'
)
;
59
60
iled
(
7
)
:=
MEM_ACT_W
;
61
iled
(
6
)
:=
MEM_ACT_R
;
62
iled
(
5
)
:=
CP_STAT
.
cmdbusy
;
63
if
CP_STAT
.
cpugo
=
'
1
'
then
64
case
DM_STAT_EXP
.
dp_psw
.
cmode
is
65
when
c_psw_kmode
=
>
66
if
CP_STAT
.
cpuwait
=
'
1
'
then
67
iled
(
2
)
:=
'
1
'
;
68
elsif
unsigned
(
DM_STAT_EXP
.
dp_psw
.
pri
)
=
0
then
69
iled
(
3
)
:=
'
1
'
;
70
else
71
iled
(
4
)
:=
'
1
'
;
72
end
if
;
73
when
c_psw_smode
=
>
74
iled
(
1
)
:=
'
1
'
;
75
when
c_psw_umode
=
>
76
iled
(
0
)
:=
'
1
'
;
77
when
others
=
>
null
;
78
end
case
;
79
else
80
iled
(
4
)
:=
'
1
'
;
81
iled
(
3
downto
0
)
:=
CP_STAT
.
cpurust
;
82
end
if
;
83
84
STATLEDS
<=
iled
;
85
86
end
process
proc_led
;
87
88
end
syn;
pdp11_statleds.syn
Definition:
pdp11_statleds.vhd:51
pdp11_statleds
Definition:
pdp11_statleds.vhd:41
pdp11_statleds.CP_STAT
in CP_STAT cp_stat_type
Definition:
pdp11_statleds.vhd:45
pdp11_statleds.MEM_ACT_W
in MEM_ACT_W slbit
Definition:
pdp11_statleds.vhd:44
pdp11_statleds.MEM_ACT_R
in MEM_ACT_R slbit
Definition:
pdp11_statleds.vhd:43
pdp11_statleds.STATLEDS
out STATLEDS slv8
Definition:
pdp11_statleds.vhd:48
pdp11_statleds.DM_STAT_EXP
in DM_STAT_EXP dm_stat_exp_type
Definition:
pdp11_statleds.vhd:46
pdp11
Definition:
pdp11.vhd:123
slvtypes
Definition:
slvtypes.vhd:28
slvtypes.slbit
std_logic slbit
Definition:
slvtypes.vhd:30
slvtypes.slv8
std_logic_vector( 7 downto 0) slv8
Definition:
slvtypes.vhd:40
w11a
pdp11_statleds.vhd
Generated on Thu Feb 9 2023 12:41:06 for w11 - vhd by
1.9.6