mirror of
https://github.com/holub/mame
synced 2025-04-23 00:39:36 +03:00
gottlieb.cpp and gts80.cpp: Add support for the older version of the MA-216 "Sound and speech" board which has a Votrax SC-01 populated instead of an SC-01-A. [Lord Nightmare]
This commit is contained in:
parent
b8553885f6
commit
c9397179aa
@ -261,10 +261,12 @@ public:
|
||||
void gottlieb2_ram_rom(machine_config &config);
|
||||
void reactor(machine_config &config);
|
||||
void g2laser(machine_config &config);
|
||||
void qbert_old(machine_config &config);
|
||||
void qbert(machine_config &config);
|
||||
void qbert_knocker(machine_config &config);
|
||||
void gottlieb1(machine_config &config);
|
||||
void gottlieb1_rom(machine_config &config);
|
||||
void gottlieb1_votrax_old(machine_config &config);
|
||||
void gottlieb1_votrax(machine_config &config);
|
||||
|
||||
void init_romtiles();
|
||||
@ -2162,10 +2164,16 @@ void gottlieb_state::gottlieb1(machine_config &config)
|
||||
GOTTLIEB_SOUND_REV1(config, m_r1_sound).add_route(ALL_OUTPUTS, "speaker", 1.0);
|
||||
}
|
||||
|
||||
void gottlieb_state::gottlieb1_votrax_old(machine_config &config)
|
||||
{
|
||||
gottlieb_core(config);
|
||||
GOTTLIEB_SOUND_SPEECH_REV1(config, m_r1_sound).add_route(ALL_OUTPUTS, "speaker", 1.0);
|
||||
}
|
||||
|
||||
void gottlieb_state::gottlieb1_votrax(machine_config &config)
|
||||
{
|
||||
gottlieb_core(config);
|
||||
GOTTLIEB_SOUND_REV1_VOTRAX(config, m_r1_sound).add_route(ALL_OUTPUTS, "speaker", 1.0);
|
||||
GOTTLIEB_SOUND_SPEECH_REV1A(config, m_r1_sound).add_route(ALL_OUTPUTS, "speaker", 1.0);
|
||||
}
|
||||
|
||||
void gottlieb_state::gottlieb1_rom(machine_config &config)
|
||||
@ -2215,7 +2223,7 @@ void gottlieb_state::g2laser(machine_config &config)
|
||||
|
||||
void gottlieb_state::reactor(machine_config &config)
|
||||
{
|
||||
gottlieb1_votrax(config);
|
||||
gottlieb1_votrax_old(config);
|
||||
|
||||
/* basic machine hardware */
|
||||
m_maincpu->set_addrmap(AS_PROGRAM, &gottlieb_state::reactor_map);
|
||||
@ -2223,6 +2231,14 @@ void gottlieb_state::reactor(machine_config &config)
|
||||
config.device_remove("nvram");
|
||||
}
|
||||
|
||||
void gottlieb_state::qbert_old(machine_config &config)
|
||||
{
|
||||
gottlieb1_votrax_old(config);
|
||||
|
||||
/* sound hardware */
|
||||
qbert_knocker(config);
|
||||
}
|
||||
|
||||
void gottlieb_state::qbert(machine_config &config)
|
||||
{
|
||||
gottlieb1_votrax(config);
|
||||
@ -3030,7 +3046,7 @@ GAME( 1982, qbert, 0, qbert, qbert, gottlieb_state, i
|
||||
GAME( 1982, qberta, qbert, qbert, qbert, gottlieb_state, init_qbert, ROT270, "Gottlieb", "Q*bert (US set 2)", MACHINE_IMPERFECT_SOUND | MACHINE_SUPPORTS_SAVE )
|
||||
GAME( 1982, qbertj, qbert, qbert, qbert, gottlieb_state, init_qbert, ROT270, "Gottlieb (Konami license)", "Q*bert (Japan)", MACHINE_IMPERFECT_SOUND | MACHINE_SUPPORTS_SAVE )
|
||||
GAME( 1982, myqbert, qbert, qbert, qbert, gottlieb_state, init_qbert, ROT270, "Gottlieb", "Mello Yello Q*bert", MACHINE_IMPERFECT_SOUND | MACHINE_SUPPORTS_SAVE )
|
||||
GAME( 1982, qberttst, qbert, qbert, qbert, gottlieb_state, init_qbert, ROT270, "Gottlieb", "Q*bert (early test version)", MACHINE_IMPERFECT_SOUND | MACHINE_SUPPORTS_SAVE )
|
||||
GAME( 1982, qberttst, qbert, qbert_old, qbert, gottlieb_state, init_qbert, ROT270, "Gottlieb", "Q*bert (early test version)", MACHINE_IMPERFECT_SOUND | MACHINE_SUPPORTS_SAVE )
|
||||
GAME( 1982, qbtrktst, qbert, qbert, qbert, gottlieb_state, init_qbert, ROT270, "Gottlieb", "Q*bert Board Input Test Rom", MACHINE_IMPERFECT_SOUND | MACHINE_SUPPORTS_SAVE )
|
||||
GAME( 1982, insector, 0, gottlieb1, insector, gottlieb_state, init_romtiles, ROT0, "Gottlieb", "Insector (prototype)", MACHINE_SUPPORTS_SAVE )
|
||||
GAME( 1982, tylz, 0, gottlieb1_votrax, tylz, gottlieb_state, init_romtiles, ROT0, "Mylstar", "Tylz (prototype)", MACHINE_IMPERFECT_SOUND | MACHINE_SUPPORTS_SAVE ) // modified sound hw?
|
||||
|
@ -547,7 +547,7 @@ void gts80_state::p2(machine_config &config)
|
||||
void gts80_state::r1v(machine_config &config)
|
||||
{
|
||||
p0(config);
|
||||
GOTTLIEB_SOUND_REV1_VOTRAX(config, m_r1_sound).add_route(ALL_OUTPUTS, "mono", 0.75);
|
||||
GOTTLIEB_SOUND_SPEECH_REV1(config, m_r1_sound).add_route(ALL_OUTPUTS, "mono", 0.75);
|
||||
}
|
||||
|
||||
/* SYSTEM-80 ALTERNATE ROMS =======================================================================
|
||||
|
@ -578,7 +578,7 @@ void gts80a_state::r1(machine_config &config)
|
||||
void gts80a_state::r1v(machine_config &config)
|
||||
{
|
||||
p0(config);
|
||||
GOTTLIEB_SOUND_REV1_VOTRAX(config, m_r1_sound).add_route(ALL_OUTPUTS, "mono", 0.75);
|
||||
GOTTLIEB_SOUND_SPEECH_REV1A(config, m_r1_sound).add_route(ALL_OUTPUTS, "mono", 0.75);
|
||||
}
|
||||
|
||||
//******************* CAVEMAN ****************************************************************
|
||||
|
@ -36,7 +36,8 @@ DEFINE_DEVICE_TYPE(GOTTLIEB_SOUND_PIN5, gottlieb_sound_p5_device,
|
||||
DEFINE_DEVICE_TYPE(GOTTLIEB_SOUND_PIN6, gottlieb_sound_p6_device, "gotsndp6", "Gottlieb Sound pin. 6")
|
||||
DEFINE_DEVICE_TYPE(GOTTLIEB_SOUND_PIN7, gottlieb_sound_p7_device, "gotsndp7", "Gottlieb Sound pin. 7")
|
||||
DEFINE_DEVICE_TYPE(GOTTLIEB_SOUND_REV1, gottlieb_sound_r1_device, "gotsndr1", "Gottlieb Sound rev. 1")
|
||||
DEFINE_DEVICE_TYPE(GOTTLIEB_SOUND_REV1_VOTRAX, gottlieb_sound_r1_with_votrax_device, "gotsndr1vt", "Gottlieb Sound rev. 1 with Votrax")
|
||||
DEFINE_DEVICE_TYPE(GOTTLIEB_SOUND_SPEECH_REV1, gottlieb_sound_speech_r1_device, "gotsndspr1", "Gottlieb Sound/Speech rev. 1 w/SC-01")
|
||||
DEFINE_DEVICE_TYPE(GOTTLIEB_SOUND_SPEECH_REV1A,gottlieb_sound_speech_r1a_device, "gotsndspr1a","Gottlieb Sound/Speech rev. 1 w/SC-01-A")
|
||||
DEFINE_DEVICE_TYPE(GOTTLIEB_SOUND_REV2, gottlieb_sound_r2_device, "gotsndr2", "Gottlieb Sound rev. 2")
|
||||
|
||||
|
||||
@ -89,7 +90,7 @@ void gottlieb_sound_p2_device::p2_map(address_map &map)
|
||||
map.unmap_value_high();
|
||||
map(0x0000, 0x003f).mirror(0x1c0).m(m_r6530, FUNC(mos6530_device::ram_map));
|
||||
map(0x0200, 0x020f).mirror(0x1f0).m(m_r6530, FUNC(mos6530_device::io_map));
|
||||
map(0x0400, 0x07ff).rom();
|
||||
map(0x0400, 0x07ff).rom(); // external hm7643-5 1kx4 prom, on d0-d3
|
||||
map(0x0c00, 0x0fff).m(m_r6530, FUNC(mos6530_device::rom_map));
|
||||
}
|
||||
|
||||
@ -379,12 +380,17 @@ void gottlieb_sound_r1_device::device_start()
|
||||
//**************************************************************************
|
||||
|
||||
//-------------------------------------------------
|
||||
// gottlieb_sound_r1_with_votrax_device -
|
||||
// constructor
|
||||
// gottlieb_sound_speech_r1_device -
|
||||
// constructors
|
||||
//-------------------------------------------------
|
||||
|
||||
gottlieb_sound_r1_with_votrax_device::gottlieb_sound_r1_with_votrax_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock)
|
||||
: gottlieb_sound_r1_device(mconfig, GOTTLIEB_SOUND_REV1_VOTRAX, tag, owner, clock)
|
||||
gottlieb_sound_speech_r1_device::gottlieb_sound_speech_r1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock)
|
||||
: gottlieb_sound_speech_r1_device(mconfig, GOTTLIEB_SOUND_SPEECH_REV1, tag, owner, clock)
|
||||
{
|
||||
}
|
||||
|
||||
gottlieb_sound_speech_r1_device::gottlieb_sound_speech_r1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock)
|
||||
: gottlieb_sound_r1_device(mconfig, GOTTLIEB_SOUND_SPEECH_REV1, tag, owner, clock)
|
||||
, m_votrax(*this, "votrax")
|
||||
, m_speech_clock(0)
|
||||
{
|
||||
@ -396,7 +402,7 @@ gottlieb_sound_r1_with_votrax_device::gottlieb_sound_r1_with_votrax_device(const
|
||||
// speech chip
|
||||
//-------------------------------------------------
|
||||
|
||||
void gottlieb_sound_r1_with_votrax_device::votrax_data_w(u8 data)
|
||||
void gottlieb_sound_speech_r1_device::votrax_data_w(u8 data)
|
||||
{
|
||||
m_votrax->inflection_w(data >> 6);
|
||||
m_votrax->write(~data & 0x3f);
|
||||
@ -408,7 +414,7 @@ void gottlieb_sound_r1_with_votrax_device::votrax_data_w(u8 data)
|
||||
// the Votrax SC-01 speech chip
|
||||
//-------------------------------------------------
|
||||
|
||||
u32 gottlieb_sound_r1_with_votrax_device::convert_speech_clock(u8 data)
|
||||
u32 gottlieb_sound_speech_r1_device::convert_speech_clock(u8 data)
|
||||
{
|
||||
// prevent negative clock values (and possible crash)
|
||||
if (data < 0x40) data = 0x40;
|
||||
@ -418,7 +424,7 @@ u32 gottlieb_sound_r1_with_votrax_device::convert_speech_clock(u8 data)
|
||||
return m_speech_clock;
|
||||
}
|
||||
|
||||
void gottlieb_sound_r1_with_votrax_device::speech_clock_dac_w(u8 data)
|
||||
void gottlieb_sound_speech_r1_device::speech_clock_dac_w(u8 data)
|
||||
{
|
||||
//logerror("clock = %02X\n", data);
|
||||
|
||||
@ -430,11 +436,11 @@ void gottlieb_sound_r1_with_votrax_device::speech_clock_dac_w(u8 data)
|
||||
// audio CPU address map
|
||||
//-------------------------------------------------
|
||||
|
||||
void gottlieb_sound_r1_with_votrax_device::r1_map(address_map &map)
|
||||
void gottlieb_sound_speech_r1_device::r1_map(address_map &map)
|
||||
{
|
||||
gottlieb_sound_r1_device::r1_map(map);
|
||||
map(0x2000, 0x2000).mirror(0x0fff).w(FUNC(gottlieb_sound_r1_with_votrax_device::votrax_data_w));
|
||||
map(0x3000, 0x3000).mirror(0x0fff).w(FUNC(gottlieb_sound_r1_with_votrax_device::speech_clock_dac_w));
|
||||
map(0x2000, 0x2000).mirror(0x0fff).w(FUNC(gottlieb_sound_speech_r1_device::votrax_data_w));
|
||||
map(0x3000, 0x3000).mirror(0x0fff).w(FUNC(gottlieb_sound_speech_r1_device::speech_clock_dac_w));
|
||||
}
|
||||
|
||||
|
||||
@ -442,16 +448,16 @@ void gottlieb_sound_r1_with_votrax_device::r1_map(address_map &map)
|
||||
// input ports
|
||||
//-------------------------------------------------
|
||||
|
||||
INPUT_PORTS_START( gottlieb_sound_r1_with_votrax )
|
||||
INPUT_PORTS_START( gottlieb_sound_speech_r1 )
|
||||
PORT_INCLUDE( gottlieb_sound_r1 )
|
||||
|
||||
PORT_MODIFY("SB1")
|
||||
PORT_BIT( 0x80, 0x80, IPT_CUSTOM ) PORT_READ_LINE_DEVICE_MEMBER("votrax", votrax_sc01_device, request)
|
||||
INPUT_PORTS_END
|
||||
|
||||
ioport_constructor gottlieb_sound_r1_with_votrax_device::device_input_ports() const
|
||||
ioport_constructor gottlieb_sound_speech_r1_device::device_input_ports() const
|
||||
{
|
||||
return INPUT_PORTS_NAME(gottlieb_sound_r1_with_votrax);
|
||||
return INPUT_PORTS_NAME(gottlieb_sound_speech_r1);
|
||||
}
|
||||
|
||||
|
||||
@ -459,15 +465,15 @@ ioport_constructor gottlieb_sound_r1_with_votrax_device::device_input_ports() co
|
||||
// device_add_mconfig - add device configuration
|
||||
//-------------------------------------------------
|
||||
|
||||
void gottlieb_sound_r1_with_votrax_device::device_add_mconfig(machine_config &config)
|
||||
void gottlieb_sound_speech_r1_device::device_add_mconfig(machine_config &config)
|
||||
{
|
||||
gottlieb_sound_r1_device::device_add_mconfig(config);
|
||||
|
||||
m_dac->reset_routes();
|
||||
m_dac->add_route(ALL_OUTPUTS, *this, 0.20);
|
||||
|
||||
// Note: early boards use an SC-01 (reactor, q-bert test version, maybe some early pinball machines?) while later boards (qbert main release, most pinball machines) use an SC-01-A
|
||||
VOTRAX_SC01A(config, m_votrax, convert_speech_clock(0));
|
||||
// Note: used on machines in early 1981, such as reactor, q-bert test version, mars: god of war, and maybe early boards of black hole and volcano
|
||||
VOTRAX_SC01(config, m_votrax, convert_speech_clock(0));
|
||||
m_votrax->ar_callback().set("nmi", FUNC(input_merger_device::in_w<1>));
|
||||
m_votrax->add_route(ALL_OUTPUTS, *this, 0.80);
|
||||
}
|
||||
@ -477,7 +483,7 @@ void gottlieb_sound_r1_with_votrax_device::device_add_mconfig(machine_config &co
|
||||
// device_start - device-specific startup
|
||||
//-------------------------------------------------
|
||||
|
||||
void gottlieb_sound_r1_with_votrax_device::device_start()
|
||||
void gottlieb_sound_speech_r1_device::device_start()
|
||||
{
|
||||
gottlieb_sound_r1_device::device_start();
|
||||
|
||||
@ -487,6 +493,37 @@ void gottlieb_sound_r1_with_votrax_device::device_start()
|
||||
|
||||
|
||||
|
||||
//**************************************************************************
|
||||
// REV 1 SOUND/SPEECH BOARD; part number MA-216 (same PCB as MA-309 above but with a Votrax SC-01-A and support components populated)
|
||||
//**************************************************************************
|
||||
|
||||
//-------------------------------------------------
|
||||
// gottlieb_sound_speech_r1a_device -
|
||||
// constructor
|
||||
//-------------------------------------------------
|
||||
|
||||
gottlieb_sound_speech_r1a_device::gottlieb_sound_speech_r1a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock)
|
||||
: gottlieb_sound_speech_r1_device(mconfig, GOTTLIEB_SOUND_SPEECH_REV1A, tag, owner, clock)
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
//-------------------------------------------------
|
||||
// device_add_mconfig - add device configuration
|
||||
//-------------------------------------------------
|
||||
|
||||
void gottlieb_sound_speech_r1a_device::device_add_mconfig(machine_config &config)
|
||||
{
|
||||
gottlieb_sound_speech_r1_device::device_add_mconfig(config);
|
||||
|
||||
// Note: used on all machines past mid-late 1981
|
||||
VOTRAX_SC01A(config.replace(), m_votrax, convert_speech_clock(0));
|
||||
m_votrax->ar_callback().set("nmi", FUNC(input_merger_device::in_w<1>));
|
||||
m_votrax->add_route(ALL_OUTPUTS, *this, 0.80);
|
||||
}
|
||||
|
||||
|
||||
|
||||
//**************************************************************************
|
||||
// REV 2 SOUND BOARD: 6502 + 2 x DAC + 2 x AY-8913 + SPO250
|
||||
//**************************************************************************
|
||||
|
@ -28,7 +28,8 @@ DECLARE_DEVICE_TYPE(GOTTLIEB_SOUND_PIN5, gottlieb_sound_p5_device)
|
||||
DECLARE_DEVICE_TYPE(GOTTLIEB_SOUND_PIN6, gottlieb_sound_p6_device)
|
||||
DECLARE_DEVICE_TYPE(GOTTLIEB_SOUND_PIN7, gottlieb_sound_p7_device)
|
||||
DECLARE_DEVICE_TYPE(GOTTLIEB_SOUND_REV1, gottlieb_sound_r1_device)
|
||||
DECLARE_DEVICE_TYPE(GOTTLIEB_SOUND_REV1_VOTRAX, gottlieb_sound_r1_with_votrax_device)
|
||||
DECLARE_DEVICE_TYPE(GOTTLIEB_SOUND_SPEECH_REV1, gottlieb_sound_speech_r1_device)
|
||||
DECLARE_DEVICE_TYPE(GOTTLIEB_SOUND_SPEECH_REV1A, gottlieb_sound_speech_r1a_device)
|
||||
DECLARE_DEVICE_TYPE(GOTTLIEB_SOUND_REV2, gottlieb_sound_r2_device)
|
||||
|
||||
|
||||
@ -97,7 +98,7 @@ private:
|
||||
|
||||
// ======================> gottlieb_sound_r1_device
|
||||
|
||||
// rev 1 sound board, with unpopulated VOTRAX
|
||||
// rev 1 sound board, with unpopulated SC-01[-A] and support circuitry
|
||||
class gottlieb_sound_r1_device : public device_t, public device_mixer_interface
|
||||
{
|
||||
public:
|
||||
@ -128,16 +129,18 @@ private:
|
||||
};
|
||||
|
||||
|
||||
// ======================> gottlieb_sound_r1_with_votrax_device
|
||||
// ======================> gottlieb_sound_speech_r1_device
|
||||
|
||||
// fully populated rev 1 sound board
|
||||
class gottlieb_sound_r1_with_votrax_device : public gottlieb_sound_r1_device
|
||||
// fully populated rev 1 sound board with SC-01 installed
|
||||
class gottlieb_sound_speech_r1_device : public gottlieb_sound_r1_device
|
||||
{
|
||||
public:
|
||||
// construction/destruction
|
||||
gottlieb_sound_r1_with_votrax_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0);
|
||||
gottlieb_sound_speech_r1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0);
|
||||
|
||||
protected:
|
||||
gottlieb_sound_speech_r1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock);
|
||||
|
||||
// device-level overrides
|
||||
virtual void device_add_mconfig(machine_config &config) override;
|
||||
virtual ioport_constructor device_input_ports() const override;
|
||||
@ -146,19 +149,33 @@ protected:
|
||||
|
||||
virtual void r1_map(address_map &map) override;
|
||||
|
||||
private:
|
||||
// internal communications
|
||||
void votrax_data_w(u8 data);
|
||||
void speech_clock_dac_w(u8 data);
|
||||
u32 convert_speech_clock(u8 data);
|
||||
|
||||
// devices
|
||||
required_device<votrax_sc01_device> m_votrax;
|
||||
|
||||
private:
|
||||
// internal communications
|
||||
void votrax_data_w(u8 data);
|
||||
void speech_clock_dac_w(u8 data);
|
||||
|
||||
// internal state
|
||||
u32 m_speech_clock;
|
||||
};
|
||||
|
||||
// fully populated rev 1 sound board with SC-01-A installed
|
||||
class gottlieb_sound_speech_r1a_device : public gottlieb_sound_speech_r1_device
|
||||
{
|
||||
public:
|
||||
// construction/destruction
|
||||
gottlieb_sound_speech_r1a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0);
|
||||
|
||||
protected:
|
||||
// device-level overrides
|
||||
virtual void device_add_mconfig(machine_config &config) override;
|
||||
};
|
||||
|
||||
|
||||
// ======================> gottlieb_sound_p4_device
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user