diff options
Diffstat (limited to 'src/emu/sound/es8712.c')
-rw-r--r-- | src/emu/sound/es8712.c | 51 |
1 files changed, 49 insertions, 2 deletions
diff --git a/src/emu/sound/es8712.c b/src/emu/sound/es8712.c index 8cae3700798..191621756bf 100644 --- a/src/emu/sound/es8712.c +++ b/src/emu/sound/es8712.c @@ -51,7 +51,7 @@ INLINE es8712_state *get_safe_token(device_t *device) { assert(device != NULL); assert(device->type() == ES8712); - return (es8712_state *)downcast<legacy_device_base *>(device)->token(); + return (es8712_state *)downcast<es8712_device *>(device)->token(); } @@ -407,4 +407,51 @@ DEVICE_GET_INFO( es8712 ) } -DEFINE_LEGACY_SOUND_DEVICE(ES8712, es8712); +const device_type ES8712 = &device_creator<es8712_device>; + +es8712_device::es8712_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock) + : device_t(mconfig, ES8712, "ES8712", tag, owner, clock), + device_sound_interface(mconfig, *this) +{ + m_token = global_alloc_array_clear(UINT8, sizeof(es8712_state)); +} + +//------------------------------------------------- +// device_config_complete - perform any +// operations now that the configuration is +// complete +//------------------------------------------------- + +void es8712_device::device_config_complete() +{ +} + +//------------------------------------------------- +// device_start - device-specific startup +//------------------------------------------------- + +void es8712_device::device_start() +{ + DEVICE_START_NAME( es8712 )(this); +} + +//------------------------------------------------- +// device_reset - device-specific reset +//------------------------------------------------- + +void es8712_device::device_reset() +{ + DEVICE_RESET_NAME( es8712 )(this); +} + +//------------------------------------------------- +// sound_stream_update - handle a stream update +//------------------------------------------------- + +void es8712_device::sound_stream_update(sound_stream &stream, stream_sample_t **inputs, stream_sample_t **outputs, int samples) +{ + // should never get here + fatalerror("sound_stream_update called; not applicable to legacy sound devices\n"); +} + + |