diff options
Diffstat (limited to 'src/mame/audio/spacefb.cpp')
-rw-r--r-- | src/mame/audio/spacefb.cpp | 23 |
1 files changed, 13 insertions, 10 deletions
diff --git a/src/mame/audio/spacefb.cpp b/src/mame/audio/spacefb.cpp index 3128fd58a13..a6e3055d130 100644 --- a/src/mame/audio/spacefb.cpp +++ b/src/mame/audio/spacefb.cpp @@ -77,14 +77,17 @@ static const char *const spacefb_sample_names[] = }; -MACHINE_CONFIG_START(spacefb_state::spacefb_audio) +void spacefb_state::spacefb_audio(machine_config &config) +{ SPEAKER(config, "speaker").front_center(); - MCFG_DEVICE_ADD("dac", DAC_8BIT_R2R, 0) MCFG_SOUND_ROUTE(ALL_OUTPUTS, "speaker", 0.25) // unknown DAC - MCFG_DEVICE_ADD("vref", VOLTAGE_REGULATOR, 0) MCFG_VOLTAGE_REGULATOR_OUTPUT(5.0) - MCFG_SOUND_ROUTE(0, "dac", 1.0, DAC_VREF_POS_INPUT) MCFG_SOUND_ROUTE(0, "dac", -1.0, DAC_VREF_NEG_INPUT) - - MCFG_DEVICE_ADD("samples", SAMPLES) - MCFG_SAMPLES_CHANNELS(3) - MCFG_SAMPLES_NAMES(spacefb_sample_names) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "speaker", 1.0) -MACHINE_CONFIG_END + DAC_8BIT_R2R(config, "dac", 0).add_route(ALL_OUTPUTS, "speaker", 0.25); // unknown DAC + voltage_regulator_device &vref(VOLTAGE_REGULATOR(config, "vref", 0)); + vref.set_output(5.0); + vref.add_route(0, "dac", 1.0, DAC_VREF_POS_INPUT); + vref.add_route(0, "dac", -1.0, DAC_VREF_NEG_INPUT); + + SAMPLES(config, m_samples); + m_samples->set_channels(3); + m_samples->set_samples_names(spacefb_sample_names); + m_samples->add_route(ALL_OUTPUTS, "speaker", 1.0); +} |