-
Notifications
You must be signed in to change notification settings - Fork 399
/
Copy pathwb_if.sv
69 lines (52 loc) · 1.19 KB
/
wb_if.sv
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
//------------------------------------------------------------------------------
// wb_if.sv
// published as part of https://github.com/pConst/basic_verilog
// Konstantin Pavlov, [email protected]
//------------------------------------------------------------------------------
// INFO ------------------------------------------------------------------------
// Wishbone instantiation
//
interface wb_if #( parameter
ADDR_W = 32,
DATA_W = 32,
SEL_W = 4
//TAG_W = 4
);
logic ack;
logic [ADDR_W-1:0] adr;
logic cyc;
logic [DATA_W-1:0] dat;
logic [DATA_W-1:0] dat;
logic err;
logic rty;
logic [ SEL_W-1:0] sel;
logic stb;
//logic [ TAG_W-1:0] tgd; // user-defined TAG signals
logic we;
modport master_mp(
input ack,
input dat,
input err,
input rty,
output adr,
output cyc,
output dat,
output sel,
output stb,
//output tgd,
output we
);
modport slave_mp(
input adr,
input cyc,
input dat,
input sel,
input stb,
//input tgd,
input we,
output ack,
output dat,
output err,
output rty
);
endinterface