summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatt Ettus <matt@ettus.com>2010-02-16 10:24:18 -0800
committerMatt Ettus <matt@ettus.com>2010-02-16 10:24:18 -0800
commit034eeacfe8d35b0e9733dd9183f1a9dbed78f347 (patch)
tree4deadd7bb8925cc5c3afe7e7bd47e631b106ad70
parente091b4812ff4f7e6f959aabf48ac65bac5be86b7 (diff)
downloaduhd-034eeacfe8d35b0e9733dd9183f1a9dbed78f347.tar.gz
uhd-034eeacfe8d35b0e9733dd9183f1a9dbed78f347.tar.bz2
uhd-034eeacfe8d35b0e9733dd9183f1a9dbed78f347.zip
basic read support for the GPMC, responds with 16'hBEEF
-rw-r--r--usrp2/top/safe_u1e/safe_u1e.v10
1 files changed, 8 insertions, 2 deletions
diff --git a/usrp2/top/safe_u1e/safe_u1e.v b/usrp2/top/safe_u1e/safe_u1e.v
index 3f16d941c..ddd203cf9 100644
--- a/usrp2/top/safe_u1e/safe_u1e.v
+++ b/usrp2/top/safe_u1e/safe_u1e.v
@@ -7,7 +7,7 @@ module safe_u1e
output [2:0] debug_led, output [31:0] debug, output [1:0] debug_clk,
// GPMC
- input EM_CLK, input [15:0] EM_D, input [10:1] EM_A,
+ input EM_CLK, inout [15:0] EM_D, input [10:1] EM_A,
input EM_WAIT0, input EM_NCS4, input EM_NWP, input EM_NWE, input EM_NOE, input EM_NADV_ALE
);
@@ -27,5 +27,11 @@ module safe_u1e
assign debug_clk = { EM_CLK, clk_fpga };
assign debug = { { EM_WAIT0, EM_NADV_ALE, EM_NWP, EM_NCS4, EM_NWE, EM_NOE, EM_A[10:1] },
{ EM_D } };
-
+
+ wire EM_output_enable = (~EM_NOE & ~EM_NCS4);
+ wire [15:0] EM_D_out = 16'hBEEF;
+ wire [15:0] EM_D_in = EM_D;
+
+ assign EM_D = EM_output_enable ? EM_D_out : 16'bz;
+
endmodule // safe_u2plus