summaryrefslogtreecommitdiffstatshomepage
path: root/src/devices/video
diff options
context:
space:
mode:
author hap <happppp@users.noreply.github.com>2020-08-13 20:52:25 +0200
committer hap <happppp@users.noreply.github.com>2020-08-13 20:52:25 +0200
commite098721575b963c8beaef6f43e6293ca94b9e1f5 (patch)
treef798831ac031e381eac07fcf23d0d89eaf95f39b /src/devices/video
parente56c517e3b861ef624045c3007549660381c99be (diff)
ef9340: add keyboard cursor
Diffstat (limited to 'src/devices/video')
-rw-r--r--src/devices/video/ef9340_1.cpp6
-rw-r--r--src/devices/video/ef9340_1.h2
2 files changed, 7 insertions, 1 deletions
diff --git a/src/devices/video/ef9340_1.cpp b/src/devices/video/ef9340_1.cpp
index 1083b160f68..d36ae8a7cc1 100644
--- a/src/devices/video/ef9340_1.cpp
+++ b/src/devices/video/ef9340_1.cpp
@@ -343,7 +343,7 @@ void ef9340_1_device::ef9340_scanline(int vpos)
}
else
{
- // Alphannumeric
+ // Alphanumeric
if ( b & 0x80 )
{
if ( b & 0x60 )
@@ -372,6 +372,10 @@ void ef9340_1_device::ef9340_scanline(int vpos)
}
}
+ // Cursor is enabled
+ if ( m_ef9340.R & 0x10 && x == m_ef9340.X && y_row == m_ef9340.Y )
+ char_data ^= 0xff;
+
for ( int i = 0; i < 8; i++ )
{
m_tmp_bitmap.pix16(vpos, 0 + x*8 + i ) = (char_data & 0x80) ? fg : bg;
diff --git a/src/devices/video/ef9340_1.h b/src/devices/video/ef9340_1.h
index 52f0278a36f..42295d131d4 100644
--- a/src/devices/video/ef9340_1.h
+++ b/src/devices/video/ef9340_1.h
@@ -62,6 +62,7 @@ protected:
uint8_t TB;
uint8_t busy;
} m_ef9341;
+
struct
{
uint8_t X;
@@ -71,6 +72,7 @@ protected:
uint8_t M;
int max_vpos;
} m_ef9340;
+
uint8_t m_ef934x_ram_a[1024];
uint8_t m_ef934x_ram_b[1024];
uint8_t m_ef934x_ext_char_ram[2048]; /* The G7400 has 2KB of external ram hooked up. The datasheet only describes how to hookup 1KB. */