mirror of
https://github.com/holub/mame
synced 2025-04-20 23:42:22 +03:00
heathzenith/h89: Change how SigmaSoft parallel port connects to IGC (#13040)
This commit is contained in:
parent
3b6388bd6c
commit
ed76d900c1
@ -1816,6 +1816,60 @@ void heath_igc_tlb_device::device_reset()
|
||||
m_window_address = 0x0000;
|
||||
}
|
||||
|
||||
void heath_igc_tlb_device::sigma_w(u8 offset, u8 data)
|
||||
{
|
||||
switch (offset)
|
||||
{
|
||||
case 0:
|
||||
sigma_video_mem_w(data);
|
||||
break;
|
||||
case 1:
|
||||
sigma_io_lo_addr_w(data);
|
||||
break;
|
||||
case 2:
|
||||
sigma_io_hi_addr_w(data);
|
||||
break;
|
||||
case 3:
|
||||
sigma_window_lo_addr_w(data);
|
||||
break;
|
||||
case 4:
|
||||
sigma_window_hi_addr_w(data);
|
||||
break;
|
||||
case 5:
|
||||
sigma_ctrl_w(data);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
u8 heath_igc_tlb_device::sigma_r(u8 offset)
|
||||
{
|
||||
u8 val = 0;
|
||||
|
||||
switch (offset)
|
||||
{
|
||||
case 0:
|
||||
val = sigma_video_mem_r();
|
||||
break;
|
||||
case 1:
|
||||
// TODO - Low pen address
|
||||
break;
|
||||
case 2:
|
||||
// TODO - High pen address
|
||||
break;
|
||||
case 3:
|
||||
// TODO - Left input device
|
||||
break;
|
||||
case 4:
|
||||
// TODO - Right input device
|
||||
break;
|
||||
case 5:
|
||||
val = sigma_ctrl_r();
|
||||
break;
|
||||
}
|
||||
|
||||
return val;
|
||||
}
|
||||
|
||||
void heath_igc_tlb_device::sigma_ctrl_w(u8 data)
|
||||
{
|
||||
LOGREG("%s: data: %02x\n", FUNCNAME, data);
|
||||
|
@ -38,14 +38,8 @@ public:
|
||||
virtual void cts_in_w(int state) {}
|
||||
|
||||
// optional SigmaSet operations
|
||||
virtual void sigma_ctrl_w(u8 data) {}
|
||||
virtual u8 sigma_ctrl_r() { return 0x00; }
|
||||
virtual u8 sigma_video_mem_r() { return 0x00; }
|
||||
virtual void sigma_video_mem_w(u8 val) {}
|
||||
virtual void sigma_io_lo_addr_w(u8 val) {}
|
||||
virtual void sigma_io_hi_addr_w(u8 val) {}
|
||||
virtual void sigma_window_lo_addr_w(u8 val) {}
|
||||
virtual void sigma_window_hi_addr_w(u8 val) {}
|
||||
virtual void sigma_w(u8 offset, u8 data) {}
|
||||
virtual u8 sigma_r(u8 offset) { return 0x00; }
|
||||
|
||||
protected:
|
||||
device_heath_tlb_card_interface(const machine_config &mconfig, device_t &device);
|
||||
@ -317,17 +311,8 @@ class heath_igc_tlb_device : public heath_tlb_device
|
||||
public:
|
||||
heath_igc_tlb_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0);
|
||||
|
||||
virtual void sigma_ctrl_w(u8 data) override;
|
||||
virtual u8 sigma_ctrl_r() override;
|
||||
|
||||
virtual u8 sigma_video_mem_r() override;
|
||||
virtual void sigma_video_mem_w(u8 val) override;
|
||||
|
||||
virtual void sigma_io_lo_addr_w(u8 val) override;
|
||||
virtual void sigma_io_hi_addr_w(u8 val) override;
|
||||
|
||||
virtual void sigma_window_lo_addr_w(u8 val) override;
|
||||
virtual void sigma_window_hi_addr_w(u8 val) override;
|
||||
virtual void sigma_w(u8 offset, u8 data) override;
|
||||
virtual u8 sigma_r(u8 offset) override;
|
||||
|
||||
protected:
|
||||
heath_igc_tlb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock = 0);
|
||||
@ -338,6 +323,19 @@ protected:
|
||||
|
||||
virtual MC6845_UPDATE_ROW(crtc_update_row) override;
|
||||
|
||||
virtual void sigma_ctrl_w(u8 data);
|
||||
virtual u8 sigma_ctrl_r();
|
||||
|
||||
u8 sigma_video_mem_r();
|
||||
void sigma_video_mem_w(u8 val);
|
||||
|
||||
void sigma_io_lo_addr_w(u8 val);
|
||||
void sigma_io_hi_addr_w(u8 val);
|
||||
|
||||
void sigma_window_lo_addr_w(u8 val);
|
||||
void sigma_window_hi_addr_w(u8 val);
|
||||
|
||||
|
||||
std::unique_ptr<u8[]> m_p_graphic_ram;
|
||||
|
||||
// Control Register
|
||||
@ -457,17 +455,8 @@ public:
|
||||
void reset_out(int data) { m_reset(data); }
|
||||
|
||||
// optional SigmaSet IGC operations
|
||||
u8 sigma_ctrl_r() { return (m_tlb) ? m_tlb->sigma_ctrl_r() : 0x00; }
|
||||
void sigma_ctrl_w(u8 data) { if (m_tlb) m_tlb->sigma_ctrl_w(data); }
|
||||
|
||||
u8 sigma_video_mem_r() { return (m_tlb) ? m_tlb->sigma_video_mem_r() : 0x00; }
|
||||
void sigma_video_mem_w(u8 val) { if (m_tlb) m_tlb->sigma_video_mem_w(val); }
|
||||
|
||||
void sigma_io_lo_addr_w(u8 val) { if (m_tlb) m_tlb->sigma_io_lo_addr_w(val); }
|
||||
void sigma_io_hi_addr_w(u8 val) { if (m_tlb) m_tlb->sigma_io_hi_addr_w(val); }
|
||||
|
||||
void sigma_window_lo_addr_w(u8 val) { if (m_tlb) m_tlb->sigma_window_lo_addr_w(val); }
|
||||
void sigma_window_hi_addr_w(u8 val) { if (m_tlb) m_tlb->sigma_window_hi_addr_w(val); }
|
||||
u8 sigma_r(u8 offset) { return (m_tlb) ? m_tlb->sigma_r(offset) : 0x00; }
|
||||
void sigma_w(u8 offset, u8 data) { if (m_tlb) m_tlb->sigma_w(offset, data); }
|
||||
|
||||
protected:
|
||||
virtual void device_start() override ATTR_COLD;
|
||||
|
@ -13,16 +13,11 @@
|
||||
#include "h_88_3.h"
|
||||
#include "h_88_5.h"
|
||||
#include "mms77316_fdc.h"
|
||||
#include "sigmasoft_parallel_port.h"
|
||||
#include "sigmasoft_sound.h"
|
||||
#include "we_pullup.h"
|
||||
#include "z_89_11.h"
|
||||
#include "z37_fdc.h"
|
||||
|
||||
void h89_left_cards(device_slot_interface &device)
|
||||
{
|
||||
device.option_add("ss_parallel", H89BUS_SIGMASOFT_PARALLEL);
|
||||
}
|
||||
|
||||
void h89_right_cards(device_slot_interface &device)
|
||||
{
|
||||
|
@ -11,7 +11,6 @@
|
||||
|
||||
#pragma once
|
||||
|
||||
void h89_left_cards(device_slot_interface &device) ATTR_COLD;
|
||||
void h89_right_cards(device_slot_interface &device) ATTR_COLD;
|
||||
void h89_right_cards_mms(device_slot_interface &device) ATTR_COLD;
|
||||
void h89_right_p506_cards(device_slot_interface &device) ATTR_COLD;
|
||||
|
@ -32,192 +32,97 @@
|
||||
#define FUNCNAME __PRETTY_FUNCTION__
|
||||
#endif
|
||||
|
||||
// TODO make this configurable with jumper config
|
||||
static constexpr u8 BASE_ADDR = 0x08;
|
||||
|
||||
class sigmasoft_parallel_port : public device_t, public device_h89bus_left_card_interface
|
||||
{
|
||||
public:
|
||||
sigmasoft_parallel_port(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0);
|
||||
|
||||
virtual u8 read(u8 select_lines, u16 offset) override;
|
||||
virtual void write(u8 select_lines, u16 offset, u8 data) override;
|
||||
|
||||
auto ctrl_r_cb() { return m_ctrl_r.bind(); }
|
||||
auto video_mem_r_cb() { return m_video_mem_r.bind(); }
|
||||
|
||||
auto video_mem_cb() { return m_video_mem_w.bind(); }
|
||||
auto io_lo_cb() { return m_io_lo_addr.bind(); }
|
||||
auto io_hi_cb() { return m_io_hi_addr.bind(); }
|
||||
auto window_lo_cb() { return m_window_lo_addr.bind(); }
|
||||
auto window_hi_cb() { return m_window_hi_addr.bind(); }
|
||||
auto ctrl_cb() { return m_ctrl_w.bind(); }
|
||||
|
||||
protected:
|
||||
|
||||
virtual void device_start() override ATTR_COLD;
|
||||
virtual void device_add_mconfig(machine_config& config) override ATTR_COLD;;
|
||||
|
||||
u8 video_mem_r();
|
||||
void video_mem_w(u8 val);
|
||||
|
||||
void io_lo_addr_w(u8 val);
|
||||
void io_hi_addr_w(u8 val);
|
||||
|
||||
void window_lo_addr_w(u8 val);
|
||||
void window_hi_addr_w(u8 val);
|
||||
|
||||
void ctrl_w(u8 val);
|
||||
u8 ctrl_r();
|
||||
|
||||
private:
|
||||
|
||||
// Reads
|
||||
devcb_read8 m_ctrl_r;
|
||||
devcb_read8 m_video_mem_r;
|
||||
|
||||
// Writes
|
||||
devcb_write8 m_video_mem_w;
|
||||
devcb_write8 m_io_lo_addr;
|
||||
devcb_write8 m_io_hi_addr;
|
||||
devcb_write8 m_window_lo_addr;
|
||||
devcb_write8 m_window_hi_addr;
|
||||
devcb_write8 m_ctrl_w;
|
||||
};
|
||||
|
||||
static constexpr u16 SELECT_ADDR_MASK = 0xF8;
|
||||
|
||||
/**
|
||||
* The SigmaSoft Parallel Port
|
||||
*/
|
||||
sigmasoft_parallel_port::sigmasoft_parallel_port(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock):
|
||||
device_t(mconfig, H89BUS_SIGMASOFT_PARALLEL, tag, owner, clock),
|
||||
sigmasoft_parallel_port(mconfig, H89BUS_SIGMASOFT_PARALLEL, tag, owner, clock)
|
||||
{
|
||||
}
|
||||
|
||||
sigmasoft_parallel_port::sigmasoft_parallel_port(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock):
|
||||
device_t(mconfig, type, tag, owner, clock),
|
||||
device_h89bus_left_card_interface(mconfig, *this),
|
||||
m_ctrl_r(*this, 0x00),
|
||||
m_video_mem_r(*this, 0x00),
|
||||
m_video_mem_w(*this),
|
||||
m_io_lo_addr(*this),
|
||||
m_io_hi_addr(*this),
|
||||
m_window_lo_addr(*this),
|
||||
m_window_hi_addr(*this),
|
||||
m_ctrl_w(*this)
|
||||
m_jumpers(*this, "JUMPERS")
|
||||
{
|
||||
}
|
||||
|
||||
void sigmasoft_parallel_port::video_mem_w(u8 val)
|
||||
inline bool sigmasoft_parallel_port::card_selected(u8 select_lines, u16 offset)
|
||||
{
|
||||
m_video_mem_w(val);
|
||||
return m_enabled &&
|
||||
(select_lines & h89bus_device::H89_IO) &&
|
||||
((offset & SELECT_ADDR_MASK) == m_base_addr);
|
||||
}
|
||||
|
||||
void sigmasoft_parallel_port::io_lo_addr_w(u8 val)
|
||||
void sigmasoft_parallel_port::igc_w(u8 offset, u8 val)
|
||||
{
|
||||
m_io_lo_addr(val);
|
||||
}
|
||||
|
||||
void sigmasoft_parallel_port::io_hi_addr_w(u8 val)
|
||||
{
|
||||
m_io_hi_addr(val);
|
||||
}
|
||||
|
||||
void sigmasoft_parallel_port::window_lo_addr_w(u8 val)
|
||||
{
|
||||
m_window_lo_addr(val);
|
||||
}
|
||||
|
||||
void sigmasoft_parallel_port::window_hi_addr_w(u8 val)
|
||||
{
|
||||
m_window_hi_addr(val);
|
||||
}
|
||||
|
||||
void sigmasoft_parallel_port::ctrl_w(u8 val)
|
||||
{
|
||||
m_ctrl_w(val);
|
||||
}
|
||||
|
||||
void sigmasoft_parallel_port::write(u8 select_lines, u16 offset, u8 data)
|
||||
{
|
||||
offset -= BASE_ADDR;
|
||||
if (!(select_lines & h89bus_device::H89_IO) || offset >= 8)
|
||||
if (!card_selected(select_lines, offset))
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
LOGFUNC("%s: reg: %d val: %d\n", FUNCNAME, offset, data);
|
||||
|
||||
offset &= 0x07;
|
||||
|
||||
switch (offset)
|
||||
{
|
||||
case 0:
|
||||
video_mem_w(data);
|
||||
break;
|
||||
case 1:
|
||||
io_lo_addr_w(data);
|
||||
break;
|
||||
case 2:
|
||||
io_hi_addr_w(data);
|
||||
break;
|
||||
case 3:
|
||||
window_lo_addr_w(data);
|
||||
break;
|
||||
case 4:
|
||||
window_hi_addr_w(data);
|
||||
break;
|
||||
case 5:
|
||||
ctrl_w(data);
|
||||
break;
|
||||
case 6:
|
||||
// TODO - Centronics interface
|
||||
break;
|
||||
case 7:
|
||||
// TODO - Centronics interface
|
||||
break;
|
||||
case 0:
|
||||
case 1:
|
||||
case 2:
|
||||
case 3:
|
||||
case 4:
|
||||
case 5:
|
||||
igc_w(offset, data);
|
||||
break;
|
||||
case 6:
|
||||
// TODO - Centronics interface
|
||||
break;
|
||||
case 7:
|
||||
// TODO - Centronics interface
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
u8 sigmasoft_parallel_port::video_mem_r()
|
||||
u8 sigmasoft_parallel_port::igc_r(u8 offset)
|
||||
{
|
||||
// get video memory value from igc device
|
||||
return m_video_mem_r();
|
||||
}
|
||||
|
||||
u8 sigmasoft_parallel_port::ctrl_r()
|
||||
{
|
||||
// get control register from igc device
|
||||
return m_ctrl_r();
|
||||
return 0;
|
||||
}
|
||||
|
||||
u8 sigmasoft_parallel_port::read(u8 select_lines, u16 offset)
|
||||
{
|
||||
offset -= BASE_ADDR;
|
||||
u8 value = 0x00;
|
||||
u8 value = 0;
|
||||
|
||||
if (!(select_lines & h89bus_device::H89_IO) || offset >= 8)
|
||||
if (!card_selected(select_lines, offset))
|
||||
{
|
||||
return value;
|
||||
}
|
||||
|
||||
offset &= 0x07;
|
||||
|
||||
switch (offset)
|
||||
{
|
||||
case 0:
|
||||
value = video_mem_r();
|
||||
break;
|
||||
case 1:
|
||||
// TODO - Light Pen Low address
|
||||
break;
|
||||
case 2:
|
||||
// TODO - Light Pen High address
|
||||
break;
|
||||
case 3:
|
||||
// TODO - Left input device
|
||||
break;
|
||||
case 4:
|
||||
// TODO - Right input device
|
||||
break;
|
||||
case 5:
|
||||
// Control Register
|
||||
value = ctrl_r();
|
||||
break;
|
||||
case 6:
|
||||
// TODO - Centronics interface
|
||||
break;
|
||||
case 7:
|
||||
// TODO - Centronics interface
|
||||
break;
|
||||
case 0:
|
||||
case 1:
|
||||
case 2:
|
||||
case 3:
|
||||
case 4:
|
||||
case 5:
|
||||
value = igc_r(offset);
|
||||
break;
|
||||
case 6:
|
||||
// TODO - Centronics interface
|
||||
break;
|
||||
case 7:
|
||||
// TODO - Centronics interface
|
||||
break;
|
||||
}
|
||||
|
||||
LOGFUNC("%s: reg: %d val: %d\n", FUNCNAME, offset, value);
|
||||
@ -229,17 +134,73 @@ void sigmasoft_parallel_port::device_start()
|
||||
{
|
||||
}
|
||||
|
||||
void sigmasoft_parallel_port::device_add_mconfig(machine_config &config)
|
||||
void sigmasoft_parallel_port::device_reset()
|
||||
{
|
||||
// connect callbacks to TLB
|
||||
ctrl_r_cb().set("^^tlbc", FUNC(heath_tlb_connector::sigma_ctrl_r));
|
||||
video_mem_r_cb().set("^^tlbc", FUNC(heath_tlb_connector::sigma_video_mem_r));
|
||||
video_mem_cb().set("^^tlbc", FUNC(heath_tlb_connector::sigma_video_mem_w));
|
||||
io_lo_cb().set("^^tlbc", FUNC(heath_tlb_connector::sigma_io_lo_addr_w));
|
||||
io_hi_cb().set("^^tlbc", FUNC(heath_tlb_connector::sigma_io_hi_addr_w));
|
||||
window_lo_cb().set("^^tlbc", FUNC(heath_tlb_connector::sigma_window_lo_addr_w));
|
||||
window_hi_cb().set("^^tlbc", FUNC(heath_tlb_connector::sigma_window_hi_addr_w));
|
||||
ctrl_cb().set("^^tlbc", FUNC(heath_tlb_connector::sigma_ctrl_w));
|
||||
ioport_value const jumpers(m_jumpers->read());
|
||||
|
||||
m_enabled = bool(jumpers & 0x20);
|
||||
|
||||
m_base_addr = (jumpers & 0x1f) << 3;
|
||||
}
|
||||
|
||||
static INPUT_PORTS_START( sigmasoft_parallel_port_device )
|
||||
PORT_START("JUMPERS")
|
||||
PORT_CONFNAME(0x01, 0x01, "Port Address Selection a3" )
|
||||
PORT_CONFSETTING( 0x00, "0")
|
||||
PORT_CONFSETTING( 0x01, "1")
|
||||
PORT_CONFNAME(0x02, 0x00, "Port Address Selection a4" )
|
||||
PORT_CONFSETTING( 0x00, "0")
|
||||
PORT_CONFSETTING( 0x02, "1")
|
||||
PORT_CONFNAME(0x04, 0x00, "Port Address Selection a5" )
|
||||
PORT_CONFSETTING( 0x00, "0")
|
||||
PORT_CONFSETTING( 0x04, "1")
|
||||
PORT_CONFNAME(0x08, 0x00, "Port Address Selection a6" )
|
||||
PORT_CONFSETTING( 0x00, "0")
|
||||
PORT_CONFSETTING( 0x08, "1")
|
||||
PORT_CONFNAME(0x10, 0x00, "Port Address Selection a7" )
|
||||
PORT_CONFSETTING( 0x00, "0")
|
||||
PORT_CONFSETTING( 0x10, "1")
|
||||
|
||||
PORT_CONFNAME(0x20, 0x20, "Enabled" )
|
||||
PORT_CONFSETTING( 0x00, DEF_STR( No ))
|
||||
PORT_CONFSETTING( 0x20, DEF_STR( Yes ))
|
||||
INPUT_PORTS_END
|
||||
|
||||
ioport_constructor sigmasoft_parallel_port::device_input_ports() const
|
||||
{
|
||||
return INPUT_PORTS_NAME(sigmasoft_parallel_port_device);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* The SigmaSoft Parallel Port connected to a SigmaSoft IGC board
|
||||
*/
|
||||
sigmasoft_parallel_port_igc::sigmasoft_parallel_port_igc(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock):
|
||||
sigmasoft_parallel_port(mconfig, H89BUS_SIGMASOFT_PARALLEL_IGC, tag, owner, clock),
|
||||
m_tlbc(*this, finder_base::DUMMY_TAG)
|
||||
{
|
||||
}
|
||||
|
||||
void sigmasoft_parallel_port_igc::igc_w(u8 offset, u8 val)
|
||||
{
|
||||
m_tlbc->sigma_w(offset, val);
|
||||
}
|
||||
|
||||
u8 sigmasoft_parallel_port_igc::igc_r(u8 offset)
|
||||
{
|
||||
return m_tlbc->sigma_r(offset);
|
||||
}
|
||||
|
||||
void sigmasoft_parallel_port_igc::device_start()
|
||||
{
|
||||
sigmasoft_parallel_port::device_start();
|
||||
}
|
||||
|
||||
void sigmasoft_parallel_port_igc::device_reset()
|
||||
{
|
||||
sigmasoft_parallel_port::device_reset();
|
||||
}
|
||||
|
||||
|
||||
DEFINE_DEVICE_TYPE_PRIVATE(H89BUS_SIGMASOFT_PARALLEL, device_h89bus_left_card_interface, sigmasoft_parallel_port, "sigmasoft_parallel_port", "SigmaSoft Universal Parallel Board");
|
||||
DEFINE_DEVICE_TYPE_PRIVATE(H89BUS_SIGMASOFT_PARALLEL_IGC, device_h89bus_left_card_interface, sigmasoft_parallel_port_igc, "sigmasoft_parallel_port_igc", "SigmaSoft Universal Parallel Board connected to SigmaSoft IGC");
|
||||
|
@ -13,6 +13,61 @@
|
||||
|
||||
#include "h89bus.h"
|
||||
|
||||
#include "bus/heathzenith/h19/tlb.h"
|
||||
|
||||
class sigmasoft_parallel_port : public device_t, public device_h89bus_left_card_interface
|
||||
{
|
||||
public:
|
||||
sigmasoft_parallel_port(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0);
|
||||
|
||||
virtual u8 read(u8 select_lines, u16 offset) override;
|
||||
virtual void write(u8 select_lines, u16 offset, u8 data) override;
|
||||
|
||||
protected:
|
||||
sigmasoft_parallel_port(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock);
|
||||
|
||||
virtual void device_start() override ATTR_COLD;
|
||||
virtual void device_reset() override ATTR_COLD;
|
||||
virtual ioport_constructor device_input_ports() const override ATTR_COLD;
|
||||
|
||||
inline bool card_selected(u8 select_lines, u16 offset);
|
||||
|
||||
virtual void igc_w(u8 offset, u8 val);
|
||||
virtual u8 igc_r(u8 offset);
|
||||
|
||||
private:
|
||||
|
||||
required_ioport m_jumpers;
|
||||
|
||||
// physical jumper on the board to enable/disable entire board
|
||||
bool m_enabled;
|
||||
|
||||
// base address of board configured by jumpers.
|
||||
u16 m_base_addr;
|
||||
};
|
||||
|
||||
class sigmasoft_parallel_port_igc : public sigmasoft_parallel_port
|
||||
{
|
||||
public:
|
||||
sigmasoft_parallel_port_igc(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0);
|
||||
|
||||
template <typename T> void set_tlbc(T &&tag) { m_tlbc.set_tag(std::forward<T>(tag)); }
|
||||
|
||||
protected:
|
||||
|
||||
virtual void device_start() override ATTR_COLD;
|
||||
virtual void device_reset() override ATTR_COLD;
|
||||
|
||||
virtual void igc_w(u8 offset, u8 val) override;
|
||||
virtual u8 igc_r(u8 offset) override;
|
||||
|
||||
private:
|
||||
|
||||
required_device<heath_tlb_connector> m_tlbc;
|
||||
|
||||
};
|
||||
|
||||
DECLARE_DEVICE_TYPE(H89BUS_SIGMASOFT_PARALLEL, device_h89bus_left_card_interface)
|
||||
DECLARE_DEVICE_TYPE(H89BUS_SIGMASOFT_PARALLEL_IGC, device_h89bus_left_card_interface)
|
||||
|
||||
#endif // MAME_BUS_HEATHZENITH_H89_SIGMASOFT_PARALLEL_PORT_H
|
||||
|
@ -48,6 +48,8 @@
|
||||
#include "bus/heathzenith/h19/tlb.h"
|
||||
#include "bus/heathzenith/h89/h89bus.h"
|
||||
#include "bus/heathzenith/h89/cards.h"
|
||||
#include "bus/heathzenith/h89/sigmasoft_parallel_port.h"
|
||||
|
||||
#include "cpu/z80/z80.h"
|
||||
#include "machine/ins8250.h"
|
||||
#include "machine/ram.h"
|
||||
@ -157,6 +159,8 @@ protected:
|
||||
void reset_single_step_state();
|
||||
|
||||
template <int line> void slot_irq(int state);
|
||||
|
||||
void h89_left_cards(device_slot_interface &device);
|
||||
};
|
||||
|
||||
/**
|
||||
@ -193,17 +197,6 @@ public:
|
||||
void h89(machine_config &config);
|
||||
};
|
||||
|
||||
class h89_sigmasoft_state : public h89_state
|
||||
{
|
||||
public:
|
||||
h89_sigmasoft_state(const machine_config &mconfig, device_type type, const char *tag):
|
||||
h89_state(mconfig, type, tag)
|
||||
{
|
||||
}
|
||||
|
||||
void h89_sigmasoft(machine_config &config);
|
||||
};
|
||||
|
||||
class h89_cdr_state : public h89_base_state
|
||||
{
|
||||
public:
|
||||
@ -910,24 +903,17 @@ void h89_mms_state::port_f2_mms_w(offs_t offset, u8 data)
|
||||
|
||||
static void tlb_options(device_slot_interface &device)
|
||||
{
|
||||
device.option_add("heath", HEATH_TLB);
|
||||
device.option_add("gp19", HEATH_GP19);
|
||||
device.option_add("imaginator", HEATH_IMAGINATOR);
|
||||
device.option_add("super19", HEATH_SUPER19);
|
||||
device.option_add("superset", HEATH_SUPERSET);
|
||||
device.option_add("ultrarom", HEATH_ULTRA);
|
||||
device.option_add("watzman", HEATH_WATZ);
|
||||
}
|
||||
|
||||
|
||||
static void sigma_tlb_options(device_slot_interface *device)
|
||||
{
|
||||
device->option_reset();
|
||||
device->option_add("igc", HEATH_IGC);
|
||||
device->option_add("igc_super19", HEATH_IGC_SUPER19);
|
||||
device->option_add("igc_ultrarom", HEATH_IGC_ULTRA);
|
||||
device->option_add("igc_watzman", HEATH_IGC_WATZ);
|
||||
device->set_default_option("igc");
|
||||
device.option_add("heath", HEATH_TLB);
|
||||
device.option_add("gp19", HEATH_GP19);
|
||||
device.option_add("imaginator", HEATH_IMAGINATOR);
|
||||
device.option_add("super19", HEATH_SUPER19);
|
||||
device.option_add("superset", HEATH_SUPERSET);
|
||||
device.option_add("ultrarom", HEATH_ULTRA);
|
||||
device.option_add("watzman", HEATH_WATZ);
|
||||
device.option_add("igc", HEATH_IGC);
|
||||
device.option_add("igc_super19", HEATH_IGC_SUPER19);
|
||||
device.option_add("igc_ultrarom", HEATH_IGC_ULTRA);
|
||||
device.option_add("igc_watzman", HEATH_IGC_WATZ);
|
||||
}
|
||||
|
||||
static void intr_ctrl_options(device_slot_interface &device)
|
||||
@ -937,6 +923,18 @@ static void intr_ctrl_options(device_slot_interface &device)
|
||||
device.option_add("mms", HEATH_MMS_INTR_CNTRL);
|
||||
}
|
||||
|
||||
|
||||
void h89_base_state::h89_left_cards(device_slot_interface &device)
|
||||
{
|
||||
device.option_add("ss_parallel", H89BUS_SIGMASOFT_PARALLEL);
|
||||
device.option_add("ss_parallel_igc", H89BUS_SIGMASOFT_PARALLEL_IGC).machine_config(
|
||||
[this](device_t *device)
|
||||
{
|
||||
downcast<sigmasoft_parallel_port_igc &>(*device).set_tlbc(m_tlbc);
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
void h89_base_state::h89_base(machine_config &config)
|
||||
{
|
||||
config.set_default_layout(layout_h89);
|
||||
@ -985,9 +983,9 @@ void h89_base_state::h89_base(machine_config &config)
|
||||
m_h89bus->out_fdcdrq_callback().set(m_intr_socket, FUNC(heath_intr_socket::set_drq));
|
||||
m_h89bus->out_blockirq_callback().set(m_intr_socket, FUNC(heath_intr_socket::block_interrupts));
|
||||
m_h89bus->out_fmwe_callback().set(FUNC(h89_base_state::set_fmwe));
|
||||
H89BUS_LEFT_SLOT(config, "p501", "h89bus", h89_left_cards, nullptr);
|
||||
H89BUS_LEFT_SLOT(config, "p502", "h89bus", h89_left_cards, nullptr);
|
||||
H89BUS_LEFT_SLOT(config, "p503", "h89bus", h89_left_cards, nullptr);
|
||||
H89BUS_LEFT_SLOT(config, "p501", "h89bus", [this](device_slot_interface &device) { h89_left_cards(device); }, nullptr);
|
||||
H89BUS_LEFT_SLOT(config, "p502", "h89bus", [this](device_slot_interface &device) { h89_left_cards(device); }, nullptr);
|
||||
H89BUS_LEFT_SLOT(config, "p503", "h89bus", [this](device_slot_interface &device) { h89_left_cards(device); }, nullptr);
|
||||
H89BUS_RIGHT_SLOT(config, "p504", "h89bus", h89_right_cards, nullptr);
|
||||
H89BUS_RIGHT_SLOT(config, "p505", "h89bus", h89_right_cards, "ha_88_3");
|
||||
H89BUS_RIGHT_SLOT(config, "p506", "h89bus", h89_right_p506_cards, "we_pullup").set_p506_signalling(true);
|
||||
@ -1018,16 +1016,6 @@ void h89_state::h89(machine_config &config)
|
||||
H89BUS_RIGHT_SLOT(config.replace(), "p504", "h89bus", h89_right_cards, "z37fdc");
|
||||
}
|
||||
|
||||
void h89_sigmasoft_state::h89_sigmasoft(machine_config &config)
|
||||
{
|
||||
h89(config);
|
||||
m_h89bus->set_default_bios_tag("444-61");
|
||||
|
||||
sigma_tlb_options(m_tlbc);
|
||||
|
||||
H89BUS_LEFT_SLOT(config.replace(), "p501", "h89bus", h89_left_cards, "ss_parallel");
|
||||
}
|
||||
|
||||
void h89_cdr_state::h89_cdr(machine_config &config)
|
||||
{
|
||||
h89_base(config);
|
||||
@ -1148,37 +1136,6 @@ ROM_START( h89 )
|
||||
ROM_CDR_80B2(11)
|
||||
ROM_END
|
||||
|
||||
ROM_START( h89_sigmasoft )
|
||||
ROM_REGION( 0x2000, "maincpu", ROMREGION_ERASEFF )
|
||||
ROM_DEFAULT_BIOS("mtr90")
|
||||
|
||||
ROM_H17
|
||||
|
||||
ROM_MTR90_444_142(0)
|
||||
|
||||
ROM_MTR89(1)
|
||||
|
||||
ROM_MMS_444_84B(2)
|
||||
|
||||
ROM_KMR_100(3)
|
||||
|
||||
ROM_ULTIMETH_4K(4)
|
||||
|
||||
ROM_MTR90_444_84(5)
|
||||
|
||||
ROM_MMS_444_84A(6)
|
||||
|
||||
ROM_ULTIMETH_2K(7)
|
||||
|
||||
ROM_SIGMA_V_1_3(8)
|
||||
|
||||
ROM_SIGMA_V_1_2(9)
|
||||
|
||||
ROM_CDR_8390(10)
|
||||
|
||||
ROM_CDR_80B2(11)
|
||||
ROM_END
|
||||
|
||||
ROM_START( h89_cdr )
|
||||
ROM_REGION( 0x2000, "maincpu", ROMREGION_ERASEFF )
|
||||
ROM_DEFAULT_BIOS("cdr8390")
|
||||
@ -1247,4 +1204,3 @@ COMP( 1979, h89, 0, 0, h89, h89, h89_state,
|
||||
COMP( 1981, h89_cdr, h89, 0, h89_cdr, h89, h89_cdr_state, empty_init, "Heath Company", "H-89 with CDR Equipment", MACHINE_SUPPORTS_SAVE)
|
||||
COMP( 1981, h89_mms, h89, 0, h89_mms, h89, h89_mms_state, empty_init, "Heath Company", "H-89 with MMS Equipment", MACHINE_SUPPORTS_SAVE)
|
||||
COMP( 1981, z90, h89, 0, h89, h89, h89_state, empty_init, "Zenith Data Systems", "Z-90", MACHINE_SUPPORTS_SAVE)
|
||||
COMP( 1984, h89_sigmasoft, h89, 0, h89_sigmasoft, h89, h89_sigmasoft_state, empty_init, "Heath Company", "H-89 with SigmaSoft IGC", MACHINE_SUPPORTS_SAVE)
|
||||
|
@ -19634,7 +19634,6 @@ h89 // Heath H89 (WH89)
|
||||
h88 // Heath H88 (with cassette tape)
|
||||
h89_cdr // Heath H89 with CDR Systems hardware
|
||||
h89_mms // Heath H89 with Magnolia MicroSystems(MMS) hardware
|
||||
h89_sigmasoft // H89 with the SigmaSoft IGC card
|
||||
z90 // Zenith Z-90
|
||||
|
||||
@source:heathzenith/mdt60.cpp
|
||||
|
Loading…
Reference in New Issue
Block a user