diff options
author | Angelo Salese <angelosa@users.noreply.github.com> | 2013-09-09 23:56:45 +0000 |
---|---|---|
committer | Angelo Salese <angelosa@users.noreply.github.com> | 2013-09-09 23:56:45 +0000 |
commit | 61b0af210398f0ade8d2f951b5b1d4ea2f9616bc (patch) | |
tree | 7de380eb29f51a8d9cd432e527b1c27bc18eec30 /src/mame/machine/dc.c | |
parent | 700f3be2db2c2a05d7cca224cf916395a9d2c54e (diff) |
Fixed ARMRST behaviour
Diffstat (limited to 'src/mame/machine/dc.c')
-rw-r--r-- | src/mame/machine/dc.c | 25 |
1 files changed, 17 insertions, 8 deletions
diff --git a/src/mame/machine/dc.c b/src/mame/machine/dc.c index 209a2a2ff9a..7314eaf7ff4 100644 --- a/src/mame/machine/dc.c +++ b/src/mame/machine/dc.c @@ -666,6 +666,7 @@ void dc_state::machine_start() void dc_state::machine_reset() { /* halt the ARM7 */ + m_armrst = 1; m_soundcpu->set_input_line(INPUT_LINE_RESET, ASSERT_LINE); memset(dc_sysctrl_regs, 0, sizeof(dc_sysctrl_regs)); @@ -677,6 +678,9 @@ READ32_MEMBER(dc_state::dc_aica_reg_r) { // mame_printf_verbose("AICA REG: [%08x] read %" I64FMT "x, mask %" I64FMT "x\n", 0x700000+reg*4, (UINT64)offset, mem_mask); + if(offset == 0x2c00/4) + return m_armrst; + return aica_r(machine().device("aica"), space, offset*2, 0xffff); } @@ -684,15 +688,20 @@ WRITE32_MEMBER(dc_state::dc_aica_reg_w) { if (offset == (0x2c00/4)) { - if (data & 1) - { - /* halt the ARM7 */ - m_soundcpu->set_input_line(INPUT_LINE_RESET, ASSERT_LINE); - } - else + if(ACCESSING_BITS_0_7) { - /* it's alive ! */ - m_soundcpu->set_input_line(INPUT_LINE_RESET, CLEAR_LINE); + m_armrst = data & 1; + + if (data & 1) + { + /* halt the ARM7 */ + m_soundcpu->set_input_line(INPUT_LINE_RESET, ASSERT_LINE); + } + else + { + /* it's alive ! */ + m_soundcpu->set_input_line(INPUT_LINE_RESET, CLEAR_LINE); + } } } |