summaryrefslogtreecommitdiffstatshomepage
path: root/src/mame/drivers/gts1.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/mame/drivers/gts1.c')
-rw-r--r--src/mame/drivers/gts1.c24
1 files changed, 19 insertions, 5 deletions
diff --git a/src/mame/drivers/gts1.c b/src/mame/drivers/gts1.c
index dffe6b9b7d8..94654909856 100644
--- a/src/mame/drivers/gts1.c
+++ b/src/mame/drivers/gts1.c
@@ -246,6 +246,25 @@ WRITE8_MEMBER(gts1_state::gts1_display_w)
/* e */ _d | _e | _f | _g,
/* f */ 0
};
+ UINT8 a = ttl7448_mod[(data >> 0) & 15];
+ UINT8 b = ttl7448_mod[(data >> 4) & 15];
+ LOG(("%s: offset:%d data:%02x a:%02x b:%02x\n", __FUNCTION__, offset, data, a, b));
+ if ((offset % 8) < 7) {
+ output_set_indexed_value("digit8_", offset, a);
+ output_set_indexed_value("digit8_", offset + 16, b);
+ } else {
+ /*
+ * For the 4 7-seg displays the segment h is turned back into
+ * segments b and c to display the 7-seg "1".
+ */
+ if (a & _h)
+ a = _b | _c;
+ if (b & _h)
+ b = _b | _c;
+ output_set_indexed_value("digit7_", offset, a);
+ // FIXME: there is nothing on outputs 22, 23, 30 and 31?
+ output_set_indexed_value("digit7_", offset + 16, b);
+ }
#undef _a
#undef _b
#undef _c
@@ -254,11 +273,6 @@ WRITE8_MEMBER(gts1_state::gts1_display_w)
#undef _f
#undef _g
#undef _h
- LOG(("%s: offset:%d data:%02x\n", __FUNCTION__, offset, data));
- const UINT8 a = ttl7448_mod[(data >> 0) & 15];
- const UINT8 b = ttl7448_mod[(data >> 4) & 15];
- output_set_digit_value(offset, a);
- output_set_digit_value(offset + 16, b);
}
READ8_MEMBER (gts1_state::gts1_io_r)