diff options
Diffstat (limited to 'src/devices/bus/cbus/pc9801_86.cpp')
-rw-r--r-- | src/devices/bus/cbus/pc9801_86.cpp | 30 |
1 files changed, 17 insertions, 13 deletions
diff --git a/src/devices/bus/cbus/pc9801_86.cpp b/src/devices/bus/cbus/pc9801_86.cpp index 04c1feb4cf8..d9d6150a9fa 100644 --- a/src/devices/bus/cbus/pc9801_86.cpp +++ b/src/devices/bus/cbus/pc9801_86.cpp @@ -47,7 +47,8 @@ WRITE_LINE_MEMBER(pc9801_86_device::sound_irq) // device_add_mconfig - add device configuration //------------------------------------------------- -MACHINE_CONFIG_START(pc9801_86_device::pc9801_86_config) +void pc9801_86_device::pc9801_86_config(machine_config &config) +{ SPEAKER(config, "lspeaker").front_left(); SPEAKER(config, "rspeaker").front_right(); YM2608(config, m_opna, 7.987_MHz_XTAL); @@ -62,16 +63,19 @@ MACHINE_CONFIG_START(pc9801_86_device::pc9801_86_config) m_opna->add_route(1, "lspeaker", 1.00); m_opna->add_route(2, "rspeaker", 1.00); - MCFG_DEVICE_ADD("ldac", DAC_16BIT_R2R_TWOS_COMPLEMENT, 0) MCFG_SOUND_ROUTE(ALL_OUTPUTS, "lspeaker", 1.0) // burr brown pcm61p - MCFG_DEVICE_ADD("rdac", DAC_16BIT_R2R_TWOS_COMPLEMENT, 0) MCFG_SOUND_ROUTE(ALL_OUTPUTS, "rspeaker", 1.0) // burr brown pcm61p - MCFG_DEVICE_ADD("vref", VOLTAGE_REGULATOR, 0) MCFG_VOLTAGE_REGULATOR_OUTPUT(5.0) - MCFG_SOUND_ROUTE(0, "ldac", 1.0, DAC_VREF_POS_INPUT) MCFG_SOUND_ROUTE(0, "ldac", -1.0, DAC_VREF_NEG_INPUT) - MCFG_SOUND_ROUTE(0, "rdac", 1.0, DAC_VREF_POS_INPUT) MCFG_SOUND_ROUTE(0, "rdac", -1.0, DAC_VREF_NEG_INPUT) -MACHINE_CONFIG_END + DAC_16BIT_R2R_TWOS_COMPLEMENT(config, m_ldac, 0).add_route(ALL_OUTPUTS, "lspeaker", 1.0); // burr brown pcm61p + DAC_16BIT_R2R_TWOS_COMPLEMENT(config, m_rdac, 0).add_route(ALL_OUTPUTS, "rspeaker", 1.0); // burr brown pcm61p + voltage_regulator_device &vref(VOLTAGE_REGULATOR(config, "vref")); + vref.add_route(0, "ldac", 1.0, DAC_VREF_POS_INPUT); + vref.add_route(0, "ldac", -1.0, DAC_VREF_NEG_INPUT); + vref.add_route(0, "rdac", 1.0, DAC_VREF_POS_INPUT); + vref.add_route(0, "rdac", -1.0, DAC_VREF_NEG_INPUT); +} -MACHINE_CONFIG_START(pc9801_86_device::device_add_mconfig) +void pc9801_86_device::device_add_mconfig(machine_config &config) +{ pc9801_86_config(config); -MACHINE_CONFIG_END +} // to load a different bios for slots: // -cbusX pc9801_86,bios=N @@ -197,7 +201,7 @@ void pc9801_86_device::device_reset() READ8_MEMBER(pc9801_86_device::opna_r) { if((offset & 1) == 0) - return m_opna->read(space, offset >> 1); + return m_opna->read(offset >> 1); else // odd { logerror("PC9801-86: Read to undefined port [%02x]\n",offset+0x188); @@ -208,7 +212,7 @@ READ8_MEMBER(pc9801_86_device::opna_r) WRITE8_MEMBER(pc9801_86_device::opna_w) { if((offset & 1) == 0) - m_opna->write(space, offset >> 1,data); + m_opna->write(offset >> 1,data); else // odd logerror("PC9801-86: Write to undefined port [%02x] %02x\n",offset+0x188,data); } @@ -419,7 +423,7 @@ void pc9801_speakboard_device::device_reset() READ8_MEMBER(pc9801_speakboard_device::opna_slave_r) { if((offset & 1) == 0) - return m_opna_slave->read(space, offset >> 1); + return m_opna_slave->read(offset >> 1); else // odd { logerror("PC9801-SPB: Read to undefined port [%02x]\n",offset+0x588); @@ -430,7 +434,7 @@ READ8_MEMBER(pc9801_speakboard_device::opna_slave_r) WRITE8_MEMBER(pc9801_speakboard_device::opna_slave_w) { if((offset & 1) == 0) - m_opna_slave->write(space, offset >> 1,data); + m_opna_slave->write(offset >> 1,data); else // odd logerror("PC9801-SPB: Write to undefined port [%02x] %02x\n",offset+0x588,data); } |