summaryrefslogtreecommitdiffstatshomepage
path: root/src/devices/video
diff options
context:
space:
mode:
author hap <happppp@users.noreply.github.com>2020-08-21 23:33:07 +0200
committer hap <happppp@users.noreply.github.com>2020-08-21 23:33:20 +0200
commitfad6c0733128b7b48b7f7f594aee7aad18a7f317 (patch)
tree334b9208867879a1b13ce7e07c25b8671fb513b7 /src/devices/video
parentd87a23d9b6e90a8d9e6e65613b1dd7c3d97d1c47 (diff)
i8244: simplify pos strobe hold
Diffstat (limited to 'src/devices/video')
-rw-r--r--src/devices/video/i8244.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/devices/video/i8244.cpp b/src/devices/video/i8244.cpp
index 985c18affba..f2aaa56be48 100644
--- a/src/devices/video/i8244.cpp
+++ b/src/devices/video/i8244.cpp
@@ -304,13 +304,13 @@ uint8_t i8244_device::read(offs_t offset)
{
data = m_control_status;
- // position strobe status
- data |= m_vdc.s.control & 0x02;
-
// hstatus (not same as hblank), goes high at falling edge of X=0x70
int h = screen().hpos();
data |= (h >= 225 && h < m_bgate_start && get_y_beam() <= m_vblank_start) ? 1 : 0;
+ // position strobe status
+ data |= m_pos_hold ? 2 : 0;
+
m_irq_func(CLEAR_LINE);
m_control_status &= ~0xcc;
@@ -328,7 +328,7 @@ uint8_t i8244_device::read(offs_t offset)
data = m_y_latch;
m_y_hold = false;
}
- else if (m_pos_hold || !(m_vdc.s.control & 0x02))
+ else if (m_pos_hold)
data = m_y_beam_pos;
else
data = get_y_beam();
@@ -337,7 +337,7 @@ uint8_t i8244_device::read(offs_t offset)
case 0xa5:
{
- if (m_pos_hold || !(m_vdc.s.control & 0x02))
+ if (m_pos_hold)
{
data = m_x_beam_pos;
m_pos_hold = false;
@@ -347,7 +347,7 @@ uint8_t i8244_device::read(offs_t offset)
// Y is latched when reading X
m_y_hold = true;
- m_y_latch = (m_vdc.s.control & 0x02) ? get_y_beam() : m_y_beam_pos;
+ m_y_latch = get_y_beam();
break;
}