summaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
author cracyc <cracyc@users.noreply.github.com>2021-07-15 14:13:02 -0500
committer cracyc <cracyc@users.noreply.github.com>2021-07-15 14:13:02 -0500
commit4c88820670180290e46fcf26fe62c641f9cdd0d3 (patch)
tree5283d9b829a24228e4f6505698312495d36d79ed
parent4acf8a000fda2c317d9e87023f15f74c7c0b944b (diff)
funkball: add sound cpu
-rw-r--r--src/mame/drivers/funkball.cpp16
1 files changed, 15 insertions, 1 deletions
diff --git a/src/mame/drivers/funkball.cpp b/src/mame/drivers/funkball.cpp
index 5500f61e757..e74b7776dc4 100644
--- a/src/mame/drivers/funkball.cpp
+++ b/src/mame/drivers/funkball.cpp
@@ -80,7 +80,9 @@ Notes:
#include "machine/pckeybrd.h"
#include "machine/pcshare.h"
#include "video/voodoo.h"
+#include "sound/ks0164.h"
#include "screen.h"
+#include "speaker.h"
class funkball_state : public pcat_base_state
@@ -89,6 +91,7 @@ public:
funkball_state(const machine_config &mconfig, device_type type, const char *tag)
: pcat_base_state(mconfig, type, tag)
, m_voodoo(*this, "voodoo_0")
+ , m_sound(*this, "ks0164")
, m_unk_ram(*this, "unk_ram")
, m_flashbank(*this, "flashbank")
, m_inputs(*this, "IN.%u", 0)
@@ -109,6 +112,7 @@ private:
// devices
required_device<voodoo_1_device> m_voodoo;
+ required_device<ks0164_device> m_sound;
required_shared_ptr<uint32_t> m_unk_ram;
required_device<address_map_bank_device> m_flashbank;
@@ -371,6 +375,9 @@ void funkball_state::funkball_io(address_map &map)
map(0x0cf8, 0x0cff).rw("pcibus", FUNC(pci_bus_legacy_device::read), FUNC(pci_bus_legacy_device::write));
+ map(0x0320, 0x0323).rw(m_sound, FUNC(ks0164_device::mpu401_data_r), FUNC(ks0164_device::mpu401_data_w)).umask32(0x000000ff);
+ map(0x0320, 0x0323).rw(m_sound, FUNC(ks0164_device::mpu401_status_r), FUNC(ks0164_device::mpu401_ctrl_w)).umask32(0x0000ff00);
+
map(0x0360, 0x0363).w(FUNC(funkball_state::flash_w));
// map(0x0320, 0x0323).r(FUNC(funkball_state::test_r));
@@ -778,13 +785,20 @@ void funkball_state::funkball(machine_config &config)
INTEL_28F320J5(config, "u29");
INTEL_28F320J5(config, "u30");
INTEL_28F320J5(config, "u3");
+
+ SPEAKER(config, "lspeaker").front_left();
+ SPEAKER(config, "rspeaker").front_right();
+
+ KS0164(config, m_sound, 16.9344_MHz_XTAL);
+ m_sound->add_route(0, "lspeaker", 1.0);
+ m_sound->add_route(1, "rspeaker", 1.0);
}
ROM_START( funkball )
ROM_REGION32_LE(0x20000, "bios", ROMREGION_ERASEFF)
ROM_LOAD( "512k-epr.u62", 0x010000, 0x010000, CRC(cced894a) SHA1(298c81716e375da4b7215f3e588a45ca3ea7e35c) )
- ROM_REGION16_BE(0x400000, "u3", ROMREGION_ERASE00) // Sound Program / Samples
+ ROM_REGION(0x400000, "ks0164", ROMREGION_ERASE00) // Sound Program / Samples
ROM_LOAD16_WORD_SWAP( "flash.u3", 0x000000, 0x400000, CRC(fb376abc) SHA1(ea4c48bb6cd2055431a33f5c426e52c7af6997eb) )
ROM_REGION16_BE(0x400000, "u29", ROMREGION_ERASE00) // Main Program