diff options
author | Aaron Giles <aaron@aarongiles.com> | 2009-11-26 23:43:19 +0000 |
---|---|---|
committer | Aaron Giles <aaron@aarongiles.com> | 2009-11-26 23:43:19 +0000 |
commit | cdd9d7c75755992b00a51392b456b6cfcc2bdb60 (patch) | |
tree | 402d3158aa2ff8996dbf32256321595b39636caa /src/mame/drivers/superqix.c | |
parent | 1583458859bd0e9a75654063b6785269d68054dc (diff) |
Introduced a generic_pointers structure within machine that is
designed to hold generic pointers that are commonly used. For
now, only generic_nvram has moved there. Added AM_BASE_GENERIC
and AM_SIZE_GENERIC macros for initializing generic pointers
in memory maps. Also added AM_BASE_SIZE_GENERIC to set both
base and size in one step.
Moved global variables out of machine/generic and into a private
data structure hanging off of the running_machine. Added newly-
needed machine parameters to coin_counter_w, coin_lockout_w, and
coin_lockout_global_w. Also added machine parameter to
set_led_state.
Added interface functions to get the number of dispensed tickets
and to increment the count, to remove the need for direct access
to these global variables. Also added functions to get the
current count on a particular coin counter and to determine the
lockout state.
Future checkins will move the remaining generic pointers (for
paletteram, videoram, spriteram, colorram, etc.) into the new
generic_pointers structure.
Diffstat (limited to 'src/mame/drivers/superqix.c')
-rw-r--r-- | src/mame/drivers/superqix.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/mame/drivers/superqix.c b/src/mame/drivers/superqix.c index 8d8ea719b77..7bbfb992eb4 100644 --- a/src/mame/drivers/superqix.c +++ b/src/mame/drivers/superqix.c @@ -233,13 +233,13 @@ static WRITE8_HANDLER( bootleg_mcu_p1_w ) // ??? break; case 1: - coin_counter_w(0,data & 1); + coin_counter_w(space->machine, 0,data & 1); break; case 2: - coin_counter_w(1,data & 1); + coin_counter_w(space->machine, 1,data & 1); break; case 3: - coin_lockout_global_w((data & 1) ^ invert_coin_lockout); + coin_lockout_global_w(space->machine, (data & 1) ^ invert_coin_lockout); break; case 4: flip_screen_set(space->machine, data & 1); @@ -300,13 +300,13 @@ static WRITE8_HANDLER( sqixu_mcu_p2_w ) // bit 0 = unknown (clocked often) // bit 1 = coin cointer 1 - coin_counter_w(0,data & 2); + coin_counter_w(space->machine, 0,data & 2); // bit 2 = coin counter 2 - coin_counter_w(1,data & 4); + coin_counter_w(space->machine, 1,data & 4); // bit 3 = coin lockout - coin_lockout_global_w(~data & 8); + coin_lockout_global_w(space->machine, ~data & 8); // bit 4 = flip screen flip_screen_set(space->machine, data & 0x10); |