pvic_connection_interface.v
4.34 KB
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
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
// ----------------------------------------------------------------------------
// Copyright 2001 VAutomation Inc. Nashua NH USA. All rights reserved.
// This software is provided under license and contains proprietary
// and confidential material which is the property of VAutomation Inc.
// HTTP://www.vautomation.com
// ----------------------------------------------------------------------------
`timescale 1 ns / 1 ps // timescale for following modules
// -----------------------------------------------------------------------------
module pvic_connection_interface (master_clock,
master_rst,
device_1_t_cmdack,
device_1_t_rdata,
device_1_t_reop,
device_1_t_rspval,
device_1_t_addr,
device_1_t_be,
device_1_t_cmd,
device_1_t_cmdval,
device_1_t_eop,
device_1_t_rspack,
device_1_t_wdata,
device_1_i_addr,
device_1_i_be,
device_1_i_cmd,
device_1_i_cmdval,
device_1_i_eop,
device_1_i_rspack,
device_1_i_wdata,
device_1_i_cmdack,
device_1_i_rdata,
device_1_i_reop,
device_1_i_rspval,
pirq_1_irq_0,
pirq_1_irq_1,
pirq_1_irq_2,
pirq_1_irq_3,
pirq_1_irq_4,
pirq_1_irq_5,
pirq_1_irq_6,
pirq_1_irq_7
);
input master_clock;
input master_rst;
output device_1_t_cmdack; // Command Acknowledge
output [31:0] device_1_t_rdata; // Read Data
output device_1_t_reop; // Response End of Packet
output device_1_t_rspval; // Response Valid
input [31:0] device_1_t_addr; // Byte Address
input [3:0] device_1_t_be; // Byte enables
input [1:0] device_1_t_cmd; // Command 00=idle, 01=read, 10=write, 11=locked read
input device_1_t_cmdval; // Command Valid
input device_1_t_eop; // End Of Packet
input device_1_t_rspack; // Unused
input [31:0] device_1_t_wdata; // Write Data
output [31:0] device_1_i_addr; // Byte Address
output [3:0] device_1_i_be; // Byte enables
output [1:0] device_1_i_cmd; // Command 00=idle, 01=read, 10=write, 11=locked read
output device_1_i_cmdval; // Command Valid
output device_1_i_eop; // End Of Packet
output device_1_i_rspack; // Unused
output [31:0] device_1_i_wdata; // Write Data
input device_1_i_cmdack; // Command Acknowledge
input [31:0] device_1_i_rdata; // Read Data
input device_1_i_reop; // Response End of Packet
input device_1_i_rspval; // Response Valid
input pirq_1_irq_0; // IRQ0
input pirq_1_irq_1; // IRQ1
input pirq_1_irq_2; // IRQ2
input pirq_1_irq_3;
input pirq_1_irq_4; // IRQ0
input pirq_1_irq_5; // IRQ1
input pirq_1_irq_6; // IRQ2
input pirq_1_irq_7;
// BVCI Target
wire device_1_t_cmdack;
wire [31:0] device_1_t_rdata;
wire device_1_t_reop;
wire device_1_t_rspval;
wire [31:0] device_1_i_addr;
wire [3:0] device_1_i_be;
wire [1:0] device_1_i_cmd;
wire device_1_i_cmdval;
wire device_1_i_eop;
wire device_1_i_rspack;
wire [31:0] device_1_i_wdata;
//Put IN_SIG = 0, OUT_SIG = 1, INOUT_SIG = 3;
initial begin : startup
$SignalInitVPI(
0, master_clock,
0, master_rst,
1, device_1_t_cmdack,
1, device_1_t_rdata,
1, device_1_t_reop,
1, device_1_t_rspval,
0, device_1_t_addr,
0, device_1_t_be,
0, device_1_t_cmd,
0, device_1_t_cmdval,
0, device_1_t_eop,
0, device_1_t_rspack,
0, device_1_t_wdata,
1, device_1_i_addr,
1, device_1_i_be,
1, device_1_i_cmd,
1, device_1_i_cmdval,
1, device_1_i_eop,
1, device_1_i_rspack,
1, device_1_i_wdata,
0, device_1_i_cmdack,
0, device_1_i_rdata,
0, device_1_i_reop,
0, device_1_i_rspval,
0, pirq_1_irq_0,
0, pirq_1_irq_1,
0, pirq_1_irq_2,
0, pirq_1_irq_3,
0, pirq_1_irq_4,
0, pirq_1_irq_5,
0, pirq_1_irq_6,
0, pirq_1_irq_7
);
end
always @ (master_clock)
begin
#(0);
$SignalChangeCallbackVPI(
master_clock,
master_rst,
device_1_t_cmdack,
device_1_t_rdata,
device_1_t_reop,
device_1_t_rspval,
device_1_t_addr,
device_1_t_be,
device_1_t_cmd,
device_1_t_cmdval,
device_1_t_eop,
device_1_t_rspack,
device_1_t_wdata,
device_1_i_addr,
device_1_i_be,
device_1_i_cmd,
device_1_i_cmdval,
device_1_i_eop,
device_1_i_rspack,
device_1_i_wdata,
device_1_i_cmdack,
device_1_i_rdata,
device_1_i_reop,
device_1_i_rspval,
pirq_1_irq_0,
pirq_1_irq_1,
pirq_1_irq_2,
pirq_1_irq_3,
pirq_1_irq_4,
pirq_1_irq_5,
pirq_1_irq_6,
pirq_1_irq_7
);
end
endmodule