diff options
author | 2014-01-04 02:52:16 +0000 | |
---|---|---|
committer | 2014-01-04 02:52:16 +0000 | |
commit | 1c5f0dfe04c09654823ce0f96b8f8f4642f0b399 (patch) | |
tree | 7d28b90ece7741231d56109323796232357a9939 | |
parent | 2f47171686d1dbccce8045266a10d49606057ef6 (diff) |
fixed protovision adapter (nw)
-rw-r--r-- | src/emu/bus/vic20/4cga.c | 10 | ||||
-rw-r--r-- | src/emu/bus/vic20/4cga.h | 4 |
2 files changed, 5 insertions, 9 deletions
diff --git a/src/emu/bus/vic20/4cga.c b/src/emu/bus/vic20/4cga.c index caec55ec63a..91d1f1e3b7b 100644 --- a/src/emu/bus/vic20/4cga.c +++ b/src/emu/bus/vic20/4cga.c @@ -29,7 +29,7 @@ static INPUT_PORTS_START( c64_4player ) PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_JOYSTICK_DOWN ) PORT_8WAY PORT_PLAYER(1) PORT_WRITE_LINE_DEVICE_MEMBER(DEVICE_SELF, c64_4cga_device, write_joy3_1) PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT ) PORT_8WAY PORT_PLAYER(1) PORT_WRITE_LINE_DEVICE_MEMBER(DEVICE_SELF, c64_4cga_device, write_joy3_2) PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT ) PORT_8WAY PORT_PLAYER(1) PORT_WRITE_LINE_DEVICE_MEMBER(DEVICE_SELF, c64_4cga_device, write_joy3_3) - PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_BUTTON1 ) PORT_PLAYER(1) PORT_WRITE_LINE_DEVICE_MEMBER(DEVICE_SELF, c64_4cga_device, write_joy3_4) + PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_BUTTON1 ) PORT_PLAYER(1) PORT_WRITE_LINE_DEVICE_MEMBER(DEVICE_SELF, device_vic20_user_port_interface, output_h) PORT_BIT( 0xe0, IP_ACTIVE_LOW, IPT_UNUSED ) PORT_START("JOY4") @@ -37,7 +37,7 @@ static INPUT_PORTS_START( c64_4player ) PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_JOYSTICK_DOWN ) PORT_8WAY PORT_PLAYER(2) PORT_WRITE_LINE_DEVICE_MEMBER(DEVICE_SELF, c64_4cga_device, write_joy4_1) PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT ) PORT_8WAY PORT_PLAYER(2) PORT_WRITE_LINE_DEVICE_MEMBER(DEVICE_SELF, c64_4cga_device, write_joy4_2) PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT ) PORT_8WAY PORT_PLAYER(2) PORT_WRITE_LINE_DEVICE_MEMBER(DEVICE_SELF, c64_4cga_device, write_joy4_3) - PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_BUTTON1 ) PORT_PLAYER(2) PORT_WRITE_LINE_DEVICE_MEMBER(DEVICE_SELF, c64_4cga_device, write_joy4_4) + PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_BUTTON1 ) PORT_PLAYER(2) PORT_WRITE_LINE_DEVICE_MEMBER(DEVICE_SELF, device_vic20_user_port_interface, output_j) PORT_BIT( 0xe0, IP_ACTIVE_LOW, IPT_UNUSED ) INPUT_PORTS_END @@ -64,7 +64,9 @@ ioport_constructor c64_4cga_device::device_input_ports() const c64_4cga_device::c64_4cga_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock) : device_t(mconfig, C64_4CGA, "C64 Protovision 4 Player Interface", tag, owner, clock, "c64_4cga", __FILE__), device_vic20_user_port_interface(mconfig, *this), - m_port(0) + m_port(0), + m_joy3(0xf), + m_joy4(0xf) { } @@ -100,8 +102,6 @@ void c64_4cga_device::update_output() output_d((data>>1)&1); output_e((data>>2)&1); output_f((data>>3)&1); - output_h((data>>4)&1); - output_j((data>>5)&1); } diff --git a/src/emu/bus/vic20/4cga.h b/src/emu/bus/vic20/4cga.h index 9d2478fc39a..e2a128fbd50 100644 --- a/src/emu/bus/vic20/4cga.h +++ b/src/emu/bus/vic20/4cga.h @@ -40,15 +40,11 @@ public: DECLARE_WRITE_LINE_MEMBER(write_joy3_1) { if (state) m_joy3 |= 2; else m_joy3 &= ~2; update_output(); } DECLARE_WRITE_LINE_MEMBER(write_joy3_2) { if (state) m_joy3 |= 4; else m_joy3 &= ~4; update_output(); } DECLARE_WRITE_LINE_MEMBER(write_joy3_3) { if (state) m_joy3 |= 8; else m_joy3 &= ~8; update_output(); } - DECLARE_WRITE_LINE_MEMBER(write_joy3_4) { if (state) m_joy3 |= 16; else m_joy3 &= ~16; update_output(); } - DECLARE_WRITE_LINE_MEMBER(write_joy3_5) { if (state) m_joy3 |= 32; else m_joy3 &= ~32; update_output(); } DECLARE_WRITE_LINE_MEMBER(write_joy4_0) { if (state) m_joy4 |= 1; else m_joy4 &= ~1; update_output(); } DECLARE_WRITE_LINE_MEMBER(write_joy4_1) { if (state) m_joy4 |= 2; else m_joy4 &= ~2; update_output(); } DECLARE_WRITE_LINE_MEMBER(write_joy4_2) { if (state) m_joy4 |= 4; else m_joy4 &= ~4; update_output(); } DECLARE_WRITE_LINE_MEMBER(write_joy4_3) { if (state) m_joy4 |= 8; else m_joy4 &= ~8; update_output(); } - DECLARE_WRITE_LINE_MEMBER(write_joy4_4) { if (state) m_joy4 |= 16; else m_joy4 &= ~16; update_output(); } - DECLARE_WRITE_LINE_MEMBER(write_joy4_5) { if (state) m_joy4 |= 32; else m_joy4 &= ~32; update_output(); } protected: // device-level overrides |