From f6ec0e05966df1514f1704fb2adcd88a69776993 Mon Sep 17 00:00:00 2001 From: jbu Date: Tue, 9 Dec 2014 18:43:46 +0100 Subject: [PATCH] Add 4 7seg digits for the outputs 6, 7, 14 and 15. The remaining 22, 23, 30 and 31 are unused (nw) --- src/mame/drivers/gts1.c | 24 ++++++++++--- src/mame/layout/gts1.lay | 75 ++++++++++++++++++++++++---------------- src/osd/sdl/input.c | 2 +- 3 files changed, 65 insertions(+), 36 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) diff --git a/src/mame/layout/gts1.lay b/src/mame/layout/gts1.lay index ac392641344..2831e227ea6 100644 --- a/src/mame/layout/gts1.lay +++ b/src/mame/layout/gts1.lay @@ -4,107 +4,122 @@ - + + + + + + - - - - - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + + + + + + + + + + + + + + + diff --git a/src/osd/sdl/input.c b/src/osd/sdl/input.c index 7881a0e7c76..d85a2bc41d0 100644 --- a/src/osd/sdl/input.c +++ b/src/osd/sdl/input.c @@ -167,7 +167,7 @@ static UINT8 input_paused; static sdl_window_info * focus_window = NULL; // input buffer - only for SDLMAME_EVENTS_IN_WORKER_THREAD -#define MAX_BUF_EVENTS (500) /* 100 not enough for SDL 1.3 */ +#define MAX_BUF_EVENTS (1000) /* 100 not enough for SDL 1.3 */ static SDL_Event event_buf[MAX_BUF_EVENTS]; static int event_buf_count;