Add 4 7seg digits for the outputs 6, 7, 14 and 15. The remaining 22, 23, 30 and 31 are unused (nw)

This commit is contained in:
jbu 2014-12-09 18:43:46 +01:00
parent 546354341a
commit f6ec0e0596
3 changed files with 65 additions and 36 deletions

View File

@ -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)

View File

@ -4,107 +4,122 @@
<mamelayout version="2">
<element name="digit" defstate="0">
<element name="digit8_" defstate="0">
<led8seg>
<color red="0.0" green="0.75" blue="1.0" />
</led8seg>
</element>
<element name="digit7_" defstate="0">
<led7seg>
<color red="0.0" green="0.75" blue="1.0" />
</led7seg>
</element>
<element name="background">
<rect>
<bounds left="0" top="0" right="1" bottom="1" />
<color red="0.0" green="0.0" blue="0.0" />
</rect>
</element>
<element name="P3"><text string="Player 1"><color red="1.0" green="1.0" blue="1.0" /></text></element>
<element name="P4"><text string="Player 2"><color red="1.0" green="1.0" blue="1.0" /></text></element>
<element name="P5"><text string="Player 3"><color red="1.0" green="1.0" blue="1.0" /></text></element>
<element name="P6"><text string="Player 4"><color red="1.0" green="1.0" blue="1.0" /></text></element>
<view name="Default Layout">
<!-- Background -->
<backdrop element="background">
<bounds left="0" top="25" right="325" bottom="179" />
<bounds left="0" top="25" right="325" bottom="205" />
</backdrop>
<!-- Top Row -->
<bezel name="digit0" element="digit">
<bezel name="digit8_0" element="digit8_">
<bounds left="10" top="45" right="30" bottom="84" />
</bezel>
<bezel name="digit1" element="digit">
<bezel name="digit8_1" element="digit8_">
<bounds left="34" top="45" right="54" bottom="84" />
</bezel>
<bezel name="digit2" element="digit">
<bezel name="digit8_2" element="digit8_">
<bounds left="58" top="45" right="78" bottom="84" />
</bezel>
<bezel name="digit3" element="digit">
<bezel name="digit8_3" element="digit8_">
<bounds left="87" top="45" right="107" bottom="84" />
</bezel>
<bezel name="digit4" element="digit">
<bezel name="digit8_4" element="digit8_">
<bounds left="111" top="45" right="131" bottom="84" />
</bezel>
<bezel name="digit5" element="digit">
<bezel name="digit8_5" element="digit8_">
<bounds left="135" top="45" right="155" bottom="84" />
</bezel>
<!-- Digits 6 and 7 are not used -->
<bezel name="digit8" element="digit">
<bezel name="digit8_8" element="digit8_">
<bounds left="170" top="45" right="190" bottom="84" />
</bezel>
<bezel name="digit9" element="digit">
<bezel name="digit8_9" element="digit8_">
<bounds left="194" top="45" right="214" bottom="84" />
</bezel>
<bezel name="digit10" element="digit">
<bezel name="digit8_10" element="digit8_">
<bounds left="218" top="45" right="238" bottom="84" />
</bezel>
<bezel name="digit11" element="digit">
<bezel name="digit8_11" element="digit8_">
<bounds left="247" top="45" right="267" bottom="84" />
</bezel>
<bezel name="digit12" element="digit">
<bezel name="digit8_12" element="digit8_">
<bounds left="271" top="45" right="291" bottom="84" />
</bezel>
<bezel name="digit13" element="digit">
<bezel name="digit8_13" element="digit8_">
<bounds left="295" top="45" right="315" bottom="84" />
</bezel>
<!-- Digits 14 and 15 are not used -->
<!-- Bottom Row -->
<bezel name="digit16" element="digit">
<bezel name="digit8_16" element="digit8_">
<bounds left="10" top="100" right="30" bottom="139" />
</bezel>
<bezel name="digit17" element="digit">
<bezel name="digit8_17" element="digit8_">
<bounds left="34" top="100" right="54" bottom="139" />
</bezel>
<bezel name="digit18" element="digit">
<bezel name="digit8_18" element="digit8_">
<bounds left="58" top="100" right="78" bottom="139" />
</bezel>
<bezel name="digit19" element="digit">
<bezel name="digit8_19" element="digit8_">
<bounds left="87" top="100" right="107" bottom="139" />
</bezel>
<bezel name="digit20" element="digit">
<bezel name="digit8_20" element="digit8_">
<bounds left="111" top="100" right="131" bottom="139" />
</bezel>
<bezel name="digit21" element="digit">
<bezel name="digit8_21" element="digit8_">
<bounds left="135" top="100" right="155" bottom="139" />
</bezel>
<!-- Digits 22 and 23 are not used -->
<bezel name="digit24" element="digit">
<bezel name="digit8_24" element="digit8_">
<bounds left="170" top="100" right="190" bottom="139" />
</bezel>
<bezel name="digit25" element="digit">
<bezel name="digit8_25" element="digit8_">
<bounds left="194" top="100" right="214" bottom="139" />
</bezel>
<bezel name="digit26" element="digit">
<bezel name="digit8_26" element="digit8_">
<bounds left="218" top="100" right="238" bottom="139" />
</bezel>
<bezel name="digit27" element="digit">
<bezel name="digit8_27" element="digit8_">
<bounds left="247" top="100" right="267" bottom="139" />
</bezel>
<bezel name="digit28" element="digit">
<bezel name="digit8_28" element="digit8_">
<bounds left="271" top="100" right="291" bottom="139" />
</bezel>
<bezel name="digit29" element="digit">
<bezel name="digit8_29" element="digit8_">
<bounds left="295" top="100" right="315" bottom="139" />
</bezel>
<!-- Digits 30 and 31 are not used -->
<!-- 4 digit display -->
<bezel name="digit7_6" element="digit7_">
<bounds left="111" top="155" right="131" bottom="194" />
</bezel>
<bezel name="digit7_7" element="digit7_">
<bounds left="135" top="155" right="155" bottom="194" />
</bezel>
<bezel name="digit7_14" element="digit7_">
<bounds left="170" top="155" right="190" bottom="194" />
</bezel>
<bezel name="digit7_15" element="digit7_">
<bounds left="194" top="155" right="214" bottom="194" />
</bezel>
</view>
</mamelayout>

View File

@ -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;