|
@@ -1,68 +1,68 @@
|
|
|
module abcbus (
|
|
|
- input rst_n,
|
|
|
- input sys_clk,
|
|
|
- input sdram_clk, // Assumed to be a multiple of sys_clk
|
|
|
- input stb_1mhz, // 1-2 MHz sys_clk strobe
|
|
|
+ input rst_n,
|
|
|
+ input sys_clk,
|
|
|
+ input sdram_clk, // Assumed to be a multiple of sys_clk
|
|
|
+ input stb_1mhz, // 1-2 MHz sys_clk strobe
|
|
|
|
|
|
// CPU interface
|
|
|
- input abc_valid, // Control/status registers
|
|
|
- input map_valid, // Memory map
|
|
|
- input [31:0] cpu_addr,
|
|
|
- input [31:0] cpu_wdata,
|
|
|
- input [3:0] cpu_wstrb,
|
|
|
- output [31:0] cpu_rdata, // For the ABC-bus control
|
|
|
- output [31:0] cpu_rdata_map, // For the map RAM
|
|
|
- output reg irq,
|
|
|
+ input abc_valid, // Control/status registers
|
|
|
+ input map_valid, // Memory map
|
|
|
+ input [31:0] cpu_addr,
|
|
|
+ input [31:0] cpu_wdata,
|
|
|
+ input [3:0] cpu_wstrb,
|
|
|
+ output reg [31:0] cpu_rdata, // For the ABC-bus control
|
|
|
+ output [31:0] cpu_rdata_map, // For the map RAM
|
|
|
+ output reg irq,
|
|
|
|
|
|
// ABC bus
|
|
|
- input abc_clk,
|
|
|
- input [15:0] abc_a,
|
|
|
- inout [7:0] abc_d,
|
|
|
- output reg abc_d_oe,
|
|
|
- input abc_rst_n,
|
|
|
- input abc_cs_n,
|
|
|
- input [4:0] abc_out_n,
|
|
|
- input [1:0] abc_inp_n,
|
|
|
- input abc_xmemfl_n,
|
|
|
- input abc_xmemw800_n, // Memory write strobe (ABC800)
|
|
|
- input abc_xmemw80_n, // Memory write strobe (ABC80)
|
|
|
- input abc_xinpstb_n, // I/O read strobe (ABC800)
|
|
|
- input abc_xoutpstb_n, // I/O write strobe (ABC80)
|
|
|
+ input abc_clk,
|
|
|
+ input [15:0] abc_a,
|
|
|
+ inout [7:0] abc_d,
|
|
|
+ output reg abc_d_oe,
|
|
|
+ input abc_rst_n,
|
|
|
+ input abc_cs_n,
|
|
|
+ input [4:0] abc_out_n,
|
|
|
+ input [1:0] abc_inp_n,
|
|
|
+ input abc_xmemfl_n,
|
|
|
+ input abc_xmemw800_n, // Memory write strobe (ABC800)
|
|
|
+ input abc_xmemw80_n, // Memory write strobe (ABC80)
|
|
|
+ input abc_xinpstb_n, // I/O read strobe (ABC800)
|
|
|
+ input abc_xoutpstb_n, // I/O write strobe (ABC80)
|
|
|
// The following are inverted versus the bus IF
|
|
|
// the corresponding MOSFETs are installed
|
|
|
- output abc_rdy_x, // RDY = WAIT#
|
|
|
- output abc_resin_x, // System reset request
|
|
|
- output abc_int80_x, // System INT request (ABC80)
|
|
|
- output abc_int800_x, // System INT request (ABC800)
|
|
|
- output abc_nmi_x, // System NMI request (ABC800)
|
|
|
- output abc_xm_x, // System memory override (ABC800)
|
|
|
+ output abc_rdy_x, // RDY = WAIT#
|
|
|
+ output abc_resin_x, // System reset request
|
|
|
+ output abc_int80_x, // System INT request (ABC80)
|
|
|
+ output abc_int800_x, // System INT request (ABC800)
|
|
|
+ output abc_nmi_x, // System NMI request (ABC800)
|
|
|
+ output abc_xm_x, // System memory override (ABC800)
|
|
|
// Host/device control
|
|
|
- output abc_host, // 1 = host, 0 = device
|
|
|
- output reg abc_a_oe,
|
|
|
+ output abc_host, // 1 = host, 0 = device
|
|
|
+ output reg abc_a_oe,
|
|
|
// Bus isolation
|
|
|
- output abc_d_ce_n,
|
|
|
+ output abc_d_ce_n,
|
|
|
|
|
|
// ABC-bus extension header
|
|
|
// (Note: cannot use an array here because HC and HH are
|
|
|
// input only.)
|
|
|
- inout exth_ha,
|
|
|
- inout exth_hb,
|
|
|
- input exth_hc,
|
|
|
- inout exth_hd,
|
|
|
- inout exth_he,
|
|
|
- inout exth_hf,
|
|
|
- inout exth_hg,
|
|
|
- input exth_hh,
|
|
|
+ inout exth_ha,
|
|
|
+ inout exth_hb,
|
|
|
+ input exth_hc,
|
|
|
+ inout exth_hd,
|
|
|
+ inout exth_he,
|
|
|
+ inout exth_hf,
|
|
|
+ inout exth_hg,
|
|
|
+ input exth_hh,
|
|
|
|
|
|
// SDRAM interface
|
|
|
- output [24:0] sdram_addr,
|
|
|
- input [7:0] sdram_rd,
|
|
|
- output reg sdram_rrq,
|
|
|
- input sdram_rack,
|
|
|
- input sdram_rready,
|
|
|
- output [7:0] sdram_wd,
|
|
|
- output reg sdram_wrq,
|
|
|
- input sdram_wack
|
|
|
+ output [24:0] sdram_addr,
|
|
|
+ input [7:0] sdram_rd,
|
|
|
+ output reg sdram_rrq,
|
|
|
+ input sdram_rack,
|
|
|
+ input sdram_rready,
|
|
|
+ output [7:0] sdram_wd,
|
|
|
+ output reg sdram_wrq,
|
|
|
+ input sdram_wack
|
|
|
);
|
|
|
|
|
|
// Set if MOSFETs Q1-Q6 are installed rather than the corresponding
|