w11 - vhd
0.794
W11 CPU core and support modules
Toggle main menu visibility
Main Page
Packages
Package List
Design Units
Design Unit List
Design Unit Index
Design Unit Hierarchy
Design Unit Members
All
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Functions/Procedures/Processes
b
c
d
e
g
h
i
n
o
p
r
s
t
w
x
Variables
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Files
File List
File Members
All
t
Variables
t
▼
w11 - vhd
►
Packages
►
Design Units
▼
Files
►
File List
►
File Members
•
All
Classes
Namespaces
Files
Functions
Variables
Loading...
Searching...
No Matches
gray2bin_gen.vhd
Go to the documentation of this file.
1
-- $Id: gray2bin_gen.vhd 1181 2019-07-08 17:00:50Z mueller $
2
-- SPDX-License-Identifier: GPL-3.0-or-later
3
-- Copyright 2007- by Walter F.J. Mueller <W.F.J.Mueller@gsi.de>
4
--
5
------------------------------------------------------------------------------
6
-- Module Name: gray2bin_gen - syn
7
-- Description: Gray code to binary converter
8
--
9
-- Dependencies: -
10
-- Test bench: tb/tb_gray_cnt_n
11
-- Target Devices: generic
12
-- Tool versions: xst 8.1-14.7; viv 2014.4-2015.4; ghdl 0.18-0.33
13
-- Revision History:
14
-- Date Rev Version Comment
15
-- 2007-12-26 106 1.0 Initial version
16
------------------------------------------------------------------------------
17
18
library
ieee
;
19
use
ieee.std_logic_1164.
all
;
20
21
use
work.
slvtypes
.
all
;
22
23
entity
gray2bin_gen
is
-- gray->bin converter, generic vector
24
generic
(
25
DWIDTH
:
positive
:=
4
)
;
-- data width
26
port
(
27
DI
:
in
slv
(
DWIDTH
-
1
downto
0
)
;
-- gray code input
28
DO
:
out
slv
(
DWIDTH
-
1
downto
0
)
-- binary code output
29
)
;
30
end
entity
gray2bin_gen
;
31
32
33
architecture
syn
of
gray2bin_gen
is
34
35
begin
36
37
proc_comb:
process
(
DI
)
38
39
variable
ido
:
slv
(
DWIDTH
-
1
downto
0
)
;
40
41
begin
42
43
ido
:=
(
others
=
>
'
0
'
)
;
44
45
ido
(
DWIDTH
-
1
)
:=
DI
(
DWIDTH
-
1
)
;
46
for
i
in
DWIDTH
-
2
downto
0
loop
47
ido
(
i
)
:=
ido
(
i
+
1
)
xor
DI
(
i
)
;
48
end
loop
;
49
50
DO
<=
ido
;
51
52
end
process
proc_comb
;
53
54
end
syn;
55
gray2bin_gen.syn
Definition:
gray2bin_gen.vhd:33
gray2bin_gen
Definition:
gray2bin_gen.vhd:23
gray2bin_gen.DWIDTH
DWIDTH positive := 4
Definition:
gray2bin_gen.vhd:25
gray2bin_gen.DO
out DO slv( DWIDTH- 1 downto 0)
Definition:
gray2bin_gen.vhd:29
gray2bin_gen.DI
in DI slv( DWIDTH- 1 downto 0)
Definition:
gray2bin_gen.vhd:27
slvtypes
Definition:
slvtypes.vhd:28
slvtypes.slv
std_logic_vector slv
Definition:
slvtypes.vhd:31
vlib
genlib
gray2bin_gen.vhd
Generated on Thu Feb 9 2023 12:41:05 for w11 - vhd by
1.9.6