mirror of
https://github.com/holub/mame
synced 2025-07-06 18:39:28 +03:00
pokey.cpp: remove m_SKCTL assignment hack in device_start and issue a potgo at device_reset instead (#10462)
- fixes a1200xl booting to self-test no matter J1 setting
This commit is contained in:
parent
8d20e0cbc6
commit
026f8c97d9
@ -257,11 +257,10 @@ void pokey_device::device_start()
|
|||||||
m_KBCODE = 0x09; // Atari 800 'no key'
|
m_KBCODE = 0x09; // Atari 800 'no key'
|
||||||
m_SKCTL = 0;
|
m_SKCTL = 0;
|
||||||
|
|
||||||
// TODO, remove this line:
|
// TODO: several a7800 demos don't explicitly reset pokey at startup
|
||||||
m_SKCTL = SK_RESET;
|
|
||||||
// It's left in place to accomodate demos that don't explicitly reset pokey.
|
|
||||||
// See https://atariage.com/forums/topic/337317-a7800-52-release/ and
|
// See https://atariage.com/forums/topic/337317-a7800-52-release/ and
|
||||||
// https://atariage.com/forums/topic/268458-a7800-the-atari-7800-emulator/?do=findComment&comment=5079170)
|
// https://atariage.com/forums/topic/268458-a7800-the-atari-7800-emulator/?do=findComment&comment=5079170)
|
||||||
|
// m_SKCTL = SK_RESET;
|
||||||
|
|
||||||
m_SKSTAT = 0;
|
m_SKSTAT = 0;
|
||||||
/* This bit should probably get set later. Acid5200 pokey_setoc test tests this. */
|
/* This bit should probably get set later. Acid5200 pokey_setoc test tests this. */
|
||||||
@ -357,6 +356,10 @@ void pokey_device::device_start()
|
|||||||
void pokey_device::device_reset()
|
void pokey_device::device_reset()
|
||||||
{
|
{
|
||||||
m_stream->update();
|
m_stream->update();
|
||||||
|
// a1200xl reads POT4 twice at startup for reading self-test mode jumpers.
|
||||||
|
// we need to update POT counters here otherwise it will boot to self-test
|
||||||
|
// the first time around no matter the setting.
|
||||||
|
pokey_potgo();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -979,7 +982,8 @@ void pokey_device::write_internal(offs_t offset, uint8_t data)
|
|||||||
|
|
||||||
case POTGO_C:
|
case POTGO_C:
|
||||||
LOG("%s: POKEY POTGO $%02x\n", machine().describe_context(), data);
|
LOG("%s: POKEY POTGO $%02x\n", machine().describe_context(), data);
|
||||||
pokey_potgo();
|
if (m_SKCTL & SK_RESET)
|
||||||
|
pokey_potgo();
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case SEROUT_C:
|
case SEROUT_C:
|
||||||
@ -1104,9 +1108,6 @@ inline void pokey_device::process_channel(int ch)
|
|||||||
|
|
||||||
void pokey_device::pokey_potgo()
|
void pokey_device::pokey_potgo()
|
||||||
{
|
{
|
||||||
if (!(m_SKCTL & SK_RESET))
|
|
||||||
return;
|
|
||||||
|
|
||||||
LOG("pokey_potgo\n");
|
LOG("pokey_potgo\n");
|
||||||
|
|
||||||
m_ALLPOT = 0x00;
|
m_ALLPOT = 0x00;
|
||||||
|
Loading…
Reference in New Issue
Block a user