Previous 15994 Revisions Next

r15240 Sunday 20th May, 2012 at 09:44:31 UTC by Miodrag Milanović
removed legacy function usage for pokey device in mess drivers (no whatsnew)
[src/emu/sound]pokey.h
[src/mess/machine]a7800.c atarifdc.c

src/emu/sound/pokey.h
r15239r15240
2424/* uncomment the line below for MESS to avoid breaking compile
2525 * please migrate as soon as possible to new device so that we can get rid of the legacy */
2626
27#define OLDDEVICE_FOR_MESS 1
27//#define OLDDEVICE_FOR_MESS 1
2828
2929//#define POKEY_EXEC_INTERFACE
3030
src/mess/machine/a7800.c
r15239r15240
124124   /* pokey cartridge */
125125   if (state->m_cart_type & 0x01)
126126   {
127      device_t *pokey = machine.device("pokey");
128      space->install_legacy_read_handler(*pokey, 0x4000, 0x7FFF, FUNC(pokey_r));
129      space->install_legacy_write_handler(*pokey, 0x4000, 0x7FFF, FUNC(pokey_w));
127      pokeyn_device *pokey = machine.device<pokeyn_device>("pokey");
128      space->install_readwrite_handler(0x4000, 0x7FFF, read8_delegate(FUNC(pokeyn_device::read),pokey), write8_delegate(FUNC(pokeyn_device::write),pokey));
130129   }
131130}
132131
r15239r15240
412411      }
413412      else if(m_cart_type & 0x01)
414413      {
415         device_t *pokey = machine().device("pokey");
416         pokey_w(pokey, offset, data);
414         pokeyn_device *pokey = machine().device<pokeyn_device>("pokey");
415         pokey->write(space, offset, data);
417416      }
418417      else
419418      {
src/mess/machine/atarifdc.c
r15239r15240
421421static void clr_serin(device_t *device, int ser_delay)
422422{
423423   atari_fdc_t *fdc = get_safe_token(device);
424   device_t *pokey = device->machine().device("pokey");
424   pokeyn_device *pokey = device->machine().device<pokeyn_device>("pokey");
425425   fdc->serin_chksum = 0;
426426   fdc->serin_offs = 0;
427427   fdc->serin_count = 0;
428   pokey_serin_ready(pokey, ser_delay * 40);
428   pokey->serin_ready(ser_delay * 40);
429429}
430430
431431static void add_serin(device_t *device,UINT8 data, int with_checksum)
r15239r15240
706706
707707   if (fdc->serin_count)
708708   {
709      device_t *pokey = device->machine().device("pokey");
709      pokeyn_device *pokey = device->machine().device<pokeyn_device>("pokey");
710710
711711      data = fdc->serin_buff[fdc->serin_offs];
712712      ser_delay = 2 * 40;
r15239r15240
720720      if (--fdc->serin_count == 0)
721721         fdc->serin_offs = 0;
722722      else
723         pokey_serin_ready(pokey, ser_delay);
723         pokey->serin_ready(ser_delay);
724724   }
725725
726726   if (VERBOSE_SERIAL)

Previous 15994 Revisions Next


© 1998-2018 The MESS Team