blob: b5460f5058c88c76bf97fa49d9b18eaac0467d88 [file] [log] [blame]
Matt Venn08cd6eb2020-11-16 12:01:14 +01001`default_nettype none
Tim Edwardsb86fc842020-10-13 17:11:54 -04002/*
3 *-------------------------------------------------------------
4 *
5 * user_project_wrapper
6 *
7 * This wrapper enumerates all of the pins available to the
8 * user for the user project.
9 *
10 * An example user project is provided in this wrapper. The
11 * example should be removed and replaced with the actual
12 * user project.
13 *
14 *-------------------------------------------------------------
15 */
16
17module user_project_wrapper #(
Tim Edwardsb86fc842020-10-13 17:11:54 -040018 parameter BITS = 32
19)(
20 inout vdda1, // User area 1 3.3V supply
21 inout vdda2, // User area 2 3.3V supply
22 inout vssa1, // User area 1 analog ground
23 inout vssa2, // User area 2 analog ground
24 inout vccd1, // User area 1 1.8V supply
25 inout vccd2, // User area 2 1.8v supply
26 inout vssd1, // User area 1 digital ground
27 inout vssd2, // User area 2 digital ground
28
29 // Wishbone Slave ports (WB MI A)
30 input wb_clk_i,
31 input wb_rst_i,
32 input wbs_stb_i,
33 input wbs_cyc_i,
34 input wbs_we_i,
35 input [3:0] wbs_sel_i,
36 input [31:0] wbs_dat_i,
37 input [31:0] wbs_adr_i,
38 output wbs_ack_o,
39 output [31:0] wbs_dat_o,
40
41 // Logic Analyzer Signals
42 input [127:0] la_data_in,
43 output [127:0] la_data_out,
44 input [127:0] la_oen,
45
46 // IOs
Ahmed Ghazy22d29d62020-10-28 03:42:02 +020047 input [`MPRJ_IO_PADS-1:0] io_in,
48 output [`MPRJ_IO_PADS-1:0] io_out,
49 output [`MPRJ_IO_PADS-1:0] io_oeb,
Tim Edwardsb86fc842020-10-13 17:11:54 -040050
Tim Edwards581068f2020-11-19 12:45:25 -050051 // Analog (direct connection to GPIO pad---use with caution)
52 // Note that analog I/O is not available on the 7 lowest-numbered
53 // GPIO pads, and so the analog_io indexing is offset from the
54 // GPIO indexing by 7.
55 inout [`MPRJ_IO_PADS-8:0] analog_io,
56
Tim Edwardsb86fc842020-10-13 17:11:54 -040057 // Independent clock (on independent integer divider)
58 input user_clock2
59);
60
61 /*--------------------------------------*/
62 /* User project is instantiated here */
63 /*--------------------------------------*/
64
Ahmed Ghazy22d29d62020-10-28 03:42:02 +020065 user_proj_example mprj (
Tim Edwardsb86fc842020-10-13 17:11:54 -040066 .vdda1(vdda1), // User area 1 3.3V power
67 .vdda2(vdda2), // User area 2 3.3V power
68 .vssa1(vssa1), // User area 1 analog ground
69 .vssa2(vssa2), // User area 2 analog ground
70 .vccd1(vccd1), // User area 1 1.8V power
71 .vccd2(vccd2), // User area 2 1.8V power
72 .vssd1(vssd1), // User area 1 digital ground
73 .vssd2(vssd2), // User area 2 digital ground
74
75 // MGMT core clock and reset
76
77 .wb_clk_i(wb_clk_i),
78 .wb_rst_i(wb_rst_i),
79
Ahmed Ghazy22d29d62020-10-28 03:42:02 +020080 // MGMT SoC Wishbone Slave
Tim Edwardsb86fc842020-10-13 17:11:54 -040081
82 .wbs_cyc_i(wbs_cyc_i),
83 .wbs_stb_i(wbs_stb_i),
84 .wbs_we_i(wbs_we_i),
85 .wbs_sel_i(wbs_sel_i),
86 .wbs_adr_i(wbs_adr_i),
87 .wbs_dat_i(wbs_dat_i),
88 .wbs_ack_o(wbs_ack_o),
89 .wbs_dat_o(wbs_dat_o),
90
91 // Logic Analyzer
92
93 .la_data_in(la_data_in),
94 .la_data_out(la_data_out),
95 .la_oen (la_oen),
96
97 // IO Pads
98
99 .io_in (io_in),
100 .io_out(io_out),
101 .io_oeb(io_oeb)
102 );
103
104endmodule // user_project_wrapper
Tim Edwards581068f2020-11-19 12:45:25 -0500105`default_nettype wire