diff options
Diffstat (limited to 'src')
116 files changed, 226 insertions, 422 deletions
diff --git a/src/devices/bus/einstein/pipe/speculator.cpp b/src/devices/bus/einstein/pipe/speculator.cpp index 1925a55620f..8334f2d3f65 100644 --- a/src/devices/bus/einstein/pipe/speculator.cpp +++ b/src/devices/bus/einstein/pipe/speculator.cpp @@ -45,12 +45,10 @@ MACHINE_CONFIG_START(einstein_speculator_device::device_add_mconfig) MCFG_TTL74123_OUTPUT_CHANGED_CB(WRITELINE(*this, einstein_speculator_device, ic5b_q_w)) SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) - MCFG_DEVICE_ADD("speaker", SPEAKER_SOUND, 0) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50) + WAVE(config, "wave", m_cassette).add_route(ALL_OUTPUTS, "mono", 0.25); + SPEAKER_SOUND(config, m_speaker).add_route(ALL_OUTPUTS, "mono", 0.50); - MCFG_CASSETTE_ADD("cassette") + MCFG_CASSETTE_ADD(m_cassette) MCFG_CASSETTE_FORMATS(tzx_cassette_formats) MCFG_CASSETTE_DEFAULT_STATE(CASSETTE_STOPPED | CASSETTE_SPEAKER_ENABLED | CASSETTE_MOTOR_ENABLED) MCFG_CASSETTE_INTERFACE("spectrum_cass") diff --git a/src/devices/bus/vcs/scharger.cpp b/src/devices/bus/vcs/scharger.cpp index 85ede8b6b26..36a9ee65acc 100644 --- a/src/devices/bus/vcs/scharger.cpp +++ b/src/devices/bus/vcs/scharger.cpp @@ -93,7 +93,7 @@ MACHINE_CONFIG_START(a26_rom_ss_device::device_add_mconfig) MCFG_CASSETTE_DEFAULT_STATE(CASSETTE_STOPPED | CASSETTE_MOTOR_ENABLED | CASSETTE_SPEAKER_ENABLED) MCFG_CASSETTE_INTERFACE("a2600_cass") -// MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") +// MCFG_SOUND_WAVE_ADD("wave", "cassette") // MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) MACHINE_CONFIG_END diff --git a/src/devices/sound/wave.cpp b/src/devices/sound/wave.cpp index c7dd698dab6..ac564f70226 100644 --- a/src/devices/sound/wave.cpp +++ b/src/devices/sound/wave.cpp @@ -25,13 +25,12 @@ -DEFINE_DEVICE_TYPE(WAVE, wave_device, "wave", "Wave") +DEFINE_DEVICE_TYPE(WAVE, wave_device, "wave", "Cassette Sound") wave_device::wave_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : device_t(mconfig, WAVE, tag, owner, clock) , device_sound_interface(mconfig, *this) - , m_cassette_tag(nullptr) - , m_cass(nullptr) + , m_cass(*this, finder_base::DUMMY_TAG) { } @@ -47,7 +46,6 @@ void wave_device::device_start() machine().sound().stream_alloc(*this, 0, 2, machine().sample_rate()); else machine().sound().stream_alloc(*this, 0, 1, machine().sample_rate()); - m_cass = owner()->subdevice<cassette_image_device>(m_cassette_tag); } //------------------------------------------------- diff --git a/src/devices/sound/wave.h b/src/devices/sound/wave.h index 27ad6f18682..fe5cf6b51a2 100644 --- a/src/devices/sound/wave.h +++ b/src/devices/sound/wave.h @@ -15,9 +15,15 @@ class wave_device : public device_t, public device_sound_interface { public: - wave_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + template <typename T> + wave_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&cassette_tag) + : wave_device(mconfig, tag, owner, uint32_t(0)) + { + m_cass.set_tag(std::forward<T>(cassette_tag)); + } + wave_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); - void set_cassette_tag(const char *cassette_tag) { m_cassette_tag = cassette_tag; } + template <typename T> void set_cassette_tag(T &&cassette_tag) { m_cass.set_tag(std::forward<T>(cassette_tag)); } protected: // device-level overrides @@ -27,19 +33,9 @@ protected: virtual void sound_stream_update(sound_stream &stream, stream_sample_t **inputs, stream_sample_t **outputs, int samples) override; private: - const char *m_cassette_tag; - cassette_image_device *m_cass; + required_device<cassette_image_device> m_cass; }; DECLARE_DEVICE_TYPE(WAVE, wave_device) - -#define WAVE_TAG "wave" -#define WAVE2_TAG "wave2" - - -#define MCFG_SOUND_WAVE_ADD(_tag, _cass_tag) \ - MCFG_DEVICE_ADD( _tag, WAVE, 0 ) \ - downcast<wave_device &>(*device).set_cassette_tag(_cass_tag); - #endif // MAME_SOUND_WAVE_H diff --git a/src/devices/video/nt7534.h b/src/devices/video/nt7534.h index 210ca50552c..06e37d2bd26 100644 --- a/src/devices/video/nt7534.h +++ b/src/devices/video/nt7534.h @@ -12,9 +12,6 @@ #pragma once -#define MCFG_NT7534_ADD( _tag ) \ - MCFG_DEVICE_ADD( _tag, NT7534, 0 ) - #define MCFG_NT7534_PIXEL_UPDATE_CB(_class, _method) \ downcast<nt7534_device &>(*device).set_pixel_update_cb(nt7534_device::pixel_update_delegate(&_class::_method, #_class "::" #_method, this)); @@ -33,7 +30,7 @@ public: typedef device_delegate<void (bitmap_ind16 &bitmap, uint8_t line, uint8_t pos, uint8_t y, uint8_t x, int state)> pixel_update_delegate; // construction/destruction - nt7534_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nt7534_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); template <typename Object> void set_pixel_update_cb(Object &&cb) { m_pixel_update_cb = std::forward<Object>(cb); } diff --git a/src/mame/drivers/a5105.cpp b/src/mame/drivers/a5105.cpp index b2204c52f10..84a8ec7c967 100644 --- a/src/mame/drivers/a5105.cpp +++ b/src/mame/drivers/a5105.cpp @@ -586,10 +586,8 @@ MACHINE_CONFIG_START(a5105_state::a5105) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) - MCFG_DEVICE_ADD("beeper", BEEP, 500) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); + BEEP(config, "beeper", 500).add_route(ALL_OUTPUTS, "mono", 0.50); /* Devices */ MCFG_DEVICE_ADD("upd7220", UPD7220, XTAL(15'000'000) / 16) // unk clock diff --git a/src/mame/drivers/a6809.cpp b/src/mame/drivers/a6809.cpp index 13757281abd..78bfb85efc2 100644 --- a/src/mame/drivers/a6809.cpp +++ b/src/mame/drivers/a6809.cpp @@ -240,8 +240,7 @@ MACHINE_CONFIG_START(a6809_state::a6809) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); /* Devices */ MCFG_DEVICE_ADD("via", VIA6522, XTAL(4'000'000) / 4) diff --git a/src/mame/drivers/abc80.cpp b/src/mame/drivers/abc80.cpp index ddc61a9262f..6d25a0aedb2 100644 --- a/src/mame/drivers/abc80.cpp +++ b/src/mame/drivers/abc80.cpp @@ -509,8 +509,7 @@ MACHINE_CONFIG_START(abc80_state::abc80) MCFG_SN76477_ONESHOT_PARAMS(CAP_U(0.1), RES_K(330)) // oneshot caps + res: C53 0.1u - R25 330k MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, CASSETTE_TAG) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", CASSETTE_TAG).add_route(ALL_OUTPUTS, "mono", 0.25); // devices MCFG_DEVICE_ADD(Z80PIO_TAG, Z80PIO, XTAL(11'980'800)/2/2) diff --git a/src/mame/drivers/ac1.cpp b/src/mame/drivers/ac1.cpp index ecb7cdda717..18e850b2b3c 100644 --- a/src/mame/drivers/ac1.cpp +++ b/src/mame/drivers/ac1.cpp @@ -155,8 +155,7 @@ MACHINE_CONFIG_START(ac1_state::ac1) MCFG_PALETTE_ADD_MONOCHROME("palette") SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); MCFG_CASSETTE_ADD( "cassette" ) MACHINE_CONFIG_END diff --git a/src/mame/drivers/acrnsys1.cpp b/src/mame/drivers/acrnsys1.cpp index d8cb8ef1a56..d4a2fcd2f01 100644 --- a/src/mame/drivers/acrnsys1.cpp +++ b/src/mame/drivers/acrnsys1.cpp @@ -274,8 +274,7 @@ MACHINE_CONFIG_START(acrnsys1_state::acrnsys1) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); /* devices */ MCFG_DEVICE_ADD("b1", INS8154, 0) diff --git a/src/mame/drivers/aim65.cpp b/src/mame/drivers/aim65.cpp index a4dd3084356..8befd6904a7 100644 --- a/src/mame/drivers/aim65.cpp +++ b/src/mame/drivers/aim65.cpp @@ -207,8 +207,7 @@ MACHINE_CONFIG_START(aim65_state::aim65) /* Sound - wave sound only */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); /* other devices */ MCFG_DEVICE_ADD("riot", MOS6532_NEW, AIM65_CLOCK) diff --git a/src/mame/drivers/alphatro.cpp b/src/mame/drivers/alphatro.cpp index f146f43f3a7..b001d796a72 100644 --- a/src/mame/drivers/alphatro.cpp +++ b/src/mame/drivers/alphatro.cpp @@ -717,10 +717,8 @@ MACHINE_CONFIG_START(alphatro_state::alphatro) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_DEVICE_ADD("beeper", BEEP, 950) /* piezo-device needs to be measured */ - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.00) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + BEEP(config, "beeper", 950).add_route(ALL_OUTPUTS, "mono", 1.00); /* piezo-device needs to be measured */ + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); /* Devices */ MCFG_UPD765A_ADD("fdc", true, true) diff --git a/src/mame/drivers/amstrad.cpp b/src/mame/drivers/amstrad.cpp index 78ae761a2c3..829daa592a9 100644 --- a/src/mame/drivers/amstrad.cpp +++ b/src/mame/drivers/amstrad.cpp @@ -948,8 +948,7 @@ MACHINE_CONFIG_START(amstrad_state::amstrad_base) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); MCFG_DEVICE_ADD("ay", AY8912, XTAL(16'000'000) / 16) MCFG_AY8910_PORT_A_READ_CB(READ8(*this, amstrad_state, amstrad_psg_porta_read)) /* portA read */ MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) @@ -1076,8 +1075,7 @@ MACHINE_CONFIG_START(amstrad_state::cpcplus) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); MCFG_DEVICE_ADD("ay", AY8912, XTAL(40'000'000) / 40) MCFG_AY8910_PORT_A_READ_CB(READ8(*this, amstrad_state, amstrad_psg_porta_read)) /* portA read */ MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) diff --git a/src/mame/drivers/apf.cpp b/src/mame/drivers/apf.cpp index e9dc9a82e99..cc538bfe4a7 100644 --- a/src/mame/drivers/apf.cpp +++ b/src/mame/drivers/apf.cpp @@ -562,8 +562,7 @@ MACHINE_CONFIG_START(apf_state::apfimag) MCFG_RAM_DEFAULT_SIZE("8K") MCFG_RAM_EXTRA_OPTIONS("16K") - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.15) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.15); MCFG_DEVICE_ADD("pia1", PIA6821, 0) MCFG_PIA_READPA_HANDLER(READ8(*this, apf_state, pia1_porta_r)) diff --git a/src/mame/drivers/apogee.cpp b/src/mame/drivers/apogee.cpp index e280fde1833..365bf5c07fc 100644 --- a/src/mame/drivers/apogee.cpp +++ b/src/mame/drivers/apogee.cpp @@ -254,8 +254,7 @@ MACHINE_CONFIG_START(apogee_state::apogee) MCFG_PALETTE_INIT_OWNER(apogee_state,radio86) SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); MCFG_DEVICE_ADD("speaker", SPEAKER_SOUND) MCFG_SPEAKER_LEVELS(4, speaker_levels) MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.75) diff --git a/src/mame/drivers/applix.cpp b/src/mame/drivers/applix.cpp index 5174f8c052b..68c2be0417c 100644 --- a/src/mame/drivers/applix.cpp +++ b/src/mame/drivers/applix.cpp @@ -878,8 +878,7 @@ MACHINE_CONFIG_START(applix_state::applix) 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) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "lspeaker", 0.50) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "lspeaker", 0.50); /* Devices */ MCFG_MC6845_ADD("crtc", MC6845, "screen", XTAL(30'000'000) / 16) // MC6545 @ 1.875 MHz diff --git a/src/mame/drivers/binbug.cpp b/src/mame/drivers/binbug.cpp index 6bdeef87701..cdd24aca87b 100644 --- a/src/mame/drivers/binbug.cpp +++ b/src/mame/drivers/binbug.cpp @@ -325,8 +325,7 @@ MACHINE_CONFIG_START(binbug_state::binbug) /* Cassette */ MCFG_CASSETTE_ADD( "cassette" ) SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); /* quickload */ MCFG_QUICKLOAD_ADD("quickload", binbug_state, binbug, "pgm", 1) @@ -561,8 +560,7 @@ MACHINE_CONFIG_START(dg680_state::dg680) /* Cassette */ MCFG_CASSETTE_ADD( "cassette" ) SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); /* Devices */ MCFG_DEVICE_ADD("z80ctc", Z80CTC, XTAL(8'000'000) / 4) diff --git a/src/mame/drivers/bk.cpp b/src/mame/drivers/bk.cpp index 79bf5f50674..04782172016 100644 --- a/src/mame/drivers/bk.cpp +++ b/src/mame/drivers/bk.cpp @@ -184,8 +184,7 @@ MACHINE_CONFIG_START(bk_state::bk0010) SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); MCFG_CASSETTE_ADD( "cassette" ) MCFG_CASSETTE_DEFAULT_STATE(CASSETTE_STOPPED | CASSETTE_SPEAKER_ENABLED | CASSETTE_MOTOR_ENABLED) diff --git a/src/mame/drivers/bmjr.cpp b/src/mame/drivers/bmjr.cpp index c3c93309e98..1d7b3f7945b 100644 --- a/src/mame/drivers/bmjr.cpp +++ b/src/mame/drivers/bmjr.cpp @@ -357,10 +357,8 @@ MACHINE_CONFIG_START(bmjr_state::bmjr) /* Audio */ SPEAKER(config, "mono").front_center(); - MCFG_DEVICE_ADD("beeper", BEEP, 1200) // guesswork - MCFG_SOUND_ROUTE(ALL_OUTPUTS,"mono",0.50) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + BEEP(config, "beeper", 1200).add_route(ALL_OUTPUTS, "mono", 0.50); // guesswork + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); /* Devices */ MCFG_CASSETTE_ADD( "cassette" ) diff --git a/src/mame/drivers/bml3.cpp b/src/mame/drivers/bml3.cpp index abea68e0287..777a27b9266 100644 --- a/src/mame/drivers/bml3.cpp +++ b/src/mame/drivers/bml3.cpp @@ -1014,10 +1014,8 @@ MACHINE_CONFIG_START(bml3_state::bml3_common) /* Audio */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) - MCFG_DEVICE_ADD("speaker", SPEAKER_SOUND) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); + SPEAKER_SOUND(config, "speaker").add_route(ALL_OUTPUTS, "mono", 0.50); /* slot devices */ MCFG_DEVICE_ADD("bml3bus", BML3BUS, 0) diff --git a/src/mame/drivers/c80.cpp b/src/mame/drivers/c80.cpp index 669fff0b3e8..a1df7752e73 100644 --- a/src/mame/drivers/c80.cpp +++ b/src/mame/drivers/c80.cpp @@ -279,8 +279,7 @@ MACHINE_CONFIG_START(c80_state::c80) MCFG_CASSETTE_DEFAULT_STATE(CASSETTE_STOPPED | CASSETTE_MOTOR_ENABLED | CASSETTE_SPEAKER_ENABLED ) SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); /* internal ram */ MCFG_RAM_ADD(RAM_TAG) diff --git a/src/mame/drivers/camplynx.cpp b/src/mame/drivers/camplynx.cpp index b3dd2be9943..1643938e786 100644 --- a/src/mame/drivers/camplynx.cpp +++ b/src/mame/drivers/camplynx.cpp @@ -851,8 +851,7 @@ MACHINE_CONFIG_START(camplynx_state::lynx_common) MCFG_DEVICE_ADD("dac", DAC_6BIT_R2R, 0) MCFG_SOUND_ROUTE(ALL_OUTPUTS, "speaker", 0.375) // 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_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "speaker", 0.02) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "speaker", 0.02); MACHINE_CONFIG_END MACHINE_CONFIG_START(camplynx_state::lynx_disk) diff --git a/src/mame/drivers/cd2650.cpp b/src/mame/drivers/cd2650.cpp index 97efb70a8f7..81b2bf1b5b6 100644 --- a/src/mame/drivers/cd2650.cpp +++ b/src/mame/drivers/cd2650.cpp @@ -316,10 +316,8 @@ MACHINE_CONFIG_START(cd2650_state::cd2650) /* Sound */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) - MCFG_DEVICE_ADD("beeper", BEEP, 950) // guess - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); + BEEP(config, "beeper", 950).add_route(ALL_OUTPUTS, "mono", 0.50); // guess /* Devices */ MCFG_DEVICE_ADD("keyboard", GENERIC_KEYBOARD, 0) diff --git a/src/mame/drivers/coco12.cpp b/src/mame/drivers/coco12.cpp index b92724dc897..a59932d1556 100644 --- a/src/mame/drivers/coco12.cpp +++ b/src/mame/drivers/coco12.cpp @@ -390,11 +390,9 @@ MACHINE_CONFIG_START(coco_state::coco_sound) MCFG_SOUND_ROUTE(0, "dac", 1.0, DAC_VREF_POS_INPUT) MCFG_SOUND_ROUTE(0, "dac", -1.0, DAC_VREF_NEG_INPUT) // Single-bit sound: R22 = 10K - MCFG_DEVICE_ADD("sbs", DAC_1BIT, 0) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "speaker", 0.125) + DAC_1BIT(config, "sbs", 0).add_route(ALL_OUTPUTS, "speaker", 0.125); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "speaker", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "speaker", 0.25); MACHINE_CONFIG_END diff --git a/src/mame/drivers/controlid.cpp b/src/mame/drivers/controlid.cpp index 2fd0d91642c..f2cbf683288 100644 --- a/src/mame/drivers/controlid.cpp +++ b/src/mame/drivers/controlid.cpp @@ -37,8 +37,9 @@ class controlidx628_state : public driver_device { public: controlidx628_state(const machine_config &mconfig, device_type type, const char *tag) - : driver_device(mconfig, type, tag), - m_lcdc(*this, "nt7534") { } + : driver_device(mconfig, type, tag) + , m_lcdc(*this, "nt7534") + { } void controlidx628(machine_config &config); private: @@ -113,26 +114,26 @@ PALETTE_INIT_MEMBER(controlidx628_state, controlidx628) MACHINE_CONFIG_START(controlidx628_state::controlidx628) // basic machine hardware - MCFG_DEVICE_ADD("maincpu", I80C32, XTAL(11'059'200)) /* Actually the board has an Atmel AT89S52 mcu. */ + MCFG_DEVICE_ADD("maincpu", I80C32, XTAL(11'059'200)) // Actually the board has an Atmel AT89S52 MCU. MCFG_DEVICE_PROGRAM_MAP(prog_map) MCFG_DEVICE_IO_MAP(io_map) MCFG_MCS51_PORT_P0_OUT_CB(WRITE8(*this, controlidx628_state, p0_w)) MCFG_MCS51_PORT_P1_OUT_CB(WRITE8(*this, controlidx628_state, p1_w)) MCFG_MCS51_PORT_P3_OUT_CB(WRITE8(*this, controlidx628_state, p3_w)) - /* video hardware */ - MCFG_SCREEN_ADD("screen", LCD) - MCFG_SCREEN_REFRESH_RATE(50) - MCFG_SCREEN_VBLANK_TIME(ATTOSECONDS_IN_USEC(2500)) /* not accurate */ - MCFG_SCREEN_SIZE(132, 65) - MCFG_SCREEN_VISIBLE_AREA(3, 130, 0, 63) - MCFG_SCREEN_UPDATE_DEVICE("nt7534", nt7534_device, screen_update) - MCFG_SCREEN_PALETTE("palette") + // video hardware + MCFG_SCREEN_ADD("screen", LCD) + MCFG_SCREEN_REFRESH_RATE(50) + MCFG_SCREEN_VBLANK_TIME(ATTOSECONDS_IN_USEC(2500)) // not accurate + MCFG_SCREEN_SIZE(132, 65) + MCFG_SCREEN_VISIBLE_AREA(3, 130, 0, 63) + MCFG_SCREEN_UPDATE_DEVICE("nt7534", nt7534_device, screen_update) + MCFG_SCREEN_PALETTE("palette") - MCFG_PALETTE_ADD("palette", 2) - MCFG_PALETTE_INIT_OWNER(controlidx628_state, controlidx628) + MCFG_PALETTE_ADD("palette", 2) + MCFG_PALETTE_INIT_OWNER(controlidx628_state, controlidx628) - MCFG_NT7534_ADD("nt7534") + NT7534(config, m_lcdc); MACHINE_CONFIG_END diff --git a/src/mame/drivers/crvision.cpp b/src/mame/drivers/crvision.cpp index 9896d32d214..9f58c09d6f6 100644 --- a/src/mame/drivers/crvision.cpp +++ b/src/mame/drivers/crvision.cpp @@ -768,8 +768,7 @@ MACHINE_CONFIG_START(crvision_state::creativision) MCFG_SN76496_READY_HANDLER(WRITELINE(PIA6821_TAG, pia6821_device, cb1_w)) MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.00) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(1, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(1, "mono", 0.25); // cartridge MCFG_CRVISION_CARTRIDGE_ADD("cartslot", crvision_cart, nullptr) @@ -852,8 +851,7 @@ MACHINE_CONFIG_START(laser2001_state::lasr2001) MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.00) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(1, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(1, "mono", 0.25); // cartridge MCFG_CRVISION_CARTRIDGE_ADD("cartslot", crvision_cart, nullptr) diff --git a/src/mame/drivers/d6800.cpp b/src/mame/drivers/d6800.cpp index b511e13f820..43a33bcce3e 100644 --- a/src/mame/drivers/d6800.cpp +++ b/src/mame/drivers/d6800.cpp @@ -402,10 +402,8 @@ MACHINE_CONFIG_START(d6800_state::d6800) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50) - MCFG_DEVICE_ADD("beeper", BEEP, 1200) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.50); + BEEP(config, "beeper", 1200).add_route(ALL_OUTPUTS, "mono", 0.50); /* devices */ MCFG_DEVICE_ADD("pia", PIA6821, 0) diff --git a/src/mame/drivers/dai.cpp b/src/mame/drivers/dai.cpp index 13efcd72d9b..2e1be7ce0f7 100644 --- a/src/mame/drivers/dai.cpp +++ b/src/mame/drivers/dai.cpp @@ -221,13 +221,10 @@ MACHINE_CONFIG_START(dai_state::dai) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); SPEAKER(config, "lspeaker").front_left(); SPEAKER(config, "rspeaker").front_right(); - MCFG_DEVICE_ADD("custom", DAI_SOUND) - MCFG_SOUND_ROUTE(0, "lspeaker", 0.50) - MCFG_SOUND_ROUTE(1, "rspeaker", 0.50) + DAI_SOUND(config, "custom").add_route(0, "lspeaker", 0.50).add_route(1, "rspeaker", 0.50); /* cassette */ MCFG_CASSETTE_ADD( "cassette" ) diff --git a/src/mame/drivers/dolphunk.cpp b/src/mame/drivers/dolphunk.cpp index 50a57570a5e..8cf5655144a 100644 --- a/src/mame/drivers/dolphunk.cpp +++ b/src/mame/drivers/dolphunk.cpp @@ -244,13 +244,11 @@ MACHINE_CONFIG_START(dauphin_state::dauphin) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_DEVICE_ADD("speaker", SPEAKER_SOUND) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.00) + SPEAKER_SOUND(config, "speaker").add_route(ALL_OUTPUTS, "mono", 1.00); + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); /* cassette */ MCFG_CASSETTE_ADD( "cassette" ) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) MCFG_TIMER_DRIVER_ADD_PERIODIC("dauphin_c", dauphin_state, dauphin_c, attotime::from_hz(4000)) MACHINE_CONFIG_END diff --git a/src/mame/drivers/elwro800.cpp b/src/mame/drivers/elwro800.cpp index 299dab5e777..bec5edd8149 100644 --- a/src/mame/drivers/elwro800.cpp +++ b/src/mame/drivers/elwro800.cpp @@ -614,10 +614,8 @@ MACHINE_CONFIG_START(elwro800_state::elwro800) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) - MCFG_DEVICE_ADD("speaker", SPEAKER_SOUND) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); + SPEAKER_SOUND(config, "speaker").add_route(ALL_OUTPUTS, "mono", 0.50); MCFG_CASSETTE_ADD( "cassette" ) MCFG_CASSETTE_FORMATS(tzx_cassette_formats) diff --git a/src/mame/drivers/et3400.cpp b/src/mame/drivers/et3400.cpp index 20c8036b25d..097a37bdcf0 100644 --- a/src/mame/drivers/et3400.cpp +++ b/src/mame/drivers/et3400.cpp @@ -251,8 +251,7 @@ MACHINE_CONFIG_START(et3400_state::et3400) MCFG_CASSETTE_ADD("cassette") MCFG_CASSETTE_DEFAULT_STATE(CASSETTE_STOPPED | CASSETTE_MOTOR_ENABLED | CASSETTE_SPEAKER_ENABLED) SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.05) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.05); MACHINE_CONFIG_END /* ROM definition */ diff --git a/src/mame/drivers/excali64.cpp b/src/mame/drivers/excali64.cpp index ed80866ccb0..e89095cac43 100644 --- a/src/mame/drivers/excali64.cpp +++ b/src/mame/drivers/excali64.cpp @@ -576,10 +576,8 @@ MACHINE_CONFIG_START(excali64_state::excali64) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_DEVICE_ADD("speaker", SPEAKER_SOUND) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.05) + SPEAKER_SOUND(config, "speaker").add_route(ALL_OUTPUTS, "mono", 0.50); + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.05); /* Video hardware */ MCFG_SCREEN_ADD("screen", RASTER) diff --git a/src/mame/drivers/fc100.cpp b/src/mame/drivers/fc100.cpp index 2175c285e35..5e2bc11c47e 100644 --- a/src/mame/drivers/fc100.cpp +++ b/src/mame/drivers/fc100.cpp @@ -530,8 +530,7 @@ MACHINE_CONFIG_START(fc100_state::fc100) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.05) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.05); MCFG_DEVICE_ADD("psg", AY8910, XTAL(7'159'090)/3/2) /* AY-3-8910 - clock not verified */ MCFG_AY8910_PORT_A_READ_CB(IOPORT("JOY0")) MCFG_AY8910_PORT_B_READ_CB(IOPORT("JOY1")) diff --git a/src/mame/drivers/fm7.cpp b/src/mame/drivers/fm7.cpp index 03c354424e5..6196e0cf85b 100644 --- a/src/mame/drivers/fm7.cpp +++ b/src/mame/drivers/fm7.cpp @@ -2081,10 +2081,8 @@ MACHINE_CONFIG_START(fm7_state::fm7) SPEAKER(config, "mono").front_center(); MCFG_DEVICE_ADD("psg", AY8910, XTAL(4'915'200) / 4) MCFG_SOUND_ROUTE(ALL_OUTPUTS,"mono", 1.00) - MCFG_DEVICE_ADD("beeper", BEEP, 1200) - MCFG_SOUND_ROUTE(ALL_OUTPUTS,"mono", 0.50) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS,"mono", 0.25) + BEEP(config, "beeper", 1200).add_route(ALL_OUTPUTS, "mono", 0.50); + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); MCFG_MACHINE_START_OVERRIDE(fm7_state,fm7) @@ -2134,10 +2132,8 @@ MACHINE_CONFIG_START(fm7_state::fm8) MCFG_QUANTUM_PERFECT_CPU("sub") SPEAKER(config, "mono").front_center(); - MCFG_DEVICE_ADD("beeper", BEEP, 1200) - MCFG_SOUND_ROUTE(ALL_OUTPUTS,"mono",0.50) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS,"mono",0.25) + BEEP(config, "beeper", 1200).add_route(ALL_OUTPUTS, "mono", 0.50); + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); MCFG_MACHINE_START_OVERRIDE(fm7_state,fm7) @@ -2187,10 +2183,8 @@ MACHINE_CONFIG_START(fm7_state::fm77av) MCFG_AY8910_PORT_A_READ_CB(READ8(*this, fm7_state, fm77av_joy_1_r)) MCFG_AY8910_PORT_B_READ_CB(READ8(*this, fm7_state, fm77av_joy_2_r)) MCFG_SOUND_ROUTE(ALL_OUTPUTS,"mono",1.0) - MCFG_DEVICE_ADD("beeper", BEEP, 1200) - MCFG_SOUND_ROUTE(ALL_OUTPUTS,"mono",0.50) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS,"mono",0.25) + BEEP(config, "beeper", 1200).add_route(ALL_OUTPUTS, "mono", 0.50); + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); MCFG_MACHINE_START_OVERRIDE(fm7_state,fm77av) @@ -2262,10 +2256,8 @@ MACHINE_CONFIG_START(fm7_state::fm11) MCFG_DEVICE_IO_MAP(fm11_x86_io) SPEAKER(config, "mono").front_center(); - MCFG_DEVICE_ADD("beeper", BEEP, 1200) - MCFG_SOUND_ROUTE(ALL_OUTPUTS,"mono",0.50) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS,"mono",0.25) + BEEP(config, "beeper", 1200).add_route(ALL_OUTPUTS, "mono", 0.50); + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); MCFG_MACHINE_START_OVERRIDE(fm7_state,fm11) @@ -2327,10 +2319,8 @@ MACHINE_CONFIG_START(fm7_state::fm16beta) MCFG_QUANTUM_PERFECT_CPU("sub") SPEAKER(config, "mono").front_center(); - MCFG_DEVICE_ADD("beeper", BEEP, 1200) - MCFG_SOUND_ROUTE(ALL_OUTPUTS,"mono",0.50) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS,"mono",0.25) + BEEP(config, "beeper", 1200).add_route(ALL_OUTPUTS, "mono", 0.50); + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); MCFG_MACHINE_START_OVERRIDE(fm7_state,fm16) diff --git a/src/mame/drivers/galaxy.cpp b/src/mame/drivers/galaxy.cpp index 68cb071eeeb..d8d385fde6d 100644 --- a/src/mame/drivers/galaxy.cpp +++ b/src/mame/drivers/galaxy.cpp @@ -201,8 +201,7 @@ MACHINE_CONFIG_START(galaxy_state::galaxy) MCFG_SNAPSHOT_ADD("snapshot", galaxy_state, galaxy, "gal", 0) SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); MCFG_CASSETTE_ADD( "cassette" ) MCFG_CASSETTE_FORMATS(gtp_cassette_formats) @@ -244,9 +243,8 @@ MACHINE_CONFIG_START(galaxy_state::galaxyp) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_DEVICE_ADD("ay8910", AY8910, XTAL/4) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + MCFG_DEVICE_ADD("ay8910", AY8910, XTAL/4) // FIXME: really no output routes for this AY? + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); MCFG_CASSETTE_ADD( "cassette" ) MCFG_CASSETTE_FORMATS(gtp_cassette_formats) diff --git a/src/mame/drivers/h8.cpp b/src/mame/drivers/h8.cpp index 106e1aa980f..daad3c0004f 100644 --- a/src/mame/drivers/h8.cpp +++ b/src/mame/drivers/h8.cpp @@ -323,10 +323,8 @@ MACHINE_CONFIG_START(h8_state::h8) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_DEVICE_ADD("beeper", BEEP, H8_BEEP_FRQ) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.00) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + BEEP(config, "beeper", H8_BEEP_FRQ).add_route(ALL_OUTPUTS, "mono", 1.00); + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); /* Devices */ MCFG_DEVICE_ADD("uart", I8251, 0) diff --git a/src/mame/drivers/homelab.cpp b/src/mame/drivers/homelab.cpp index 06d68a01768..44de590a4cd 100644 --- a/src/mame/drivers/homelab.cpp +++ b/src/mame/drivers/homelab.cpp @@ -770,8 +770,7 @@ MACHINE_CONFIG_START(homelab_state::homelab) 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_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "speaker", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "speaker", 0.25); MCFG_CASSETTE_ADD( "cassette" ) MCFG_QUICKLOAD_ADD("quickload", homelab_state, homelab, "htp", 2) @@ -803,8 +802,7 @@ MACHINE_CONFIG_START(homelab_state::homelab3) 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_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "speaker", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "speaker", 0.25); MCFG_CASSETTE_ADD( "cassette" ) MCFG_QUICKLOAD_ADD("quickload", homelab_state, homelab, "htp", 2) @@ -836,8 +834,7 @@ MACHINE_CONFIG_START(homelab_state::brailab4) 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_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "speaker", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "speaker", 0.25); MCFG_DEVICE_ADD("mea8000", MEA8000, 3840000) MCFG_SOUND_ROUTE(ALL_OUTPUTS, "speaker", 1.0) diff --git a/src/mame/drivers/instruct.cpp b/src/mame/drivers/instruct.cpp index 7ee4496297a..1570215fb88 100644 --- a/src/mame/drivers/instruct.cpp +++ b/src/mame/drivers/instruct.cpp @@ -437,8 +437,7 @@ MACHINE_CONFIG_START(instruct_state::instruct) /* cassette */ MCFG_CASSETTE_ADD( "cassette" ) SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); MACHINE_CONFIG_END /* ROM definition */ diff --git a/src/mame/drivers/jr100.cpp b/src/mame/drivers/jr100.cpp index 7cc33da0951..fae0dd89df7 100644 --- a/src/mame/drivers/jr100.cpp +++ b/src/mame/drivers/jr100.cpp @@ -393,10 +393,8 @@ MACHINE_CONFIG_START(jr100_state::jr100) MCFG_VIA6522_CB2_HANDLER(WRITELINE(*this, jr100_state, jr100_via_write_cb2)) SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) - MCFG_DEVICE_ADD("speaker", SPEAKER_SOUND) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.00) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); + SPEAKER_SOUND(config, "speaker").add_route(ALL_OUTPUTS, "mono", 1.00); MCFG_DEVICE_ADD("beeper", BEEP, 0) MCFG_SOUND_ROUTE(ALL_OUTPUTS,"mono",0.50) diff --git a/src/mame/drivers/jtc.cpp b/src/mame/drivers/jtc.cpp index 6528e54ac6b..8f128e4b777 100644 --- a/src/mame/drivers/jtc.cpp +++ b/src/mame/drivers/jtc.cpp @@ -735,11 +735,9 @@ MACHINE_CONFIG_START(jtc_state::basic) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_DEVICE_ADD("speaker", SPEAKER_SOUND) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + SPEAKER_SOUND(config, "speaker").add_route(ALL_OUTPUTS, "mono", 0.25); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(1, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(1, "mono", 0.25); /* cassette */ MCFG_CASSETTE_ADD("cassette") diff --git a/src/mame/drivers/jupace.cpp b/src/mame/drivers/jupace.cpp index 3e7aebe2e4b..4572e985137 100644 --- a/src/mame/drivers/jupace.cpp +++ b/src/mame/drivers/jupace.cpp @@ -773,10 +773,8 @@ MACHINE_CONFIG_START(ace_state::ace) // sound hardware SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) - MCFG_DEVICE_ADD("speaker", SPEAKER_SOUND) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.00) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); + SPEAKER_SOUND(config, "speaker").add_route(ALL_OUTPUTS, "mono", 1.00); MCFG_DEVICE_ADD(AY8910_TAG, AY8910, XTAL(6'500'000)/2) MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) diff --git a/src/mame/drivers/kc.cpp b/src/mame/drivers/kc.cpp index 0f029f292d9..dd91b1dc447 100644 --- a/src/mame/drivers/kc.cpp +++ b/src/mame/drivers/kc.cpp @@ -134,10 +134,8 @@ MACHINE_CONFIG_START(kc_state::kc85_3) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) - MCFG_DEVICE_ADD("speaker", SPEAKER_SOUND) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); + SPEAKER_SOUND(config, "speaker").add_route(ALL_OUTPUTS, "mono", 0.50); /* devices */ MCFG_QUICKLOAD_ADD("quickload", kc_state, kc, "kcc", 2) @@ -218,10 +216,8 @@ MACHINE_CONFIG_START(kc85_4_state::kc85_4) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) - MCFG_DEVICE_ADD("speaker", SPEAKER_SOUND) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); + SPEAKER_SOUND(config, "speaker").add_route(ALL_OUTPUTS, "mono", 0.50); /* devices */ MCFG_QUICKLOAD_ADD("quickload", kc_state, kc, "kcc", 2) diff --git a/src/mame/drivers/lola8a.cpp b/src/mame/drivers/lola8a.cpp index 6be5316a130..8032ac61351 100644 --- a/src/mame/drivers/lola8a.cpp +++ b/src/mame/drivers/lola8a.cpp @@ -294,8 +294,7 @@ MACHINE_CONFIG_START(lola8a_state::lola8a) /* Cassette */ MCFG_CASSETTE_ADD( "cassette" ) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); MACHINE_CONFIG_END /* ROM definition */ diff --git a/src/mame/drivers/lviv.cpp b/src/mame/drivers/lviv.cpp index b24c11a97e5..955bc2f082c 100644 --- a/src/mame/drivers/lviv.cpp +++ b/src/mame/drivers/lviv.cpp @@ -460,10 +460,8 @@ MACHINE_CONFIG_START(lviv_state::lviv) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) - MCFG_DEVICE_ADD("speaker", SPEAKER_SOUND) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); + SPEAKER_SOUND(config, "speaker").add_route(ALL_OUTPUTS, "mono", 0.50); /* snapshot */ MCFG_SNAPSHOT_ADD("snapshot", lviv_state, lviv, "sav", 0) diff --git a/src/mame/drivers/mbee.cpp b/src/mame/drivers/mbee.cpp index 003d0a098b9..4e079930f80 100644 --- a/src/mame/drivers/mbee.cpp +++ b/src/mame/drivers/mbee.cpp @@ -677,10 +677,8 @@ MACHINE_CONFIG_START(mbee_state::mbee) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.05) - MCFG_DEVICE_ADD("speaker", SPEAKER_SOUND) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.05); + SPEAKER_SOUND(config, "speaker").add_route(ALL_OUTPUTS, "mono", 0.50); /* devices */ MCFG_MC6845_ADD("crtc", SY6545_1, "screen", XTAL(12'000'000) / 8) @@ -736,10 +734,8 @@ MACHINE_CONFIG_START(mbee_state::mbeeic) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.05) - MCFG_DEVICE_ADD("speaker", SPEAKER_SOUND) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.05); + SPEAKER_SOUND(config, "speaker").add_route(ALL_OUTPUTS, "mono", 0.50); /* devices */ MCFG_MC6845_ADD("crtc", SY6545_1, "screen", XTAL_13_5MHz / 8) diff --git a/src/mame/drivers/mc1502.cpp b/src/mame/drivers/mc1502.cpp index 5034a49bc4d..6da6f30b4ec 100644 --- a/src/mame/drivers/mc1502.cpp +++ b/src/mame/drivers/mc1502.cpp @@ -297,9 +297,8 @@ MACHINE_CONFIG_START(mc1502_state::mc1502) MCFG_DEVICE_ADD("isa2", ISA8_SLOT, 0, "isa", mc1502_isa8_cards, "rom", false) SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_DEVICE_ADD("speaker", SPEAKER_SOUND) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.80) + WAVE(config, "wave", "cassette"); // FIXME: really no output routes for the cassette sound? + SPEAKER_SOUND(config, "speaker").add_route(ALL_OUTPUTS, "mono", 0.80); MCFG_CENTRONICS_ADD("centronics", centronics_devices, "printer") MCFG_CENTRONICS_ACK_HANDLER(WRITELINE("cent_status_in", input_buffer_device, write_bit6)) diff --git a/src/mame/drivers/mekd2.cpp b/src/mame/drivers/mekd2.cpp index 0efda01cc51..3415d03753e 100644 --- a/src/mame/drivers/mekd2.cpp +++ b/src/mame/drivers/mekd2.cpp @@ -382,8 +382,7 @@ MACHINE_CONFIG_START(mekd2_state::mekd2) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); MCFG_CASSETTE_ADD("cassette") diff --git a/src/mame/drivers/microtan.cpp b/src/mame/drivers/microtan.cpp index 218cf79c733..0c00f10eafe 100644 --- a/src/mame/drivers/microtan.cpp +++ b/src/mame/drivers/microtan.cpp @@ -232,8 +232,7 @@ MACHINE_CONFIG_START(microtan_state::microtan) /* sound hardware */ SPEAKER(config, "speaker").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "speaker", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "speaker", 0.25); MCFG_DEVICE_ADD("ay8910.1", AY8910, 1000000) MCFG_SOUND_ROUTE(ALL_OUTPUTS, "speaker", 0.5) MCFG_DEVICE_ADD("ay8910.2", AY8910, 1000000) diff --git a/src/mame/drivers/mikro80.cpp b/src/mame/drivers/mikro80.cpp index 117ef167a9d..95c75791acf 100644 --- a/src/mame/drivers/mikro80.cpp +++ b/src/mame/drivers/mikro80.cpp @@ -188,8 +188,7 @@ MACHINE_CONFIG_START(mikro80_state::mikro80) MCFG_PALETTE_ADD_MONOCHROME("palette") SPEAKER(config, "speaker").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "speaker", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "speaker", 0.25); MCFG_CASSETTE_ADD( "cassette" ) MCFG_CASSETTE_FORMATS(rk8_cassette_formats) diff --git a/src/mame/drivers/mikrosha.cpp b/src/mame/drivers/mikrosha.cpp index accb19619fc..b2629cff9a7 100644 --- a/src/mame/drivers/mikrosha.cpp +++ b/src/mame/drivers/mikrosha.cpp @@ -245,8 +245,7 @@ MACHINE_CONFIG_START(mikrosha_state::mikrosha) MCFG_PALETTE_INIT_OWNER(mikrosha_state,radio86) SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); MCFG_DEVICE_ADD("dma8257", I8257, XTAL(16'000'000) / 9) MCFG_I8257_OUT_HRQ_CB(WRITELINE(*this, radio86_state, hrq_w)) diff --git a/src/mame/drivers/mk14.cpp b/src/mame/drivers/mk14.cpp index b4b17f8bc34..e06f4b781dd 100644 --- a/src/mame/drivers/mk14.cpp +++ b/src/mame/drivers/mk14.cpp @@ -211,8 +211,7 @@ MACHINE_CONFIG_START(mk14_state::mk14) // sound SPEAKER(config, "speaker").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "speaker", 0.05) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "speaker", 0.05); MCFG_DEVICE_ADD("dac", DAC_1BIT, 0) MCFG_SOUND_ROUTE(ALL_OUTPUTS, "speaker", 0.25) MCFG_DEVICE_ADD("dac8", ZN425E, 0) MCFG_SOUND_ROUTE(ALL_OUTPUTS, "speaker", 0.5) // Ferranti ZN425E MCFG_DEVICE_ADD("vref", VOLTAGE_REGULATOR, 0) MCFG_VOLTAGE_REGULATOR_OUTPUT(5.0) diff --git a/src/mame/drivers/mkit09.cpp b/src/mame/drivers/mkit09.cpp index 8a3537c36ca..7e7456572dc 100644 --- a/src/mame/drivers/mkit09.cpp +++ b/src/mame/drivers/mkit09.cpp @@ -205,8 +205,7 @@ MACHINE_CONFIG_START(mkit09_state::mkit09) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); /* Devices */ MCFG_DEVICE_ADD("pia", PIA6821, 0) @@ -230,8 +229,7 @@ MACHINE_CONFIG_START(mkit09_state::mkit09a) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); /* Devices */ MCFG_DEVICE_ADD("pia", PIA6821, 0) diff --git a/src/mame/drivers/msx.cpp b/src/mame/drivers/msx.cpp index 6d12981e0a1..bc5fed2a61e 100644 --- a/src/mame/drivers/msx.cpp +++ b/src/mame/drivers/msx.cpp @@ -1365,8 +1365,7 @@ MACHINE_CONFIG_START(msx_state::msx) 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_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "speaker", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "speaker", 0.25); MCFG_DEVICE_ADD("ay8910", AY8910, XTAL(10'738'635)/3/2) MCFG_AY8910_OUTPUT_TYPE(AY8910_SINGLE_OUTPUT) MCFG_AY8910_PORT_A_READ_CB(READ8(*this, msx_state, msx_psg_port_a_r)) @@ -1518,8 +1517,7 @@ MACHINE_CONFIG_START(msx_state::msx2) 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_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "speaker", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "speaker", 0.25); MCFG_DEVICE_ADD("ay8910", AY8910, XTAL(21'477'272)/6/2) MCFG_AY8910_OUTPUT_TYPE(AY8910_SINGLE_OUTPUT) MCFG_AY8910_PORT_A_READ_CB(READ8(*this, msx_state, msx_psg_port_a_r)) @@ -1576,8 +1574,7 @@ MACHINE_CONFIG_START(msx_state::msx2p) 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_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "speaker", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "speaker", 0.25); MCFG_DEVICE_ADD("ay8910", AY8910, XTAL(21'477'272)/6/2) MCFG_AY8910_OUTPUT_TYPE(AY8910_SINGLE_OUTPUT) MCFG_AY8910_PORT_A_READ_CB(READ8(*this, msx_state, msx_psg_port_a_r)) diff --git a/src/mame/drivers/mycom.cpp b/src/mame/drivers/mycom.cpp index f3c9d24a8a2..ef7aab41c9e 100644 --- a/src/mame/drivers/mycom.cpp +++ b/src/mame/drivers/mycom.cpp @@ -543,8 +543,7 @@ MACHINE_CONFIG_START(mycom_state::mycom) SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.05) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.05); MCFG_DEVICE_ADD("sn1", SN76489, XTAL(10'000'000) / 4) MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.50) diff --git a/src/mame/drivers/mz2000.cpp b/src/mame/drivers/mz2000.cpp index b57ae7f001b..dd14b5eac6e 100644 --- a/src/mame/drivers/mz2000.cpp +++ b/src/mame/drivers/mz2000.cpp @@ -927,11 +927,9 @@ MACHINE_CONFIG_START(mz2000_state::mz2000) SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); - MCFG_DEVICE_ADD("beeper", BEEP, 4096) - MCFG_SOUND_ROUTE(ALL_OUTPUTS,"mono",0.15) + BEEP(config, "beeper", 4096).add_route(ALL_OUTPUTS,"mono",0.15); MACHINE_CONFIG_END MACHINE_CONFIG_START(mz2000_state::mz80b) diff --git a/src/mame/drivers/mz700.cpp b/src/mame/drivers/mz700.cpp index eda092ad40b..795b1219c56 100644 --- a/src/mame/drivers/mz700.cpp +++ b/src/mame/drivers/mz700.cpp @@ -398,10 +398,8 @@ MACHINE_CONFIG_START(mz_state::mz700) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.05) - MCFG_DEVICE_ADD("speaker", SPEAKER_SOUND) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.05); + SPEAKER_SOUND(config, "speaker").add_route(ALL_OUTPUTS, "mono", 0.50); /* ne556 timers */ MCFG_TIMER_DRIVER_ADD_PERIODIC("cursor", mz_state, ne556_cursor_callback, attotime::from_hz(1.5)) diff --git a/src/mame/drivers/mz80.cpp b/src/mame/drivers/mz80.cpp index 7fc34aee344..d317a3e9a44 100644 --- a/src/mame/drivers/mz80.cpp +++ b/src/mame/drivers/mz80.cpp @@ -298,10 +298,8 @@ MACHINE_CONFIG_START(mz80_state::mz80k) /* Audio */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.05) - MCFG_DEVICE_ADD("speaker", SPEAKER_SOUND) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.05); + SPEAKER_SOUND(config, "speaker").add_route(ALL_OUTPUTS, "mono", 0.50); /* Devices */ MCFG_DEVICE_ADD("ppi8255", I8255, 0) diff --git a/src/mame/drivers/ondra.cpp b/src/mame/drivers/ondra.cpp index 6aa0a83eb60..e640ef0719f 100644 --- a/src/mame/drivers/ondra.cpp +++ b/src/mame/drivers/ondra.cpp @@ -142,8 +142,7 @@ MACHINE_CONFIG_START(ondra_state::ondra) // sound hardware SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); MCFG_CASSETTE_ADD( "cassette" ) MCFG_CASSETTE_DEFAULT_STATE(CASSETTE_STOPPED | CASSETTE_MOTOR_ENABLED | CASSETTE_SPEAKER_ENABLED) diff --git a/src/mame/drivers/orao.cpp b/src/mame/drivers/orao.cpp index 0b1e849e832..418452e0813 100644 --- a/src/mame/drivers/orao.cpp +++ b/src/mame/drivers/orao.cpp @@ -189,10 +189,8 @@ MACHINE_CONFIG_START(orao_state::orao) /* audio hardware */ SPEAKER(config, "mono").front_center(); - MCFG_DEVICE_ADD("speaker", SPEAKER_SOUND) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + SPEAKER_SOUND(config, "speaker").add_route(ALL_OUTPUTS, "mono", 0.50); + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); MCFG_CASSETTE_ADD( "cassette") MCFG_CASSETTE_FORMATS(orao_cassette_formats) diff --git a/src/mame/drivers/oric.cpp b/src/mame/drivers/oric.cpp index f05f0f1b28c..bba9b07b128 100644 --- a/src/mame/drivers/oric.cpp +++ b/src/mame/drivers/oric.cpp @@ -790,8 +790,7 @@ MACHINE_CONFIG_START(oric_state::oric) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); MCFG_DEVICE_ADD("ay8912", AY8912, XTAL(12'000'000)/12) MCFG_AY8910_OUTPUT_TYPE(AY8910_DISCRETE_OUTPUT) MCFG_AY8910_RES_LOADS(4700, 4700, 4700) diff --git a/src/mame/drivers/orion.cpp b/src/mame/drivers/orion.cpp index 19297b94ce7..5c880df930e 100644 --- a/src/mame/drivers/orion.cpp +++ b/src/mame/drivers/orion.cpp @@ -126,8 +126,7 @@ MACHINE_CONFIG_START(orion_state::orion128) MCFG_VIDEO_START_OVERRIDE(orion_state,orion128) SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); MCFG_CASSETTE_ADD( "cassette" ) MCFG_CASSETTE_FORMATS(rko_cassette_formats) @@ -202,10 +201,8 @@ MACHINE_CONFIG_START(orion_state::orionz80) MCFG_MC146818_ADD( "rtc", XTAL(4'194'304) ) SPEAKER(config, "mono").front_center(); - MCFG_DEVICE_ADD("speaker", SPEAKER_SOUND) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.0) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + SPEAKER_SOUND(config, "speaker").add_route(ALL_OUTPUTS, "mono", 1.0); + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); MCFG_DEVICE_ADD("ay8912", AY8912, 1773400) MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.00) @@ -278,10 +275,8 @@ MACHINE_CONFIG_START(orion_state::orionpro) MCFG_VIDEO_START_OVERRIDE(orion_state,orion128) SPEAKER(config, "mono").front_center(); - MCFG_DEVICE_ADD("speaker", SPEAKER_SOUND) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.0) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + SPEAKER_SOUND(config, "speaker").add_route(ALL_OUTPUTS, "mono", 1.0); + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); MCFG_DEVICE_ADD("ay8912", AY8912, 1773400) MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.00) diff --git a/src/mame/drivers/partner.cpp b/src/mame/drivers/partner.cpp index 815157f846b..c730204c4fa 100644 --- a/src/mame/drivers/partner.cpp +++ b/src/mame/drivers/partner.cpp @@ -199,8 +199,7 @@ MACHINE_CONFIG_START(partner_state::partner) MCFG_PALETTE_INIT_OWNER(partner_state,radio86) SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); MCFG_DEVICE_ADD("dma8257", I8257, XTAL(16'000'000) / 9) MCFG_I8257_OUT_HRQ_CB(WRITELINE(*this, partner_state, hrq_w)) diff --git a/src/mame/drivers/pc6001.cpp b/src/mame/drivers/pc6001.cpp index 6ab55b07326..4ed4910e381 100644 --- a/src/mame/drivers/pc6001.cpp +++ b/src/mame/drivers/pc6001.cpp @@ -1529,8 +1529,7 @@ MACHINE_CONFIG_START(pc6001_state::pc6001) MCFG_AY8910_PORT_A_READ_CB(IOPORT("P1")) MCFG_AY8910_PORT_B_READ_CB(IOPORT("P2")) MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.00) -// MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") -// MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) +// WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); /* TODO: accurate timing on this */ MCFG_TIMER_DRIVER_ADD_PERIODIC("keyboard_timer", pc6001_state, keyboard_callback, attotime::from_hz(250)) diff --git a/src/mame/drivers/pcm.cpp b/src/mame/drivers/pcm.cpp index fc904af7b8c..2281aeff75e 100644 --- a/src/mame/drivers/pcm.cpp +++ b/src/mame/drivers/pcm.cpp @@ -274,10 +274,8 @@ MACHINE_CONFIG_START(pcm_state::pcm) /* Sound */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) - MCFG_DEVICE_ADD("speaker", SPEAKER_SOUND) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); + SPEAKER_SOUND(config, "speaker").add_route(ALL_OUTPUTS, "mono", 0.50); /* Devices */ MCFG_K7659_KEYBOARD_ADD() diff --git a/src/mame/drivers/pegasus.cpp b/src/mame/drivers/pegasus.cpp index 7a2e2a99cb9..b3f4235f7c9 100644 --- a/src/mame/drivers/pegasus.cpp +++ b/src/mame/drivers/pegasus.cpp @@ -504,8 +504,7 @@ MACHINE_CONFIG_START(pegasus_state::pegasus) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.05) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.05); /* devices */ MCFG_DEVICE_ADD("pia_s", PIA6821, 0) diff --git a/src/mame/drivers/pencil2.cpp b/src/mame/drivers/pencil2.cpp index 4c263c4dc2d..8e9a17c869c 100644 --- a/src/mame/drivers/pencil2.cpp +++ b/src/mame/drivers/pencil2.cpp @@ -324,8 +324,7 @@ MACHINE_CONFIG_START(pencil2_state::pencil2) SPEAKER(config, "mono").front_center(); MCFG_DEVICE_ADD("sn76489a", SN76489A, XTAL(10'738'635)/3) // guess MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.00) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); /* cassette */ MCFG_CASSETTE_ADD( "cassette" ) diff --git a/src/mame/drivers/phc25.cpp b/src/mame/drivers/phc25.cpp index a7b59c670c2..186d773b1e1 100644 --- a/src/mame/drivers/phc25.cpp +++ b/src/mame/drivers/phc25.cpp @@ -320,8 +320,7 @@ MACHINE_CONFIG_START(phc25_state::phc25) MCFG_AY8910_PORT_A_READ_CB(IOPORT("JOY0")) MCFG_AY8910_PORT_B_READ_CB(IOPORT("JOY1")) MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.00) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.15) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.15); /* devices */ MCFG_CASSETTE_ADD("cassette") diff --git a/src/mame/drivers/phunsy.cpp b/src/mame/drivers/phunsy.cpp index 86a02788cf5..04cbba8809a 100644 --- a/src/mame/drivers/phunsy.cpp +++ b/src/mame/drivers/phunsy.cpp @@ -364,10 +364,8 @@ MACHINE_CONFIG_START(phunsy_state::phunsy) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) - MCFG_DEVICE_ADD("speaker", SPEAKER_SOUND) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); + SPEAKER_SOUND(config, "speaker").add_route(ALL_OUTPUTS, "mono", 0.50); /* Devices */ MCFG_DEVICE_ADD("keyboard", GENERIC_KEYBOARD, 0) diff --git a/src/mame/drivers/pk8000.cpp b/src/mame/drivers/pk8000.cpp index a3fe9c08560..7682eb83e5b 100644 --- a/src/mame/drivers/pk8000.cpp +++ b/src/mame/drivers/pk8000.cpp @@ -390,10 +390,8 @@ MACHINE_CONFIG_START(pk8000_state::pk8000) /* audio hardware */ SPEAKER(config, "mono").front_center(); - MCFG_DEVICE_ADD("speaker", SPEAKER_SOUND) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + SPEAKER_SOUND(config, "speaker").add_route(ALL_OUTPUTS, "mono", 0.50); + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); MCFG_CASSETTE_ADD( "cassette" ) MCFG_CASSETTE_FORMATS(fmsx_cassette_formats) diff --git a/src/mame/drivers/pk8020.cpp b/src/mame/drivers/pk8020.cpp index f8de3af24ce..b589aa11bb1 100644 --- a/src/mame/drivers/pk8020.cpp +++ b/src/mame/drivers/pk8020.cpp @@ -235,10 +235,8 @@ MACHINE_CONFIG_START(pk8020_state::pk8020) /* audio hardware */ SPEAKER(config, "mono").front_center(); - MCFG_DEVICE_ADD("speaker", SPEAKER_SOUND) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + SPEAKER_SOUND(config, "speaker").add_route(ALL_OUTPUTS, "mono", 0.25); + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); MCFG_CASSETTE_ADD( "cassette" ) MCFG_CASSETTE_DEFAULT_STATE(CASSETTE_PLAY) diff --git a/src/mame/drivers/pmd85.cpp b/src/mame/drivers/pmd85.cpp index 6e4e7488aaf..d1691091bfa 100644 --- a/src/mame/drivers/pmd85.cpp +++ b/src/mame/drivers/pmd85.cpp @@ -626,8 +626,7 @@ MACHINE_CONFIG_START(pmd85_state::pmd85) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); /* cassette */ MCFG_CASSETTE_ADD("cassette") diff --git a/src/mame/drivers/poly88.cpp b/src/mame/drivers/poly88.cpp index ad15d5675fd..7a87d734db5 100644 --- a/src/mame/drivers/poly88.cpp +++ b/src/mame/drivers/poly88.cpp @@ -218,8 +218,7 @@ MACHINE_CONFIG_START(poly88_state::poly88) /* audio hardware */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); /* cassette */ MCFG_CASSETTE_ADD( "cassette" ) diff --git a/src/mame/drivers/pp01.cpp b/src/mame/drivers/pp01.cpp index 601011b7117..266fc80e50f 100644 --- a/src/mame/drivers/pp01.cpp +++ b/src/mame/drivers/pp01.cpp @@ -220,10 +220,8 @@ MACHINE_CONFIG_START(pp01_state::pp01) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_DEVICE_ADD("speaker", SPEAKER_SOUND) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50) - //MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - //MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + SPEAKER_SOUND(config, "speaker").add_route(ALL_OUTPUTS, "mono", 0.50); + //WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); /* Devices */ MCFG_DEVICE_ADD("uart", I8251, 0) diff --git a/src/mame/drivers/primo.cpp b/src/mame/drivers/primo.cpp index 6ba14d439bc..6fd39d067ce 100644 --- a/src/mame/drivers/primo.cpp +++ b/src/mame/drivers/primo.cpp @@ -265,10 +265,8 @@ MACHINE_CONFIG_START(primo_state::primoa32) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) - MCFG_DEVICE_ADD("speaker", SPEAKER_SOUND) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); + SPEAKER_SOUND(config, "speaker").add_route(ALL_OUTPUTS, "mono", 0.50); /* snapshot/quickload */ MCFG_SNAPSHOT_ADD("snapshot", primo_state, primo, "pss", 0) diff --git a/src/mame/drivers/pro80.cpp b/src/mame/drivers/pro80.cpp index af8e5919964..e95ee7c8015 100644 --- a/src/mame/drivers/pro80.cpp +++ b/src/mame/drivers/pro80.cpp @@ -184,8 +184,7 @@ MACHINE_CONFIG_START(pro80_state::pro80) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.05) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.05); /* Devices */ MCFG_CASSETTE_ADD( "cassette" ) diff --git a/src/mame/drivers/proteus3.cpp b/src/mame/drivers/proteus3.cpp index 933a9f5ca40..82b37b0419d 100644 --- a/src/mame/drivers/proteus3.cpp +++ b/src/mame/drivers/proteus3.cpp @@ -407,8 +407,7 @@ MACHINE_CONFIG_START(proteus3_state::proteus3) MCFG_CASSETTE_ADD("cassette") MCFG_CASSETTE_DEFAULT_STATE(CASSETTE_PLAY | CASSETTE_MOTOR_ENABLED | CASSETTE_SPEAKER_ENABLED) SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); MCFG_TIMER_DRIVER_ADD_PERIODIC("timer_c", proteus3_state, timer_c, attotime::from_hz(4800)) MCFG_TIMER_DRIVER_ADD_PERIODIC("timer_p", proteus3_state, timer_p, attotime::from_hz(40000)) diff --git a/src/mame/drivers/ptcsol.cpp b/src/mame/drivers/ptcsol.cpp index 46bb1ff693d..223bf62319e 100644 --- a/src/mame/drivers/ptcsol.cpp +++ b/src/mame/drivers/ptcsol.cpp @@ -733,12 +733,9 @@ MACHINE_CONFIG_START(sol20_state::sol20) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_DEVICE_ADD("speaker", SPEAKER_SOUND) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 2.00) // music board - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.05) // cass1 speaker - MCFG_SOUND_WAVE_ADD(WAVE2_TAG, "cassette2") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.05) // cass2 speaker + SPEAKER_SOUND(config, "speaker").add_route(ALL_OUTPUTS, "mono", 2.00); // music board + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.05); // cass1 speaker + WAVE(config, "wave2", "cassette2").add_route(ALL_OUTPUTS, "mono", 0.05); // cass2 speaker // devices MCFG_CASSETTE_ADD("cassette") diff --git a/src/mame/drivers/pv2000.cpp b/src/mame/drivers/pv2000.cpp index d6caacf54f2..7568e06300f 100644 --- a/src/mame/drivers/pv2000.cpp +++ b/src/mame/drivers/pv2000.cpp @@ -404,8 +404,7 @@ MACHINE_CONFIG_START(pv2000_state::pv2000) MCFG_DEVICE_ADD("sn76489a", SN76489A, XTAL(7'159'090)/2) /* 3.579545 MHz */ MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.00) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); /* cassette */ MCFG_CASSETTE_ADD( "cassette" ) diff --git a/src/mame/drivers/px8.cpp b/src/mame/drivers/px8.cpp index 2a0c2850b03..784fe625247 100644 --- a/src/mame/drivers/px8.cpp +++ b/src/mame/drivers/px8.cpp @@ -780,8 +780,7 @@ MACHINE_CONFIG_START(px8_state::px8) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(0, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(0, "mono", 0.25); /* cartridge */ MCFG_GENERIC_CARTSLOT_ADD("capsule1", generic_plain_slot, "px8_cart") diff --git a/src/mame/drivers/radio86.cpp b/src/mame/drivers/radio86.cpp index 66102c49a95..506864cc965 100644 --- a/src/mame/drivers/radio86.cpp +++ b/src/mame/drivers/radio86.cpp @@ -380,8 +380,7 @@ MACHINE_CONFIG_START(radio86_state::radio86) MCFG_PALETTE_INIT_OWNER(radio86_state,radio86) SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); MCFG_DEVICE_ADD("dma8257", I8257, XTAL(16'000'000) / 9) MCFG_I8257_OUT_HRQ_CB(WRITELINE(*this, radio86_state, hrq_w)) diff --git a/src/mame/drivers/ravens.cpp b/src/mame/drivers/ravens.cpp index e212893fd62..1564e738855 100644 --- a/src/mame/drivers/ravens.cpp +++ b/src/mame/drivers/ravens.cpp @@ -353,8 +353,7 @@ MACHINE_CONFIG_START(ravens_state::ravens) /* cassette */ MCFG_CASSETTE_ADD( "cassette" ) SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.05) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.05); MACHINE_CONFIG_END MACHINE_CONFIG_START(ravens_state::ravens2) @@ -377,8 +376,7 @@ MACHINE_CONFIG_START(ravens_state::ravens2) /* cassette */ MCFG_CASSETTE_ADD( "cassette" ) SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.05) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.05); MACHINE_CONFIG_END /* ROM definition */ diff --git a/src/mame/drivers/rx78.cpp b/src/mame/drivers/rx78.cpp index 3854d6d2a82..13aa65121a1 100644 --- a/src/mame/drivers/rx78.cpp +++ b/src/mame/drivers/rx78.cpp @@ -504,8 +504,7 @@ MACHINE_CONFIG_START(rx78_state::rx78) SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); MCFG_DEVICE_ADD("sn1", SN76489A, XTAL(28'636'363)/8) // unknown divider MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50) diff --git a/src/mame/drivers/sorcerer.cpp b/src/mame/drivers/sorcerer.cpp index eb0a2138828..5d29f53f362 100644 --- a/src/mame/drivers/sorcerer.cpp +++ b/src/mame/drivers/sorcerer.cpp @@ -436,10 +436,8 @@ MACHINE_CONFIG_START(sorcerer_state::sorcerer) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.05) // cass1 speaker - MCFG_SOUND_WAVE_ADD(WAVE2_TAG, "cassette2") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.05) // cass2 speaker + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.05); // cass1 speaker + WAVE(config, "wave2", "cassette2").add_route(ALL_OUTPUTS, "mono", 0.05); // cass2 speaker MCFG_DEVICE_ADD( "uart", AY31015, 0 ) MCFG_AY31015_TX_CLOCK(ES_UART_CLOCK) diff --git a/src/mame/drivers/spc1000.cpp b/src/mame/drivers/spc1000.cpp index 905bb229c53..ec117cd8bd1 100644 --- a/src/mame/drivers/spc1000.cpp +++ b/src/mame/drivers/spc1000.cpp @@ -486,8 +486,7 @@ MACHINE_CONFIG_START(spc1000_state::spc1000) MCFG_AY8910_PORT_A_READ_CB(READ8(*this, spc1000_state, porta_r)) MCFG_AY8910_PORT_B_WRITE_CB(WRITE8("cent_data_out", output_latch_device, write)) MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.00) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.05) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.05); MCFG_DEVICE_ADD("ext1", SPC1000_EXP_SLOT, 0) MCFG_DEVICE_SLOT_INTERFACE(spc1000_exp, nullptr, false) diff --git a/src/mame/drivers/spc1500.cpp b/src/mame/drivers/spc1500.cpp index 6a4a055fadd..6fc4602c689 100644 --- a/src/mame/drivers/spc1500.cpp +++ b/src/mame/drivers/spc1500.cpp @@ -911,8 +911,7 @@ MACHINE_CONFIG_START(spc1500_state::spc1500) MCFG_AY8910_PORT_A_READ_CB(READ8(*this, spc1500_state, psga_r)) MCFG_AY8910_PORT_B_WRITE_CB(WRITE8(*this, spc1500_state, psgb_w)) MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.00) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); MCFG_CENTRONICS_ADD("centronics", centronics_devices, "printer") MCFG_CENTRONICS_BUSY_HANDLER(WRITELINE(*this, spc1500_state, centronics_busy_w)) diff --git a/src/mame/drivers/special.cpp b/src/mame/drivers/special.cpp index f30dd4b5072..3d090382d8a 100644 --- a/src/mame/drivers/special.cpp +++ b/src/mame/drivers/special.cpp @@ -384,12 +384,11 @@ MACHINE_CONFIG_START(special_state::special) /* audio hardware */ SPEAKER(config, "speaker").front_center(); - MCFG_DEVICE_ADD("dac", DAC_1BIT, 0) MCFG_SOUND_ROUTE(ALL_OUTPUTS, "speaker", 0.0625) + DAC_1BIT(config, "dac", 0).add_route(ALL_OUTPUTS, "speaker", 0.0625); 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_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "speaker", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "speaker", 0.25); /* Devices */ MCFG_DEVICE_ADD("ppi8255", I8255, 0) @@ -506,12 +505,11 @@ MACHINE_CONFIG_START(special_state::erik) /* audio hardware */ SPEAKER(config, "speaker").front_center(); - MCFG_DEVICE_ADD("dac", DAC_1BIT, 0) MCFG_SOUND_ROUTE(ALL_OUTPUTS, "speaker", 0.0625) + DAC_1BIT(config, "dac", 0).add_route(ALL_OUTPUTS, "speaker", 0.0625); 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_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "speaker", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "speaker", 0.25); /* Devices */ MCFG_CASSETTE_ADD( "cassette" ) diff --git a/src/mame/drivers/spectrum.cpp b/src/mame/drivers/spectrum.cpp index 77559a20ce8..2fbbe6aae8c 100644 --- a/src/mame/drivers/spectrum.cpp +++ b/src/mame/drivers/spectrum.cpp @@ -693,10 +693,8 @@ MACHINE_CONFIG_START(spectrum_state::spectrum_common) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) - MCFG_DEVICE_ADD("speaker", SPEAKER_SOUND) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); + SPEAKER_SOUND(config, "speaker").add_route(ALL_OUTPUTS, "mono", 0.50); /* expansion port */ MCFG_SPECTRUM_EXPANSION_SLOT_ADD("exp", spectrum_expansion_devices, "kempjoy") diff --git a/src/mame/drivers/super80.cpp b/src/mame/drivers/super80.cpp index 4f1443358a8..dd1f1b3011a 100644 --- a/src/mame/drivers/super80.cpp +++ b/src/mame/drivers/super80.cpp @@ -733,10 +733,8 @@ MACHINE_CONFIG_START(super80_state::super80) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.05) - MCFG_DEVICE_ADD("speaker", SPEAKER_SOUND) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.05); + SPEAKER_SOUND(config, "speaker").add_route(ALL_OUTPUTS, "mono", 0.50); MCFG_DEVICE_ADD("samples", SAMPLES) MCFG_SAMPLES_CHANNELS(1) MCFG_SAMPLES_NAMES(relay_sample_names) @@ -827,10 +825,8 @@ MACHINE_CONFIG_START(super80_state::super80v) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.05) - MCFG_DEVICE_ADD("speaker", SPEAKER_SOUND) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.05); + SPEAKER_SOUND(config, "speaker").add_route(ALL_OUTPUTS, "mono", 0.50); MCFG_DEVICE_ADD("samples", SAMPLES) MCFG_SAMPLES_CHANNELS(1) MCFG_SAMPLES_NAMES(relay_sample_names) diff --git a/src/mame/drivers/svi318.cpp b/src/mame/drivers/svi318.cpp index a3c89879c21..05dc7471c0b 100644 --- a/src/mame/drivers/svi318.cpp +++ b/src/mame/drivers/svi318.cpp @@ -557,10 +557,8 @@ MACHINE_CONFIG_START(svi3x8_state::svi318) // sound hardware SPEAKER(config, "mono").front_center(); - MCFG_DEVICE_ADD("speaker", SPEAKER_SOUND) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + SPEAKER_SOUND(config, "speaker").add_route(ALL_OUTPUTS, "mono", 0.25); + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); MCFG_DEVICE_ADD("psg", AY8910, XTAL(10'738'635) / 6) MCFG_AY8910_PORT_A_READ_CB(IOPORT("JOY")) MCFG_AY8910_PORT_B_WRITE_CB(WRITE8(*this, svi3x8_state, bank_w)) diff --git a/src/mame/drivers/tavernie.cpp b/src/mame/drivers/tavernie.cpp index 9663389f0b9..8bfa6763a43 100644 --- a/src/mame/drivers/tavernie.cpp +++ b/src/mame/drivers/tavernie.cpp @@ -301,8 +301,7 @@ MACHINE_CONFIG_START(tavernie_state::cpu09) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.05) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.05); /* Devices */ MCFG_CASSETTE_ADD( "cassette" ) diff --git a/src/mame/drivers/tec1.cpp b/src/mame/drivers/tec1.cpp index e93aeebbb7e..d5db3a246a4 100644 --- a/src/mame/drivers/tec1.cpp +++ b/src/mame/drivers/tec1.cpp @@ -89,7 +89,7 @@ public: , m_maincpu(*this, "maincpu") , m_speaker(*this, "speaker") , m_cass(*this, "cassette") - , m_wave(*this, WAVE_TAG) + , m_wave(*this, "wave") , m_key_pressed(0) , m_io_line0(*this, "LINE0") , m_io_line1(*this, "LINE1") @@ -441,10 +441,8 @@ MACHINE_CONFIG_START(tec1_state::tecjmon) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_DEVICE_ADD("speaker", SPEAKER_SOUND) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.05) + SPEAKER_SOUND(config, "speaker").add_route(ALL_OUTPUTS, "mono", 0.50); + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.05); /* Devices */ MCFG_CASSETTE_ADD( "cassette" ) diff --git a/src/mame/drivers/ti99_4p.cpp b/src/mame/drivers/ti99_4p.cpp index f00e3c8b46a..152702522d3 100644 --- a/src/mame/drivers/ti99_4p.cpp +++ b/src/mame/drivers/ti99_4p.cpp @@ -1038,8 +1038,7 @@ MACHINE_CONFIG_START(ti99_4p_state::ti99_4p_60hz) SPEAKER(config, "cass_out").front_center(); MCFG_CASSETTE_ADD( "cassette" ) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "cass_out", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "cass_out", 0.25); // Joystick port MCFG_TI_JOYPORT4A_ADD( TI_JOYPORT_TAG ) diff --git a/src/mame/drivers/ti99_4x.cpp b/src/mame/drivers/ti99_4x.cpp index 516bfc6c090..38e268c2959 100644 --- a/src/mame/drivers/ti99_4x.cpp +++ b/src/mame/drivers/ti99_4x.cpp @@ -900,8 +900,7 @@ MACHINE_CONFIG_START(ti99_4x_state::ti99_4) MCFG_CASSETTE_ADD( "cassette" ) MCFG_CASSETTE_ADD( "cassette2" ) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "cass_out", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "cass_out", 0.25); // GROM devices MCFG_GROM_ADD( TI99_GROM0_TAG, 0, TI99_CONSOLEGROM, 0x0000, WRITELINE(*this, ti99_4x_state, console_ready_grom)) @@ -1019,8 +1018,7 @@ MACHINE_CONFIG_START(ti99_4x_state::ti99_4a) MCFG_CASSETTE_ADD( "cassette" ) MCFG_CASSETTE_ADD( "cassette2" ) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "cass_out", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "cass_out", 0.25); // GROM devices MCFG_GROM_ADD( TI99_GROM0_TAG, 0, TI99_CONSOLEGROM, 0x0000, WRITELINE(*this, ti99_4x_state, console_ready_grom)) @@ -1176,8 +1174,7 @@ MACHINE_CONFIG_START(ti99_4x_state::ti99_4ev_60hz) MCFG_CASSETTE_ADD( "cassette" ) MCFG_CASSETTE_ADD( "cassette2" ) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "cass_out", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "cass_out", 0.25); // GROM devices MCFG_GROM_ADD( TI99_GROM0_TAG, 0, TI99_CONSOLEGROM, 0x0000, WRITELINE(*this, ti99_4x_state, console_ready_grom)) diff --git a/src/mame/drivers/ti99_8.cpp b/src/mame/drivers/ti99_8.cpp index e26c51307d1..cda481fb9b1 100644 --- a/src/mame/drivers/ti99_8.cpp +++ b/src/mame/drivers/ti99_8.cpp @@ -794,8 +794,7 @@ MACHINE_CONFIG_START(ti99_8_state::ti99_8) // Cassette drive SPEAKER(config, "cass_out").front_center(); MCFG_CASSETTE_ADD( "cassette" ) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "cass_out", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "cass_out", 0.25); // GROM library MCFG_GROM_ADD( TI998_SYSGROM0_TAG, 0, TI998_SYSGROM_REG, 0x0000, WRITELINE(TI998_MAINBOARD_TAG, bus::ti99::internal::mainboard8_device, system_grom_ready)) diff --git a/src/mame/drivers/tm990189.cpp b/src/mame/drivers/tm990189.cpp index c70b433b04a..1bcdd235e30 100644 --- a/src/mame/drivers/tm990189.cpp +++ b/src/mame/drivers/tm990189.cpp @@ -824,10 +824,8 @@ MACHINE_CONFIG_START(tm990189_state::tm990_189) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) - MCFG_DEVICE_ADD("speaker", SPEAKER_SOUND) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); + SPEAKER_SOUND(config, "speaker").add_route(ALL_OUTPUTS, "mono", 0.50); /* Devices */ MCFG_CASSETTE_ADD( "cassette" ) @@ -885,10 +883,8 @@ MACHINE_CONFIG_START(tm990189_state::tm990_189_v) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) - MCFG_DEVICE_ADD("speaker", SPEAKER_SOUND) /* one two-level buzzer */ - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); + SPEAKER_SOUND(config, "speaker").add_route(ALL_OUTPUTS, "mono", 0.50); /* one two-level buzzer */ /* Devices */ MCFG_CASSETTE_ADD( "cassette" ) diff --git a/src/mame/drivers/trs80.cpp b/src/mame/drivers/trs80.cpp index 765cd95205d..95fb05e333b 100644 --- a/src/mame/drivers/trs80.cpp +++ b/src/mame/drivers/trs80.cpp @@ -624,10 +624,8 @@ MACHINE_CONFIG_START(trs80_state::trs80) // the original model I, level I, /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_DEVICE_ADD("speaker", SPEAKER_SOUND) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.05) + SPEAKER_SOUND(config, "speaker").add_route(ALL_OUTPUTS, "mono", 0.50); + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.05); /* devices */ MCFG_CASSETTE_ADD("cassette") diff --git a/src/mame/drivers/tutor.cpp b/src/mame/drivers/tutor.cpp index 0d4a12b652b..7bca1a782ae 100644 --- a/src/mame/drivers/tutor.cpp +++ b/src/mame/drivers/tutor.cpp @@ -760,8 +760,7 @@ MACHINE_CONFIG_START(tutor_state::tutor) MCFG_DEVICE_ADD("sn76489a", SN76489A, 3579545) /* 3.579545 MHz */ MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.75) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); MCFG_CENTRONICS_ADD("centronics", centronics_devices, "printer") MCFG_CENTRONICS_BUSY_HANDLER(WRITELINE(*this, tutor_state, write_centronics_busy)) diff --git a/src/mame/drivers/ut88.cpp b/src/mame/drivers/ut88.cpp index e5d44ed739f..daa58201e4e 100644 --- a/src/mame/drivers/ut88.cpp +++ b/src/mame/drivers/ut88.cpp @@ -209,12 +209,11 @@ MACHINE_CONFIG_START(ut88_state::ut88) /* audio hardware */ SPEAKER(config, "speaker").front_center(); - MCFG_DEVICE_ADD("dac", DAC_1BIT, 0) MCFG_SOUND_ROUTE(ALL_OUTPUTS, "speaker", 0.25) + DAC_1BIT(config, "dac", 0).add_route(ALL_OUTPUTS, "speaker", 0.25); 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_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "speaker", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "speaker", 0.25); /* Devices */ MCFG_DEVICE_ADD("ppi8255", I8255A, 0) @@ -243,8 +242,7 @@ MACHINE_CONFIG_START(ut88_state::ut88mini) /* Cassette */ SPEAKER(config, "speaker").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "speaker", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "speaker", 0.25); MCFG_CASSETTE_ADD( "cassette" ) MCFG_CASSETTE_FORMATS(rku_cassette_formats) diff --git a/src/mame/drivers/vc4000.cpp b/src/mame/drivers/vc4000.cpp index ef822f4bfb9..28a7df52bb0 100644 --- a/src/mame/drivers/vc4000.cpp +++ b/src/mame/drivers/vc4000.cpp @@ -598,8 +598,7 @@ MACHINE_CONFIG_START(vc4000_state::elektor) MCFG_DEVICE_MODIFY("maincpu") MCFG_DEVICE_PROGRAM_MAP(elektor_mem) MCFG_CASSETTE_ADD( "cassette" ) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); MACHINE_CONFIG_END diff --git a/src/mame/drivers/vector06.cpp b/src/mame/drivers/vector06.cpp index 6d3615daaa9..4916a2bdc53 100644 --- a/src/mame/drivers/vector06.cpp +++ b/src/mame/drivers/vector06.cpp @@ -181,8 +181,7 @@ MACHINE_CONFIG_START(vector06_state::vector06) MCFG_PALETTE_INIT_OWNER(vector06_state, vector06) SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); /* devices */ MCFG_DEVICE_ADD("ppi8255", I8255, 0) diff --git a/src/mame/drivers/vg5k.cpp b/src/mame/drivers/vg5k.cpp index 8e1efe3c1b1..84af1d80189 100644 --- a/src/mame/drivers/vg5k.cpp +++ b/src/mame/drivers/vg5k.cpp @@ -390,13 +390,12 @@ MACHINE_CONFIG_START(vg5k_state::vg5k) /* sound hardware */ SPEAKER(config, "speaker").front_center(); - MCFG_DEVICE_ADD("dac", DAC_1BIT, 0) MCFG_SOUND_ROUTE(ALL_OUTPUTS, "speaker", 0.125) + DAC_1BIT(config, "dac", 0).add_route(ALL_OUTPUTS, "speaker", 0.125); MCFG_DEVICE_ADD("vref", VOLTAGE_REGULATOR, 0) MCFG_VOLTAGE_REGULATOR_OUTPUT(5.0) MCFG_SOUND_ROUTE(0, "dac", 1.0, DAC_VREF_POS_INPUT) /* cassette */ - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(0, "speaker", 0.25) + WAVE(config, "wave", "cassette").add_route(0, "speaker", 0.25); MCFG_CASSETTE_ADD( "cassette" ) MCFG_CASSETTE_FORMATS(vg5k_cassette_formats) diff --git a/src/mame/drivers/vtech1.cpp b/src/mame/drivers/vtech1.cpp index 412e495aeff..84c1faaf036 100644 --- a/src/mame/drivers/vtech1.cpp +++ b/src/mame/drivers/vtech1.cpp @@ -454,8 +454,7 @@ MACHINE_CONFIG_START(vtech1_state::laser110) // sound hardware SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); MCFG_DEVICE_ADD("speaker", SPEAKER_SOUND) MCFG_SPEAKER_LEVELS(4, speaker_levels) MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.75) diff --git a/src/mame/drivers/vtech2.cpp b/src/mame/drivers/vtech2.cpp index 750a72739b8..c70a3222a77 100644 --- a/src/mame/drivers/vtech2.cpp +++ b/src/mame/drivers/vtech2.cpp @@ -439,10 +439,8 @@ MACHINE_CONFIG_START(vtech2_state::laser350) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) - MCFG_DEVICE_ADD("speaker", SPEAKER_SOUND) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.75) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); + SPEAKER_SOUND(config, "speaker").add_route(ALL_OUTPUTS, "mono", 0.75); MCFG_CASSETTE_ADD( "cassette" ) MCFG_CASSETTE_FORMATS(vtech2_cassette_formats) diff --git a/src/mame/drivers/x07.cpp b/src/mame/drivers/x07.cpp index 6b48c637502..1354447ce39 100644 --- a/src/mame/drivers/x07.cpp +++ b/src/mame/drivers/x07.cpp @@ -1502,10 +1502,8 @@ MACHINE_CONFIG_START(x07_state::x07) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_DEVICE_ADD( "beeper", BEEP, 0 ) - MCFG_SOUND_ROUTE( ALL_OUTPUTS, "mono", 0.50 ) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + BEEP(config, "beeper", 0).add_route(ALL_OUTPUTS, "mono", 0.50); + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); /* printer */ MCFG_DEVICE_ADD("printer", PRINTER, 0) diff --git a/src/mame/drivers/x1.cpp b/src/mame/drivers/x1.cpp index 67ebe6f1240..2721876a9d3 100644 --- a/src/mame/drivers/x1.cpp +++ b/src/mame/drivers/x1.cpp @@ -2276,9 +2276,7 @@ MACHINE_CONFIG_START(x1_state::x1) MCFG_SOUND_ROUTE(0, "rspeaker", 0.25) MCFG_SOUND_ROUTE(1, "lspeaker", 0.5) MCFG_SOUND_ROUTE(2, "rspeaker", 0.5) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "lspeaker", 0.25) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "rspeaker", 0.10) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "lspeaker", 0.25).add_route(ALL_OUTPUTS, "rspeaker", 0.10); MCFG_CASSETTE_ADD("cassette") MCFG_CASSETTE_FORMATS(x1_cassette_formats) diff --git a/src/mame/drivers/x1twin.cpp b/src/mame/drivers/x1twin.cpp index 1073a7158f4..f064e3cd8b0 100644 --- a/src/mame/drivers/x1twin.cpp +++ b/src/mame/drivers/x1twin.cpp @@ -507,9 +507,7 @@ MACHINE_CONFIG_START(x1twin_state::x1twin) MCFG_SOUND_ROUTE(0, "x1_r", 0.25) MCFG_SOUND_ROUTE(1, "x1_l", 0.5) MCFG_SOUND_ROUTE(2, "x1_r", 0.5) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "x1_l", 0.25) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "x1_r", 0.10) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "x1_l", 0.25).add_route(ALL_OUTPUTS, "x1_r", 0.10); MCFG_CASSETTE_ADD("cassette") MCFG_CASSETTE_FORMATS(x1_cassette_formats) diff --git a/src/mame/drivers/z1013.cpp b/src/mame/drivers/z1013.cpp index ade01619763..3b36b37e063 100644 --- a/src/mame/drivers/z1013.cpp +++ b/src/mame/drivers/z1013.cpp @@ -388,8 +388,7 @@ MACHINE_CONFIG_START(z1013_state::z1013) /* sound hardware */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); /* devices */ MCFG_DEVICE_ADD("z80pio", Z80PIO, XTAL(1'000'000)) diff --git a/src/mame/drivers/z9001.cpp b/src/mame/drivers/z9001.cpp index 350c5995b86..b60553b2615 100644 --- a/src/mame/drivers/z9001.cpp +++ b/src/mame/drivers/z9001.cpp @@ -224,10 +224,8 @@ MACHINE_CONFIG_START(z9001_state::z9001) /* Sound */ SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) - MCFG_DEVICE_ADD("beeper", BEEP, 800) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); + BEEP(config, "beeper", 800).add_route(ALL_OUTPUTS, "mono", 0.50); /* Devices */ MCFG_DEVICE_ADD("keyboard", GENERIC_KEYBOARD, 0) diff --git a/src/mame/drivers/zx.cpp b/src/mame/drivers/zx.cpp index 806e4c965e2..7eed9f24fc7 100644 --- a/src/mame/drivers/zx.cpp +++ b/src/mame/drivers/zx.cpp @@ -383,10 +383,8 @@ MACHINE_CONFIG_START(zx_state::zx81_spk ) /* sound hardware */ /* Used by pc8300/lambda/pow3000 */ SPEAKER(config, "mono").front_center(); - MCFG_DEVICE_ADD("speaker", SPEAKER_SOUND) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.75) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + SPEAKER_SOUND(config, "speaker").add_route(ALL_OUTPUTS, "mono", 0.75); + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); MACHINE_CONFIG_END MACHINE_CONFIG_START(zx_state::ts1000) diff --git a/src/mame/includes/mbee.h b/src/mame/includes/mbee.h index e95302af897..bae296595c8 100644 --- a/src/mame/includes/mbee.h +++ b/src/mame/includes/mbee.h @@ -45,7 +45,7 @@ public: , m_maincpu(*this, "maincpu") , m_pio(*this, "z80pio") , m_cassette(*this, "cassette") - , m_wave(*this, WAVE_TAG) + , m_wave(*this, "wave") , m_speaker(*this, "speaker") , m_centronics(*this, "centronics") , m_cent_data_out(*this, "cent_data_out") diff --git a/src/mame/includes/sorcerer.h b/src/mame/includes/sorcerer.h index abfef33f451..cd98658c694 100644 --- a/src/mame/includes/sorcerer.h +++ b/src/mame/includes/sorcerer.h @@ -56,8 +56,8 @@ public: , m_maincpu(*this, "maincpu") , m_cassette1(*this, "cassette") , m_cassette2(*this, "cassette2") - , m_wave1(*this, WAVE_TAG) - , m_wave2(*this, WAVE2_TAG) + , m_wave1(*this, "wave") + , m_wave2(*this, "wave2") , m_uart(*this, "uart") , m_rs232(*this, "rs232") , m_centronics(*this, "centronics") diff --git a/src/mame/includes/super80.h b/src/mame/includes/super80.h index cbeb5847b37..6d21adce8ac 100644 --- a/src/mame/includes/super80.h +++ b/src/mame/includes/super80.h @@ -40,7 +40,7 @@ public: , m_p_videoram(*this, "videoram") , m_pio(*this, "z80pio") , m_cassette(*this, "cassette") - , m_wave(*this, WAVE_TAG) + , m_wave(*this, "wave") , m_samples(*this, "samples") , m_speaker(*this, "speaker") , m_centronics(*this, "centronics") diff --git a/src/mame/machine/coco.cpp b/src/mame/machine/coco.cpp index cfb60864d67..345a8ed18e8 100644 --- a/src/mame/machine/coco.cpp +++ b/src/mame/machine/coco.cpp @@ -88,7 +88,7 @@ coco_state::coco_state(const machine_config &mconfig, device_type type, const ch m_pia_1(*this, PIA1_TAG), m_dac(*this, "dac"), m_sbs(*this, "sbs"), - m_wave(*this, WAVE_TAG), + m_wave(*this, "wave"), m_screen(*this, SCREEN_TAG), m_cococart(*this, CARTRIDGE_TAG), m_ram(*this, RAM_TAG), diff --git a/src/mame/machine/hec2hrp.cpp b/src/mame/machine/hec2hrp.cpp index 0a4d30f5eac..3dbd3bf8df2 100644 --- a/src/mame/machine/hec2hrp.cpp +++ b/src/mame/machine/hec2hrp.cpp @@ -805,8 +805,7 @@ DISCRETE_SOUND_END MACHINE_CONFIG_START(hec2hrp_state::hector_audio) SPEAKER(config, "mono").front_center(); - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(0, "mono", 0.25) /* Sound level for cassette, as it is in mono => output channel=0*/ + WAVE(config, "wave", "cassette").add_route(0, "mono", 0.25); /* Sound level for cassette, as it is in mono => output channel=0*/ MCFG_DEVICE_ADD("sn76477", SN76477) MCFG_SN76477_NOISE_PARAMS(RES_K(47), RES_K(330), CAP_P(390)) // noise + filter diff --git a/src/mame/video/comx35.cpp b/src/mame/video/comx35.cpp index d59b84b087e..2754d80d2d5 100644 --- a/src/mame/video/comx35.cpp +++ b/src/mame/video/comx35.cpp @@ -105,8 +105,7 @@ MACHINE_CONFIG_START(comx35_state::comx35_pal_video) MCFG_CDP1869_SET_SCREEN(SCREEN_TAG) MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); MACHINE_CONFIG_END MACHINE_CONFIG_START(comx35_state::comx35_ntsc_video) @@ -125,6 +124,5 @@ MACHINE_CONFIG_START(comx35_state::comx35_ntsc_video) MCFG_CDP1869_SET_SCREEN(SCREEN_TAG) MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); MACHINE_CONFIG_END diff --git a/src/mame/video/pecom.cpp b/src/mame/video/pecom.cpp index 37bed986e47..d013bb52a52 100644 --- a/src/mame/video/pecom.cpp +++ b/src/mame/video/pecom.cpp @@ -104,6 +104,5 @@ MACHINE_CONFIG_START(pecom_state::pecom_video) MCFG_CDP1869_PAL_NTSC_CALLBACK(VCC) MCFG_CDP1869_PRD_CALLBACK(WRITELINE(*this, pecom_state, pecom_prd_w)) MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) - MCFG_SOUND_WAVE_ADD(WAVE_TAG, "cassette") - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) + WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); MACHINE_CONFIG_END |