aboutsummaryrefslogtreecommitdiffstats
path: root/icefuzz/tests/sb_io_od.v
diff options
context:
space:
mode:
authorDavid Shah <davey1576@gmail.com>2017-10-23 17:48:22 +0100
committerDavid Shah <davey1576@gmail.com>2017-10-23 17:48:22 +0100
commit81e0d3c361e1b639064e07ff7efd1b8232090e0c (patch)
tree6041ea53d896750a68bbbb3747e00c61919fde4e /icefuzz/tests/sb_io_od.v
parentbf21b644984656fdea6ec2609b22a74f3296115b (diff)
downloadicestorm-81e0d3c361e1b639064e07ff7efd1b8232090e0c.tar.gz
icestorm-81e0d3c361e1b639064e07ff7efd1b8232090e0c.tar.bz2
icestorm-81e0d3c361e1b639064e07ff7efd1b8232090e0c.zip
Add some verilog tests for analysing up5k features
Diffstat (limited to 'icefuzz/tests/sb_io_od.v')
-rw-r--r--icefuzz/tests/sb_io_od.v62
1 files changed, 62 insertions, 0 deletions
diff --git a/icefuzz/tests/sb_io_od.v b/icefuzz/tests/sb_io_od.v
new file mode 100644
index 0000000..7894741
--- /dev/null
+++ b/icefuzz/tests/sb_io_od.v
@@ -0,0 +1,62 @@
+//`define CONN_INTERNAL_BITS
+
+`define PINTYPE 6'b010001
+// `define IOSTANDARD "SB_LVCMOS"
+`define IOSTANDARD "SB_LVCMOS"
+
+// The following IO standards are just aliases for SB_LVCMOS
+// `define IOSTANDARD "SB_LVCMOS25_16"
+// `define IOSTANDARD "SB_LVCMOS25_12"
+// `define IOSTANDARD "SB_LVCMOS25_8"
+// `define IOSTANDARD "SB_LVCMOS25_4"
+// `define IOSTANDARD "SB_LVCMOS18_10"
+// `define IOSTANDARD "SB_LVCMOS18_8"
+// `define IOSTANDARD "SB_LVCMOS18_4"
+// `define IOSTANDARD "SB_LVCMOS18_2"
+// `define IOSTANDARD "SB_LVCMOS15_4"
+// `define IOSTANDARD "SB_LVCMOS15_2"
+// `define IOSTANDARD "SB_MDDR10"
+// `define IOSTANDARD "SB_MDDR8"
+// `define IOSTANDARD "SB_MDDR4"
+// `define IOSTANDARD "SB_MDDR2"
+
+`ifdef CONN_INTERNAL_BITS
+module top (
+ inout pin,
+ input latch_in,
+ input clk_in,
+ input clk_out,
+ input oen,
+ input dout_0,
+ input dout_1,
+ output din_0,
+ output din_1
+);
+`else
+module top(pin);
+ inout pin;
+ wire latch_in = 0;
+ wire clk_in = 0;
+ wire clk_out = 0;
+ wire oen = 0;
+ wire dout_0 = 0;
+ wire dout_1 = 0;
+ wire din_0;
+ wire din_1;
+`endif
+ SB_IO_OD #(
+ .PIN_TYPE(`PINTYPE),
+ .NEG_TRIGGER(1'b0)
+ ) IO_PIN_I (
+ .PACKAGEPIN(pin),
+ .LATCHINPUTVALUE(latch_in),
+ .CLOCKENABLE(clk_en),
+ .INPUTCLK(clk_in),
+ .OUTPUTCLK(clk_out),
+ .OUTPUTENABLE(oen),
+ .DOUT0(dout_0),
+ .DOUT1(dout_1),
+ .DIN0(din_0),
+ .DIN1(din_1)
+ );
+endmodule