summaryrefslogtreecommitdiffstatshomepage
path: root/src/mame/drivers/stadhero.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/mame/drivers/stadhero.c')
-rw-r--r--src/mame/drivers/stadhero.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/src/mame/drivers/stadhero.c b/src/mame/drivers/stadhero.c
index 703d0295866..aec2e9e541f 100644
--- a/src/mame/drivers/stadhero.c
+++ b/src/mame/drivers/stadhero.c
@@ -20,25 +20,25 @@
/******************************************************************************/
-static READ16_HANDLER( stadhero_control_r )
+READ16_MEMBER(stadhero_state::stadhero_control_r)
{
switch (offset<<1)
{
case 0:
- return input_port_read(space->machine(), "INPUTS");
+ return input_port_read(machine(), "INPUTS");
case 2:
- return input_port_read(space->machine(), "COIN");
+ return input_port_read(machine(), "COIN");
case 4:
- return input_port_read(space->machine(), "DSW");
+ return input_port_read(machine(), "DSW");
}
- logerror("CPU #0 PC %06x: warning - read unmapped memory address %06x\n",cpu_get_pc(&space->device()),0x30c000+offset);
+ logerror("CPU #0 PC %06x: warning - read unmapped memory address %06x\n",cpu_get_pc(&space.device()),0x30c000+offset);
return ~0;
}
-static WRITE16_HANDLER( stadhero_control_w )
+WRITE16_MEMBER(stadhero_state::stadhero_control_w)
{
switch (offset<<1)
{
@@ -46,10 +46,10 @@ static WRITE16_HANDLER( stadhero_control_w )
break;
case 6: /* 6502 sound cpu */
soundlatch_w(space, 0, data & 0xff);
- cputag_set_input_line(space->machine(), "audiocpu", INPUT_LINE_NMI, PULSE_LINE);
+ cputag_set_input_line(machine(), "audiocpu", INPUT_LINE_NMI, PULSE_LINE);
break;
default:
- logerror("CPU #0 PC %06x: warning - write %02x to unmapped memory address %06x\n",cpu_get_pc(&space->device()),data,0x30c010+offset);
+ logerror("CPU #0 PC %06x: warning - write %02x to unmapped memory address %06x\n",cpu_get_pc(&space.device()),data,0x30c010+offset);
break;
}
}
@@ -63,7 +63,7 @@ static ADDRESS_MAP_START( main_map, AS_PROGRAM, 16, stadhero_state )
AM_RANGE(0x240000, 0x240007) AM_DEVWRITE_LEGACY("tilegen1", deco_bac06_pf_control_0_w) /* text layer */
AM_RANGE(0x240010, 0x240017) AM_DEVWRITE_LEGACY("tilegen1", deco_bac06_pf_control_1_w)
AM_RANGE(0x260000, 0x261fff) AM_DEVREADWRITE_LEGACY("tilegen1", deco_bac06_pf_data_r, deco_bac06_pf_data_w)
- AM_RANGE(0x30c000, 0x30c00b) AM_READWRITE_LEGACY(stadhero_control_r, stadhero_control_w)
+ AM_RANGE(0x30c000, 0x30c00b) AM_READWRITE(stadhero_control_r, stadhero_control_w)
AM_RANGE(0x310000, 0x3107ff) AM_RAM_WRITE_LEGACY(paletteram16_xxxxBBBBGGGGRRRR_word_w) AM_BASE_GENERIC(paletteram)
AM_RANGE(0xff8000, 0xffbfff) AM_RAM /* Main ram */
AM_RANGE(0xffc000, 0xffc7ff) AM_MIRROR(0x000800) AM_RAM AM_BASE(m_spriteram)