diff options
author | 2019-10-20 12:16:00 +1100 | |
---|---|---|
committer | 2019-10-20 12:16:00 +1100 | |
commit | 57802cdd7f843f635a1a068a70d16218d3a440eb (patch) | |
tree | 5c483650a64d7e59a8cee21e54e81d2572d84b50 /src/devices/cpu/upd7810/upd7810.cpp | |
parent | 24e839d947a5be7dee6a35209542d8c02697f380 (diff) |
(nw) upd7801: reworked following unfavourable comments
- reverted all of last commit
- fixing the bug a different way
Diffstat (limited to 'src/devices/cpu/upd7810/upd7810.cpp')
-rw-r--r-- | src/devices/cpu/upd7810/upd7810.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/devices/cpu/upd7810/upd7810.cpp b/src/devices/cpu/upd7810/upd7810.cpp index e88b33d91aa..99e0f5a9980 100644 --- a/src/devices/cpu/upd7810/upd7810.cpp +++ b/src/devices/cpu/upd7810/upd7810.cpp @@ -1889,6 +1889,7 @@ void upd7801_device::device_reset() upd7810_device::device_reset(); MA = 0; /* Port A is output port on the uPD7801 */ m_ovc0 = 0; + m_int2 = 0; } void upd78c05_device::device_reset() @@ -2005,19 +2006,19 @@ void upd7801_device::execute_set_input(int irqline, int state) /* Check if the ES bit is set then check for rising edge, otherwise falling edge */ if ( MKL & 0x20 ) { - if ( m_int2 != CLEAR_LINE && state == ASSERT_LINE ) + if ( m_int2 == CLEAR_LINE && state == ASSERT_LINE ) { IRR |= INTF2; } } else { - if ( m_int2 != ASSERT_LINE && state == CLEAR_LINE ) + if ( m_int2 == ASSERT_LINE && state == CLEAR_LINE ) { IRR |= INTF2; } } - m_int2 = !state; + m_int2 = state; break; } } |