summaryrefslogtreecommitdiffstatshomepage
path: root/src/mame/drivers/model2.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/mame/drivers/model2.c')
-rw-r--r--src/mame/drivers/model2.c48
1 files changed, 24 insertions, 24 deletions
diff --git a/src/mame/drivers/model2.c b/src/mame/drivers/model2.c
index d8d8ce491e7..bc0beecd6e0 100644
--- a/src/mame/drivers/model2.c
+++ b/src/mame/drivers/model2.c
@@ -433,7 +433,7 @@ static WRITE32_HANDLER(ctrl0_w)
static READ32_HANDLER(ctrl0_r)
{
- UINT32 ret = input_port_read_indexed(machine, 0);
+ UINT32 ret = input_port_read(machine, "IN0");
ret <<= 16;
if(model2_ctrlmode==0)
{
@@ -447,25 +447,25 @@ static READ32_HANDLER(ctrl0_r)
}
static READ32_HANDLER(ctrl1_r)
{
- return input_port_read_indexed(machine, 1) | input_port_read_indexed(machine, 2)<<16;
+ return input_port_read(machine, "IN1") | input_port_read(machine, "IN2")<<16;
}
static READ32_HANDLER(ctrl10_r)
{
- return input_port_read_indexed(machine, 0) | input_port_read_indexed(machine, 1)<<16;
+ return input_port_read(machine, "IN0") | input_port_read(machine, "IN1")<<16;
}
static READ32_HANDLER(ctrl14_r)
{
- return input_port_read_indexed(machine, 2);
+ return input_port_read(machine, "IN2");
}
static READ32_HANDLER(analog_r)
{
if (offset)
- return input_port_read_indexed(machine, 5);
+ return input_port_read_safe(machine, "BRAKE", 0);
- return input_port_read_indexed(machine, 3) | input_port_read_indexed(machine, 4)<<16;
+ return input_port_read_safe(machine, "STEER", 0) | input_port_read_safe(machine, "ACCEL", 0)<<16;
}
static READ32_HANDLER(fifoctl_r)
@@ -1422,7 +1422,7 @@ ADDRESS_MAP_END
PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT ) PORT_PLAYER(_n_)
static INPUT_PORTS_START( model2 )
- PORT_START
+ PORT_START_TAG("IN0")
PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_COIN1 )
PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_COIN2 )
PORT_SERVICE_NO_TOGGLE( 0x04, IP_ACTIVE_LOW )
@@ -1432,15 +1432,15 @@ static INPUT_PORTS_START( model2 )
PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_SERVICE ) PORT_NAME("1P Push Switch") PORT_CODE(KEYCODE_7)
PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_SERVICE ) PORT_NAME("2P Push Switch") PORT_CODE(KEYCODE_8)
- PORT_START
+ PORT_START_TAG("IN1")
MODEL2_PLAYER_INPUTS(1, BUTTON1, BUTTON2, BUTTON3, BUTTON4)
- PORT_START
+ PORT_START_TAG("IN2")
MODEL2_PLAYER_INPUTS(2, BUTTON1, BUTTON2, BUTTON3, BUTTON4)
INPUT_PORTS_END
static INPUT_PORTS_START( desert )
- PORT_START
+ PORT_START_TAG("IN0")
PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_COIN1 )
PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_COIN2 )
PORT_SERVICE_NO_TOGGLE( 0x04, IP_ACTIVE_LOW )
@@ -1450,28 +1450,28 @@ static INPUT_PORTS_START( desert )
PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_BUTTON5 ) PORT_PLAYER(1) // VR 2 (Green)
PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_BUTTON6 ) PORT_PLAYER(1) // VR 3 (Red)
- PORT_START
+ PORT_START_TAG("IN1")
PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_BUTTON3 ) PORT_PLAYER(1) // shift
PORT_BIT( 0x0e, IP_ACTIVE_LOW, IPT_UNUSED )
PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_BUTTON1 ) PORT_PLAYER(1) // machine gun
PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_BUTTON2 ) PORT_PLAYER(1) // cannon
PORT_BIT( 0xc0, IP_ACTIVE_LOW, IPT_UNUSED )
- PORT_START
+ PORT_START_TAG("IN2")
MODEL2_PLAYER_INPUTS(2, BUTTON1, BUTTON2, BUTTON3, BUTTON4)
- PORT_START // steer
+ PORT_START_TAG("STEER") // steer
PORT_BIT( 0xff, 0x80, IPT_PADDLE ) PORT_SENSITIVITY(30) PORT_KEYDELTA(10) PORT_PLAYER(1)
- PORT_START // accel
+ PORT_START_TAG("ACCEL") // accel
PORT_BIT( 0xff, 0x00, IPT_PEDAL ) PORT_SENSITIVITY(30) PORT_KEYDELTA(10) PORT_PLAYER(1)
- PORT_START // brake
+ PORT_START_TAG("BRAKE") // brake
PORT_BIT( 0xff, 0x00, IPT_PEDAL2 ) PORT_SENSITIVITY(30) PORT_KEYDELTA(10) PORT_PLAYER(1)
INPUT_PORTS_END
static INPUT_PORTS_START( daytona )
- PORT_START
+ PORT_START_TAG("IN0")
PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_COIN1 )
PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_COIN2 )
PORT_SERVICE_NO_TOGGLE( 0x04, IP_ACTIVE_LOW )
@@ -1481,7 +1481,7 @@ static INPUT_PORTS_START( daytona )
PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_BUTTON5 ) PORT_PLAYER(1) // VR 2 (Blue)
PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_BUTTON6 ) PORT_PLAYER(1) // VR 3 (Yellow)
- PORT_START
+ PORT_START_TAG("IN1")
PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_BUTTON7 ) PORT_PLAYER(1) // VR 4 (Green)
PORT_BIT(0x0e, IP_ACTIVE_LOW, IPT_UNUSED )
PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_BUTTON1 ) PORT_PLAYER(1) // shift 3
@@ -1489,21 +1489,21 @@ static INPUT_PORTS_START( daytona )
PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT ) PORT_PLAYER(1)
PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT ) PORT_PLAYER(1)
- PORT_START
+ PORT_START_TAG("IN2")
MODEL2_PLAYER_INPUTS(2, BUTTON1, BUTTON2, BUTTON3, BUTTON4)
- PORT_START // steer
+ PORT_START_TAG("STEER") // steer
PORT_BIT( 0xff, 0x80, IPT_PADDLE ) PORT_SENSITIVITY(30) PORT_KEYDELTA(10) PORT_PLAYER(1)
- PORT_START // accel
+ PORT_START_TAG("ACCEL") // accel
PORT_BIT( 0xff, 0x00, IPT_PEDAL ) PORT_SENSITIVITY(30) PORT_KEYDELTA(10) PORT_PLAYER(1)
- PORT_START // brake
+ PORT_START_TAG("BREAK") // brake
PORT_BIT( 0xff, 0x00, IPT_PEDAL2 ) PORT_SENSITIVITY(30) PORT_KEYDELTA(10) PORT_PLAYER(1)
INPUT_PORTS_END
static INPUT_PORTS_START( bel )
- PORT_START
+ PORT_START_TAG("IN0")
PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_COIN1 )
PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_COIN2 )
PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_SERVICE1 )
@@ -1513,10 +1513,10 @@ static INPUT_PORTS_START( bel )
PORT_BIT(0x40, IP_ACTIVE_LOW, IPT_SERVICE ) PORT_NAME("1P Push Switch") PORT_CODE(KEYCODE_7)
PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_SERVICE ) PORT_NAME("2P Push Switch") PORT_CODE(KEYCODE_8)
- PORT_START
+ PORT_START_TAG("IN1")
MODEL2_PLAYER_INPUTS(1, BUTTON1, BUTTON2, BUTTON3, BUTTON4)
- PORT_START
+ PORT_START_TAG("IN2")
MODEL2_PLAYER_INPUTS(2, BUTTON1, BUTTON2, BUTTON3, BUTTON4)
INPUT_PORTS_END