diff options
Diffstat (limited to 'src')
142 files changed, 1205 insertions, 1180 deletions
diff --git a/src/devices/bus/a2bus/a2diskiing.cpp b/src/devices/bus/a2bus/a2diskiing.cpp index 5459c4249ce..28194db0421 100644 --- a/src/devices/bus/a2bus/a2diskiing.cpp +++ b/src/devices/bus/a2bus/a2diskiing.cpp @@ -39,7 +39,7 @@ ROM_END ROM_START( diskiing13 ) ROM_REGION(0x100, DISKII_ROM_REGION, 0) - ROM_LOAD( "341-0009.bin", 0x000000, 0x000100, CRC(d34eb2ff) SHA1(afd060e6f35faf3bb0146fa889fc787adf56330a) ) + ROM_LOAD( "341-0009.bin", 0x000000, 0x000100, CRC(d34eb2ff) SHA1(afd060e6f35faf3bb0146fa889fc787adf56330a) ) ROM_END FLOPPY_FORMATS_MEMBER( diskiing_device::floppy_formats ) diff --git a/src/devices/bus/cbus/mpu_pc98.cpp b/src/devices/bus/cbus/mpu_pc98.cpp index 7978cbd75e6..a3a8a6667f7 100644 --- a/src/devices/bus/cbus/mpu_pc98.cpp +++ b/src/devices/bus/cbus/mpu_pc98.cpp @@ -71,8 +71,7 @@ void mpu_pc98_device::map(address_map &map) void mpu_pc98_device::device_start() { - address_space &iospace = m_bus->io_space(); - iospace.install_device(0xe0d0, 0xe0d3, *this, &mpu_pc98_device::map); + m_bus->io_space().install_device(0xe0d0, 0xe0d3, *this, &mpu_pc98_device::map); } //------------------------------------------------- diff --git a/src/devices/bus/cbus/pc9801_118.cpp b/src/devices/bus/cbus/pc9801_118.cpp index 719f226fe3b..57e17a9e465 100644 --- a/src/devices/bus/cbus/pc9801_118.cpp +++ b/src/devices/bus/cbus/pc9801_118.cpp @@ -8,7 +8,7 @@ TODO: - preliminary, presumably needs CS-4231 too - - joystick code should be shared between -26, -86 and -118 + - verify sound irq; ***************************************************************************/ @@ -28,18 +28,7 @@ // device type definition DEFINE_DEVICE_TYPE(PC9801_118, pc9801_118_device, "pc9801_118", "pc9801_118") - -READ8_MEMBER(pc9801_118_device::opn_porta_r) -{ - if(m_joy_sel & 0x80) - return ioport(m_joy_sel & 0x40 ? "OPN3_PA2" : "OPN3_PA1")->read(); - - return 0xff; -} - -WRITE8_MEMBER(pc9801_118_device::opn_portb_w){ m_joy_sel = data; } - -WRITE_LINE_MEMBER(pc9801_118_device::pc9801_sound_irq) +WRITE_LINE_MEMBER(pc9801_118_device::sound_irq) { /* TODO: seems to die very often */ m_bus->int_w<5>(state); @@ -50,14 +39,16 @@ WRITE_LINE_MEMBER(pc9801_118_device::pc9801_sound_irq) //------------------------------------------------- MACHINE_CONFIG_START(pc9801_118_device::device_add_mconfig) - SPEAKER(config, "mono").front_center(); + SPEAKER(config, "lspeaker").front_left(); + SPEAKER(config, "rspeaker").front_right(); MCFG_DEVICE_ADD("opn3", YM2608, MAIN_CLOCK_X2*4) // actually YMF288, unknown clock / divider, might be X1 x 5 actually - MCFG_YM2608_IRQ_HANDLER(WRITELINE(*this, pc9801_118_device, pc9801_sound_irq)) + MCFG_YM2608_IRQ_HANDLER(WRITELINE(*this, pc9801_118_device, sound_irq)) MCFG_AY8910_PORT_A_READ_CB(READ8(*this, pc9801_118_device, opn_porta_r)) //MCFG_AY8910_PORT_B_READ_CB(READ8(*this, pc9801_state, opn_portb_r)) //MCFG_AY8910_PORT_A_WRITE_CB(WRITE8(*this, pc9801_state, opn_porta_w)) MCFG_AY8910_PORT_B_WRITE_CB(WRITE8(*this, pc9801_118_device, opn_portb_w)) - MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.00) + MCFG_SOUND_ROUTE(ALL_OUTPUTS, "lspeaker", 1.00) + MCFG_SOUND_ROUTE(ALL_OUTPUTS, "rspeaker", 1.00) MACHINE_CONFIG_END @@ -66,23 +57,7 @@ MACHINE_CONFIG_END //------------------------------------------------- static INPUT_PORTS_START( pc9801_118 ) - PORT_START("OPN3_PA1") - PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) PORT_8WAY PORT_PLAYER(1) PORT_NAME("P1 Joystick Up") - PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_JOYSTICK_DOWN ) PORT_8WAY PORT_PLAYER(1) PORT_NAME("P1 Joystick Down") - PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT ) PORT_8WAY PORT_PLAYER(1) PORT_NAME("P1 Joystick Left") - PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT ) PORT_8WAY PORT_PLAYER(1) PORT_NAME("P1 Joystick Right") - PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_BUTTON1 ) PORT_PLAYER(1) PORT_NAME("P1 Joystick Button 1") - PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_BUTTON2 ) PORT_PLAYER(1) PORT_NAME("P1 Joystick Button 2") - PORT_BIT( 0xc0, IP_ACTIVE_LOW, IPT_UNUSED ) - - PORT_START("OPN3_PA2") - PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) PORT_8WAY PORT_PLAYER(2) PORT_NAME("P2 Joystick Up") - PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_JOYSTICK_DOWN ) PORT_8WAY PORT_PLAYER(2) PORT_NAME("P2 Joystick Down") - PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT ) PORT_8WAY PORT_PLAYER(2) PORT_NAME("P2 Joystick Left") - PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT ) PORT_8WAY PORT_PLAYER(2) PORT_NAME("P2 Joystick Right") - PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_BUTTON1 ) PORT_PLAYER(2) PORT_NAME("P2 Joystick Button 1") - PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_BUTTON2 ) PORT_PLAYER(2) PORT_NAME("P2 Joystick Button 2") - PORT_BIT( 0xc0, IP_ACTIVE_LOW, IPT_UNUSED ) + PORT_INCLUDE( pc9801_joy_port ) PORT_START("OPN3_DSW") PORT_CONFNAME( 0x01, 0x00, "PC-9801-118: Port Base" ) @@ -114,7 +89,7 @@ const tiny_rom_entry *pc9801_118_device::device_rom_region() const //------------------------------------------------- pc9801_118_device::pc9801_118_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) - : device_t(mconfig, PC9801_118, tag, owner, clock), + : pc9801_snd_device(mconfig, PC9801_118, tag, owner, clock), m_bus(*this, DEVICE_SELF_OWNER), m_opn3(*this, "opn3") { @@ -134,28 +109,12 @@ void pc9801_118_device::device_validity_check(validity_checker &valid) const // device_start - device-specific startup //------------------------------------------------- -void pc9801_118_device::install_device(offs_t start, offs_t end, read8_delegate rhandler, write8_delegate whandler) -{ - int buswidth = m_bus->io_space().data_width(); - switch(buswidth) - { - case 8: - m_bus->io_space().install_readwrite_handler(start, end, rhandler, whandler, 0); - break; - case 16: - m_bus->io_space().install_readwrite_handler(start, end, rhandler, whandler, 0xffff); - break; - case 32: - m_bus->io_space().install_readwrite_handler(start, end, rhandler, whandler, 0xffffffff); - break; - default: - fatalerror("PC-9801-118: Bus width %d not supported\n", buswidth); - } -} - void pc9801_118_device::device_start() { + m_bus->install_io(0xa460, 0xa463, read8_delegate(FUNC(pc9801_118_device::id_r), this), write8_delegate(FUNC(pc9801_118_device::ext_w), this) ); + + save_item(NAME(m_ext_reg)); } @@ -166,8 +125,8 @@ void pc9801_118_device::device_start() void pc9801_118_device::device_reset() { uint16_t port_base = (ioport("OPN3_DSW")->read() & 1) << 8; - install_device(port_base + 0x0088, port_base + 0x008f, read8_delegate(FUNC(pc9801_118_device::pc9801_118_r), this), write8_delegate(FUNC(pc9801_118_device::pc9801_118_w), this) ); - install_device(0xa460, 0xa463, read8_delegate(FUNC(pc9801_118_device::pc9801_118_ext_r), this), write8_delegate(FUNC(pc9801_118_device::pc9801_118_ext_w), this) ); + m_bus->io_space().unmap_readwrite(0x0088, 0x008b, 0x100); + m_bus->install_io(port_base + 0x0088, port_base + 0x008f, read8_delegate(FUNC(pc9801_118_device::opn3_r), this), write8_delegate(FUNC(pc9801_118_device::opn3_w), this) ); m_ext_reg = 1; // TODO: enabled or disabled? } @@ -177,7 +136,7 @@ void pc9801_118_device::device_reset() //************************************************************************** -READ8_MEMBER(pc9801_118_device::pc9801_118_r) +READ8_MEMBER(pc9801_118_device::opn3_r) { if(((offset & 5) == 0) || m_ext_reg) return m_opn3->read(space, offset >> 1); @@ -189,7 +148,7 @@ READ8_MEMBER(pc9801_118_device::pc9801_118_r) } -WRITE8_MEMBER(pc9801_118_device::pc9801_118_w) +WRITE8_MEMBER(pc9801_118_device::opn3_w) { if(((offset & 5) == 0) || m_ext_reg) m_opn3->write(space, offset >> 1,data); @@ -197,7 +156,7 @@ WRITE8_MEMBER(pc9801_118_device::pc9801_118_w) // printf("PC9801-118: Write to undefined port [%02x] %02x\n",offset+0x188,data); } -READ8_MEMBER( pc9801_118_device::pc9801_118_ext_r ) +READ8_MEMBER( pc9801_118_device::id_r ) { if(offset == 0) { @@ -209,7 +168,7 @@ READ8_MEMBER( pc9801_118_device::pc9801_118_ext_r ) return 0xff; } -WRITE8_MEMBER( pc9801_118_device::pc9801_118_ext_w ) +WRITE8_MEMBER( pc9801_118_device::ext_w ) { if(offset == 0) { diff --git a/src/devices/bus/cbus/pc9801_118.h b/src/devices/bus/cbus/pc9801_118.h index 99a4287e429..491179a478c 100644 --- a/src/devices/bus/cbus/pc9801_118.h +++ b/src/devices/bus/cbus/pc9801_118.h @@ -13,6 +13,7 @@ #include "bus/cbus/pc9801_cbus.h" #include "sound/2608intf.h" +#include "pc9801_snd.h" //************************************************************************** @@ -21,16 +22,16 @@ // ======================> pc9801_118_device -class pc9801_118_device : public device_t +class pc9801_118_device : public pc9801_snd_device { public: // construction/destruction pc9801_118_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); - DECLARE_READ8_MEMBER(pc9801_118_r); - DECLARE_WRITE8_MEMBER(pc9801_118_w); - DECLARE_READ8_MEMBER(pc9801_118_ext_r); - DECLARE_WRITE8_MEMBER(pc9801_118_ext_w); + DECLARE_READ8_MEMBER(opn3_r); + DECLARE_WRITE8_MEMBER(opn3_w); + DECLARE_READ8_MEMBER(id_r); + DECLARE_WRITE8_MEMBER(ext_w); protected: // device-level overrides @@ -41,18 +42,14 @@ protected: virtual void device_add_mconfig(machine_config &config) override; virtual ioport_constructor device_input_ports() const override; virtual const tiny_rom_entry *device_rom_region() const override; - void install_device(offs_t start, offs_t end, read8_delegate rhandler, write8_delegate whandler); private: required_device<pc9801_slot_device> m_bus; required_device<ym2608_device> m_opn3; - uint8_t m_joy_sel; uint8_t m_ext_reg; - DECLARE_READ8_MEMBER(opn_porta_r); - DECLARE_WRITE8_MEMBER(opn_portb_w); - DECLARE_WRITE_LINE_MEMBER(pc9801_sound_irq); + DECLARE_WRITE_LINE_MEMBER(sound_irq); }; diff --git a/src/devices/bus/cbus/pc9801_26.cpp b/src/devices/bus/cbus/pc9801_26.cpp index d19bf57f522..a06ac5c07ef 100644 --- a/src/devices/bus/cbus/pc9801_26.cpp +++ b/src/devices/bus/cbus/pc9801_26.cpp @@ -7,7 +7,7 @@ Legacy sound card for PC-98xx family, composed by a single YM2203 TODO: - - joystick code should be shared between -26, -86 and -118 + - verify sound irq; ***************************************************************************/ @@ -27,19 +27,7 @@ // device type definition DEFINE_DEVICE_TYPE(PC9801_26, pc9801_26_device, "pc9801_26", "pc9801_26") - - -READ8_MEMBER(pc9801_26_device::opn_porta_r) -{ - if(m_joy_sel & 0x80) - return ioport(m_joy_sel & 0x40 ? "OPN_PA2" : "OPN_PA1")->read(); - - return 0xff; -} - -WRITE8_MEMBER(pc9801_26_device::opn_portb_w){ m_joy_sel = data; } - -WRITE_LINE_MEMBER(pc9801_26_device::pc9801_sound_irq) +WRITE_LINE_MEMBER(pc9801_26_device::sound_irq) { /* TODO: seems to die very often */ m_bus->int_w<5>(state); @@ -53,7 +41,7 @@ WRITE_LINE_MEMBER(pc9801_26_device::pc9801_sound_irq) MACHINE_CONFIG_START(pc9801_26_device::device_add_mconfig) SPEAKER(config, "mono").front_center(); MCFG_DEVICE_ADD("opn", YM2203, MAIN_CLOCK_X1*2) // unknown clock / divider - MCFG_YM2203_IRQ_HANDLER(WRITELINE(*this, pc9801_26_device, pc9801_sound_irq)) + MCFG_YM2203_IRQ_HANDLER(WRITELINE(*this, pc9801_26_device, sound_irq)) MCFG_AY8910_PORT_A_READ_CB(READ8(*this, pc9801_26_device, opn_porta_r)) //MCFG_AY8910_PORT_B_READ_CB(READ8(*this, pc9801_state, opn_portb_r)) //MCFG_AY8910_PORT_A_WRITE_CB(WRITE8(*this, pc9801_state, opn_porta_w)) @@ -88,25 +76,7 @@ const tiny_rom_entry *pc9801_26_device::device_rom_region() const //------------------------------------------------- static INPUT_PORTS_START( pc9801_26 ) - PORT_START("OPN_PA1") - PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) PORT_8WAY PORT_PLAYER(1) PORT_NAME("P1 Joystick Up") - PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_JOYSTICK_DOWN ) PORT_8WAY PORT_PLAYER(1) PORT_NAME("P1 Joystick Down") - PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT ) PORT_8WAY PORT_PLAYER(1) PORT_NAME("P1 Joystick Left") - PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT ) PORT_8WAY PORT_PLAYER(1) PORT_NAME("P1 Joystick Right") - PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_BUTTON1 ) PORT_PLAYER(1) PORT_NAME("P1 Joystick Button 1") - PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_BUTTON2 ) PORT_PLAYER(1) PORT_NAME("P1 Joystick Button 2") - PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_UNUSED ) - PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_UNUSED ) - - PORT_START("OPN_PA2") - PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) PORT_8WAY PORT_PLAYER(2) PORT_NAME("P2 Joystick Up") - PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_JOYSTICK_DOWN ) PORT_8WAY PORT_PLAYER(2) PORT_NAME("P2 Joystick Down") - PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT ) PORT_8WAY PORT_PLAYER(2) PORT_NAME("P2 Joystick Left") - PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT ) PORT_8WAY PORT_PLAYER(2) PORT_NAME("P2 Joystick Right") - PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_BUTTON1 ) PORT_PLAYER(2) PORT_NAME("P2 Joystick Button 1") - PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_BUTTON2 ) PORT_PLAYER(2) PORT_NAME("P2 Joystick Button 2") - PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_UNUSED ) - PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_UNUSED ) + PORT_INCLUDE( pc9801_joy_port ) PORT_START("OPN_DSW") PORT_CONFNAME( 0x01, 0x01, "PC-9801-26: Port Base" ) @@ -128,7 +98,7 @@ ioport_constructor pc9801_26_device::device_input_ports() const //------------------------------------------------- pc9801_26_device::pc9801_26_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) - : device_t(mconfig, PC9801_26, tag, owner, clock), + : pc9801_snd_device(mconfig, PC9801_26, tag, owner, clock), m_bus(*this, DEVICE_SELF_OWNER), m_opn(*this, "opn") { @@ -148,25 +118,6 @@ void pc9801_26_device::device_validity_check(validity_checker &valid) const // device_start - device-specific startup //------------------------------------------------- -void pc9801_26_device::install_device(offs_t start, offs_t end, read8_delegate rhandler, write8_delegate whandler) -{ - int buswidth = m_bus->io_space().data_width(); - switch(buswidth) - { - case 8: - m_bus->io_space().install_readwrite_handler(start, end, rhandler, whandler, 0); - break; - case 16: - m_bus->io_space().install_readwrite_handler(start, end, rhandler, whandler, 0xffff); - break; - case 32: - m_bus->io_space().install_readwrite_handler(start, end, rhandler, whandler, 0xffffffff); - break; - default: - fatalerror("PC-9801-26: Bus width %d not supported\n", buswidth); - } -} - void pc9801_26_device::device_start() { @@ -183,7 +134,7 @@ void pc9801_26_device::device_reset() uint16_t port_base = (ioport("OPN_DSW")->read() & 1) << 8; m_bus->io_space().unmap_readwrite(0x0088, 0x008b, 0x100); - install_device(port_base + 0x0088, port_base + 0x008b, read8_delegate(FUNC(pc9801_26_device::opn_r), this), write8_delegate(FUNC(pc9801_26_device::opn_w), this) ); + m_bus->install_io(port_base + 0x0088, port_base + 0x008b, read8_delegate(FUNC(pc9801_26_device::opn_r), this), write8_delegate(FUNC(pc9801_26_device::opn_w), this) ); } diff --git a/src/devices/bus/cbus/pc9801_26.h b/src/devices/bus/cbus/pc9801_26.h index 250d38a6d8a..abda3181512 100644 --- a/src/devices/bus/cbus/pc9801_26.h +++ b/src/devices/bus/cbus/pc9801_26.h @@ -13,7 +13,7 @@ Template for skeleton device #include "bus/cbus/pc9801_cbus.h" #include "sound/2203intf.h" - +#include "pc9801_snd.h" //************************************************************************** // TYPE DEFINITIONS @@ -21,7 +21,7 @@ Template for skeleton device // ======================> pc9801_26_device -class pc9801_26_device : public device_t +class pc9801_26_device : public pc9801_snd_device { public: // construction/destruction @@ -39,17 +39,12 @@ protected: virtual void device_add_mconfig(machine_config &config) override; virtual ioport_constructor device_input_ports() const override; virtual const tiny_rom_entry *device_rom_region() const override; - void install_device(offs_t start, offs_t end, read8_delegate rhandler, write8_delegate whandler); private: required_device<pc9801_slot_device> m_bus; required_device<ym2203_device> m_opn; - uint8_t m_joy_sel; - - DECLARE_WRITE_LINE_MEMBER(pc9801_sound_irq); - DECLARE_READ8_MEMBER(opn_porta_r); - DECLARE_WRITE8_MEMBER(opn_portb_w); + DECLARE_WRITE_LINE_MEMBER(sound_irq); }; diff --git a/src/devices/bus/cbus/pc9801_86.cpp b/src/devices/bus/cbus/pc9801_86.cpp index 130878a58ee..f14d362f9a6 100644 --- a/src/devices/bus/cbus/pc9801_86.cpp +++ b/src/devices/bus/cbus/pc9801_86.cpp @@ -3,20 +3,24 @@ /*************************************************************************** NEC PC-9801-86 sound card - NEC PC-9801-SpeakBoard sound card + NEC PC-9801-SpeakBoard sound card Similar to PC-9801-26, this one has YM2608 instead of YM2203 and an additional DAC port - SpeakBoard sound card seems to be derived design from -86, with an additional - OPNA mapped at 0x58* + SpeakBoard sound card seems to be derived design from -86, with an additional + OPNA mapped at 0x58* TODO: - joystick code should be shared between -26, -86 and -118 - Test all pcm modes - Make volume work - Recording - - actual stereo sound routing (currently routes to ALL_OUTPUTS) - - SpeakBoard: no idea about software that uses this; + - actual stereo sound routing (currently routes to ALL_OUTPUTS) + - SpeakBoard: no idea about software that uses this, also board shows a single YM2608B? + "-86 only supports ADPCM instead of PCM, while SpeakBoard has OPNA + 256 Kbit RAM" + Sounds like a sound core flaw since OPNA requires a rom region in any case; + - SpeakBoard: sounds horrible, due of the MAME mixing (same as Sega 32X, needs user to lower individual channel volumes); + - verify sound irq; ***************************************************************************/ @@ -34,17 +38,6 @@ // device type definition DEFINE_DEVICE_TYPE(PC9801_86, pc9801_86_device, "pc9801_86", "pc9801_86") - -READ8_MEMBER(pc9801_86_device::opn_porta_r) -{ - if(m_joy_sel & 0x80) - return ioport(m_joy_sel & 0x40 ? "OPNA_PA2" : "OPNA_PA1")->read(); - - return 0xff; -} - -WRITE8_MEMBER(pc9801_86_device::opn_portb_w){ m_joy_sel = data; } - WRITE_LINE_MEMBER(pc9801_86_device::sound_irq) { m_fmirq = state ? true : false; @@ -69,6 +62,7 @@ MACHINE_CONFIG_START(pc9801_86_device::pc9801_86_config) MCFG_AY8910_PORT_B_WRITE_CB(WRITE8(*this, pc9801_86_device, opn_portb_w)) MCFG_SOUND_ROUTE(ALL_OUTPUTS, "lspeaker", 1.00) MCFG_SOUND_ROUTE(ALL_OUTPUTS, "rspeaker", 1.00) + MCFG_DEVICE_ADD("ldac", DAC_16BIT_R2R_TWOS_COMPLEMENT, 0) MCFG_SOUND_ROUTE(ALL_OUTPUTS, "lspeaker", 1.0) // burr brown pcm61p MCFG_DEVICE_ADD("rdac", DAC_16BIT_R2R_TWOS_COMPLEMENT, 0) MCFG_SOUND_ROUTE(ALL_OUTPUTS, "rspeaker", 1.0) // burr brown pcm61p MCFG_DEVICE_ADD("vref", VOLTAGE_REGULATOR, 0) MCFG_VOLTAGE_REGULATOR_OUTPUT(5.0) @@ -108,23 +102,7 @@ const tiny_rom_entry *pc9801_86_device::device_rom_region() const //------------------------------------------------- static INPUT_PORTS_START( pc9801_86 ) - PORT_START("OPNA_PA1") - PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) PORT_8WAY PORT_PLAYER(1) PORT_NAME("P1 Joystick Up") - PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_JOYSTICK_DOWN ) PORT_8WAY PORT_PLAYER(1) PORT_NAME("P1 Joystick Down") - PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT ) PORT_8WAY PORT_PLAYER(1) PORT_NAME("P1 Joystick Left") - PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT ) PORT_8WAY PORT_PLAYER(1) PORT_NAME("P1 Joystick Right") - PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_BUTTON1 ) PORT_PLAYER(1) PORT_NAME("P1 Joystick Button 1") - PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_BUTTON2 ) PORT_PLAYER(1) PORT_NAME("P1 Joystick Button 2") - PORT_BIT( 0xc0, IP_ACTIVE_LOW, IPT_UNUSED ) - - PORT_START("OPNA_PA2") - PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) PORT_8WAY PORT_PLAYER(2) PORT_NAME("P2 Joystick Up") - PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_JOYSTICK_DOWN ) PORT_8WAY PORT_PLAYER(2) PORT_NAME("P2 Joystick Down") - PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT ) PORT_8WAY PORT_PLAYER(2) PORT_NAME("P2 Joystick Left") - PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT ) PORT_8WAY PORT_PLAYER(2) PORT_NAME("P2 Joystick Right") - PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_BUTTON1 ) PORT_PLAYER(2) PORT_NAME("P2 Joystick Button 1") - PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_BUTTON2 ) PORT_PLAYER(2) PORT_NAME("P2 Joystick Button 2") - PORT_BIT( 0xc0, IP_ACTIVE_LOW, IPT_UNUSED ) + PORT_INCLUDE( pc9801_joy_port ) PORT_START("OPNA_DSW") PORT_CONFNAME( 0x01, 0x01, "PC-9801-86: Port Base" ) @@ -146,7 +124,7 @@ ioport_constructor pc9801_86_device::device_input_ports() const //------------------------------------------------- pc9801_86_device::pc9801_86_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) - : device_t(mconfig, type, tag, owner, clock), + : pc9801_snd_device(mconfig, type, tag, owner, clock), m_bus(*this, DEVICE_SELF_OWNER), m_opna(*this, "opna"), m_ldac(*this, "ldac"), @@ -158,7 +136,7 @@ pc9801_86_device::pc9801_86_device(const machine_config &mconfig, device_type ty pc9801_86_device::pc9801_86_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : pc9801_86_device(mconfig, PC9801_86, tag, owner, clock) { - + } @@ -175,32 +153,13 @@ void pc9801_86_device::device_validity_check(validity_checker &valid) const // device_start - device-specific startup //------------------------------------------------- -void pc9801_86_device::install_device(offs_t start, offs_t end, read8_delegate rhandler, write8_delegate whandler) -{ - int buswidth = m_bus->io_space().data_width(); - switch(buswidth) - { - case 8: - m_bus->io_space().install_readwrite_handler(start, end, rhandler, whandler, 0); - break; - case 16: - m_bus->io_space().install_readwrite_handler(start, end, rhandler, whandler, 0xffff); - break; - case 32: - m_bus->io_space().install_readwrite_handler(start, end, rhandler, whandler, 0xffffffff); - break; - default: - fatalerror("PC-9801-86: Bus width %d not supported\n", buswidth); - } -} - void pc9801_86_device::device_start() { m_bus->program_space().install_rom(0xcc000,0xcffff,memregion(this->subtag("sound_bios").c_str())->base()); - install_device(0xa460, 0xa463, read8_delegate(FUNC(pc9801_86_device::id_r), this), write8_delegate(FUNC(pc9801_86_device::mask_w), this)); - install_device(0xa464, 0xa46f, read8_delegate(FUNC(pc9801_86_device::pcm_r), this), write8_delegate(FUNC(pc9801_86_device::pcm_w), this)); - install_device(0xa66c, 0xa66f, read8_delegate([this](address_space &s, offs_t o, u8 mm){ return o == 2 ? m_pcm_mute : 0xff; }, "pc9801_86_mute_r"), + m_bus->install_io(0xa460, 0xa463, read8_delegate(FUNC(pc9801_86_device::id_r), this), write8_delegate(FUNC(pc9801_86_device::mask_w), this)); + m_bus->install_io(0xa464, 0xa46f, read8_delegate(FUNC(pc9801_86_device::pcm_r), this), write8_delegate(FUNC(pc9801_86_device::pcm_w), this)); + m_bus->install_io(0xa66c, 0xa66f, read8_delegate([this](address_space &s, offs_t o, u8 mm){ return o == 2 ? m_pcm_mute : 0xff; }, "pc9801_86_mute_r"), write8_delegate([this](address_space &s, offs_t o, u8 d, u8 mm){ if(o == 2) m_pcm_mute = d; }, "pc9801_86_mute_w")); m_dac_timer = timer_alloc(); @@ -218,7 +177,7 @@ void pc9801_86_device::device_reset() { uint16_t port_base = (ioport("OPNA_DSW")->read() & 1) << 8; m_bus->io_space().unmap_readwrite(0x0088, 0x008f, 0x100); - install_device(port_base + 0x0088, port_base + 0x008f, read8_delegate(FUNC(pc9801_86_device::opna_r), this), write8_delegate(FUNC(pc9801_86_device::opna_w), this) ); + m_bus->install_io(port_base + 0x0088, port_base + 0x008f, read8_delegate(FUNC(pc9801_86_device::opna_r), this), write8_delegate(FUNC(pc9801_86_device::opna_w), this) ); m_mask = 0; m_head = m_tail = m_count = 0; @@ -419,7 +378,7 @@ const tiny_rom_entry *pc9801_speakboard_device::device_rom_region() const //************************************************************************** //------------------------------------------------- -// pc9801_86_device - constructor +// pc9801_speakboard_device - constructor //------------------------------------------------- pc9801_speakboard_device::pc9801_speakboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) @@ -440,8 +399,8 @@ MACHINE_CONFIG_END void pc9801_speakboard_device::device_start() { pc9801_86_device::device_start(); - - install_device(0x0588, 0x058f, read8_delegate(FUNC(pc9801_speakboard_device::opna_slave_r), this), write8_delegate(FUNC(pc9801_speakboard_device::opna_slave_w), this) ); + + m_bus->install_io(0x0588, 0x058f, read8_delegate(FUNC(pc9801_speakboard_device::opna_slave_r), this), write8_delegate(FUNC(pc9801_speakboard_device::opna_slave_w), this) ); } void pc9801_speakboard_device::device_reset() diff --git a/src/devices/bus/cbus/pc9801_86.h b/src/devices/bus/cbus/pc9801_86.h index 29088119e58..2042bb0eda3 100644 --- a/src/devices/bus/cbus/pc9801_86.h +++ b/src/devices/bus/cbus/pc9801_86.h @@ -14,6 +14,7 @@ #include "bus/cbus/pc9801_cbus.h" #include "sound/2608intf.h" #include "sound/dac.h" +#include "pc9801_snd.h" //************************************************************************** // TYPE DEFINITIONS @@ -21,7 +22,7 @@ // ======================> pc9801_86_device -class pc9801_86_device : public device_t +class pc9801_86_device : public pc9801_snd_device { public: // construction/destruction @@ -36,8 +37,6 @@ public: DECLARE_WRITE8_MEMBER(pcm_w); DECLARE_WRITE_LINE_MEMBER(sound_irq); - DECLARE_READ8_MEMBER(opn_porta_r); - DECLARE_WRITE8_MEMBER(opn_portb_w); protected: // device-level overrides @@ -48,17 +47,17 @@ protected: virtual void device_add_mconfig(machine_config &config) override; virtual ioport_constructor device_input_ports() const override; virtual const tiny_rom_entry *device_rom_region() const override; - void install_device(offs_t start, offs_t end, read8_delegate rhandler, write8_delegate whandler); virtual void device_timer(emu_timer &timer, device_timer_id id, int param, void *ptr) override; void pc9801_86_config(machine_config &config); + required_device<pc9801_slot_device> m_bus; + private: int queue_count(); uint8_t queue_pop(); - required_device<pc9801_slot_device> m_bus; - uint8_t m_joy_sel, m_mask, m_pcm_mode, m_vol[7], m_pcm_ctrl, m_pcm_mute; + uint8_t m_mask, m_pcm_mode, m_vol[7], m_pcm_ctrl, m_pcm_mute; uint16_t m_head, m_tail, m_count, m_irq_rate; bool m_pcmirq, m_fmirq, m_pcm_clk, m_init; required_device<ym2608_device> m_opna; @@ -82,7 +81,7 @@ protected: virtual void device_start() override; virtual void device_reset() override; virtual const tiny_rom_entry *device_rom_region() const override; - + private: required_device<ym2608_device> m_opna_slave; }; diff --git a/src/devices/bus/cbus/pc9801_amd98.cpp b/src/devices/bus/cbus/pc9801_amd98.cpp index 0e5d39579da..84f69c47999 100644 --- a/src/devices/bus/cbus/pc9801_amd98.cpp +++ b/src/devices/bus/cbus/pc9801_amd98.cpp @@ -124,26 +124,6 @@ void pc9801_amd98_device::device_validity_check(validity_checker &valid) const // device_start - device-specific startup //------------------------------------------------- -void pc9801_amd98_device::install_device(offs_t start, offs_t end, read8_delegate rhandler, write8_delegate whandler) -{ - int buswidth = m_bus->io_space().data_width(); - switch(buswidth) - { - case 8: - m_bus->io_space().install_readwrite_handler(start, end, rhandler, whandler, 0); - break; - case 16: - m_bus->io_space().install_readwrite_handler(start, end, rhandler, whandler, 0xffff); - break; - case 32: - m_bus->io_space().install_readwrite_handler(start, end, rhandler, whandler, 0xffffffff); - break; - default: - fatalerror("PC-9801-AMD98: Bus width %d not supported\n", buswidth); - } -} - - void pc9801_amd98_device::device_start() { } @@ -155,9 +135,9 @@ void pc9801_amd98_device::device_start() void pc9801_amd98_device::device_reset() { - install_device(0x00d8, 0x00df, read8_delegate(FUNC(pc9801_amd98_device::read), this), write8_delegate(FUNC(pc9801_amd98_device::write), this) ); + m_bus->install_io(0x00d8, 0x00df, read8_delegate(FUNC(pc9801_amd98_device::read), this), write8_delegate(FUNC(pc9801_amd98_device::write), this) ); // Thexder access with following - install_device(0x38d8, 0x38df, read8_delegate(FUNC(pc9801_amd98_device::read), this), write8_delegate(FUNC(pc9801_amd98_device::write), this) ); + m_bus->install_io(0x38d8, 0x38df, read8_delegate(FUNC(pc9801_amd98_device::read), this), write8_delegate(FUNC(pc9801_amd98_device::write), this) ); } diff --git a/src/devices/bus/cbus/pc9801_amd98.h b/src/devices/bus/cbus/pc9801_amd98.h index db5d6d89727..993cd6e9e4b 100644 --- a/src/devices/bus/cbus/pc9801_amd98.h +++ b/src/devices/bus/cbus/pc9801_amd98.h @@ -39,7 +39,6 @@ protected: virtual void device_reset() override; // optional information overrides virtual void device_add_mconfig(machine_config &config) override; - void install_device(offs_t start, offs_t end, read8_delegate rhandler, write8_delegate whandler); virtual ioport_constructor device_input_ports() const override; private: diff --git a/src/devices/bus/cbus/pc9801_cbus.cpp b/src/devices/bus/cbus/pc9801_cbus.cpp index 70f22990159..528dd86ce43 100644 --- a/src/devices/bus/cbus/pc9801_cbus.cpp +++ b/src/devices/bus/cbus/pc9801_cbus.cpp @@ -94,3 +94,22 @@ void pc9801_slot_device::device_start() { // m_card = dynamic_cast<device_pc9801_slot_card_interface *>(get_card_device()); } + +void pc9801_slot_device::install_io(offs_t start, offs_t end, read8_delegate rhandler, write8_delegate whandler) +{ + int buswidth = this->io_space().data_width(); + switch(buswidth) + { + case 8: + this->io_space().install_readwrite_handler(start, end, rhandler, whandler, 0); + break; + case 16: + this->io_space().install_readwrite_handler(start, end, rhandler, whandler, 0xffff); + break; + case 32: + this->io_space().install_readwrite_handler(start, end, rhandler, whandler, 0xffffffff); + break; + default: + fatalerror("PC-9801-26: Bus width %d not supported\n", buswidth); + } +} diff --git a/src/devices/bus/cbus/pc9801_cbus.h b/src/devices/bus/cbus/pc9801_cbus.h index 4b5dba8fa76..5508e1297d8 100644 --- a/src/devices/bus/cbus/pc9801_cbus.h +++ b/src/devices/bus/cbus/pc9801_cbus.h @@ -84,6 +84,7 @@ public: address_space &program_space() const { return m_cpu->space(AS_PROGRAM); } address_space &io_space() const { return m_cpu->space(AS_IO); } template<int I> void int_w(bool state) { m_int_callback[I](state); } + void install_io(offs_t start, offs_t end, read8_delegate rhandler, write8_delegate whandler); protected: // device-level overrides diff --git a/src/devices/bus/cbus/pc9801_snd.cpp b/src/devices/bus/cbus/pc9801_snd.cpp new file mode 100644 index 00000000000..670e423e4d3 --- /dev/null +++ b/src/devices/bus/cbus/pc9801_snd.cpp @@ -0,0 +1,50 @@ +// license:BSD-3-Clause +// copyright-holders:Angelo Salese +/*************************************************************************** + + NEC PC-9801 + common functions for CBUS sound boards -26, -86, -118 + +***************************************************************************/ + +#include "emu.h" +#include "pc9801_snd.h" + +//DEFINE_DEVICE_TYPE(PC9801_SND, pc9801_snd_device, "pc9801_snd", "PC9801 CBUS Sound") + +pc9801_snd_device::pc9801_snd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) + : device_t(mconfig, type, tag, owner, clock) +{ +} + +READ8_MEMBER(pc9801_snd_device::opn_porta_r) +{ + if(m_joy_sel & 0x80) + return ioport(m_joy_sel & 0x40 ? "PA2" : "PA1")->read(); + + return 0xff; +} + +WRITE8_MEMBER(pc9801_snd_device::opn_portb_w) { m_joy_sel = data; } + +INPUT_PORTS_START(pc9801_joy_port) + PORT_START("PA1") + PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) PORT_8WAY PORT_PLAYER(1) PORT_NAME("P1 Joystick Up") + PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_JOYSTICK_DOWN ) PORT_8WAY PORT_PLAYER(1) PORT_NAME("P1 Joystick Down") + PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT ) PORT_8WAY PORT_PLAYER(1) PORT_NAME("P1 Joystick Left") + PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT ) PORT_8WAY PORT_PLAYER(1) PORT_NAME("P1 Joystick Right") + PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_BUTTON1 ) PORT_PLAYER(1) PORT_NAME("P1 Joystick Button 1") + PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_BUTTON2 ) PORT_PLAYER(1) PORT_NAME("P1 Joystick Button 2") + PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_UNUSED ) + PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_UNUSED ) + + PORT_START("PA2") + PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) PORT_8WAY PORT_PLAYER(2) PORT_NAME("P2 Joystick Up") + PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_JOYSTICK_DOWN ) PORT_8WAY PORT_PLAYER(2) PORT_NAME("P2 Joystick Down") + PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT ) PORT_8WAY PORT_PLAYER(2) PORT_NAME("P2 Joystick Left") + PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT ) PORT_8WAY PORT_PLAYER(2) PORT_NAME("P2 Joystick Right") + PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_BUTTON1 ) PORT_PLAYER(2) PORT_NAME("P2 Joystick Button 1") + PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_BUTTON2 ) PORT_PLAYER(2) PORT_NAME("P2 Joystick Button 2") + PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_UNUSED ) + PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_UNUSED ) +INPUT_PORTS_END diff --git a/src/devices/bus/cbus/pc9801_snd.h b/src/devices/bus/cbus/pc9801_snd.h new file mode 100644 index 00000000000..600e555b329 --- /dev/null +++ b/src/devices/bus/cbus/pc9801_snd.h @@ -0,0 +1,31 @@ +// license:BSD-3-Clause +// copyright-holders:Angelo Salese +/*************************************************************************** + + NEC PC-9801 + common functions for CBUS sound boards -26, -86, -118 + +***************************************************************************/ + +#ifndef MAME_BUS_CBUS_PC9801_SND_H +#define MAME_BUS_CBUS_PC9801_SND_H + +#pragma once + +class pc9801_snd_device : public device_t +{ +public: + pc9801_snd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + +protected: + DECLARE_READ8_MEMBER(opn_porta_r); + DECLARE_WRITE8_MEMBER(opn_portb_w); + +private: + uint8_t m_joy_sel; +}; + +//DECLARE_DEVICE_TYPE(PC9801_SND, pc9801_snd_device) +INPUT_PORTS_EXTERN(pc9801_joy_port); + +#endif diff --git a/src/devices/bus/interpro/sr/edge.cpp b/src/devices/bus/interpro/sr/edge.cpp index 80c8fc6e0f9..d65791e66ac 100644 --- a/src/devices/bus/interpro/sr/edge.cpp +++ b/src/devices/bus/interpro/sr/edge.cpp @@ -253,7 +253,7 @@ void edge1_device_base::map_dynamic(address_map &map) [this](address_space &space, offs_t offset, u8 data, u8 mem_mask) { m_vram->write((offset >> 2) | (offset & 0x3), data); }); //map(0x02028200, 0x0202827f).lr32("idprom", - // [this](address_space &space, offs_t offset, u8 mem_mask) { return memregion("idprom")->as_u32(offset); }); + // [this](address_space &space, offs_t offset, u8 mem_mask) { return memregion("idprom")->as_u32(offset); }); map(0x02410000, 0x0241000f).m("ramdac", FUNC(bt458_device::map)).umask32(0x000000ff); @@ -321,7 +321,7 @@ void edge2plus_framebuffer_device_base::map_dynamic(address_map &map) [this](address_space &space, offs_t offset, u8 mem_mask) { return m_sram->read(offset); }, [this](address_space &space, offs_t offset, u8 data, u8 mem_mask) { m_sram->write(offset, data); }); - map(0x01000000, 0x01ffffff).lrw8("vram", + map(0x01000000, 0x01ffffff).lrw8("vram", [this](address_space &space, offs_t offset, u8 mem_mask) { return m_vram->read(offset); }, [this](address_space &space, offs_t offset, u8 data, u8 mem_mask) { m_vram->write(offset, data); }); @@ -383,7 +383,7 @@ ROM_END * "9 planes (1 for highlights) of double-buffered graphics, 256 colours from 16.7 million" * 1024x1024x10x2 == 2621440 bytes == 2560KiB == 2.5MiB * FIXME: diag reports 128KiB static ram, 1MiB video ram, 4 screens, 1 user, z-buffer absent -* +* */ MACHINE_CONFIG_START(mpcb828_device::device_add_mconfig) MCFG_SCREEN_ADD("screen", RASTER) diff --git a/src/devices/bus/interpro/sr/edge.h b/src/devices/bus/interpro/sr/edge.h index f8c73cfced7..5f3247b5158 100644 --- a/src/devices/bus/interpro/sr/edge.h +++ b/src/devices/bus/interpro/sr/edge.h @@ -45,10 +45,10 @@ enum attention_mask enum reg0_mask { /* - 0x08, - 0x10, // mouse button interrupt? - 0x20, - 0x40, + 0x08, + 0x10, // mouse button interrupt? + 0x20, + 0x40, */ SCC_INT = 0x80, // serial controller VBLANK = 0x1000, // vertical blank? diff --git a/src/devices/bus/isa/lbaenhancer.cpp b/src/devices/bus/isa/lbaenhancer.cpp index 683572b37b5..14bd28826ef 100644 --- a/src/devices/bus/isa/lbaenhancer.cpp +++ b/src/devices/bus/isa/lbaenhancer.cpp @@ -6,7 +6,7 @@ *********************************************************************** - Generic BIOS extension card. Adds 28 bit LBA mode to any pre-1994 + Generic BIOS extension card. Adds 28 bit LBA mode to any pre-1994 board with an empty ISA slot. Supports 1 to 4 large hard disks. Bios boot remains possible. @@ -18,13 +18,13 @@ See: ftp://ami.com/archive/utility/LBA.TXT Usage: - select type 47 for each LBA drive and set C,H,S (params) to '8', + select type 47 for each LBA drive and set C,H,S (params) to '8', then repartition and reformat (Fdisk and Format). Data is lost. Other notes: ROM bank should be excluded in EMM386. - C8000 - CBFFF is sometimes occupied (by graphics). + C8000 - CBFFF is sometimes occupied (by graphics). Changes to the ROM location require a hard reset! - + Requirements: Compatible OS (DOS >= 6.22) and LBA capable drive(s). *********************************************************************** @@ -48,7 +48,7 @@ Notes: J3, J2, J1 set BIOS (start) address to C800, CC00, D000, D400, D800 or DC00 -- one CD74LS245 +- one CD74LS245 - one PALCE16V8H-25 - one 32 K EPROM : 27C256 (STM) (mirrored after 16 K) @@ -85,23 +85,23 @@ const tiny_rom_entry *lba_enhancer_device::device_rom_region() const // device_add_mconfig - add device configuration //------------------------------------------------- MACHINE_CONFIG_START( lba_enhancer_device::device_add_mconfig ) -// MCFG_DEVICE_ADD("lba_enhancer", lba_enhancer, 0) +// MCFG_DEVICE_ADD("lba_enhancer", lba_enhancer, 0) MACHINE_CONFIG_END //------------------------------------------------- -// jumpers +// jumpers //------------------------------------------------- static INPUT_PORTS_START( lba_enhancer_dsw ) PORT_START("ROM_ADDRESS") PORT_CONFNAME( 0x07, 0x00, "16 K ROM bank") PORT_CONFSETTING( 0, "C8000 - CBFFF" ) - PORT_CONFSETTING( 1, "CC000 - CFFFF" ) - PORT_CONFSETTING( 2, "D0000 - D3FFF" ) - PORT_CONFSETTING( 3, "D4000 - D7FFF" ) - PORT_CONFSETTING( 4, "D8000 - DBFFF" ) - PORT_CONFSETTING( 5, "DC000 - DFFFF" ) + PORT_CONFSETTING( 1, "CC000 - CFFFF" ) + PORT_CONFSETTING( 2, "D0000 - D3FFF" ) + PORT_CONFSETTING( 3, "D4000 - D7FFF" ) + PORT_CONFSETTING( 4, "D8000 - DBFFF" ) + PORT_CONFSETTING( 5, "DC000 - DFFFF" ) INPUT_PORTS_END //------------------------------------------------- @@ -133,7 +133,7 @@ void lba_enhancer_device::device_reset() uint32_t current_rom_end = m_current_rom_start + 0x04000 - 1; m_isa->install_rom(this, m_current_rom_start, current_rom_end, "lbabios", "lbabios"); - + logerror("LBA enhancer (for 28 bit LBA) located at BIOS address %x - %x\n", m_current_rom_start, current_rom_end); } } diff --git a/src/devices/bus/isa/lbaenhancer.h b/src/devices/bus/isa/lbaenhancer.h index f73aaa5eff0..71e36c02665 100644 --- a/src/devices/bus/isa/lbaenhancer.h +++ b/src/devices/bus/isa/lbaenhancer.h @@ -18,7 +18,7 @@ //************************************************************************** class lba_enhancer_device : public device_t, - public device_isa8_card_interface + public device_isa8_card_interface { public: // construction/destruction diff --git a/src/devices/bus/lpci/i82439tx.cpp b/src/devices/bus/lpci/i82439tx.cpp index 046f600a78e..1fe0e22717f 100644 --- a/src/devices/bus/lpci/i82439tx.cpp +++ b/src/devices/bus/lpci/i82439tx.cpp @@ -18,8 +18,8 @@ DEFINE_DEVICE_TYPE(I82439TX_LEGACY, i82439tx_device, "i82439tx_legacy", "Intel 82439TX") -i82439tx_device::i82439tx_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) - : northbridge_device(mconfig, I82439TX_LEGACY, tag, owner, clock), +i82439tx_device::i82439tx_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : + northbridge_device(mconfig, I82439TX_LEGACY, tag, owner, clock), pci_device_interface(mconfig, *this), m_cpu_tag(nullptr), m_region_tag(nullptr), diff --git a/src/devices/cpu/i86/i86.cpp b/src/devices/cpu/i86/i86.cpp index f56f5a40045..d578c6f3a2c 100644 --- a/src/devices/cpu/i86/i86.cpp +++ b/src/devices/cpu/i86/i86.cpp @@ -468,7 +468,7 @@ void i8086_common_cpu_device::device_start() { m_program = &space(AS_PROGRAM); m_opcodes = has_space(AS_OPCODES) ? &space(AS_OPCODES) : m_program; - + if(m_opcodes->data_width() == 8) { auto cache = m_opcodes->cache<0, 0, ENDIANNESS_LITTLE>(); m_or8 = [cache](offs_t address) -> u8 { return cache->read_byte(address); }; diff --git a/src/devices/cpu/m6502/xavix.cpp b/src/devices/cpu/m6502/xavix.cpp index 6df019c5bb8..bc805165390 100644 --- a/src/devices/cpu/m6502/xavix.cpp +++ b/src/devices/cpu/m6502/xavix.cpp @@ -4,11 +4,11 @@ xavix.cpp - The dies for these are marked - - SSD 97 PA7270-107 (only seen on Ping Pong) - SSD 98 PA7351-107 - SSD 98 PL7351-181 + The dies for these are marked + + SSD 97 PA7270-107 (only seen on Ping Pong) + SSD 98 PA7351-107 + SSD 98 PL7351-181 6502 with custom opcodes integrated gfx / sound @@ -21,7 +21,7 @@ 0x00ff contains the DATA bank, set manually in code 0x00fe appears to be the current CODE bank, set with either the custom opcodes, or manually (if running from lowbus only?) - + ***************************************************************************/ #include "emu.h" diff --git a/src/devices/cpu/m6502/xavix2000.cpp b/src/devices/cpu/m6502/xavix2000.cpp index ab40752b1fe..afbf87fd8c6 100644 --- a/src/devices/cpu/m6502/xavix2000.cpp +++ b/src/devices/cpu/m6502/xavix2000.cpp @@ -4,12 +4,12 @@ xavix2000.cpp - The dies for these are marked - - SSD 2000 NEC 85605-621 - and possibly - SSD 2002 NEC 85054-611 (although this might use even more opcodes and need it's own file) - + The dies for these are marked + + SSD 2000 NEC 85605-621 + and possibly + SSD 2002 NEC 85054-611 (although this might use even more opcodes and need it's own file) + 6502 with custom opcodes integrated gfx / sound @@ -17,64 +17,64 @@ see xavix.cpp for basic notes - the machines using the '2000' series chips seem to have more extra - opcodes, so presumably these were only available in those models. - of note, push x / push y and pull x / pull y - - Dirt Rebel MX, which is confirmed as 2000 type however seems to require - some of the documented but 'undocumented' opcodes on the 6502 to have additonal - meaning for one specific function on startup - - 01BC37: A0 3F ldy #$3f - 01BC39: B2 ?? - 01BC3A: 1B ?? - 9B ?? - -- outer loop - 01BC3C: 98 tya - 01BC3D: 5B (has to be 1 byte?) - -- inner loop - 01BC3E: A3 (has to be 1 byte) - 73 (could be 3 byte?) - 01BC40: 83 FB presumably fb is the address - 01BC42: A7 (presumably 1 byte) - 73 (could be 3 byte?) - 01BC44: 87 FB presumably fb is the address - 01BC46: D0 F6 bne $1bc3e - 01BC48: 88 dey - 01BC49: 10 F1 bpl $1bc3c - 01BC4B: 8D FB 00 sta $00fb - 01BC4E: A3 ?? - 01BC4F: 8D FA 00 sta $00fa - 01BC52: 07 ?? - -- - 01BC53: D0 03 bne $1bc58 - 01BC55: CE fa 00 dec $00fa - 01BC58: 80 retf - - this is presumably meant to be similar to the function found in Namco - Nostalgia 2 - - 09FFD8: A9 3F lda #$3f - 09FFDA: 85 01 sta $01 - 09FFDC: A0 00 ldy #$00 - 09FFDE: AD FA 00 lda $00fa - 09FFE1: 71 00 adc ($00), y - 09FFE3: 8D FA 00 sta $00fa - 09FFE6: C8 iny - 09FFE7: AD FB 00 lda $00fb - 09FFEA: 71 00 adc ($00), y - 09FFEC: 8D FB 00 sta $00fb - 09FFEF: C8 iny - 09FFF0: D0 EC bne $c - 09FFF2: C6 01 dec $01 - 09FFF4: 10 E8 bpl $9ffde - 09FFF6: 0D FA 00 ora $00fa - -- - 09FFF9: D0 03 bne $9fffe - 09FFFB: CE FA 00 dec $00fa - 09FFFE: 80 retf - - + the machines using the '2000' series chips seem to have more extra + opcodes, so presumably these were only available in those models. + of note, push x / push y and pull x / pull y + + Dirt Rebel MX, which is confirmed as 2000 type however seems to require + some of the documented but 'undocumented' opcodes on the 6502 to have additonal + meaning for one specific function on startup + + 01BC37: A0 3F ldy #$3f + 01BC39: B2 ?? + 01BC3A: 1B ?? + 9B ?? + -- outer loop + 01BC3C: 98 tya + 01BC3D: 5B (has to be 1 byte?) + -- inner loop + 01BC3E: A3 (has to be 1 byte) + 73 (could be 3 byte?) + 01BC40: 83 FB presumably fb is the address + 01BC42: A7 (presumably 1 byte) + 73 (could be 3 byte?) + 01BC44: 87 FB presumably fb is the address + 01BC46: D0 F6 bne $1bc3e + 01BC48: 88 dey + 01BC49: 10 F1 bpl $1bc3c + 01BC4B: 8D FB 00 sta $00fb + 01BC4E: A3 ?? + 01BC4F: 8D FA 00 sta $00fa + 01BC52: 07 ?? + -- + 01BC53: D0 03 bne $1bc58 + 01BC55: CE fa 00 dec $00fa + 01BC58: 80 retf + + this is presumably meant to be similar to the function found in Namco + Nostalgia 2 + + 09FFD8: A9 3F lda #$3f + 09FFDA: 85 01 sta $01 + 09FFDC: A0 00 ldy #$00 + 09FFDE: AD FA 00 lda $00fa + 09FFE1: 71 00 adc ($00), y + 09FFE3: 8D FA 00 sta $00fa + 09FFE6: C8 iny + 09FFE7: AD FB 00 lda $00fb + 09FFEA: 71 00 adc ($00), y + 09FFEC: 8D FB 00 sta $00fb + 09FFEF: C8 iny + 09FFF0: D0 EC bne $c + 09FFF2: C6 01 dec $01 + 09FFF4: 10 E8 bpl $9ffde + 09FFF6: 0D FA 00 ora $00fa + -- + 09FFF9: D0 03 bne $9fffe + 09FFFB: CE FA 00 dec $00fa + 09FFFE: 80 retf + + ***************************************************************************/ #include "emu.h" diff --git a/src/devices/cpu/m68000/m68kcpu.cpp b/src/devices/cpu/m68000/m68kcpu.cpp index 7e7b17721ee..1c9240035db 100644 --- a/src/devices/cpu/m68000/m68kcpu.cpp +++ b/src/devices/cpu/m68000/m68kcpu.cpp @@ -1302,7 +1302,7 @@ void m68000_base_device::init32mmu(address_space &space, address_space &ospace) u16 result = m_space->read_byte(address0) << 8; return result | m_space->read_byte(address1); } - + if (WORD_ALIGNED(address)) return m_space->read_word(address); u16 result = m_space->read_byte(address) << 8; diff --git a/src/devices/cpu/sh/sh.h b/src/devices/cpu/sh/sh.h index a78d45e3338..7c84bdffb8a 100644 --- a/src/devices/cpu/sh/sh.h +++ b/src/devices/cpu/sh/sh.h @@ -64,7 +64,7 @@ #define SH_FLAGS (SH_M|SH_Q|SH_I|SH_S|SH_T) /* SR shift values */ -#define T_SHIFT 0 +#define T_SHIFT 0 #define S_SHIFT 1 #define I_SHIFT 4 #define Q_SHIFT 8 diff --git a/src/devices/imagedev/floppy.cpp b/src/devices/imagedev/floppy.cpp index 5ef5668b741..a18308b5f36 100644 --- a/src/devices/imagedev/floppy.cpp +++ b/src/devices/imagedev/floppy.cpp @@ -771,9 +771,10 @@ attotime floppy_image_device::get_next_index_time(std::vector<uint32_t> &buf, in { uint32_t next_position; int cells = buf.size(); - if(index+delta < cells) + if(index+delta < cells) { next_position = buf[index+delta] & floppy_image::TIME_MASK; - else { + + } else { if((buf[cells-1]^buf[0]) & floppy_image::MG_MASK) delta--; index = index + delta - cells + 1; @@ -788,14 +789,6 @@ attotime floppy_image_device::get_next_transition(const attotime &from_when) if(!image || mon) return attotime::never; - // If the drive is still spinning up, pretend that no transitions will come - // TODO: Implement a proper spin-up ramp for transition times, also in order - // to cover potential copy protection measures that have direct device - // access (mz) - // MORE TODO: this breaks the tandy2k and pcjr. needs investigation. - //if (ready_counter > 0) - // return attotime::never; - std::vector<uint32_t> &buf = image->get_buffer(cyl, ss, subcyl); uint32_t cells = buf.size(); if(cells <= 1) @@ -809,10 +802,11 @@ attotime floppy_image_device::get_next_transition(const attotime &from_when) if(index == -1) return attotime::never; - attotime result = get_next_index_time(buf, index, 1, base); - if(result > from_when) - return result; - return get_next_index_time(buf, index, 2, base); + for(unsigned int i=1;; i++) { + attotime result = get_next_index_time(buf, index, i, base); + if(result > from_when) + return result; + } } void floppy_image_device::write_flux(const attotime &start, const attotime &end, int transition_count, const attotime *transitions) diff --git a/src/devices/machine/amigafdc.cpp b/src/devices/machine/amigafdc.cpp index 7b065b1ad44..4217040bd5a 100644 --- a/src/devices/machine/amigafdc.cpp +++ b/src/devices/machine/amigafdc.cpp @@ -442,7 +442,7 @@ void amiga_fdc_device::setup_leds() machine().output().set_value("drive_2_led", drive == 2); machine().output().set_value("drive_3_led", drive == 3); - m_leds[0] = drive == 0 ? 1 : 0; // update internal drive led + m_leds[0] = drive == 0 ? 1 : 0; // update internal drive led m_leds[1] = drive == 1 ? 1 : 0; // update external drive led } } diff --git a/src/devices/machine/fdc37c93x.h b/src/devices/machine/fdc37c93x.h index 57c94c5139a..8638fcfa173 100644 --- a/src/devices/machine/fdc37c93x.h +++ b/src/devices/machine/fdc37c93x.h @@ -182,4 +182,4 @@ DECLARE_DEVICE_TYPE(FDC37C93X, fdc37c93x_device); #define MCFG_FDC37C93X_IRQ9_CB(_devcb) \ devcb = &downcast<fdc37c93x_device &>(*device).set_irq9_callback(DEVCB_##_devcb); -#endif // MAME_MACHINE_FDC37C93X_H
\ No newline at end of file +#endif // MAME_MACHINE_FDC37C93X_H diff --git a/src/devices/machine/pckeybrd.cpp b/src/devices/machine/pckeybrd.cpp index b06611f261f..29559c3cde9 100644 --- a/src/devices/machine/pckeybrd.cpp +++ b/src/devices/machine/pckeybrd.cpp @@ -786,7 +786,7 @@ WRITE8_MEMBER(at_keyboard_device::write) /* bits: 0 scroll lock, 1 num lock, 2 capslock */ /* led's in same order as my keyboard leds. */ - /* num lock, caps lock, scroll lock */ + /* num lock, caps lock, scroll lock */ m_leds[2] = BIT(data, 0); m_leds[0] = BIT(data, 1); m_leds[1] = BIT(data, 2); diff --git a/src/devices/sound/aica.cpp b/src/devices/sound/aica.cpp index fb6a2957bda..ad7d5467c3d 100644 --- a/src/devices/sound/aica.cpp +++ b/src/devices/sound/aica.cpp @@ -1213,7 +1213,7 @@ int32_t aica_device::UpdateSlot(AICA_SLOT *slot) } break; // TODO: causes an hang in Border Down/Metal Slug 6/Karous etc. - // for mslug6 culprit RAM address is 0x13880 ARM side (a flag that should be zeroed somehow) + // for mslug6 culprit RAM address is 0x13880 ARM side (a flag that should be zeroed somehow) case 1: //normal loop if(*addr[addr_select]>=chanlea) { diff --git a/src/devices/video/stvvdp1.cpp b/src/devices/video/stvvdp1.cpp index ccb005fefb3..3bd956600f7 100644 --- a/src/devices/video/stvvdp1.cpp +++ b/src/devices/video/stvvdp1.cpp @@ -1115,7 +1115,7 @@ void saturn_state::stv_vdp1_set_drawpixel( void ) drawpixel = &saturn_state::drawpixel_generic; return; } - + // polygon / polyline / line with replace case if (sprite_type & 4 && ((stv2_current_sprite.CMDPMOD & 0x7) == 0)) { diff --git a/src/devices/video/stvvdp2.cpp b/src/devices/video/stvvdp2.cpp index 7ea66ddac90..14d9d05dd1c 100644 --- a/src/devices/video/stvvdp2.cpp +++ b/src/devices/video/stvvdp2.cpp @@ -2251,7 +2251,7 @@ uint8_t saturn_state::stv_vdp2_is_rotation_applied(void) RP.dx == _FIXED_1 && RP.dy == _FIXED_0 && RP.kx == _FIXED_1 && - RP.ky == _FIXED_1 && + RP.ky == _FIXED_1 && STV_VDP2_RPMD < 2) // disable optimizations if roz mode is 2 or 3 { return 0; @@ -4449,7 +4449,7 @@ void saturn_state::stv_vdp2_check_tilemap(bitmap_rgb32 &bitmap, const rectangle if ( stv2_current_tilemap.linescroll_enable || stv2_current_tilemap.vertical_linescroll_enable || - stv2_current_tilemap.linezoom_enable || + stv2_current_tilemap.linezoom_enable || stv2_current_tilemap.vertical_cell_scroll_enable) { // check for vertical cell scroll enable (Sonic Jam) @@ -4462,11 +4462,11 @@ void saturn_state::stv_vdp2_check_tilemap(bitmap_rgb32 &bitmap, const rectangle int16_t base_scrollx, base_scrolly; //uint32_t base_incx, base_incy; int cur_char = 0; - + base_mask = STV_VDP2_VRAMSZ ? 0x7ffff : 0x3ffff; vcsc_address = (((STV_VDP2_VCSTAU << 16) | STV_VDP2_VCSTAL) & base_mask) * 2; vcsc_address >>= 2; - + base_offset = 0; base_multiplier = 1; // offset for both enabled @@ -4475,26 +4475,26 @@ void saturn_state::stv_vdp2_check_tilemap(bitmap_rgb32 &bitmap, const rectangle // NBG1 if(stv2_current_tilemap.layer_name & 1) base_offset = 1; - + base_multiplier = 2; } - + base_scrollx = stv2_current_tilemap.scrollx; base_scrolly = stv2_current_tilemap.scrolly; //base_incx = stv2_current_tilemap.incx; //base_incy = stv2_current_tilemap.incy; - + while(cur_char <= cliprect.max_x) { mycliprect.min_x = cur_char; mycliprect.max_x = cur_char + 8 - 1; - + uint32_t cur_address; int16_t char_scroll; - + cur_address = vcsc_address; cur_address += ((cur_char >> 3) * base_multiplier) + base_offset; - + char_scroll = m_vdp2_vram[ cur_address ] >> 16; char_scroll &= 0x07ff; if ( char_scroll & 0x0400 ) char_scroll |= 0xf800; @@ -4504,7 +4504,7 @@ void saturn_state::stv_vdp2_check_tilemap(bitmap_rgb32 &bitmap, const rectangle //stv2_current_tilemap.incy = base_incy; stv_vdp2_check_tilemap_with_linescroll(bitmap, mycliprect); - + // TODO: + 16 for tilemap and char size = 16? cur_char += 8; @@ -4512,10 +4512,10 @@ void saturn_state::stv_vdp2_check_tilemap(bitmap_rgb32 &bitmap, const rectangle } else stv_vdp2_check_tilemap_with_linescroll(bitmap, cliprect); - + return; } - + if (stv2_current_tilemap.bitmap_enable) // this layer is a bitmap { stv_vdp2_draw_basic_bitmap(bitmap, mycliprect); @@ -5047,7 +5047,7 @@ inline bool saturn_state::stv_vdp2_roz_mode3_window(int x, int y, int rot_parame uint8_t w1_enable = STV_VDP2_RPW1E; uint8_t w0_area = STV_VDP2_RPW0A; uint8_t w1_area = STV_VDP2_RPW1A; - + if (w0_enable == 0 && w1_enable == 0) return rot_parameter ^ 1; @@ -6508,7 +6508,7 @@ void saturn_state::stv_vdp2_get_window0_coordinates(int *s_x, int *e_x, int *s_y // double density makes the line window to fetch data every two lines uint8_t interlace = (STV_VDP2_LSMD == 3); uint32_t vram_data = m_vdp2_vram[(address >> 2)+(y >> interlace)]; - + *s_x = (vram_data >> 16) & 0x3ff; *e_x = (vram_data & 0x3ff); } @@ -6568,7 +6568,7 @@ void saturn_state::stv_vdp2_get_window1_coordinates(int *s_x, int *e_x, int *s_y // double density makes the line window to fetch data every two lines uint8_t interlace = (STV_VDP2_LSMD == 3); uint32_t vram_data = m_vdp2_vram[(address >> 2)+(y >> interlace)]; - + *s_x = (vram_data >> 16) & 0x3ff; *e_x = (vram_data & 0x3ff); } @@ -6865,7 +6865,7 @@ void saturn_state::draw_sprites(bitmap_rgb32 &bitmap, const rectangle &cliprect, pix &= 0x7ff; pix += color_offset_pal; bitmap_line[x] = m_palette->pen( pix ); - + } } diff --git a/src/devices/video/voodoo.h b/src/devices/video/voodoo.h index e6219e1c091..87cb23b5ede 100644 --- a/src/devices/video/voodoo.h +++ b/src/devices/video/voodoo.h @@ -1483,8 +1483,8 @@ public: uint8_t m_fbmem; uint8_t m_tmumem0; uint8_t m_tmumem1; - devcb_write_line m_vblank; - devcb_write_line m_stall; + devcb_write_line m_vblank; + devcb_write_line m_stall; // This is for internally generated PCI interrupts in Voodoo3 devcb_write_line m_pciint; @@ -1881,7 +1881,7 @@ public: uint8_t index; // index of board screen_device * m_screen; // the screen we are acting on cpu_device * m_cpu; // the CPU we interact with - const uint8_t vd_type; // type of system + const uint8_t vd_type; // type of system uint8_t chipmask; // mask for which chips are available uint32_t freq; // operating frequency attoseconds_t attoseconds_per_cycle; // attoseconds per cycle @@ -1889,8 +1889,8 @@ public: int trigger; // trigger used for stalling voodoo_reg reg[0x400]; // raw registers - const uint8_t * regaccess; // register access array - const char *const * regnames; // register names array + const uint8_t * regaccess; // register access array + const char *const * regnames; // register names array uint8_t alt_regmap; // enable alternate register map? pci_state pci; // PCI state diff --git a/src/devices/video/voodoo_pci.cpp b/src/devices/video/voodoo_pci.cpp index e8f7dad1031..0bb099a2db7 100644 --- a/src/devices/video/voodoo_pci.cpp +++ b/src/devices/video/voodoo_pci.cpp @@ -11,7 +11,7 @@ MACHINE_CONFIG_START(voodoo_1_pci_device::device_add_mconfig) MCFG_VOODOO_FBMEM(4) MCFG_VOODOO_TMUMEM(1, 0) MACHINE_CONFIG_END - + MACHINE_CONFIG_START(voodoo_2_pci_device::device_add_mconfig) MCFG_DEVICE_ADD("voodoo", VOODOO_2, STD_VOODOO_2_CLOCK) MCFG_VOODOO_FBMEM(4) diff --git a/src/emu/devcb.h b/src/emu/devcb.h index 120a5c47163..833d6938a1c 100644 --- a/src/emu/devcb.h +++ b/src/emu/devcb.h @@ -256,7 +256,7 @@ protected: }; // configuration - device_t & m_owner; // reference to our owning device + device_t & m_owner; // reference to our owning device std::reference_wrapper<device_t> m_base; // device to resolve relative to callback_type m_type; // type of callback registered const char * m_target_tag; // tag of target object diff --git a/src/emu/gamedrv.h b/src/emu/gamedrv.h index 6ebbdb20df8..c5ad4bc94f9 100644 --- a/src/emu/gamedrv.h +++ b/src/emu/gamedrv.h @@ -196,7 +196,7 @@ extern game_driver const GAME_NAME(NAME) \ COMPANY, \ [] (machine_config &config, device_t &owner) { downcast<CLASS &>(owner).MACHINE(config); }, \ INPUT_PORTS_NAME(INPUT), \ - [] (device_t &owner) { downcast<CLASS &>(owner).INIT(); }, \ + [] (device_t &owner) { downcast<CLASS &>(owner).INIT(); }, \ ROM_NAME(NAME), \ nullptr, \ nullptr, \ @@ -215,7 +215,7 @@ extern game_driver const GAME_NAME(NAME) \ COMPANY, \ [] (machine_config &config, device_t &owner) { downcast<CLASS &>(owner).MACHINE(config); }, \ INPUT_PORTS_NAME(INPUT), \ - [] (device_t &owner) { downcast<CLASS &>(owner).INIT(); }, \ + [] (device_t &owner) { downcast<CLASS &>(owner).INIT(); }, \ ROM_NAME(NAME), \ nullptr, \ &LAYOUT, \ @@ -235,7 +235,7 @@ extern game_driver const GAME_NAME(NAME) \ COMPANY, \ [] (machine_config &config, device_t &owner) { downcast<CLASS &>(owner).MACHINE(config); }, \ INPUT_PORTS_NAME(INPUT), \ - [] (device_t &owner) { downcast<CLASS &>(owner).INIT(); }, \ + [] (device_t &owner) { downcast<CLASS &>(owner).INIT(); }, \ ROM_NAME(NAME), \ #COMPAT, \ nullptr, \ @@ -254,7 +254,7 @@ extern game_driver const GAME_NAME(NAME) \ COMPANY, \ [] (machine_config &config, device_t &owner) { downcast<CLASS &>(owner).MACHINE(config); }, \ INPUT_PORTS_NAME(INPUT), \ - [] (device_t &owner) { downcast<CLASS &>(owner).INIT(); }, \ + [] (device_t &owner) { downcast<CLASS &>(owner).INIT(); }, \ ROM_NAME(NAME), \ #COMPAT, \ nullptr, \ @@ -273,7 +273,7 @@ extern game_driver const GAME_NAME(NAME) \ COMPANY, \ [] (machine_config &config, device_t &owner) { downcast<CLASS &>(owner).MACHINE(config); }, \ INPUT_PORTS_NAME(INPUT), \ - [] (device_t &owner) { downcast<CLASS &>(owner).INIT(); }, \ + [] (device_t &owner) { downcast<CLASS &>(owner).INIT(); }, \ ROM_NAME(NAME), \ #COMPAT, \ nullptr, \ diff --git a/src/lib/formats/ap2_dsk.cpp b/src/lib/formats/ap2_dsk.cpp index 8e9f37977e9..2cc0e0d0db1 100644 --- a/src/lib/formats/ap2_dsk.cpp +++ b/src/lib/formats/ap2_dsk.cpp @@ -665,7 +665,7 @@ bool a2_16sect_format::load(io_generic *io, uint32_t form_factor, floppy_image * else if (!memcmp(cpm22_block1, §or_data[0x100], 8)) { m_prodos_order = true; - } // check for subnodule disk + } // check for subnodule disk else if (!memcmp(subnod_block1, §or_data[0x100], 8)) { m_prodos_order = true; diff --git a/src/lib/formats/flopimg.cpp b/src/lib/formats/flopimg.cpp index 4ffe3e720ad..3d05ec38d03 100644 --- a/src/lib/formats/flopimg.cpp +++ b/src/lib/formats/flopimg.cpp @@ -1681,34 +1681,44 @@ void floppy_image_format_t::normalize_times(std::vector<uint32_t> &buffer) void floppy_image_format_t::generate_track_from_bitstream(int track, int head, const uint8_t *trackbuf, int track_size, floppy_image *image, int subtrack, int splice) { - if(splice >= track_size) - splice = 0; - std::vector<uint32_t> &dest = image->get_buffer(track, head, subtrack); dest.clear(); + // If the bitstream has an odd number of inversions, one needs to be added. + // Put in in the middle of the half window after the center inversion, where + // any fdc ignores it. + int inversions = 0; for(int i=0; i != track_size; i++) if(trackbuf[i >> 3] & (0x80 >> (i & 7))) inversions++; - int invert_splice = inversions & 1 ? splice : -1; + bool need_flux = inversions & 1; uint32_t cbit = floppy_image::MG_A; uint32_t count = 0; for(int i=0; i != track_size; i++) - if((i == invert_splice) ^ !!(trackbuf[i >> 3] & (0x80 >> (i & 7)))) { - dest.push_back(cbit | (count+1)); + if(trackbuf[i >> 3] & (0x80 >> (i & 7))) { + dest.push_back(cbit | (count+2)); cbit = cbit == floppy_image::MG_A ? floppy_image::MG_B : floppy_image::MG_A; - count = 1; + if(need_flux) { + need_flux = false; + dest.push_back(cbit | 1); + cbit = cbit == floppy_image::MG_A ? floppy_image::MG_B : floppy_image::MG_A; + count = 1; + } else + count = 2; } else - count += 2; + count += 4; if(count) dest.push_back(cbit | count); normalize_times(dest); - int splpos = uint64_t(200000000) * splice / track_size; - image->set_write_splice_position(track, head, splpos, subtrack); + + if(splice >= 0 || splice < track_size) { + int splpos = uint64_t(200000000) * splice / track_size; + image->set_write_splice_position(track, head, splpos, subtrack); + } } void floppy_image_format_t::generate_track_from_levels(int track, int head, std::vector<uint32_t> &trackbuf, int splice_pos, floppy_image *image) diff --git a/src/lib/formats/flopimg.h b/src/lib/formats/flopimg.h index 7617daabdc4..fe6d8ed35dd 100644 --- a/src/lib/formats/flopimg.h +++ b/src/lib/formats/flopimg.h @@ -386,8 +386,8 @@ protected: @param trackbuf track input buffer. @param track_size in cells, not bytes. @param image - @param subtrack subtrack index, 0-3 - @param splice write splice position + @param subtrack subtrack index, 0-3 + @param splice write splice position */ void generate_track_from_bitstream(int track, int head, const uint8_t *trackbuf, int track_size, floppy_image *image, int subtrack = 0, int splice = 0); diff --git a/src/lib/netlist/devices/nlid_system.h b/src/lib/netlist/devices/nlid_system.h index db324a85834..326cd3dbf2c 100644 --- a/src/lib/netlist/devices/nlid_system.h +++ b/src/lib/netlist/devices/nlid_system.h @@ -130,7 +130,7 @@ namespace netlist unsigned long pati[32]; for (int pI = 0; pI < 32; pI++) { - pati[pI] = 0; + pati[pI] = 0; } m_size = static_cast<std::uint8_t>(pat.size()); unsigned long total = 0; diff --git a/src/mame/audio/exidy440.cpp b/src/mame/audio/exidy440.cpp index 491a9e567ce..ee59b122ac9 100644 --- a/src/mame/audio/exidy440.cpp +++ b/src/mame/audio/exidy440.cpp @@ -13,6 +13,8 @@ #include "audio/exidy440.h" #include "includes/exidy440.h" +#include "cpu/m6809/m6809.h" + #define SOUND_LOG 0 #define FADE_TO_ZERO 1 @@ -41,12 +43,35 @@ static const int channel_bits[4] = }; +/************************************* + * + * Audio CPU memory map + * + *************************************/ + +void exidy440_sound_device::exidy440_audio_map(address_map &map) +{ + map(0x0000, 0x7fff).noprw(); + map(0x8000, 0x801f).mirror(0x03e0).rw(this, FUNC(exidy440_sound_device::m6844_r), FUNC(exidy440_sound_device::m6844_w)); + map(0x8400, 0x840f).mirror(0x03f0).rw(this, FUNC(exidy440_sound_device::sound_volume_r), FUNC(exidy440_sound_device::sound_volume_w)); + map(0x8800, 0x8800).mirror(0x03ff).r(this, FUNC(exidy440_sound_device::sound_command_r)).nopw(); + map(0x8c00, 0x93ff).noprw(); + map(0x9400, 0x9403).mirror(0x03fc).nopr().w(this, FUNC(exidy440_sound_device::sound_banks_w)); + map(0x9800, 0x9800).mirror(0x03ff).nopr().w(this, FUNC(exidy440_sound_device::sound_interrupt_clear_w)); + map(0x9c00, 0x9fff).noprw(); + map(0xa000, 0xbfff).ram(); + map(0xc000, 0xdfff).noprw(); + map(0xe000, 0xffff).rom().region("audiocpu", 0); +} + + DEFINE_DEVICE_TYPE(EXIDY440, exidy440_sound_device, "exidy440_sound", "Exidy 440 CVSD") exidy440_sound_device::exidy440_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : device_t(mconfig, EXIDY440, tag, owner, clock), device_sound_interface(mconfig, *this), - m_audiocpu(*this, "^audiocpu"), + m_audiocpu(*this, "audiocpu"), + m_samples(*this, "samples"), m_sound_command(0), m_sound_command_ack(0), m_mixer_buffer_left(nullptr), @@ -70,6 +95,27 @@ exidy440_sound_device::exidy440_sound_device(const machine_config &mconfig, cons } //------------------------------------------------- +// device_add_mconfig - add device configuration +//------------------------------------------------- + +MACHINE_CONFIG_START(exidy440_sound_device::device_add_mconfig) + MCFG_DEVICE_ADD("audiocpu", MC6809, EXIDY440_AUDIO_CLOCK) + MCFG_DEVICE_PROGRAM_MAP(exidy440_audio_map) + +// MCFG_DEVICE_ADD("cvsd1", MC3418, EXIDY440_MC3418_CLOCK) +// MCFG_SOUND_ROUTE(ALL_OUTPUTS, "lspeaker", 1.0) + +// MCFG_DEVICE_ADD("cvsd2", MC3418, EXIDY440_MC3418_CLOCK) +// MCFG_SOUND_ROUTE(ALL_OUTPUTS, "rspeaker", 1.0) + +// MCFG_DEVICE_ADD("cvsd3", MC3417, EXIDY440_MC3417_CLOCK) +// MCFG_SOUND_ROUTE(ALL_OUTPUTS, "lspeaker", 1.0) + +// MCFG_DEVICE_ADD("cvsd4", MC3417, EXIDY440_MC3417_CLOCK) +// MCFG_SOUND_ROUTE(ALL_OUTPUTS, "rspeaker", 1.0) +MACHINE_CONFIG_END + +//------------------------------------------------- // device_start - device-specific startup //------------------------------------------------- @@ -106,7 +152,7 @@ void exidy440_sound_device::device_start() m_stream = machine().sound().stream_alloc(*this, 0, 2, clock()); /* allocate the sample cache */ - length = machine().root_device().memregion("cvsd")->bytes() * 16 + MAX_CACHE_ENTRIES * sizeof(sound_cache_entry); + length = m_samples.bytes() * 16 + MAX_CACHE_ENTRIES * sizeof(sound_cache_entry); m_sound_cache = (sound_cache_entry *)auto_alloc_array_clear(machine(), uint8_t, length); /* determine the hard end of the cache and reset */ @@ -208,10 +254,10 @@ void exidy440_sound_device::mix_to_16(int length, stream_sample_t *dest_left, st * *************************************/ -READ8_MEMBER( exidy440_sound_device::sound_command_r ) +READ8_MEMBER(exidy440_sound_device::sound_command_r) { /* clear the FIRQ that got us here and acknowledge the read to the main CPU */ - m_audiocpu->set_input_line(1, CLEAR_LINE); + m_audiocpu->set_input_line(M6809_FIRQ_LINE, CLEAR_LINE); m_sound_command_ack = 1; return m_sound_command; @@ -222,7 +268,7 @@ void exidy440_sound_device::exidy440_sound_command(uint8_t param) { m_sound_command = param; m_sound_command_ack = 0; - m_audiocpu->set_input_line(INPUT_LINE_IRQ1, ASSERT_LINE); + m_audiocpu->set_input_line(M6809_FIRQ_LINE, ASSERT_LINE); } @@ -239,12 +285,12 @@ uint8_t exidy440_sound_device::exidy440_sound_command_ack() * *************************************/ -READ8_MEMBER( exidy440_sound_device::sound_volume_r ) +READ8_MEMBER(exidy440_sound_device::sound_volume_r) { return m_sound_volume[offset]; } -WRITE8_MEMBER( exidy440_sound_device::sound_volume_w ) +WRITE8_MEMBER(exidy440_sound_device::sound_volume_w) { if (SOUND_LOG && m_debuglog) fprintf(m_debuglog, "Volume %02X=%02X\n", offset, data); @@ -264,9 +310,20 @@ WRITE8_MEMBER( exidy440_sound_device::sound_volume_w ) * *************************************/ -WRITE8_MEMBER( exidy440_sound_device::sound_interrupt_clear_w ) +WRITE_LINE_MEMBER(exidy440_sound_device::sound_interrupt_w) +{ + if (state) + m_audiocpu->set_input_line(M6809_IRQ_LINE, ASSERT_LINE); +} + +WRITE8_MEMBER(exidy440_sound_device::sound_interrupt_clear_w) +{ + m_audiocpu->set_input_line(M6809_IRQ_LINE, CLEAR_LINE); +} + +WRITE_LINE_MEMBER(exidy440_sound_device::sound_reset_w) { - m_audiocpu->set_input_line(0, CLEAR_LINE); + m_audiocpu->set_input_line(INPUT_LINE_RESET, state); } @@ -306,7 +363,7 @@ void exidy440_sound_device::m6844_finished(m6844_channel_data *channel) * *************************************/ -READ8_MEMBER( exidy440_sound_device::m6844_r ) +READ8_MEMBER(exidy440_sound_device::m6844_r) { m6844_channel_data *m6844_channel = m_m6844_channel; int result = 0; @@ -391,7 +448,7 @@ READ8_MEMBER( exidy440_sound_device::m6844_r ) } -WRITE8_MEMBER( exidy440_sound_device::m6844_w ) +WRITE8_MEMBER(exidy440_sound_device::m6844_w) { m6844_channel_data *m6844_channel = m_m6844_channel; int i; @@ -543,7 +600,7 @@ int16_t *exidy440_sound_device::find_or_add_to_sound_cache(int address, int leng if (current->address == address && current->length == length && current->bits == bits && current->frequency == frequency) return current->data; - return add_to_sound_cache(&machine().root_device().memregion("cvsd")->base()[address], address, length, bits, frequency); + return add_to_sound_cache(&m_samples[address], address, length, bits, frequency); } @@ -776,7 +833,7 @@ void exidy440_sound_device::decode_and_filter_cvsd(uint8_t *input, int bytes, in } -WRITE8_MEMBER( exidy440_sound_device::sound_banks_w ) +WRITE8_MEMBER(exidy440_sound_device::sound_banks_w) { m_sound_banks[offset] = data; } diff --git a/src/mame/audio/exidy440.h b/src/mame/audio/exidy440.h index 45831b282eb..b7ce86da71e 100644 --- a/src/mame/audio/exidy440.h +++ b/src/mame/audio/exidy440.h @@ -5,24 +5,32 @@ #pragma once +#define EXIDY440_AUDIO_CLOCK (XTAL(12'979'200) / 4) +#define EXIDY440_MC3418_CLOCK (EXIDY440_AUDIO_CLOCK / 4 / 16) +#define EXIDY440_MC3417_CLOCK (EXIDY440_AUDIO_CLOCK / 4 / 32) + + class exidy440_sound_device : public device_t, public device_sound_interface { public: exidy440_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); ~exidy440_sound_device() {} - DECLARE_READ8_MEMBER( sound_command_r ); - DECLARE_READ8_MEMBER( sound_volume_r ); - DECLARE_WRITE8_MEMBER( sound_volume_w ); - DECLARE_WRITE8_MEMBER( sound_interrupt_clear_w ); - DECLARE_READ8_MEMBER( m6844_r ); - DECLARE_WRITE8_MEMBER( m6844_w ); - DECLARE_WRITE8_MEMBER( sound_banks_w ); + DECLARE_READ8_MEMBER(sound_command_r); + DECLARE_READ8_MEMBER(sound_volume_r); + DECLARE_WRITE8_MEMBER(sound_volume_w); + DECLARE_WRITE_LINE_MEMBER(sound_interrupt_w); + DECLARE_WRITE8_MEMBER(sound_interrupt_clear_w); + DECLARE_WRITE_LINE_MEMBER(sound_reset_w); + DECLARE_READ8_MEMBER(m6844_r); + DECLARE_WRITE8_MEMBER(m6844_w); + DECLARE_WRITE8_MEMBER(sound_banks_w); void exidy440_sound_command(uint8_t param); uint8_t exidy440_sound_command_ack(); protected: // device-level overrides + virtual void device_add_mconfig(machine_config &config) override; virtual void device_start() override; virtual void device_stop() override; @@ -30,6 +38,8 @@ protected: virtual void sound_stream_update(sound_stream &stream, stream_sample_t **inputs, stream_sample_t **outputs, int samples) override; private: + void exidy440_audio_map(address_map &map); + /* channel_data structure holds info about each 6844 DMA channel */ struct m6844_channel_data { @@ -63,6 +73,7 @@ private: }; required_device<cpu_device> m_audiocpu; + required_region_ptr<uint8_t> m_samples; // internal state uint8_t m_sound_command; diff --git a/src/mame/drivers/a7150.cpp b/src/mame/drivers/a7150.cpp index e131c8fc68f..bf2344c299d 100644 --- a/src/mame/drivers/a7150.cpp +++ b/src/mame/drivers/a7150.cpp @@ -22,6 +22,7 @@ #include "emu.h" #include "cpu/i86/i86.h" +#include "machine/i8087.h" #include "machine/i8251.h" #include "machine/i8255.h" #include "machine/pit8253.h" @@ -29,6 +30,7 @@ #include "machine/bankdev.h" #include "cpu/z80/z80.h" +#include "machine/clock.h" #include "machine/z80ctc.h" #include "machine/z80sio.h" @@ -58,6 +60,7 @@ public: , m_pic8259(*this, "pic8259") , m_gfxcpu(*this, "gfxcpu") , m_ctc(*this, Z80CTC_TAG) + , m_rs232(*this, "rs232") , m_video_ram(*this, "video_ram") , m_video_bankdev(*this, "video_bankdev") , m_palette(*this, "palette") @@ -72,14 +75,19 @@ public: DECLARE_WRITE_LINE_MEMBER(a7150_tmr2_w); DECLARE_WRITE8_MEMBER(ppi_c_w); + DECLARE_WRITE_LINE_MEMBER(ifss_write_txd); + DECLARE_WRITE_LINE_MEMBER(ifss_write_dtr); + DECLARE_READ8_MEMBER(kgs_host_r); DECLARE_WRITE8_MEMBER(kgs_host_w); DECLARE_WRITE_LINE_MEMBER(kgs_iml_w); + DECLARE_WRITE_LINE_MEMBER(ifss_loopback_w); DECLARE_WRITE8_MEMBER(kbd_put); void kgs_memory_remap(); bool m_kgs_msel, m_kgs_iml; uint8_t m_kgs_datao, m_kgs_datai, m_kgs_ctrl; + bool m_ifss_loopback; uint32_t screen_update_k7072(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect); void screen_eof(screen_device &screen, bool state); @@ -91,6 +99,7 @@ public: required_device<z80_device> m_gfxcpu; required_device<z80ctc_device> m_ctc; + required_device<rs232_port_device> m_rs232; required_shared_ptr<uint8_t> m_video_ram; required_device<address_map_bank_device> m_video_bankdev; required_device<palette_device> m_palette; @@ -136,15 +145,33 @@ WRITE_LINE_MEMBER(a7150_state::a7150_tmr2_w) m_uart8251->write_txc(state); } +WRITE_LINE_MEMBER(a7150_state::ifss_loopback_w) +{ + m_ifss_loopback = !state; +} + +WRITE_LINE_MEMBER(a7150_state::ifss_write_txd) +{ + if (m_ifss_loopback) + m_uart8251->write_rxd(state); + else + m_rs232->write_txd(state); +} + +WRITE_LINE_MEMBER(a7150_state::ifss_write_dtr) +{ + if (m_ifss_loopback) + m_uart8251->write_dsr(state); + else + m_rs232->write_dtr(state); +} + WRITE8_MEMBER(a7150_state::ppi_c_w) { // b0 -- INTR(B) // b1 -- /OBF(B) // m_centronics->write_ack(BIT(data, 2)); // m_centronics->write_strobe(BIT(data, 3)); - // b4 -- serial loopback? - // b6 - // b7 } #define KGS_ST_OBF 0x01 @@ -411,6 +438,7 @@ void a7150_state::machine_reset() m_kgs_ctrl = 3; m_kgs_datao = m_kgs_datai = 0; m_kgs_iml = m_kgs_msel = 0; + m_ifss_loopback = false; kgs_memory_remap(); } @@ -439,6 +467,14 @@ MACHINE_CONFIG_START(a7150_state::a7150) MCFG_DEVICE_PROGRAM_MAP(a7150_mem) MCFG_DEVICE_IO_MAP(a7150_io) MCFG_DEVICE_IRQ_ACKNOWLEDGE_DEVICE("pic8259", pic8259_device, inta_cb) + MCFG_I8086_ESC_OPCODE_HANDLER(WRITE32("i8087", i8087_device, insn_w)) + MCFG_I8086_ESC_DATA_HANDLER(WRITE32("i8087", i8087_device, addr_w)) + + MCFG_DEVICE_ADD("i8087", I8087, XTAL(9'832'000)/2) + MCFG_DEVICE_PROGRAM_MAP(a7150_mem) + MCFG_I8087_DATA_WIDTH(16) + MCFG_I8087_INT_HANDLER(WRITELINE("pic8259", pic8259_device, ir0_w)) + MCFG_I8087_BUSY_HANDLER(INPUTLINE("maincpu", INPUT_LINE_TEST)) MCFG_DEVICE_ADD("pic8259", PIC8259, 0) MCFG_PIC8259_OUT_INT_CB(INPUTLINE("maincpu", 0)) @@ -457,14 +493,14 @@ MACHINE_CONFIG_START(a7150_state::a7150) MCFG_PIT8253_OUT2_HANDLER(WRITELINE(*this, a7150_state, a7150_tmr2_w)) MCFG_DEVICE_ADD("uart8251", I8251, 0) - MCFG_I8251_TXD_HANDLER(WRITELINE("rs232", rs232_port_device, write_txd)) - MCFG_I8251_DTR_HANDLER(WRITELINE("rs232", rs232_port_device, write_dtr)) - MCFG_I8251_RTS_HANDLER(WRITELINE("rs232", rs232_port_device, write_rts)) + MCFG_I8251_TXD_HANDLER(WRITELINE(*this, a7150_state, ifss_write_txd)) + MCFG_I8251_DTR_HANDLER(WRITELINE(*this, a7150_state, ifss_write_dtr)) + MCFG_I8251_RTS_HANDLER(WRITELINE(*this, a7150_state, ifss_loopback_w)) MCFG_I8251_RXRDY_HANDLER(WRITELINE("pic8259", pic8259_device, ir4_w)) MCFG_I8251_TXRDY_HANDLER(WRITELINE("pic8259", pic8259_device, ir4_w)) // IFSS port on processor card -- keyboard runs at 28800 8N2 - MCFG_DEVICE_ADD("rs232", RS232_PORT, default_rs232_devices, "keyboard") // "loopback" allows ACT to pass + MCFG_DEVICE_ADD("rs232", RS232_PORT, default_rs232_devices, "keyboard") MCFG_RS232_RXD_HANDLER(WRITELINE("uart8251", i8251_device, write_rxd)) MCFG_RS232_CTS_HANDLER(WRITELINE("uart8251", i8251_device, write_cts)) MCFG_RS232_DSR_HANDLER(WRITELINE("uart8251", i8251_device, write_dsr)) @@ -486,13 +522,19 @@ MACHINE_CONFIG_START(a7150_state::a7150) MCFG_ADDRESS_MAP_BANK_DATA_WIDTH(8) MCFG_ADDRESS_MAP_BANK_STRIDE(0x10000) + MCFG_DEVICE_ADD("ctc_clock", CLOCK, 1230750) + MCFG_CLOCK_SIGNAL_HANDLER(WRITELINE(Z80CTC_TAG, z80ctc_device, trg0)) + MCFG_DEVCB_CHAIN_OUTPUT(WRITELINE(Z80CTC_TAG, z80ctc_device, trg1)) + MCFG_DEVCB_CHAIN_OUTPUT(WRITELINE(Z80CTC_TAG, z80ctc_device, trg2)) + MCFG_DEVCB_CHAIN_OUTPUT(WRITELINE(Z80CTC_TAG, z80ctc_device, trg3)) + MCFG_DEVICE_ADD(Z80CTC_TAG, Z80CTC, XTAL(16'000'000)/3) MCFG_Z80CTC_INTR_CB(INPUTLINE("gfxcpu", INPUT_LINE_IRQ0)) MCFG_Z80CTC_ZC0_CB(WRITELINE(Z80SIO_TAG, z80sio_device, rxca_w)) MCFG_DEVCB_CHAIN_OUTPUT(WRITELINE(Z80SIO_TAG, z80sio_device, txca_w)) MCFG_Z80CTC_ZC1_CB(WRITELINE(Z80SIO_TAG, z80sio_device, rxtxcb_w)) - MCFG_DEVICE_ADD(Z80SIO_TAG, Z80SIO, 4800) + MCFG_DEVICE_ADD(Z80SIO_TAG, Z80SIO, XTAL(16'000'000)/4) MCFG_Z80SIO_OUT_INT_CB(INPUTLINE("gfxcpu", INPUT_LINE_IRQ0)) MCFG_Z80SIO_OUT_TXDA_CB(WRITELINE(RS232_A_TAG, rs232_port_device, write_txd)) MCFG_Z80SIO_OUT_DTRA_CB(WRITELINE(RS232_A_TAG, rs232_port_device, write_dtr)) @@ -502,13 +544,13 @@ MACHINE_CONFIG_START(a7150_state::a7150) // MCFG_Z80SIO_OUT_RTSB_CB(WRITELINE(*this, a7150_state, kgs_ifss_loopback_w)) // V.24 port (graphics tablet) - MCFG_DEVICE_ADD(RS232_A_TAG, RS232_PORT, default_rs232_devices, nullptr) + MCFG_DEVICE_ADD(RS232_A_TAG, RS232_PORT, default_rs232_devices, "loopback") MCFG_RS232_RXD_HANDLER(WRITELINE(Z80SIO_TAG, z80sio_device, rxa_w)) MCFG_RS232_DCD_HANDLER(WRITELINE(Z80SIO_TAG, z80sio_device, dcda_w)) MCFG_RS232_CTS_HANDLER(WRITELINE(Z80SIO_TAG, z80sio_device, ctsa_w)) // IFSS (current loop) port (keyboard) - MCFG_DEVICE_ADD(RS232_B_TAG, RS232_PORT, default_rs232_devices, nullptr) + MCFG_DEVICE_ADD(RS232_B_TAG, RS232_PORT, default_rs232_devices, "loopback") MCFG_RS232_RXD_HANDLER(WRITELINE(Z80SIO_TAG, z80sio_device, rxb_w)) MCFG_SCREEN_ADD_MONOCHROME("screen", RASTER, rgb_t::green()) diff --git a/src/mame/drivers/abc80x.cpp b/src/mame/drivers/abc80x.cpp index 2e44e449a83..95783abd92a 100644 --- a/src/mame/drivers/abc80x.cpp +++ b/src/mame/drivers/abc80x.cpp @@ -141,8 +141,8 @@ Notes: TODO: - - abc802 video is all black - - abc850 is broken + - abc802 video is all black + - abc850 is broken - cassette */ @@ -266,13 +266,13 @@ void abc806_state::read_pal_p4(offs_t offset, bool m1l, bool xml, offs_t &m, boo vr = 1; } /* - if (!m1l && (offset < 0x7800) - { - TODO 0..30k read from videoram if fetch opcode from 7800-7fff - romd = 1; - hre = 1; - mux = 0; - } + if (!m1l && (offset < 0x7800) + { + TODO 0..30k read from videoram if fetch opcode from 7800-7fff + romd = 1; + hre = 1; + mux = 0; + } */ size_t videoram_mask = m_ram->size() - 0x8001; diff --git a/src/mame/drivers/amaticmg.cpp b/src/mame/drivers/amaticmg.cpp index 92f9ab708ea..cfbc40e8dd0 100644 --- a/src/mame/drivers/amaticmg.cpp +++ b/src/mame/drivers/amaticmg.cpp @@ -1141,7 +1141,7 @@ ROM_END Description: 4096 bit read/write nonvolatile memory partitioned into sixteen pages of 256 bits each and a real time - clock/calendar in binary format. + clock/calendar in binary format. SCRATCHPAD: Page0 (0H) diff --git a/src/mame/drivers/arkanoid.cpp b/src/mame/drivers/arkanoid.cpp index 7298d14a966..9662ba1ed99 100644 --- a/src/mame/drivers/arkanoid.cpp +++ b/src/mame/drivers/arkanoid.cpp @@ -2126,14 +2126,14 @@ void arkanoid_state::init_block2() { // combine these into a single swap.. int srctile = bitswap<16>(tile,15,14,13,12, - 11,10, 9, 8, - 7, 5, 6, 3, - 1, 2, 4, 0); + 11,10, 9, 8, + 7, 5, 6, 3, + 1, 2, 4, 0); srctile = bitswap<16>(srctile,15,14,13,12, - 11, 9,10, 5, - 7, 6, 8, 4, - 3, 2, 1, 0); + 11, 9,10, 5, + 7, 6, 8, 4, + 3, 2, 1, 0); srctile = srctile ^ 0xd4; diff --git a/src/mame/drivers/atari_s1.cpp b/src/mame/drivers/atari_s1.cpp index 037996c9080..7b4e6849dbc 100644 --- a/src/mame/drivers/atari_s1.cpp +++ b/src/mame/drivers/atari_s1.cpp @@ -75,6 +75,10 @@ public: , m_digits(*this, "digit%u", 0U) { } + void midearth(machine_config &config); + void atari_s1(machine_config &config); + void atarians(machine_config &config); +protected: DECLARE_READ8_MEMBER(m1080_r); DECLARE_WRITE8_MEMBER(m1080_w); DECLARE_READ8_MEMBER(m1084_r); @@ -90,9 +94,6 @@ public: DECLARE_WRITE8_MEMBER(midearth_w); TIMER_DEVICE_CALLBACK_MEMBER(nmi); TIMER_DEVICE_CALLBACK_MEMBER(timer_s); - void midearth(machine_config &config); - void atari_s1(machine_config &config); - void atarians(machine_config &config); void atari_s1_map(address_map &map); void atarians_map(address_map &map); void midearth_map(address_map &map); diff --git a/src/mame/drivers/atarist.cpp b/src/mame/drivers/atarist.cpp index 7c57703c956..b18f91a298c 100644 --- a/src/mame/drivers/atarist.cpp +++ b/src/mame/drivers/atarist.cpp @@ -1701,9 +1701,9 @@ WRITE8_MEMBER( st_state::psg_pa_w ) // drive select floppy_image_device *floppy = nullptr; if (!BIT(data, 1)) - floppy = floppy_devices[0]; + floppy = m_floppy[0]->get_device(); else if(!BIT(data, 2)) - floppy = floppy_devices[1]; + floppy = m_floppy[1]->get_device(); // side select if(floppy) @@ -1745,9 +1745,9 @@ WRITE8_MEMBER( stbook_state::psg_pa_w ) // drive select floppy_image_device *floppy = nullptr; if (!BIT(data, 1)) - floppy = floppy_devices[0]; + floppy = m_floppy[0]->get_device(); else if(!BIT(data, 2)) - floppy = floppy_devices[1]; + floppy = m_floppy[1]->get_device(); // side select if(floppy) @@ -1908,15 +1908,6 @@ void st_state::machine_start() // register for state saving state_save(); - static const char *names[] = { WD1772_TAG ":0", WD1772_TAG ":1" }; - for(int i=0; i != 2; i++) { - floppy_connector *con = machine().device<floppy_connector>(names[i]); - if(con) - floppy_devices[i] = con->get_device(); - else - floppy_devices[i] = nullptr; - } - /// TODO: get callbacks to trigger these. m_mfp->i0_w(1); m_mfp->i5_w(1); diff --git a/src/mame/drivers/battlane.cpp b/src/mame/drivers/battlane.cpp index 948c1217769..70e7f17508f 100644 --- a/src/mame/drivers/battlane.cpp +++ b/src/mame/drivers/battlane.cpp @@ -53,8 +53,8 @@ WRITE8_MEMBER(battlane_state::battlane_cpu_command_w) /* if (~m_cpu_control & 0x08) { - m_maincpu->pulse_input_line(INPUT_LINE_NMI, attotime::zero); - m_subcpu->pulse_input_line(INPUT_LINE_NMI, attotime::zero); + m_maincpu->pulse_input_line(INPUT_LINE_NMI, attotime::zero); + m_subcpu->pulse_input_line(INPUT_LINE_NMI, attotime::zero); } */ diff --git a/src/mame/drivers/blitz68k.cpp b/src/mame/drivers/blitz68k.cpp index 90d58cc85da..3e362607057 100644 --- a/src/mame/drivers/blitz68k.cpp +++ b/src/mame/drivers/blitz68k.cpp @@ -74,6 +74,7 @@ public: , m_leds2(*this, "leds2") , m_maincpu(*this, "maincpu") , m_palette(*this, "palette") + , m_crtc(*this, "crtc") , m_led(*this, "led%u", 0U) { } @@ -209,6 +210,7 @@ protected: optional_shared_ptr<uint16_t> m_leds2; required_device<cpu_device> m_maincpu; required_device<palette_device> m_palette; + optional_device<mc6845_device> m_crtc; output_finder<17> m_led; }; @@ -774,8 +776,8 @@ void blitz68k_state::bankrob_map(address_map &map) map(0x400005, 0x400005).rw(this, FUNC(blitz68k_state::bankrob_mcu1_r), FUNC(blitz68k_state::bankrob_mcu1_w)); map(0x400006, 0x400006).rw(this, FUNC(blitz68k_state::bankrob_mcu2_r), FUNC(blitz68k_state::bankrob_mcu2_w)); - map(0x800000, 0x800000).rw("crtc", FUNC(mc6845_device::status_r), FUNC(mc6845_device::address_w)); // triggered by MCU? - map(0x800002, 0x800002).rw("crtc", FUNC(mc6845_device::register_r), FUNC(mc6845_device::register_w)); + map(0x800000, 0x800000).rw(m_crtc, FUNC(mc6845_device::status_r), FUNC(mc6845_device::address_w)); // triggered by MCU? + map(0x800002, 0x800002).rw(m_crtc, FUNC(mc6845_device::register_r), FUNC(mc6845_device::register_w)); } // bankroba: @@ -918,28 +920,25 @@ WRITE16_MEMBER(blitz68k_state::cjffruit_leds3_w) // CRTC READ8_MEMBER(blitz68k_state::crtc_r) { - mc6845_device *mc6845 = machine().device<mc6845_device>("crtc"); if (offset) - return mc6845->register_r(space, 0); + return m_crtc->register_r(space, 0); else - return mc6845->status_r(space, 0); + return m_crtc->status_r(space, 0); } WRITE8_MEMBER(blitz68k_state::crtc_w) { - mc6845_device *mc6845 = machine().device<mc6845_device>("crtc"); if (offset) - mc6845->register_w(space, 0, data); + m_crtc->register_w(space, 0, data); else - mc6845->address_w(space, 0, data); + m_crtc->address_w(space, 0, data); } WRITE16_MEMBER(blitz68k_state::crtc_lpen_w) { - device_t *device = machine().device("crtc"); // 8fe0006: 0->1 if (ACCESSING_BITS_8_15 && (data & 0x0100)) - downcast<mc6845_device *>(device)->assert_light_pen_input(); + m_crtc->assert_light_pen_input(); // 8fe0007: 1->0 (MCU irq?) } @@ -1182,8 +1181,8 @@ void blitz68k_state::dualgame_map(address_map &map) map(0x400005, 0x400005).rw(this, FUNC(blitz68k_state::dualgame_mcu1_r), FUNC(blitz68k_state::dualgame_mcu1_w)); map(0x400006, 0x400006).rw(this, FUNC(blitz68k_state::dualgame_mcu2_r), FUNC(blitz68k_state::dualgame_mcu2_w)); - map(0x800000, 0x800000).rw("crtc", FUNC(mc6845_device::status_r), FUNC(mc6845_device::address_w)); - map(0x800002, 0x800002).rw("crtc", FUNC(mc6845_device::register_r), FUNC(mc6845_device::register_w)); + map(0x800000, 0x800000).rw(m_crtc, FUNC(mc6845_device::status_r), FUNC(mc6845_device::address_w)); + map(0x800002, 0x800002).rw(m_crtc, FUNC(mc6845_device::register_r), FUNC(mc6845_device::register_w)); } /************************************************************************************************************* @@ -1325,8 +1324,8 @@ void blitz68k_state::maxidbl_map(address_map &map) map(0x500005, 0x500005).rw(this, FUNC(blitz68k_state::maxidbl_mcu1_r), FUNC(blitz68k_state::maxidbl_mcu1_w)); map(0x500006, 0x500006).rw(this, FUNC(blitz68k_state::maxidbl_mcu2_r), FUNC(blitz68k_state::maxidbl_mcu2_w)); - map(0x600000, 0x600000).rw("crtc", FUNC(mc6845_device::status_r), FUNC(mc6845_device::address_w)); // triggered by MCU? - map(0x600002, 0x600002).rw("crtc", FUNC(mc6845_device::register_r), FUNC(mc6845_device::register_w)); + map(0x600000, 0x600000).rw(m_crtc, FUNC(mc6845_device::status_r), FUNC(mc6845_device::address_w)); // triggered by MCU? + map(0x600002, 0x600002).rw(m_crtc, FUNC(mc6845_device::register_r), FUNC(mc6845_device::register_w)); } @@ -1711,7 +1710,7 @@ void blitz68k_state::ramdac_map(address_map &map) } MACHINE_CONFIG_START(blitz68k_state::ilpag) - MCFG_DEVICE_ADD("maincpu", M68000, 11059200 ) // ? + MCFG_DEVICE_ADD(m_maincpu, M68000, 11059200 ) // ? MCFG_DEVICE_PROGRAM_MAP(ilpag_map) MCFG_DEVICE_VBLANK_INT_DRIVER("screen", blitz68k_state, irq4_line_hold) //3 & 6 used, mcu comms? @@ -1724,7 +1723,7 @@ MACHINE_CONFIG_START(blitz68k_state::ilpag) MCFG_NVRAM_ADD_0FILL("nvram") - MCFG_PALETTE_ADD("palette", 0x100) + MCFG_PALETTE_ADD(m_palette, 0x100) MCFG_VIDEO_START_OVERRIDE(blitz68k_state,blitz68k) @@ -1779,7 +1778,7 @@ MACHINE_CONFIG_START(blitz68k_state::steaser) MACHINE_CONFIG_END MACHINE_CONFIG_START(blitz68k_state::cjffruit) - MCFG_DEVICE_ADD("maincpu", M68000, XTAL(22'118'400)/2) + MCFG_DEVICE_ADD(m_maincpu, M68000, XTAL(22'118'400)/2) MCFG_DEVICE_PROGRAM_MAP(cjffruit_map) // MC68HC705C8P (Sound MCU) @@ -1793,13 +1792,13 @@ MACHINE_CONFIG_START(blitz68k_state::cjffruit) MCFG_SCREEN_VISIBLE_AREA(0, 512-1, 0, 256-8-1) MCFG_SCREEN_UPDATE_DRIVER(blitz68k_state, screen_update_blitz68k) - MCFG_MC6845_ADD("crtc", R6545_1, "screen", XTAL(22'118'400)/8) + MCFG_MC6845_ADD(m_crtc, R6545_1, "screen", XTAL(22'118'400)/8) MCFG_MC6845_SHOW_BORDER_AREA(false) MCFG_MC6845_CHAR_WIDTH(4) MCFG_MC6845_ADDR_CHANGED_CB(blitz68k_state, crtc_addr) MCFG_MC6845_OUT_VSYNC_CB(WRITELINE(*this, blitz68k_state, crtc_vsync_irq1)) - MCFG_PALETTE_ADD("palette", 0x100) + MCFG_PALETTE_ADD(m_palette, 0x100) MCFG_VIDEO_START_OVERRIDE(blitz68k_state,blitz68k) MCFG_RAMDAC_ADD("ramdac", ramdac_map, "palette") @@ -1807,7 +1806,7 @@ MACHINE_CONFIG_END MACHINE_CONFIG_START(blitz68k_state::bankrob) - MCFG_DEVICE_ADD("maincpu", M68000, XTAL(11'059'200)) + MCFG_DEVICE_ADD(m_maincpu, M68000, XTAL(11'059'200)) MCFG_DEVICE_PROGRAM_MAP(bankrob_map) MCFG_DEVICE_VBLANK_INT_DRIVER("screen", blitz68k_state, irq3_line_hold) // protection prevents correct irq frequency by crtc // irq 2 reads from MCUs @@ -1825,13 +1824,13 @@ MACHINE_CONFIG_START(blitz68k_state::bankrob) MCFG_SCREEN_VISIBLE_AREA(0, 512-1, 0+4, 256-1-4) MCFG_SCREEN_UPDATE_DRIVER(blitz68k_state, screen_update_blitz68k) - MCFG_MC6845_ADD("crtc", H46505, "screen", XTAL(11'059'200)/4) + MCFG_MC6845_ADD(m_crtc, H46505, "screen", XTAL(11'059'200)/4) MCFG_MC6845_SHOW_BORDER_AREA(false) MCFG_MC6845_CHAR_WIDTH(4) MCFG_MC6845_ADDR_CHANGED_CB(blitz68k_state, crtc_addr) MCFG_MC6845_OUT_VSYNC_CB(WRITELINE(*this, blitz68k_state, crtc_vsync_irq3)) - MCFG_PALETTE_ADD("palette", 0x100) + MCFG_PALETTE_ADD(m_palette, 0x100) MCFG_VIDEO_START_OVERRIDE(blitz68k_state,blitz68k) MCFG_RAMDAC_ADD("ramdac", ramdac_map, "palette") @@ -1839,7 +1838,7 @@ MACHINE_CONFIG_END MACHINE_CONFIG_START(blitz68k_state::bankroba) - MCFG_DEVICE_ADD("maincpu", M68000, XTAL(11'059'200) ) + MCFG_DEVICE_ADD(m_maincpu, M68000, XTAL(11'059'200) ) MCFG_DEVICE_PROGRAM_MAP(bankroba_map) MCFG_DEVICE_VBLANK_INT_DRIVER("screen", blitz68k_state, irq5_line_hold) // protection prevents correct irq frequency by crtc // irq 3,4 read from MCUs @@ -1855,13 +1854,13 @@ MACHINE_CONFIG_START(blitz68k_state::bankroba) MCFG_SCREEN_VISIBLE_AREA(0, 512-1, 0+7, 256-1) MCFG_SCREEN_UPDATE_DRIVER(blitz68k_state, screen_update_blitz68k) - MCFG_MC6845_ADD("crtc", H46505, "screen", XTAL(11'059'200)/4) + MCFG_MC6845_ADD(m_crtc, H46505, "screen", XTAL(11'059'200)/4) MCFG_MC6845_SHOW_BORDER_AREA(false) MCFG_MC6845_CHAR_WIDTH(4) MCFG_MC6845_ADDR_CHANGED_CB(blitz68k_state, crtc_addr) MCFG_MC6845_OUT_VSYNC_CB(WRITELINE(*this, blitz68k_state, crtc_vsync_irq5)) - MCFG_PALETTE_ADD("palette", 0x100) + MCFG_PALETTE_ADD(m_palette, 0x100) MCFG_VIDEO_START_OVERRIDE(blitz68k_state,blitz68k_addr_factor1) MCFG_RAMDAC_ADD("ramdac", ramdac_map, "palette") @@ -1869,7 +1868,7 @@ MACHINE_CONFIG_END MACHINE_CONFIG_START(blitz68k_state::deucesw2) - MCFG_DEVICE_ADD("maincpu", M68000, XTAL(22'118'400) / 2) + MCFG_DEVICE_ADD(m_maincpu, M68000, XTAL(22'118'400) / 2) MCFG_DEVICE_PROGRAM_MAP(deucesw2_map) // irq 2 reads from MCUs @@ -1884,13 +1883,13 @@ MACHINE_CONFIG_START(blitz68k_state::deucesw2) MCFG_SCREEN_VISIBLE_AREA(0, 512-1, 0, 256-1) MCFG_SCREEN_UPDATE_DRIVER(blitz68k_state, screen_update_blitz68k) - MCFG_MC6845_ADD("crtc", R6545_1, "screen", XTAL(22'118'400)/8) + MCFG_MC6845_ADD(m_crtc, R6545_1, "screen", XTAL(22'118'400)/8) MCFG_MC6845_SHOW_BORDER_AREA(false) MCFG_MC6845_CHAR_WIDTH(4) MCFG_MC6845_ADDR_CHANGED_CB(blitz68k_state, crtc_addr) MCFG_MC6845_OUT_VSYNC_CB(WRITELINE(*this, blitz68k_state, crtc_vsync_irq3)) - MCFG_PALETTE_ADD("palette", 0x100) + MCFG_PALETTE_ADD(m_palette, 0x100) MCFG_VIDEO_START_OVERRIDE(blitz68k_state,blitz68k) MCFG_RAMDAC_ADD("ramdac", ramdac_map, "palette") @@ -1898,7 +1897,7 @@ MACHINE_CONFIG_END MACHINE_CONFIG_START(blitz68k_state::dualgame) - MCFG_DEVICE_ADD("maincpu", M68000, XTAL(11'059'200) ) + MCFG_DEVICE_ADD(m_maincpu, M68000, XTAL(11'059'200) ) MCFG_DEVICE_PROGRAM_MAP(dualgame_map) MCFG_DEVICE_VBLANK_INT_DRIVER("screen", blitz68k_state, irq2_line_hold) // lev 2 = MCUs, lev 3 = vblank @@ -1915,13 +1914,13 @@ MACHINE_CONFIG_START(blitz68k_state::dualgame) MCFG_SCREEN_VISIBLE_AREA(0, 512-1, 0+4, 256-1-4) MCFG_SCREEN_UPDATE_DRIVER(blitz68k_state, screen_update_blitz68k) - MCFG_MC6845_ADD("crtc", H46505, "screen", XTAL(11'059'200)/4) + MCFG_MC6845_ADD(m_crtc, H46505, "screen", XTAL(11'059'200)/4) MCFG_MC6845_SHOW_BORDER_AREA(false) MCFG_MC6845_CHAR_WIDTH(4) MCFG_MC6845_ADDR_CHANGED_CB(blitz68k_state, crtc_addr) MCFG_MC6845_OUT_VSYNC_CB(WRITELINE(*this, blitz68k_state, crtc_vsync_irq3)) - MCFG_PALETTE_ADD("palette", 0x100) + MCFG_PALETTE_ADD(m_palette, 0x100) MCFG_VIDEO_START_OVERRIDE(blitz68k_state,blitz68k) MCFG_RAMDAC_ADD("ramdac", ramdac_map, "palette") @@ -1929,7 +1928,7 @@ MACHINE_CONFIG_END MACHINE_CONFIG_START(blitz68k_state::hermit) - MCFG_DEVICE_ADD("maincpu", M68000, XTAL(22'118'400)/2 ) + MCFG_DEVICE_ADD(m_maincpu, M68000, XTAL(22'118'400)/2 ) MCFG_DEVICE_PROGRAM_MAP(hermit_map) MCFG_DEVICE_VBLANK_INT_DRIVER("screen", blitz68k_state, irq1_line_hold) // protection prevents correct irq frequency by crtc @@ -1944,13 +1943,13 @@ MACHINE_CONFIG_START(blitz68k_state::hermit) MCFG_SCREEN_VISIBLE_AREA(0, 512-1, 0+4, 256-1-4) MCFG_SCREEN_UPDATE_DRIVER(blitz68k_state, screen_update_blitz68k) - MCFG_MC6845_ADD("crtc", H46505, "screen", XTAL(22'118'400)/8) + MCFG_MC6845_ADD(m_crtc, H46505, "screen", XTAL(22'118'400)/8) MCFG_MC6845_SHOW_BORDER_AREA(false) MCFG_MC6845_CHAR_WIDTH(4) MCFG_MC6845_ADDR_CHANGED_CB(blitz68k_state, crtc_addr) MCFG_MC6845_OUT_VSYNC_CB(WRITELINE(*this, blitz68k_state, crtc_vsync_irq1)) - MCFG_PALETTE_ADD("palette", 0x100) + MCFG_PALETTE_ADD(m_palette, 0x100) MCFG_VIDEO_START_OVERRIDE(blitz68k_state,blitz68k) MCFG_RAMDAC_ADD("ramdac", ramdac_map, "palette") @@ -1958,7 +1957,7 @@ MACHINE_CONFIG_END MACHINE_CONFIG_START(blitz68k_state::maxidbl) - MCFG_DEVICE_ADD("maincpu", M68000, XTAL(11'059'200)) + MCFG_DEVICE_ADD(m_maincpu, M68000, XTAL(11'059'200)) MCFG_DEVICE_PROGRAM_MAP(maxidbl_map) MCFG_DEVICE_VBLANK_INT_DRIVER("screen", blitz68k_state, irq3_line_hold) // protection prevents correct irq frequency by crtc // irq 2 reads from MCUs @@ -1978,13 +1977,13 @@ MACHINE_CONFIG_START(blitz68k_state::maxidbl) MCFG_SCREEN_VISIBLE_AREA(0, 512-1, 0, 256-1) MCFG_SCREEN_UPDATE_DRIVER(blitz68k_state, screen_update_blitz68k_noblit) - MCFG_MC6845_ADD("crtc", H46505, "screen", XTAL(11'059'200)/4) + MCFG_MC6845_ADD(m_crtc, H46505, "screen", XTAL(11'059'200)/4) MCFG_MC6845_SHOW_BORDER_AREA(false) MCFG_MC6845_CHAR_WIDTH(4) MCFG_MC6845_ADDR_CHANGED_CB(blitz68k_state, crtc_addr) MCFG_MC6845_OUT_VSYNC_CB(WRITELINE(*this, blitz68k_state, crtc_vsync_irq3)) - MCFG_PALETTE_ADD("palette", 0x100) + MCFG_PALETTE_ADD(m_palette, 0x100) MCFG_RAMDAC_ADD("ramdac", ramdac_map, "palette") SPEAKER(config, "mono").front_center(); diff --git a/src/mame/drivers/blmbycar.cpp b/src/mame/drivers/blmbycar.cpp index ee4483b7333..a1a092b2f87 100644 --- a/src/mame/drivers/blmbycar.cpp +++ b/src/mame/drivers/blmbycar.cpp @@ -18,7 +18,7 @@ To Do: Blomby Car is said to be a bootleg of Gaelco's World Rally and uses many of the same fonts -(Update: it actually is a bootleg of World Rally by looking how much +(Update: it actually is a bootleg of World Rally by looking how much similar the two HWs are, down to the dipswitches!) Waterball @@ -213,10 +213,10 @@ static INPUT_PORTS_START( blmbycar ) PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) PORT_START("P1_P2") /* $700002.w */ - PORT_BIT( 0x0001, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) PORT_PLAYER(1) PORT_CONDITION("DSW", 0x18, EQUALS, 0x18) - PORT_BIT( 0x0002, IP_ACTIVE_LOW, IPT_JOYSTICK_DOWN ) PORT_PLAYER(1) PORT_CONDITION("DSW", 0x18, EQUALS, 0x18) - PORT_BIT( 0x0004, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT ) PORT_PLAYER(1) PORT_CONDITION("DSW", 0x18, EQUALS, 0x18) - PORT_BIT( 0x0008, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT ) PORT_PLAYER(1) PORT_CONDITION("DSW", 0x18, EQUALS, 0x18) + PORT_BIT( 0x0001, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) PORT_PLAYER(1) PORT_CONDITION("DSW", 0x18, EQUALS, 0x18) + PORT_BIT( 0x0002, IP_ACTIVE_LOW, IPT_JOYSTICK_DOWN ) PORT_PLAYER(1) PORT_CONDITION("DSW", 0x18, EQUALS, 0x18) + PORT_BIT( 0x0004, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT ) PORT_PLAYER(1) PORT_CONDITION("DSW", 0x18, EQUALS, 0x18) + PORT_BIT( 0x0008, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT ) PORT_PLAYER(1) PORT_CONDITION("DSW", 0x18, EQUALS, 0x18) PORT_BIT( 0x000f, IP_ACTIVE_LOW, IPT_UNUSED ) PORT_CONDITION("DSW", 0x18, NOTEQUALS, 0x18) PORT_BIT( 0x0010, IP_ACTIVE_LOW, IPT_BUTTON2 ) PORT_PLAYER(1) PORT_NAME("P1 Gear Shift") PORT_TOGGLE PORT_CONDITION("DSW", 0x18, NOTEQUALS, 0x18) PORT_BIT( 0x0010, IP_ACTIVE_LOW, IPT_UNUSED ) PORT_CONDITION("DSW", 0x18, EQUALS, 0x18) @@ -235,7 +235,7 @@ static INPUT_PORTS_START( blmbycar ) PORT_START("OPT_WHEEL") /* $700004.w */ PORT_BIT ( 0x00ff, 0x0000, IPT_DIAL ) PORT_SENSITIVITY(30) PORT_KEYDELTA(1) PORT_REVERSE PORT_CONDITION("DSW", 0x18, EQUALS, 0x08) PORT_NAME("P1 Opt Wheel") - + PORT_START("POT_WHEEL") PORT_BIT ( 0x00ff, 0x0080, IPT_AD_STICK_X ) PORT_SENSITIVITY(30) PORT_KEYDELTA(1) PORT_REVERSE PORT_CONDITION("DSW", 0x18, EQUALS, 0x10) PORT_NAME("P1 Pot Wheel") diff --git a/src/mame/drivers/coco12.cpp b/src/mame/drivers/coco12.cpp index e03146e657a..e736e2c99d5 100644 --- a/src/mame/drivers/coco12.cpp +++ b/src/mame/drivers/coco12.cpp @@ -388,6 +388,7 @@ MACHINE_CONFIG_START(coco_state::coco_sound) MCFG_DEVICE_ADD("dac", DAC_6BIT_BINARY_WEIGHTED, 0) MCFG_SOUND_ROUTE(ALL_OUTPUTS, "speaker", 0.125) MCFG_DEVICE_ADD("vref", VOLTAGE_REGULATOR, 0) MCFG_VOLTAGE_REGULATOR_OUTPUT(5.0) MCFG_SOUND_ROUTE(0, "dac", 1.0, DAC_VREF_POS_INPUT) MCFG_SOUND_ROUTE(0, "dac", -1.0, DAC_VREF_NEG_INPUT) + MCFG_SOUND_ROUTE(0, "sbs", 1.0, DAC_VREF_POS_INPUT) MCFG_SOUND_ROUTE(0, "sbs", -1.0, DAC_VREF_NEG_INPUT) // Single-bit sound: R22 = 10K DAC_1BIT(config, "sbs", 0).add_route(ALL_OUTPUTS, "speaker", 0.125); diff --git a/src/mame/drivers/cps1.cpp b/src/mame/drivers/cps1.cpp index 4ce30b53be3..2dc84e56ea2 100644 --- a/src/mame/drivers/cps1.cpp +++ b/src/mame/drivers/cps1.cpp @@ -8219,10 +8219,10 @@ ROM_END /* B-Board 90629B-3 */ ROM_START( kodr2 ) ROM_REGION( CODE_SIZE, "maincpu", 0 ) /* 68000 code */ - ROM_LOAD16_BYTE( "kde_30.11e", 0x00000, 0x20000, CRC(f8dc4ce3) SHA1(3efc4ffd61b399235f27c97ffb6d556000d59b33) ) /* different CRC from kodr1, pcb verified */ - ROM_LOAD16_BYTE( "kde_37.11f", 0x00001, 0x20000, CRC(d1276c1c) SHA1(1f70972eb5b854ef58c6d0eaccda6e12611cf763) ) /* different CRC from kodr1, pcb verified */ - ROM_LOAD16_BYTE( "kde_31.12e", 0x40000, 0x20000, CRC(309debd8) SHA1(96aa498fe04c1b8f76dab1c0ab074eedd48053fa) ) /* different CRC from kodr1, pcb verified */ - ROM_LOAD16_BYTE( "kde_38.12f", 0x40001, 0x20000, CRC(76cd5738) SHA1(cb81f8db8400c9972f05ace38530f040fb66f93e) ) /* different CRC from kodr1, pcb verified */ + ROM_LOAD16_BYTE( "kde_30.11e", 0x00000, 0x20000, CRC(f8dc4ce3) SHA1(3efc4ffd61b399235f27c97ffb6d556000d59b33) ) /* different CRC from kodr1, pcb verified */ + ROM_LOAD16_BYTE( "kde_37.11f", 0x00001, 0x20000, CRC(d1276c1c) SHA1(1f70972eb5b854ef58c6d0eaccda6e12611cf763) ) /* different CRC from kodr1, pcb verified */ + ROM_LOAD16_BYTE( "kde_31.12e", 0x40000, 0x20000, CRC(309debd8) SHA1(96aa498fe04c1b8f76dab1c0ab074eedd48053fa) ) /* different CRC from kodr1, pcb verified */ + ROM_LOAD16_BYTE( "kde_38.12f", 0x40001, 0x20000, CRC(76cd5738) SHA1(cb81f8db8400c9972f05ace38530f040fb66f93e) ) /* different CRC from kodr1, pcb verified */ ROM_LOAD16_BYTE( "kd_28.9e", 0x80000, 0x20000, CRC(9367bcd9) SHA1(8243b4b9bb9756f3fa726717e19a166cb2f5b50a) ) ROM_LOAD16_BYTE( "kd_35.9f", 0x80001, 0x20000, CRC(4ca6a48a) SHA1(9d440ecd8d2d0e293fecf64ca3915252b94e7aef) ) ROM_LOAD16_BYTE( "kd_29.10e", 0xc0000, 0x20000, CRC(0360fa72) SHA1(274769c8717a874397cf37369e3ef80a682d9ef2) ) diff --git a/src/mame/drivers/csplayh5.cpp b/src/mame/drivers/csplayh5.cpp index 984e2467ce4..5adcceb6e38 100644 --- a/src/mame/drivers/csplayh5.cpp +++ b/src/mame/drivers/csplayh5.cpp @@ -921,9 +921,9 @@ ROM_END ***************************************************************************/ // 1995 - GAME( 1995, csplayh1, 0, csplayh5, csplayh5, csplayh5_state, init_csplayh1, ROT0, "Sphinx/AV Japan/Astro System Japan", "Super CD Dai8dan Mahjong Hanafuda Cosplay Tengoku (Japan)", MACHINE_NOT_WORKING ) + GAME( 1995, csplayh1, 0, csplayh5, csplayh5, csplayh5_state, init_csplayh1, ROT0, "Sphinx/AV Japan/Astro System Japan", "Super CD Dai8dan Mahjong Hanafuda Cosplay Tengoku (Japan)", MACHINE_NOT_WORKING ) - GAME( 1998, nichidvd, 0, csplayh5, csplayh5, csplayh5_state, empty_init, ROT0, "Nichibutsu", "Nichibutsu High Rate DVD BIOS", MACHINE_IS_BIOS_ROOT ) + GAME( 1998, nichidvd, 0, csplayh5, csplayh5, csplayh5_state, empty_init, ROT0, "Nichibutsu", "Nichibutsu High Rate DVD BIOS", MACHINE_IS_BIOS_ROOT ) // 1998 /* 01 */ GAME( 1998, mjgalpri, nichidvd, csplayh5, csplayh5, csplayh5_state, init_mjgalpri, ROT0, "Nichibutsu/Just&Just", "Mahjong Gal-pri - World Gal-con Grandprix (Japan)", MACHINE_NOT_WORKING ) diff --git a/src/mame/drivers/deadang.cpp b/src/mame/drivers/deadang.cpp index 361eb30c691..42084ffa976 100644 --- a/src/mame/drivers/deadang.cpp +++ b/src/mame/drivers/deadang.cpp @@ -443,19 +443,19 @@ MACHINE_CONFIG_END /* ROMs */ ROM_START( popnrun ) ROM_REGION( 0x100000, "maincpu", ROMREGION_ERASE00 ) - ROM_LOAD16_BYTE( "popnrun-27512-1-6e.bin", 0xe0001, 0x010000, CRC(cf800494) SHA1(eaed51212c91ebb16e326f8133b60a0ecf0055e5) ) - ROM_LOAD16_BYTE( "popnrun-27512-2-6h.bin", 0xe0000, 0x010000, CRC(bad47dc4) SHA1(279236cfe5102b4724f9fb4405f514dba011ae3d) ) + ROM_LOAD16_BYTE( "popnrun-27512-1-6e.bin", 0xe0001, 0x010000, CRC(cf800494) SHA1(eaed51212c91ebb16e326f8133b60a0ecf0055e5) ) + ROM_LOAD16_BYTE( "popnrun-27512-2-6h.bin", 0xe0000, 0x010000, CRC(bad47dc4) SHA1(279236cfe5102b4724f9fb4405f514dba011ae3d) ) ROM_REGION( 0x100000, "sub", ROMREGION_ERASE00 ) ROM_LOAD16_BYTE( "popnrun-27256-3-17e.bin", 0xf0001, 0x008000, CRC(93f811aa) SHA1(75998375081d3cc5faa7533d39dd2d29a4ef3e7d) ) - ROM_LOAD16_BYTE( "popnrun-27256-4-17h.bin", 0xf0000, 0x008000, CRC(8fe0c064) SHA1(2a854238b8335a85cbe75c901480b51d479273a0) ) + ROM_LOAD16_BYTE( "popnrun-27256-4-17h.bin", 0xf0000, 0x008000, CRC(8fe0c064) SHA1(2a854238b8335a85cbe75c901480b51d479273a0) ) ROM_REGION( 0x20000, "audiocpu", ROMREGION_ERASE00 ) - ROM_LOAD( "popnrun-2764-5-22c.bin", 0x000000, 0x002000, CRC(768a2ec7) SHA1(abc02ec6c6a495e612e8708377d9e7ca98981de4) ) - ROM_LOAD( "popnrun-27512-6-20c.bin", 0x010000, 0x010000, CRC(47d168ce) SHA1(36c16a400408834fcf0561c3f097e84a287560bd) ) + ROM_LOAD( "popnrun-2764-5-22c.bin", 0x000000, 0x002000, CRC(768a2ec7) SHA1(abc02ec6c6a495e612e8708377d9e7ca98981de4) ) + ROM_LOAD( "popnrun-27512-6-20c.bin", 0x010000, 0x010000, CRC(47d168ce) SHA1(36c16a400408834fcf0561c3f097e84a287560bd) ) ROM_REGION( 0x2000, "gfx1", ROMREGION_ERASE00 ) - ROM_LOAD( "popnrun-2764-7-1a.bin", 0x000000, 0x002000, CRC(5e508b8e) SHA1(3e49e8d25a3db83178965382295e7c437441b5fe) ) + ROM_LOAD( "popnrun-2764-7-1a.bin", 0x000000, 0x002000, CRC(5e508b8e) SHA1(3e49e8d25a3db83178965382295e7c437441b5fe) ) ROM_REGION( 0x80000, "gfx2", ROMREGION_ERASEFF ) /* Sprites */ ROM_LOAD( "gfx2.bin", 0x0000, 0x80000, NO_DUMP ) @@ -482,24 +482,24 @@ ROM_START( popnrun ) ROM_REGION( 0x10000, "adpcm2", ROMREGION_ERASE00 ) ROM_REGION( 0x0100, "prom", ROMREGION_ERASE00 ) - ROM_LOAD( "popnrun-63s281-9b.bin", 0x000000, 0x000100, CRC(208d17ca) SHA1(a77d56337bcac8d9a7bc3411239dfb3045e069ec) ) + ROM_LOAD( "popnrun-63s281-9b.bin", 0x000000, 0x000100, CRC(208d17ca) SHA1(a77d56337bcac8d9a7bc3411239dfb3045e069ec) ) ROM_END ROM_START( popnruna ) ROM_REGION( 0x100000, "maincpu", ROMREGION_ERASE00 ) - ROM_LOAD16_BYTE( "1.e5.27512", 0xe0001, 0x010000, CRC(fe45b6c4) SHA1(efa0d4ce6c5963f25ca1195cd2d5745e730b3b95) ) - ROM_LOAD16_BYTE( "2.h5.27512", 0xe0000, 0x010000, CRC(1e325398) SHA1(ca481c1447de4bffdea695deb9bb46c269272c68) ) + ROM_LOAD16_BYTE( "1.e5.27512", 0xe0001, 0x010000, CRC(fe45b6c4) SHA1(efa0d4ce6c5963f25ca1195cd2d5745e730b3b95) ) + ROM_LOAD16_BYTE( "2.h5.27512", 0xe0000, 0x010000, CRC(1e325398) SHA1(ca481c1447de4bffdea695deb9bb46c269272c68) ) ROM_REGION( 0x100000, "sub", ROMREGION_ERASE00 ) ROM_LOAD16_BYTE( "popnrun-27256-3-17e.bin", 0xf0001, 0x008000, CRC(93f811aa) SHA1(75998375081d3cc5faa7533d39dd2d29a4ef3e7d) ) - ROM_LOAD16_BYTE( "popnrun-27256-4-17h.bin", 0xf0000, 0x008000, CRC(8fe0c064) SHA1(2a854238b8335a85cbe75c901480b51d479273a0) ) + ROM_LOAD16_BYTE( "popnrun-27256-4-17h.bin", 0xf0000, 0x008000, CRC(8fe0c064) SHA1(2a854238b8335a85cbe75c901480b51d479273a0) ) ROM_REGION( 0x20000, "audiocpu", ROMREGION_ERASE00 ) - ROM_LOAD( "popnrun-2764-5-22c.bin", 0x000000, 0x002000, CRC(768a2ec7) SHA1(abc02ec6c6a495e612e8708377d9e7ca98981de4) ) - ROM_LOAD( "popnrun-27512-6-20c.bin", 0x010000, 0x010000, CRC(47d168ce) SHA1(36c16a400408834fcf0561c3f097e84a287560bd) ) + ROM_LOAD( "popnrun-2764-5-22c.bin", 0x000000, 0x002000, CRC(768a2ec7) SHA1(abc02ec6c6a495e612e8708377d9e7ca98981de4) ) + ROM_LOAD( "popnrun-27512-6-20c.bin", 0x010000, 0x010000, CRC(47d168ce) SHA1(36c16a400408834fcf0561c3f097e84a287560bd) ) ROM_REGION( 0x2000, "gfx1", ROMREGION_ERASE00 ) - ROM_LOAD( "popnrun-2764-7-1a.bin", 0x000000, 0x002000, CRC(5e508b8e) SHA1(3e49e8d25a3db83178965382295e7c437441b5fe) ) + ROM_LOAD( "popnrun-2764-7-1a.bin", 0x000000, 0x002000, CRC(5e508b8e) SHA1(3e49e8d25a3db83178965382295e7c437441b5fe) ) ROM_REGION( 0x80000, "gfx2", ROMREGION_ERASEFF ) /* Sprites */ ROM_LOAD( "gfx2.bin", 0x0000, 0x80000, NO_DUMP ) @@ -522,7 +522,7 @@ ROM_START( popnruna ) ROM_LOAD( "gfx7.bin", 0x0000, 0x10000, NO_DUMP ) ROM_REGION( 0x0100, "prom", ROMREGION_ERASE00 ) - ROM_LOAD( "popnrun-63s281-9b.bin", 0x000000, 0x000100, CRC(208d17ca) SHA1(a77d56337bcac8d9a7bc3411239dfb3045e069ec) ) + ROM_LOAD( "popnrun-63s281-9b.bin", 0x000000, 0x000100, CRC(208d17ca) SHA1(a77d56337bcac8d9a7bc3411239dfb3045e069ec) ) ROM_END ROM_START( deadang ) @@ -723,8 +723,8 @@ void deadang_state::init_deadang() void popnrun_state::init_popnrun() { -// m_adpcm1->decrypt(); -// m_adpcm2->decrypt(); +// m_adpcm1->decrypt(); +// m_adpcm2->decrypt(); } void deadang_state::init_ghunter() diff --git a/src/mame/drivers/dectalk.cpp b/src/mame/drivers/dectalk.cpp index 3c313ac6f30..a1c73d10372 100644 --- a/src/mame/drivers/dectalk.cpp +++ b/src/mame/drivers/dectalk.cpp @@ -436,9 +436,9 @@ WRITE_LINE_MEMBER(dectalk_state::dectalk_reset) { m_hack_self_test_is_second_read = false; // hack // stuff that is DIRECTLY affected by the RESET line - machine().device<x2212_device>("x2212")->recall(0); - machine().device<x2212_device>("x2212")->recall(1); - machine().device<x2212_device>("x2212")->recall(0); // nvram recall + m_nvram->recall(0); + m_nvram->recall(1); + m_nvram->recall(0); // nvram recall m_m68k_spcflags_latch = 1; // initial status is speech reset(d0) active and spc int(d6) disabled m_m68k_tlcflags_latch = 0; // initial status is tone detect int(d6) off, answer phone(d8) off, ring detect int(d14) off m_duart->reset(); // reset the DUART diff --git a/src/mame/drivers/exerion.cpp b/src/mame/drivers/exerion.cpp index 528e67c796c..74339732714 100644 --- a/src/mame/drivers/exerion.cpp +++ b/src/mame/drivers/exerion.cpp @@ -556,9 +556,9 @@ void exerion_state::init_exerion() for (uint32_t oldaddr = 0; oldaddr < length; oldaddr++) { uint32_t newaddr = ((oldaddr ) & 0x1f00) | /* keep n8-n4 */ - ((oldaddr << 3) & 0x00f0) | /* move n3-n0 */ - ((oldaddr >> 4) & 0x000e) | /* move v2-v0 */ - ((oldaddr ) & 0x0001); /* keep h2 */ + ((oldaddr << 3) & 0x00f0) | /* move n3-n0 */ + ((oldaddr >> 4) & 0x000e) | /* move v2-v0 */ + ((oldaddr ) & 0x0001); /* keep h2 */ dst[newaddr] = src[oldaddr]; } @@ -574,10 +574,10 @@ void exerion_state::init_exerion() for (uint32_t oldaddr = 0; oldaddr < length; oldaddr++) { uint32_t newaddr = ((oldaddr << 1) & 0x3c00) | /* move n7-n4 */ - ((oldaddr >> 4) & 0x0200) | /* move n3 */ - ((oldaddr << 4) & 0x01c0) | /* move n2-n0 */ - ((oldaddr >> 3) & 0x003c) | /* move v3-v0 */ - ((oldaddr ) & 0xc003); /* keep n9-n8 h3-h2 */ + ((oldaddr >> 4) & 0x0200) | /* move n3 */ + ((oldaddr << 4) & 0x01c0) | /* move n2-n0 */ + ((oldaddr >> 3) & 0x003c) | /* move v3-v0 */ + ((oldaddr ) & 0xc003); /* keep n9-n8 h3-h2 */ dst[newaddr] = src[oldaddr]; } } diff --git a/src/mame/drivers/exidy440.cpp b/src/mame/drivers/exidy440.cpp index da43a7076ca..c064e1235f4 100644 --- a/src/mame/drivers/exidy440.cpp +++ b/src/mame/drivers/exidy440.cpp @@ -244,9 +244,6 @@ Who Dunit 1988 6809 /* constants */ #define MAIN_CPU_CLOCK (EXIDY440_MASTER_CLOCK / 8) -#define EXIDY440_AUDIO_CLOCK (XTAL(12'979'200) / 4) -#define EXIDY440_MC3418_CLOCK (EXIDY440_AUDIO_CLOCK / 4 / 16) -#define EXIDY440_MC3417_CLOCK (EXIDY440_AUDIO_CLOCK / 4 / 32) @@ -451,7 +448,7 @@ void exidy440_state::machine_start() /* the EEROM lives in the uppermost 8k of the top bank */ uint8_t *rom = memregion("maincpu")->base(); - machine().device<nvram_device>("nvram")->set_base(&rom[0x10000 + 15 * 0x4000 + 0x2000], 0x2000); + subdevice<nvram_device>("nvram")->set_base(&rom[0x10000 + 15 * 0x4000 + 0x2000], 0x2000); } void exidy440_state::machine_reset() @@ -492,28 +489,6 @@ void exidy440_state::exidy440_map(address_map &map) } -/************************************* - * - * Audio CPU memory handlers - * - *************************************/ - -void exidy440_state::exidy440_audio_map(address_map &map) -{ - map(0x0000, 0x7fff).noprw(); - map(0x8000, 0x801f).mirror(0x03e0).rw(m_custom, FUNC(exidy440_sound_device::m6844_r), FUNC(exidy440_sound_device::m6844_w)); - map(0x8400, 0x840f).mirror(0x03f0).rw(m_custom, FUNC(exidy440_sound_device::sound_volume_r), FUNC(exidy440_sound_device::sound_volume_w)); - map(0x8800, 0x8800).mirror(0x03ff).r(m_custom, FUNC(exidy440_sound_device::sound_command_r)).nopw(); - map(0x8c00, 0x93ff).noprw(); - map(0x9400, 0x9403).mirror(0x03fc).nopr().w(m_custom, FUNC(exidy440_sound_device::sound_banks_w)); - map(0x9800, 0x9800).mirror(0x03ff).nopr().w(m_custom, FUNC(exidy440_sound_device::sound_interrupt_clear_w)); - map(0x9c00, 0x9fff).noprw(); - map(0xa000, 0xbfff).ram(); - map(0xc000, 0xdfff).noprw(); - map(0xe000, 0xffff).rom(); -} - - /************************************* * @@ -1026,7 +1001,6 @@ MACHINE_CONFIG_START(exidy440_state::exidy440) /* basic machine hardware */ MCFG_DEVICE_ADD("maincpu", MC6809E, MAIN_CPU_CLOCK) MCFG_DEVICE_PROGRAM_MAP(exidy440_map) - MCFG_DEVICE_VBLANK_INT_DRIVER("screen", exidy440_state, exidy440_vblank_interrupt) MCFG_NVRAM_ADD_0FILL("nvram") @@ -1034,28 +1008,12 @@ MACHINE_CONFIG_START(exidy440_state::exidy440) exidy440_video(config); /* audio hardware */ - MCFG_DEVICE_ADD("audiocpu", MC6809, EXIDY440_AUDIO_CLOCK) - MCFG_DEVICE_PROGRAM_MAP(exidy440_audio_map) - MCFG_DEVICE_VBLANK_INT_DRIVER("screen", driver_device, irq0_line_assert) - SPEAKER(config, "lspeaker").front_left(); SPEAKER(config, "rspeaker").front_right(); - MCFG_DEVICE_ADD("custom", EXIDY440, EXIDY440_MC3418_CLOCK) + MCFG_DEVICE_ADD("440audio", EXIDY440, EXIDY440_MC3418_CLOCK) MCFG_SOUND_ROUTE(0, "lspeaker", 1.0) MCFG_SOUND_ROUTE(1, "rspeaker", 1.0) - -// MCFG_DEVICE_ADD("cvsd1", MC3418, EXIDY440_MC3418_CLOCK) -// MCFG_SOUND_ROUTE(ALL_OUTPUTS, "lspeaker", 1.0) - -// MCFG_DEVICE_ADD("cvsd2", MC3418, EXIDY440_MC3418_CLOCK) -// MCFG_SOUND_ROUTE(ALL_OUTPUTS, "rspeaker", 1.0) - -// MCFG_DEVICE_ADD("cvsd3", MC3417, EXIDY440_MC3417_CLOCK) -// MCFG_SOUND_ROUTE(ALL_OUTPUTS, "lspeaker", 1.0) - -// MCFG_DEVICE_ADD("cvsd4", MC3417, EXIDY440_MC3417_CLOCK) -// MCFG_SOUND_ROUTE(ALL_OUTPUTS, "rspeaker", 1.0) MACHINE_CONFIG_END @@ -1110,10 +1068,10 @@ ROM_START( crossbow ) ROM_LOAD( "xbl-1.3b", 0x42000, 0x2000, CRC(4a03c2c9) SHA1(dd60cd629f60d15dd0596bde44fea4b4f1d65ae2) ) ROM_LOAD( "xbl-1.4b", 0x44000, 0x2000, CRC(7e21c624) SHA1(9e0c1297413f9d440106f6cef25f48fad60e4c85) ) - ROM_REGION( 0x10000, "audiocpu", 0 ) - ROM_LOAD( "xba-11.1h", 0x0e000, 0x2000, CRC(1b61d0c1) SHA1(de1028a3295dc0413756d4751ca577a03431583e) ) + ROM_REGION( 0x02000, "440audio:audiocpu", 0 ) + ROM_LOAD( "xba-11.1h", 0x00000, 0x2000, CRC(1b61d0c1) SHA1(de1028a3295dc0413756d4751ca577a03431583e) ) - ROM_REGION( 0x20000, "cvsd", 0 ) + ROM_REGION( 0x20000, "440audio:samples", 0 ) ROM_LOAD( "xba-1.2k", 0x00000, 0x2000, CRC(b6e57685) SHA1(ee690cb966af126bfb0bafa804e0ad5490cab1db) ) ROM_LOAD( "xba-1.2l", 0x02000, 0x2000, CRC(2c24cb35) SHA1(4ea16998f477d6429a92ca05ef74daa21315e695) ) ROM_LOAD( "xba-1.2m", 0x04000, 0x2000, CRC(f3a4f2be) SHA1(f0ab8a0a6fbb2911d99c961a65035835e54924de) ) @@ -1179,10 +1137,10 @@ ROM_START( cheyenne ) ROM_LOAD( "cyl-1.8b", 0x4a000, 0x2000, CRC(c0653d3e) SHA1(489e61d1e0a18fca47b906d80b88c47fdb927d36) ) ROM_LOAD( "cyl-1.10b", 0x4c000, 0x2000, CRC(7fc67d19) SHA1(48307d50066c02376522e8fee0298c16f758b61d) ) - ROM_REGION( 0x10000, "audiocpu", 0 ) - ROM_LOAD( "cya-1.1h", 0x0e000, 0x2000, CRC(5aed3d8c) SHA1(d04ddd09df471cd2a8dd87c47c7b55eca5d7ac15) ) + ROM_REGION( 0x02000, "440audio:audiocpu", 0 ) + ROM_LOAD( "cya-1.1h", 0x00000, 0x2000, CRC(5aed3d8c) SHA1(d04ddd09df471cd2a8dd87c47c7b55eca5d7ac15) ) - ROM_REGION( 0x20000, "cvsd", 0 ) + ROM_REGION( 0x20000, "440audio:samples", 0 ) ROM_LOAD( "cya-1.2k", 0x00000, 0x2000, CRC(dc2b716d) SHA1(ae588954431f8c4ecc7075f4964c3b8cc7ae0569) ) ROM_LOAD( "cya-1.2l", 0x02000, 0x2000, CRC(091ad047) SHA1(edab4472f39a1f19614737c6c5722677f4afd68c) ) ROM_LOAD( "cya-1.2m", 0x04000, 0x2000, CRC(59085362) SHA1(d4d7182ccdec17a29c556810b1d24aa6726f3826) ) @@ -1240,10 +1198,10 @@ ROM_START( combat ) ROM_LOAD( "8b", 0x4a000, 0x2000, CRC(ae977f4c) SHA1(a4cc9cae10482f03879b64c2b40fc8999b8a2b71) ) ROM_LOAD( "10b", 0x4c000, 0x2000, CRC(502da003) SHA1(f4c579b2f997208f71b24590794275d87b06e25c) ) - ROM_REGION( 0x10000, "audiocpu", 0 ) - ROM_LOAD( "1h", 0x0e000, 0x2000, CRC(8f3dd350) SHA1(9e329c2f502f63fcdbebeb40bf732e4a07a463c1) ) + ROM_REGION( 0x02000, "440audio:audiocpu", 0 ) + ROM_LOAD( "1h", 0x00000, 0x2000, CRC(8f3dd350) SHA1(9e329c2f502f63fcdbebeb40bf732e4a07a463c1) ) - ROM_REGION( 0x20000, "cvsd", 0 ) + ROM_REGION( 0x20000, "440audio:samples", 0 ) ROM_LOAD( "2k", 0x00000, 0x2000, CRC(1c9df8b5) SHA1(12e82f585aee01f1e2ea7396a6b013c894f7b98d) ) ROM_LOAD( "2l", 0x02000, 0x2000, CRC(6b733306) SHA1(a41cc2e646392d71642abe2ab8d72f2d56214c02) ) ROM_LOAD( "2m", 0x04000, 0x2000, CRC(dc074733) SHA1(29a036d4057b813f584373493cb5b69b711840ae) ) @@ -1301,10 +1259,10 @@ ROM_START( catch22 ) ROM_LOAD( "8b", 0x4a000, 0x2000, CRC(ae977f4c) SHA1(a4cc9cae10482f03879b64c2b40fc8999b8a2b71) ) ROM_LOAD( "10b", 0x4c000, 0x2000, CRC(502da003) SHA1(f4c579b2f997208f71b24590794275d87b06e25c) ) - ROM_REGION( 0x10000, "audiocpu", 0 ) - ROM_LOAD( "1h", 0x0e000, 0x2000, CRC(8f3dd350) SHA1(9e329c2f502f63fcdbebeb40bf732e4a07a463c1) ) + ROM_REGION( 0x02000, "440audio:audiocpu", 0 ) + ROM_LOAD( "1h", 0x00000, 0x2000, CRC(8f3dd350) SHA1(9e329c2f502f63fcdbebeb40bf732e4a07a463c1) ) - ROM_REGION( 0x20000, "cvsd", 0 ) + ROM_REGION( 0x20000, "440audio:samples", 0 ) ROM_LOAD( "2k", 0x00000, 0x2000, CRC(1c9df8b5) SHA1(12e82f585aee01f1e2ea7396a6b013c894f7b98d) ) ROM_LOAD( "2l", 0x02000, 0x2000, CRC(6b733306) SHA1(a41cc2e646392d71642abe2ab8d72f2d56214c02) ) ROM_LOAD( "2m", 0x04000, 0x2000, CRC(dc074733) SHA1(29a036d4057b813f584373493cb5b69b711840ae) ) @@ -1358,10 +1316,10 @@ ROM_START( cracksht ) ROM_LOAD( "csl2.8b", 0x4a000, 0x2000, CRC(af1c8cb8) SHA1(d753539a2afa4f6b0a79b9c7364d9814eb5ec3c0) ) ROM_LOAD( "csl2.10b", 0x4c000, 0x2000, CRC(8a0d6ad0) SHA1(024a8cebb56404c9efae0594e0b1d4a341ba9893) ) - ROM_REGION( 0x10000, "audiocpu", 0 ) - ROM_LOAD( "csa3.1h", 0x0e000, 0x2000, CRC(5ba8b4ac) SHA1(04d9d4bb7a5994c5ffe97ca22a43e7a1cbdef559) ) + ROM_REGION( 0x02000, "440audio:audiocpu", 0 ) + ROM_LOAD( "csa3.1h", 0x00000, 0x2000, CRC(5ba8b4ac) SHA1(04d9d4bb7a5994c5ffe97ca22a43e7a1cbdef559) ) - ROM_REGION( 0x20000, "cvsd", 0 ) + ROM_REGION( 0x20000, "440audio:samples", 0 ) ROM_LOAD( "csa3.2k", 0x00000, 0x2000, CRC(067a4f71) SHA1(301b44bcb0c7145dbc2dfbaf5c7d9cc5aa0e2118) ) ROM_LOAD( "csa3.2l", 0x02000, 0x2000, CRC(5716c59e) SHA1(8adb601ba04bbc27295afe993cdc0576a39c7a71) ) ROM_LOAD( "csa3.2m", 0x04000, 0x2000, CRC(b3ff659b) SHA1(295b5153ad41d92ee53b53ed454b2487aea7f355) ) @@ -1409,10 +1367,10 @@ ROM_START( claypign ) ROM_LOAD( "claypige.7b", 0x48000, 0x2000, CRC(6140b026) SHA1(16949d1bcaec3c0c398df50a731da3bb44fa8e5b) ) ROM_LOAD( "claypige.8b", 0x4a000, 0x2000, CRC(d0f9d170) SHA1(db4285a280a7d539aab91280c57db9c460468a69) ) - ROM_REGION( 0x10000, "audiocpu", 0 ) - ROM_LOAD( "claypige.h1", 0x0e000, 0x2000, CRC(9eedc68d) SHA1(966542a10e19f7afe065614bdb7dd8a9ad9d3c3d) ) + ROM_REGION( 0x02000, "440audio:audiocpu", 0 ) + ROM_LOAD( "claypige.h1", 0x00000, 0x2000, CRC(9eedc68d) SHA1(966542a10e19f7afe065614bdb7dd8a9ad9d3c3d) ) - ROM_REGION( 0x20000, "cvsd", 0 ) + ROM_REGION( 0x20000, "440audio:samples", 0 ) ROM_LOAD( "claypige.k2", 0x00000, 0x2000, CRC(0dd93c6c) SHA1(630397dbc54923a713bef1d99b08df8d2668b8ea) ) ROM_LOAD( "claypige.l2", 0x02000, 0x2000, CRC(e1d67c42) SHA1(8021432493cd9d5096b534505d469bb88a20e31f) ) ROM_LOAD( "claypige.m2", 0x04000, 0x2000, CRC(b56d8bd5) SHA1(45ac65a0f066791bb50535705d502957bfffbd53) ) @@ -1470,10 +1428,10 @@ ROM_START( chiller ) ROM_LOAD( "chl3.8b", 0x4a000, 0x2000, CRC(6172b12f) SHA1(f23e88103ed6b67eefade835cbdb1e3260d07d92) ) ROM_LOAD( "chl3.10b", 0x4c000, 0x2000, CRC(5d15342a) SHA1(74216b78a8f0bb44911b9cc74587b3edbacbbf01) ) - ROM_REGION( 0x10000, "audiocpu", 0 ) - ROM_LOAD( "cha3.1h", 0x0f000, 0x1000, CRC(b195cbba) SHA1(a74d14464ef0f07bfc83500483dd552f38fd55c8) ) + ROM_REGION( 0x02000, "440audio:audiocpu", 0 ) + ROM_LOAD( "cha3.1h", 0x01000, 0x1000, CRC(b195cbba) SHA1(a74d14464ef0f07bfc83500483dd552f38fd55c8) ) - ROM_REGION( 0x20000, "cvsd", 0 ) + ROM_REGION( 0x20000, "440audio:samples", 0 ) ROM_LOAD( "cha3.2k", 0x00000, 0x2000, CRC(814a1c6e) SHA1(f7b22bc5a7d0b8fb9914b000520d68cc87c43957) ) ROM_LOAD( "cha3.2l", 0x02000, 0x2000, CRC(b326007f) SHA1(c636f28f18697673d0a9b47a1494ea4060ca012f) ) ROM_LOAD( "cha3.2m", 0x04000, 0x2000, CRC(11075e8c) SHA1(f87cb92126ddb3899fc95b3a20a1c7109fc2a60d) ) @@ -1543,10 +1501,10 @@ ROM_START( topsecex ) ROM_LOAD( "tsl1.b8", 0x4a000, 0x2000, CRC(cc770802) SHA1(3830a7cb22e30e7af5a693fac3dad0f306a88c2b) ) ROM_LOAD( "tsl1.b10", 0x4c000, 0x2000, CRC(079d0a1d) SHA1(91ee751e27b963b98774181f5037e3e88b4877df) ) - ROM_REGION( 0x10000, "audiocpu", 0 ) - ROM_LOAD( "tsa1.1h", 0x0e000, 0x2000, CRC(35a1dd40) SHA1(2a18b166f9ad2b6afc9e8448287228cd81d34f94) ) + ROM_REGION( 0x02000, "440audio:audiocpu", 0 ) + ROM_LOAD( "tsa1.1h", 0x00000, 0x2000, CRC(35a1dd40) SHA1(2a18b166f9ad2b6afc9e8448287228cd81d34f94) ) - ROM_REGION( 0x20000, "cvsd", 0 ) + ROM_REGION( 0x20000, "440audio:samples", 0 ) ROM_LOAD( "tsa1.2k", 0x00000, 0x2000, CRC(c0b7c8f9) SHA1(1d54da254d2524f3df49df6ad6961770852a663e) ) ROM_LOAD( "tsa1.2l", 0x02000, 0x2000, CRC(d46f2f23) SHA1(6d3f9cf9f9d05faea86323a7752eea9467d6edc5) ) ROM_LOAD( "tsa1.2m", 0x04000, 0x2000, CRC(04722ee4) SHA1(ab5d730330b98365fc02c38eb8545e5e1de4e93f) ) @@ -1606,10 +1564,10 @@ ROM_START( hitnmiss ) ROM_LOAD( "hml3.b8", 0x4a000, 0x2000, CRC(e0a5a6aa) SHA1(b012a1e23fd0acf9972714ed8aea0cedbb079a31) ) ROM_LOAD( "hml3.b10", 0x4c000, 0x2000, CRC(de65dfdc) SHA1(c1105ff41596ee5f4c79143552eab87fcbe93d1e) ) - ROM_REGION( 0x10000, "audiocpu", 0 ) - ROM_LOAD( "hma3.1h", 0x0e000, 0x2000, CRC(f718da36) SHA1(6c878725e679e0c553494c621bee059fe8b67ae8) ) + ROM_REGION( 0x02000, "440audio:audiocpu", 0 ) + ROM_LOAD( "hma3.1h", 0x00000, 0x2000, CRC(f718da36) SHA1(6c878725e679e0c553494c621bee059fe8b67ae8) ) - ROM_REGION( 0x20000, "cvsd", 0 ) + ROM_REGION( 0x20000, "440audio:samples", 0 ) ROM_LOAD( "hm2.2k", 0x00000, 0x2000, CRC(d3583b62) SHA1(99be3a858ab6b1c950ef684202adec4f5e60a361) ) ROM_LOAD( "hm2.2l", 0x02000, 0x2000, CRC(c059d51e) SHA1(ddf437cdff6168e76c6a65078e0a2e2862805ca7) ) ROM_LOAD( "hma.2m", 0x04000, 0x2000, CRC(09bb8495) SHA1(ea817cbbd89aa18d81f6025a856965d466efadff) ) @@ -1667,10 +1625,10 @@ ROM_START( hitnmiss2 ) ROM_LOAD( "hml2.b8", 0x4a000, 0x2000, CRC(9c2db94a) SHA1(aa90181c0cc3e130f872ff5beb2be340e7851e1a) ) ROM_LOAD( "hml2.b10", 0x4c000, 0x2000, CRC(f01bd7d4) SHA1(169139c89582852b6141fd37e75486753674c557) ) - ROM_REGION( 0x10000, "audiocpu", 0 ) - ROM_LOAD( "hma2.1h", 0x0e000, 0x2000, CRC(9be48f45) SHA1(360138e3996828509b4bd1b3efccd61f05d215f0) ) + ROM_REGION( 0x02000, "440audio:audiocpu", 0 ) + ROM_LOAD( "hma2.1h", 0x00000, 0x2000, CRC(9be48f45) SHA1(360138e3996828509b4bd1b3efccd61f05d215f0) ) - ROM_REGION( 0x20000, "cvsd", 0 ) + ROM_REGION( 0x20000, "440audio:samples", 0 ) ROM_LOAD( "hm2.2k", 0x00000, 0x2000, CRC(d3583b62) SHA1(99be3a858ab6b1c950ef684202adec4f5e60a361) ) ROM_LOAD( "hm2.2l", 0x02000, 0x2000, CRC(c059d51e) SHA1(ddf437cdff6168e76c6a65078e0a2e2862805ca7) ) ROM_LOAD( "hma.2m", 0x04000, 0x2000, CRC(09bb8495) SHA1(ea817cbbd89aa18d81f6025a856965d466efadff) ) @@ -1736,10 +1694,10 @@ ROM_START( whodunit ) /* Version 9 */ ROM_LOAD( "wdl-9_8-b.8b", 0x4a000, 0x2000, CRC(33792758) SHA1(408da288288f54f7446b083b14dc74d43ef4ab9f) ) ROM_LOAD( "wdl-9_10-b.10b", 0x4c000, 0x2000, CRC(c5ab5805) SHA1(fd7c47e50eb4005b81309a73afae2e04a823d00b) ) - ROM_REGION( 0x10000, "audiocpu", 0 ) - ROM_LOAD( "wda-9_h-1.h1", 0x0e000, 0x2000, CRC(dc4b36f0) SHA1(1ddd47dbd7f3e360aae830b67a13dd6a1d7a6497) ) // This ROM is a 2764 eprom + ROM_REGION( 0x02000, "440audio:audiocpu", 0 ) + ROM_LOAD( "wda-9_h-1.h1", 0x00000, 0x2000, CRC(dc4b36f0) SHA1(1ddd47dbd7f3e360aae830b67a13dd6a1d7a6497) ) // This ROM is a 2764 eprom - ROM_REGION( 0x20000, "cvsd", 0 ) + ROM_REGION( 0x20000, "440audio:samples", 0 ) ROM_LOAD( "wda-9_2-k.2k", 0x00000, 0x2000, CRC(d4951375) SHA1(88616a7cb587748b366ece6126185a85e7375659) ) // all these ROMs are 2764 eproms ROM_LOAD( "wda-9_2-l.2l", 0x02000, 0x2000, CRC(be8dcf07) SHA1(9a6e9b256da07be50feb81b27e53d86b3f016f4e) ) ROM_LOAD( "wda-9_2-m.2m", 0x04000, 0x2000, CRC(fb389e2d) SHA1(8ee1be233429d6b7cbb56a13586e2db49dffaca1) ) @@ -1808,10 +1766,10 @@ ROM_START( whodunit8 ) /* Version 8 */ ROM_LOAD( "wdl8.8b", 0x4a000, 0x2000, CRC(33792758) SHA1(408da288288f54f7446b083b14dc74d43ef4ab9f) ) ROM_LOAD( "wdl6.10b", 0x4c000, 0x2000, CRC(2f48cfdb) SHA1(b546da26b7bdc52c454ff32e4503ef5e45e4b360) ) - ROM_REGION( 0x10000, "audiocpu", 0 ) - ROM_LOAD( "wda8.h1", 0x0e000, 0x2000, CRC(0090e5a7) SHA1(c97e4c83d507d1375320aa9cae07b9fa1ee442c8) ) + ROM_REGION( 0x02000, "440audio:audiocpu", 0 ) + ROM_LOAD( "wda8.h1", 0x00000, 0x2000, CRC(0090e5a7) SHA1(c97e4c83d507d1375320aa9cae07b9fa1ee442c8) ) - ROM_REGION( 0x20000, "cvsd", 0 ) + ROM_REGION( 0x20000, "440audio:samples", 0 ) ROM_LOAD( "wda6.k2", 0x00000, 0x2000, CRC(d4951375) SHA1(88616a7cb587748b366ece6126185a85e7375659) ) ROM_LOAD( "wda6.l2", 0x02000, 0x2000, CRC(be8dcf07) SHA1(9a6e9b256da07be50feb81b27e53d86b3f016f4e) ) ROM_LOAD( "wda6.m2", 0x04000, 0x2000, CRC(fb389e2d) SHA1(8ee1be233429d6b7cbb56a13586e2db49dffaca1) ) @@ -1874,10 +1832,10 @@ ROM_START( showdown ) ROM_LOAD( "sld-5_8-b.8b", 0x4a000, 0x2000, CRC(024fe6ee) SHA1(4287091e65c58aec75c54e320c534d41def951f9) ) ROM_LOAD( "sld-5_10-b.10b", 0x4c000, 0x2000, CRC(0b318dfe) SHA1(feb65530ea3aea6b0786875dc48d96e07d579636) ) - ROM_REGION( 0x10000, "audiocpu", 0 ) - ROM_LOAD( "sda-5_h-1.h1", 0x0e000, 0x2000, CRC(6a10ff47) SHA1(ee57de74ab9a5cfe5726212a9b905e91e6461225) ) + ROM_REGION( 0x02000, "440audio:audiocpu", 0 ) + ROM_LOAD( "sda-5_h-1.h1", 0x00000, 0x2000, CRC(6a10ff47) SHA1(ee57de74ab9a5cfe5726212a9b905e91e6461225) ) - ROM_REGION( 0x20000, "cvsd", 0 ) + ROM_REGION( 0x20000, "440audio:samples", 0 ) ROM_LOAD( "sda-5_k-2.k2", 0x00000, 0x2000, CRC(67a86f7f) SHA1(a4f70aab90acd2502e8f3f39efdafcd71b1a22b4) ) ROM_LOAD( "sda-5_l-2.l2", 0x02000, 0x2000, CRC(0bb8874b) SHA1(8b643dbd5412a713b3e2831dd1ba2b7d1f613ac2) ) ROM_LOAD( "sda-5_m-2.m2", 0x04000, 0x2000, CRC(8b77eac8) SHA1(d70038cd6655e71c6488c555ecb1d1a424d00d49) ) @@ -1937,10 +1895,10 @@ ROM_START( yukon ) ROM_LOAD( "yul-1.7b", 0x48000, 0x2000, CRC(30a62d8f) SHA1(8b2cefd5c7393ec238d2d7b53320c08cce43c93b) ) ROM_LOAD( "yul-1.8b", 0x4a000, 0x2000, CRC(fa85b58e) SHA1(11c18bff9f473281bcf6677ffffd499496af7b9d) ) - ROM_REGION( 0x10000, "audiocpu", 0 ) - ROM_LOAD( "yua-1.1h", 0x0e000, 0x2000, CRC(f0df665a) SHA1(1fac03007563f569fdf57d5b16a0501e9a4dff01) ) + ROM_REGION( 0x02000, "440audio:audiocpu", 0 ) + ROM_LOAD( "yua-1.1h", 0x00000, 0x2000, CRC(f0df665a) SHA1(1fac03007563f569fdf57d5b16a0501e9a4dff01) ) - ROM_REGION( 0x20000, "cvsd", 0 ) + ROM_REGION( 0x20000, "440audio:samples", 0 ) ROM_LOAD( "yua-1.2k", 0x00000, 0x2000, CRC(67a86f7f) SHA1(a4f70aab90acd2502e8f3f39efdafcd71b1a22b4) ) ROM_LOAD( "yua-1.2l", 0x02000, 0x2000, CRC(0bb8874b) SHA1(8b643dbd5412a713b3e2831dd1ba2b7d1f613ac2) ) ROM_LOAD( "yua-1.2m", 0x04000, 0x2000, CRC(8b77eac8) SHA1(d70038cd6655e71c6488c555ecb1d1a424d00d49) ) @@ -2000,10 +1958,10 @@ ROM_START( yukon1 ) ROM_LOAD( "yul-1.7b", 0x48000, 0x2000, CRC(30a62d8f) SHA1(8b2cefd5c7393ec238d2d7b53320c08cce43c93b) ) ROM_LOAD( "yul-1.8b", 0x4a000, 0x2000, CRC(fa85b58e) SHA1(11c18bff9f473281bcf6677ffffd499496af7b9d) ) - ROM_REGION( 0x10000, "audiocpu", 0 ) - ROM_LOAD( "yua-1.1h", 0x0e000, 0x2000, CRC(f0df665a) SHA1(1fac03007563f569fdf57d5b16a0501e9a4dff01) ) + ROM_REGION( 0x02000, "440audio:audiocpu", 0 ) + ROM_LOAD( "yua-1.1h", 0x00000, 0x2000, CRC(f0df665a) SHA1(1fac03007563f569fdf57d5b16a0501e9a4dff01) ) - ROM_REGION( 0x20000, "cvsd", 0 ) + ROM_REGION( 0x20000, "440audio:samples", 0 ) ROM_LOAD( "yua-1.2k", 0x00000, 0x2000, CRC(67a86f7f) SHA1(a4f70aab90acd2502e8f3f39efdafcd71b1a22b4) ) ROM_LOAD( "yua-1.2l", 0x02000, 0x2000, CRC(0bb8874b) SHA1(8b643dbd5412a713b3e2831dd1ba2b7d1f613ac2) ) ROM_LOAD( "yua-1.2m", 0x04000, 0x2000, CRC(8b77eac8) SHA1(d70038cd6655e71c6488c555ecb1d1a424d00d49) ) diff --git a/src/mame/drivers/f1gp.cpp b/src/mame/drivers/f1gp.cpp index 9b35edb9c1e..a2d8ad79c8d 100644 --- a/src/mame/drivers/f1gp.cpp +++ b/src/mame/drivers/f1gp.cpp @@ -196,7 +196,7 @@ void f1gp_state::f1gpb_cpu2_map(address_map &map) } static INPUT_PORTS_START( f1gp ) - PORT_START("INPUTS") + PORT_START("INPUTS") PORT_BIT( 0x0001, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) PORT_4WAY PORT_CONDITION("JOY_TYPE", 0x01, NOTEQUALS, 0x01) PORT_BIT( 0x0002, IP_ACTIVE_LOW, IPT_JOYSTICK_DOWN ) PORT_4WAY PORT_CONDITION("JOY_TYPE", 0x01, NOTEQUALS, 0x01) PORT_BIT( 0x0004, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT ) PORT_4WAY PORT_CONDITION("JOY_TYPE", 0x01, NOTEQUALS, 0x01) @@ -220,7 +220,7 @@ static INPUT_PORTS_START( f1gp ) PORT_START("WHEEL") PORT_BIT( 0xff, 0x80, IPT_AD_STICK_X ) PORT_SENSITIVITY(10) PORT_KEYDELTA(5) - + PORT_START("DSW1") // listed as "unused" in manual, actually enables free play PORT_DIPNAME( 0x0100, 0x0100, DEF_STR( Free_Play ) ) PORT_DIPLOCATION("SW1:1") @@ -282,7 +282,7 @@ static INPUT_PORTS_START( f1gp ) // listed as "Unused" in manual, it selects between joystick or steering wheel PORT_DIPNAME( 0x8000, 0x8000, "Input Method" ) PORT_DIPLOCATION("SW3:8") PORT_DIPSETTING( 0x8000, "Joystick" ) - // TODO: doesn't work in-game, reads from $fff002 ingame too but doesn't have an effect, + // TODO: doesn't work in-game, reads from $fff002 ingame too but doesn't have an effect, // maybe outputs threshold to $fff000 or it's not supposed to be enabled like the manual claims. PORT_DIPSETTING( 0x0000, "Steering Wheel" ) @@ -295,7 +295,7 @@ static INPUT_PORTS_START( f1gp ) PORT_DIPSETTING( 0x0004, DEF_STR( Hong_Kong ) ) PORT_DIPSETTING( 0x0008, DEF_STR( Taiwan ) ) /* all other values are invalid */ - + PORT_START("JOY_TYPE") PORT_CONFNAME( 0x01, 0x01, "Joystick Type" ) PORT_CONFSETTING( 0x01, "2-Way" ) diff --git a/src/mame/drivers/fastfred.cpp b/src/mame/drivers/fastfred.cpp index 8ee6b93d0bb..7fd738761c4 100644 --- a/src/mame/drivers/fastfred.cpp +++ b/src/mame/drivers/fastfred.cpp @@ -24,6 +24,7 @@ void fastfred_state::machine_start() { + galaxold_state::machine_start(); save_item(NAME(m_charbank)); save_item(NAME(m_colorbank)); save_item(NAME(m_nmi_mask)); diff --git a/src/mame/drivers/fcombat.cpp b/src/mame/drivers/fcombat.cpp index 92042911038..dc22509af7d 100644 --- a/src/mame/drivers/fcombat.cpp +++ b/src/mame/drivers/fcombat.cpp @@ -347,9 +347,9 @@ void fcombat_state::init_fcombat() for (uint32_t oldaddr = 0; oldaddr < length; oldaddr++) { uint32_t newaddr = ((oldaddr ) & 0x1f00) | /* keep n8-n4 */ - ((oldaddr << 3) & 0x00f0) | /* move n3-n0 */ - ((oldaddr >> 4) & 0x000e) | /* move v2-v0 */ - ((oldaddr ) & 0x0001); /* keep h2 */ + ((oldaddr << 3) & 0x00f0) | /* move n3-n0 */ + ((oldaddr >> 4) & 0x000e) | /* move v2-v0 */ + ((oldaddr ) & 0x0001); /* keep h2 */ dst[newaddr] = src[oldaddr]; } @@ -366,10 +366,10 @@ void fcombat_state::init_fcombat() for (uint32_t oldaddr = 0; oldaddr < length; oldaddr++) { uint32_t newaddr = ((oldaddr << 1) & 0x3c00) | /* move n7-n4 */ - ((oldaddr >> 4) & 0x0200) | /* move n3 */ - ((oldaddr << 4) & 0x01c0) | /* move n2-n0 */ - ((oldaddr >> 3) & 0x003c) | /* move v3-v0 */ - ((oldaddr ) & 0xc003); /* keep n9-n8 h3-h2 */ + ((oldaddr >> 4) & 0x0200) | /* move n3 */ + ((oldaddr << 4) & 0x01c0) | /* move n2-n0 */ + ((oldaddr >> 3) & 0x003c) | /* move v3-v0 */ + ((oldaddr ) & 0xc003); /* keep n9-n8 h3-h2 */ dst[newaddr] = src[oldaddr]; } @@ -387,10 +387,10 @@ void fcombat_state::init_fcombat() for (uint32_t oldaddr = 0; oldaddr < length; oldaddr++) { uint32_t newaddr = ((oldaddr << 1) & 0x3c00) | /* move n7-n4 */ - ((oldaddr >> 4) & 0x0200) | /* move n3 */ - ((oldaddr << 4) & 0x01c0) | /* move n2-n0 */ - ((oldaddr >> 3) & 0x003c) | /* move v3-v0 */ - ((oldaddr ) & 0xc003); /* keep n9-n8 h3-h2 */ + ((oldaddr >> 4) & 0x0200) | /* move n3 */ + ((oldaddr << 4) & 0x01c0) | /* move n2-n0 */ + ((oldaddr >> 3) & 0x003c) | /* move v3-v0 */ + ((oldaddr ) & 0xc003); /* keep n9-n8 h3-h2 */ dst[newaddr] = src[oldaddr]; } diff --git a/src/mame/drivers/fidel6502.cpp b/src/mame/drivers/fidel6502.cpp index 72174ca7553..f816d4942f6 100644 --- a/src/mame/drivers/fidel6502.cpp +++ b/src/mame/drivers/fidel6502.cpp @@ -20,7 +20,7 @@ the addressbus at read or write accesses. - granits gives error beeps at start, need to press clear to play - finish fphantom emulation - - PC has 14KB RAM. 0000-0fff and 8000-9fff is certain, where does the remaining map to? + - PC has 14KB RAM. 0000-0fff and 8000-9fff is certain, where does the remaining map to? ****************************************************************************** diff --git a/src/mame/drivers/gamemasters.cpp b/src/mame/drivers/gamemasters.cpp index 612e9324d3d..fe2d1df251a 100644 --- a/src/mame/drivers/gamemasters.cpp +++ b/src/mame/drivers/gamemasters.cpp @@ -42,6 +42,7 @@ private: WRITE8_MEMBER(gamemasters_state::output_1100) { + // IRQ ack? logerror("%s: Writing %02X to 1100\n", machine().describe_context(), data); } @@ -63,7 +64,7 @@ WRITE8_MEMBER(gamemasters_state::output_1540) void gamemasters_state::mem_map(address_map &map) { map(0x0000, 0x07ff).ram().share("nvram"); - map(0x1100, 0x1100).w(this, FUNC(gamemasters_state::output_1300)); + map(0x1100, 0x1100).w(this, FUNC(gamemasters_state::output_1100)); map(0x1300, 0x1300).w(this, FUNC(gamemasters_state::output_1300)); map(0x1400, 0x1400).portr("IN0"); map(0x1500, 0x1500).portr("IN1"); diff --git a/src/mame/drivers/gticlub.cpp b/src/mame/drivers/gticlub.cpp index 14061e1d728..a26e419b979 100644 --- a/src/mame/drivers/gticlub.cpp +++ b/src/mame/drivers/gticlub.cpp @@ -1001,8 +1001,7 @@ MACHINE_CONFIG_START(gticlub_state::gticlub) MCFG_K001604_ROZ_OFFSET(0) MCFG_K001604_PALETTE("palette") - MCFG_DEVICE_ADD("k001005", K001005, 0) - MCFG_K001005_TEXEL_CHIP("k001006_1") + MCFG_DEVICE_ADD("k001005", K001005, 0, "k001006_1") MCFG_DEVICE_ADD("k001006_1", K001006, 0) MCFG_K001006_GFX_REGION("gfx1") diff --git a/src/mame/drivers/igs017.cpp b/src/mame/drivers/igs017.cpp index b8459e7d0f8..f34bc674f60 100644 --- a/src/mame/drivers/igs017.cpp +++ b/src/mame/drivers/igs017.cpp @@ -456,7 +456,7 @@ WRITE8_MEMBER(igs_incdec_device::dec_w) READ8_MEMBER(igs_incdec_device::val_r) { - uint8_t res = (BIT(m_val, 0) << 7) | + uint8_t res = (BIT(m_val, 0) << 7) | (BIT(m_val, 3) << 5) | (BIT(m_val, 2) << 4) | (BIT(m_val, 1) << 2) ; @@ -4718,8 +4718,8 @@ ROM_START( spkrform ) ROM_END -GAME( 1996, iqblocka, iqblock, iqblocka, iqblocka, igs017_state, init_iqblocka, ROT0, "IGS", "Shuzi Leyuan (V127M, Gambling)", 0 ) -GAME( 1997, iqblockf, iqblock, iqblockf, iqblockf, igs017_state, init_iqblocka, ROT0, "IGS", "IQ Block (V113FR, Gambling)", 0 ) +GAME( 1996, iqblocka, iqblock, iqblocka, iqblocka, igs017_state, init_iqblocka, ROT0, "IGS", "Shuzi Leyuan (V127M, gambling)", 0 ) +GAME( 1997, iqblockf, iqblock, iqblockf, iqblockf, igs017_state, init_iqblocka, ROT0, "IGS", "IQ Block (V113FR, gambling)", 0 ) GAME( 1997, mgdh, 0, mgdha, mgdh, igs017_state, init_mgdh, ROT0, "IGS", "Mahjong Man Guan Daheng (Taiwan, V125T1)", MACHINE_IMPERFECT_COLORS ) // wrong colors in betting screen GAME( 1997, mgdha, mgdh, mgdha, mgdh , igs017_state, init_mgdha, ROT0, "IGS", "Mahjong Man Guan Daheng (Taiwan, V123T1)", 0 ) GAME( 1997, sdmg2, 0, sdmg2, sdmg2, igs017_state, init_sdmg2, ROT0, "IGS", "Mahjong Super Da Man Guan II (China, V754C)", 0 ) diff --git a/src/mame/drivers/istrebiteli.cpp b/src/mame/drivers/istrebiteli.cpp index 8ddfbbd222d..664f8985d80 100644 --- a/src/mame/drivers/istrebiteli.cpp +++ b/src/mame/drivers/istrebiteli.cpp @@ -471,4 +471,25 @@ ROM_START( istreb ) ROM_LOAD( "003-w3.bin", 0x000, 0x200, CRC(54eb4893) SHA1(c7a4724045c645ab728074ed7fef1882d9776005) ) ROM_END -GAME( 198?, istreb, 0, istreb, istreb, istrebiteli_state, empty_init, ROT0, "Terminal", "Istrebiteli", MACHINE_IMPERFECT_SOUND | MACHINE_SUPPORTS_SAVE) +// hardware is similar to Istrebiteli, but RAM location and IO is different +ROM_START( motogonki ) + ROM_REGION( 0x2000, I8080_TAG, ROMREGION_ERASEFF ) + ROM_LOAD( "005_mb3.b2", 0x000, 0x2000, CRC(4dd35ed6) SHA1(6a0ee9e370634e501b6ee15a9747a491b745a205) ) + + ROM_REGION( 0x200, "chars", 0 ) + ROM_LOAD( "003_ig8.g8", 0x000, 0x200, CRC(9af1e9de) SHA1(4bc89bc0c1f229ca3ebee983ae2fb3910d8ca599) ) + + ROM_REGION( 0x1000, "sprite", 0 ) // gfx layout is not correct + ROM_LOAD( "006_b1.b1", 0x000, 0x200, CRC(ae9820fb) SHA1(7727d20e314aee670ba36ca6ea7ca5a4da0fc1cd) ) + ROM_LOAD( "006_02.b5", 0x200, 0x200, CRC(e5c17daf) SHA1(1b6ffeba7dd98da11e5eb953280dd53f0f77fa7f) ) + ROM_LOAD( "006_03.b7", 0x400, 0x200, CRC(e1731d8d) SHA1(744fd768754a65a66bfcdb1959b4d6796bff4fcb) ) + ROM_LOAD( "006_05.b3", 0x600, 0x100, CRC(7dc4f9c9) SHA1(8a40f9f021b1662b1c638c7fdcefead1687ca4f1) ) + ROM_LOAD( "006_01.d3", 0x700, 0x100, CRC(b53b83c9) SHA1(8f9733c827cc9aacc7c182585dcbc5da01357468) ) + ROM_LOAD( "006_04.w13", 0x800, 0x100, CRC(6d6441f6) SHA1(999356e5b31a03c667d6cb975210e058e340509e) ) + + ROM_REGION(0x200, "soundrom", 0) + ROM_LOAD( "003_iw3.w3", 0x000, 0x200, CRC(814854ba) SHA1(2cbfd60df01f00d7659393efa58547de660bf201) ) +ROM_END + +GAME( 198?, istreb, 0, istreb, istreb, istrebiteli_state, empty_init, ROT0, "Terminal", "Istrebiteli", MACHINE_IMPERFECT_SOUND | MACHINE_SUPPORTS_SAVE) +GAME( 198?, motogonki, 0, istreb, istreb, istrebiteli_state, empty_init, ROT0, "Terminal", "Motogonki", MACHINE_NOT_WORKING | MACHINE_NO_SOUND) diff --git a/src/mame/drivers/jaguar.cpp b/src/mame/drivers/jaguar.cpp index ea72ee2615d..54efb91a2df 100644 --- a/src/mame/drivers/jaguar.cpp +++ b/src/mame/drivers/jaguar.cpp @@ -406,7 +406,7 @@ void cojag_devices(device_slot_interface &device) * Machine init * *************************************/ - + void jaguar_state::machine_start() { /* configure banks for gfx/sound ROMs */ @@ -446,7 +446,7 @@ void jaguar_state::machine_reset() m_butch_cmd_size = 1; } } - + /* reset banks for gfx/sound ROMs */ if (m_romboard_region != nullptr) { @@ -1341,7 +1341,7 @@ void jaguar_state::jaguarcd_map(address_map &map) * Main CPU memory handlers * *************************************/ - + void jaguar_state::r3000_map(address_map &map) { map(0x04000000, 0x047fffff).ram().share("sharedram"); diff --git a/src/mame/drivers/jeutel.cpp b/src/mame/drivers/jeutel.cpp index 7b81d56782f..7c3e32d5541 100644 --- a/src/mame/drivers/jeutel.cpp +++ b/src/mame/drivers/jeutel.cpp @@ -40,17 +40,20 @@ public: { } void init_jeutel(); + void jeutel(machine_config &config); + +protected: DECLARE_READ8_MEMBER(portb_r); DECLARE_WRITE8_MEMBER(porta_w); DECLARE_WRITE8_MEMBER(ppi0a_w); DECLARE_WRITE8_MEMBER(ppi0b_w); DECLARE_WRITE8_MEMBER(sndcmd_w); TIMER_DEVICE_CALLBACK_MEMBER(timer_a); - void jeutel(machine_config &config); void jeutel_cpu2(address_map &map); void jeutel_cpu3(address_map &map); void jeutel_cpu3_io(address_map &map); void jeutel_map(address_map &map); + private: bool m_timer_a; uint8_t m_sndcmd; diff --git a/src/mame/drivers/ksys573.cpp b/src/mame/drivers/ksys573.cpp index 44dbbf5d0ed..b1cabefa939 100644 --- a/src/mame/drivers/ksys573.cpp +++ b/src/mame/drivers/ksys573.cpp @@ -4627,6 +4627,16 @@ ROM_START( hypbbc2pk ) DISK_IMAGE_READONLY( "908a02", 0, BAD_DUMP SHA1(573194ca9938c30415fc88dcc0c0152dd3024d71) ) ROM_END +ROM_START( jppyex98 ) + SYS573_BIOS_A + + ROM_REGION( 0x0000224, "cassette:game:eeprom", 0 ) + ROM_LOAD( "gc811ja.u1", 0x000000, 0x000224, BAD_DUMP CRC(e0f93270) SHA1(02a110bf692d5d1aa15e66132e3c4f60aa3f0f3c) ) + + DISK_REGION( "cdrom0" ) + DISK_IMAGE_READONLY( "811jaa02", 0, BAD_DUMP SHA1(e9580172d58b38841f643651ae0bcaf24fd5f118) ) +ROM_END + ROM_START( konam80a ) SYS573_BIOS_A @@ -4905,6 +4915,7 @@ GAME( 1998, darkhleg, sys573, konami573x, konami573, ksys573_state, empty_ini GAME( 1998, fbaitbc, sys573, fbaitbc, fbaitbc, ksys573_state, empty_init, ROT0, "Konami", "Fisherman's Bait - A Bass Challenge (GE765 VER. UAB)", MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) GAME( 1998, bassangl, fbaitbc, fbaitbc, fbaitbc, ksys573_state, empty_init, ROT0, "Konami", "Bass Angler (GE765 VER. JAA)", MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) GAME( 1998, powyakex, sys573, konami573x, konami573, ksys573_state, empty_init, ROT0, "Konami", "Jikkyou Powerful Pro Yakyuu EX (GX802 VER. JAB)", MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) +GAME( 1998, jppyex98, sys573, konami573x, konami573, ksys573_state, empty_init, ROT0, "Konami", "Jikkyou Powerful Pro Yakyuu EX '98 (GC811 VER. JAA)", MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) GAME( 1998, konam80s, sys573, konami573x, konami573, ksys573_state, empty_init, ROT90, "Konami", "Konami 80's AC Special (GC826 VER. EAA)", MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) GAME( 1998, konam80u, konam80s, konami573x, konami573, ksys573_state, empty_init, ROT90, "Konami", "Konami 80's AC Special (GC826 VER. UAA)", MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) GAME( 1998, konam80j, konam80s, konami573x, konami573, ksys573_state, empty_init, ROT90, "Konami", "Konami 80's Gallery (GC826 VER. JAA)", MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) diff --git a/src/mame/drivers/mappy.cpp b/src/mame/drivers/mappy.cpp index 19e2aa731a0..f7b4395541e 100644 --- a/src/mame/drivers/mappy.cpp +++ b/src/mame/drivers/mappy.cpp @@ -1311,7 +1311,7 @@ WRITE8_MEMBER(mappy_state::out_lamps) void mappy_state::machine_start() { m_leds.resolve(); - + save_item(NAME(m_main_irq_mask)); save_item(NAME(m_sub_irq_mask)); save_item(NAME(m_sub2_irq_mask)); diff --git a/src/mame/drivers/markham.cpp b/src/mame/drivers/markham.cpp index c498e145ecc..ee973879726 100644 --- a/src/mame/drivers/markham.cpp +++ b/src/mame/drivers/markham.cpp @@ -202,11 +202,11 @@ void markham_state::strnskil_master_map(address_map &map) // void markham_state::banbam_master_map(address_map &map) // { -// /* TODO: uncomment when ready */ -// strnskil_master_map(map); -// map(0xd806, 0xd806).r(this, FUNC(markham_state::mcu_r)); /* mcu data read */ -// map(0xd80d, 0xd80d).w(this, FUNC(markham_state::mcu_w)); /* mcu data write */ -// map(0xd80c, 0xd80c).w(this, FUNC(markham_state::mcu_reset)); /* mcu reset? */ +// /* TODO: uncomment when ready */ +// strnskil_master_map(map); +// map(0xd806, 0xd806).r(this, FUNC(markham_state::mcu_r)); /* mcu data read */ +// map(0xd80d, 0xd80d).w(this, FUNC(markham_state::mcu_w)); /* mcu data write */ +// map(0xd80c, 0xd80c).w(this, FUNC(markham_state::mcu_reset)); /* mcu reset? */ // } void markham_state::markham_slave_map(address_map &map) diff --git a/src/mame/drivers/midzeus.cpp b/src/mame/drivers/midzeus.cpp index 4a85bf3cbd3..b2bef2461e0 100644 --- a/src/mame/drivers/midzeus.cpp +++ b/src/mame/drivers/midzeus.cpp @@ -91,7 +91,7 @@ public: protected: virtual void machine_start() override { - MACHINE_START_CALL_MEMBER(midzeus); + MACHINE_START_CALL_MEMBER(midzeus); m_led.resolve(); m_lamp.resolve(); } diff --git a/src/mame/drivers/mil4000.cpp b/src/mame/drivers/mil4000.cpp index 78315a91980..98d5f789448 100644 --- a/src/mame/drivers/mil4000.cpp +++ b/src/mame/drivers/mil4000.cpp @@ -151,7 +151,7 @@ private: required_device<cpu_device> m_maincpu; required_device<gfxdecode_device> m_gfxdecode; output_finder<7> m_lamps; - + tilemap_t *m_sc0_tilemap; tilemap_t *m_sc1_tilemap; tilemap_t *m_sc2_tilemap; diff --git a/src/mame/drivers/msx.cpp b/src/mame/drivers/msx.cpp index 8eaf0319496..6f73c243584 100644 --- a/src/mame/drivers/msx.cpp +++ b/src/mame/drivers/msx.cpp @@ -61,7 +61,7 @@ ** - cpc50a/cpc50b/cpc51: Boot to a black screen, is this correct? ** - mbh2: speed controller not implemented ** - mbh70: Verify firmware operation -** - kmc5000: Floppy supprt broken +** - kmc5000: Floppy support broken ** - mlg3: rs232c not emulated ** - perfect1: Firmware broken ** - mpc2500f: Fix keyboard layout? @@ -194,7 +194,7 @@ National CF-3000 - MSX1 - cf3000 National CF-3300 - MSX1 - cf3300 National FS-1300 - MSX1 - fs1300 National FS-4000 - MSX1 - fs4000 -Matioanl FS-4000 (alt) - MSX1 - fs4000a +National FS-4000 (alt) - MSX1 - fs4000a National FS-4500 - MSX2 - fs4500 National FS-4600 - MSX2 - fs4600 National FS-4700 - MSX2 - fs4700 @@ -442,7 +442,7 @@ Notes: IC40 - TA75559P Q1 - 10687.5 Q2 - 3579545 - CN1 - Cassette connecter + CN1 - Cassette connector CN2 - RF connector CN3 - Audio connector CN4 - Video connector @@ -507,8 +507,8 @@ Yamaha YIS-503IIR (Russian) - MSX1 - y503iir Yamaha YIS-503IIR (Estonian) - MSX1 - y503iir2 Yamaha YIS-503M - MSX1 - yis503m Yamaha YIS-503IIIR - MSX2 - y503iiir -Yamaha YIS-503IIIR Estonion - MSX2 - y503iiire -Ymaha YIS604 - MSX2 - yis60464 +Yamaha YIS-503IIIR Estonian - MSX2 - y503iiire +Yamaha YIS604 - MSX2 - yis60464 Yamaha YIS604-128 - MSX2 - yis604 Yamaha YIS805-128 - MSX2 - y805128 Yamaha YIS805-128R2 - MSX2 - y805128r2 @@ -2056,6 +2056,28 @@ MACHINE_CONFIG_START(msx_state::cpc51) msx1_cartlist(config); MACHINE_CONFIG_END +/* MSX - Dragon MSX-64 */ + +ROM_START(dgnmsx) + ROM_REGION(0x8000, "maincpu", 0) + ROM_LOAD("uk1msx048.ic37", 0x0000, 0x4000, CRC(24c198be) SHA1(7f8c94cb8913db32a696dec80ffc78e46693f1b7)) + ROM_LOAD("uk2msx058.ic6", 0x4000, 0x4000, CRC(e516e7e5) SHA1(05fedd4b9bfcf4949020c79d32c4c3f03a54fb62)) +ROM_END + +MACHINE_CONFIG_START(msx_state::dgnmsx) + msx_pal(config); + // AY8910 + // FDC: None, 0 drives + // 2 Cartridge slots + + MCFG_MSX_LAYOUT_ROM("bios", 0, 0, 0, 2, "maincpu", 0x0000) + MCFG_MSX_LAYOUT_CARTRIDGE("cartslot1", 1, 0) + MCFG_MSX_LAYOUT_RAM("ram", 2, 0, 0, 4) /* 64KB RAM */ + MCFG_MSX_LAYOUT_CARTRIDGE("cartslot2", 3, 0) + + msx1_cartlist(config); +MACHINE_CONFIG_END + /* MSX - Fenner DPC-200 */ ROM_START (fdpc200) @@ -8520,6 +8542,7 @@ COMP(1985, dpc200e, 0, 0, dpc200e, msx, msx_state, empty_i COMP(1983, cpc50a, cpc51, 0, cpc50a, msxkr, msx_state, empty_init, "Daewoo", "Zemmix CPC-50A (Korea) (MSX1)", 0) COMP(1983, cpc50b, cpc51, 0, cpc50b, msxkr, msx_state, empty_init, "Daewoo", "Zemmix CPC-50B (Korea) (MSX1)", 0) COMP(1986, cpc51, 0, 0, cpc51, msxkr, msx_state, empty_init, "Daewoo", "Zemmix CPC-51 (Korea) (MSX1)", 0) +COMP(1985, dgnmsx, 0, 0, dgnmsx, msx, msx_state, empty_init, "Eurohard S.A.", "Dragon MSX-64 (MSX1)", 0) COMP(1983, fdpc200, 0, 0, fdpc200, msx, msx_state, empty_init, "Fenner", "DPC-200 (Italy) (MSX1)", 0) COMP(1984, fpc500, 0, 0, fpc500, msx, msx_state, empty_init, "Fenner", "FPC-500 (Italy) (MSX1)", 0) COMP(1986, fspc800, 0, 0, fspc800, msx, msx_state, empty_init, "Fenner", "SPC-800 (Italy) (MSX1)", 0) diff --git a/src/mame/drivers/naomi.cpp b/src/mame/drivers/naomi.cpp index 67e17988335..ab46ea963a5 100644 --- a/src/mame/drivers/naomi.cpp +++ b/src/mame/drivers/naomi.cpp @@ -2565,11 +2565,11 @@ static INPUT_PORTS_START( naomi_kb ) PORT_BIT(0x01, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_LCONTROL) PORT_NAME("P1 Left Control") PORT_PLAYER(1) PORT_BIT(0x02, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_LSHIFT) PORT_NAME("P1 Left Shift") PORT_PLAYER(1) PORT_BIT(0x04, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_LALT) PORT_NAME("P1 Left Alt") PORT_PLAYER(1) - PORT_BIT(0x08, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_LWIN) PORT_NAME("P1 S1") PORT_PLAYER(1) + PORT_BIT(0x08, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_LWIN) PORT_NAME("P1 S1") PORT_PLAYER(1) PORT_BIT(0x10, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_RCONTROL) PORT_NAME("P1 Right Control") PORT_PLAYER(1) PORT_BIT(0x20, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_RSHIFT) PORT_NAME("P1 Right Shift") PORT_PLAYER(1) PORT_BIT(0x40, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_RALT) PORT_NAME("P1 Right Alt") PORT_PLAYER(1) - PORT_BIT(0x80, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_RWIN) PORT_NAME("P1 S2") PORT_PLAYER(1) + PORT_BIT(0x80, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_RWIN) PORT_NAME("P1 S2") PORT_PLAYER(1) PORT_START("P1.LD") // TODO: LED information @@ -2580,13 +2580,13 @@ static INPUT_PORTS_START( naomi_kb ) // ---- -x-- scroll lock // ---- --x- caps lock // ---- ---x num lock - + PORT_START("P1.KC1") PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_CUSTOM ) PORT_CUSTOM_MEMBER(DEVICE_SELF, naomi_state, naomi_kb_r, 0) PORT_START("P1.KC2") PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED ) - + PORT_START("P1.KC3") PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_UNUSED ) @@ -2631,14 +2631,14 @@ static INPUT_PORTS_START( naomi_kb ) PORT_BIT(0x10000000, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_PLAYER(1) PORT_CODE(KEYCODE_Y) PORT_NAME("P1 y / Y") PORT_BIT(0x20000000, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_PLAYER(1) PORT_CODE(KEYCODE_Z) PORT_NAME("P1 z / Z") PORT_BIT(0x40000000, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_PLAYER(1) PORT_CODE(KEYCODE_1) PORT_NAME("P1 1 / !") - PORT_BIT(0x80000000, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_PLAYER(1) PORT_CODE(KEYCODE_2) PORT_NAME("P1 2 / “") + PORT_BIT(0x80000000, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_PLAYER(1) PORT_CODE(KEYCODE_2) PORT_NAME("P1 2 / \"") PORT_START("P1.ROW1") PORT_BIT(0x00000001, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_PLAYER(1) PORT_CODE(KEYCODE_3) PORT_NAME("P1 3 / #") PORT_BIT(0x00000002, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_PLAYER(1) PORT_CODE(KEYCODE_4) PORT_NAME("P1 4 / $") PORT_BIT(0x00000004, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_PLAYER(1) PORT_CODE(KEYCODE_5) PORT_NAME("P1 5 / %") PORT_BIT(0x00000008, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_PLAYER(1) PORT_CODE(KEYCODE_6) PORT_NAME("P1 6 / &") - PORT_BIT(0x00000010, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_PLAYER(1) PORT_CODE(KEYCODE_7) PORT_NAME("P1 7 / ‘") + PORT_BIT(0x00000010, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_PLAYER(1) PORT_CODE(KEYCODE_7) PORT_NAME("P1 7 / '") PORT_BIT(0x00000020, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_PLAYER(1) PORT_CODE(KEYCODE_8) PORT_NAME("P1 8 / (") PORT_BIT(0x00000040, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_PLAYER(1) PORT_CODE(KEYCODE_9) PORT_NAME("P1 9 / )") PORT_BIT(0x00000080, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_PLAYER(1) PORT_CODE(KEYCODE_0) PORT_NAME("P1 0 / ~") @@ -2687,7 +2687,7 @@ static INPUT_PORTS_START( naomi_kb ) PORT_BIT(0x00010000, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_PLAYER(1) PORT_CODE(KEYCODE_LEFT) PORT_NAME("P1 Left") PORT_BIT(0x00020000, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_PLAYER(1) PORT_CODE(KEYCODE_DOWN) PORT_NAME("P1 Down") PORT_BIT(0x00040000, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_PLAYER(1) PORT_CODE(KEYCODE_UP) PORT_NAME("P1 Up") - PORT_BIT(0xfff80000, IP_ACTIVE_HIGH, IPT_UNUSED ) + PORT_BIT(0xfff80000, IP_ACTIVE_HIGH, IPT_UNUSED ) PORT_START("P1.ROW3") PORT_BIT(0x0000001f, IP_ACTIVE_HIGH, IPT_UNUSED ) @@ -2702,7 +2702,7 @@ static INPUT_PORTS_START( naomi_kb ) PORT_BIT(0x00000400, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_PLAYER(1) /*PORT_CODE(KEYCODE_?)*/ PORT_NAME("P1 Kanji Henkan") PORT_BIT(0x00000800, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_PLAYER(1) /*PORT_CODE(KEYCODE_?)*/ PORT_NAME("P1 Kanji Muhenkan") PORT_BIT(0xfffff000, IP_ACTIVE_HIGH, IPT_UNUSED ) - + // TODO: keyboard for player 2 PORT_START("P2.M") PORT_DIPNAME( 0x01, 0x00, "P2.ROW0" ) @@ -2732,7 +2732,7 @@ static INPUT_PORTS_START( naomi_kb ) PORT_START("P2.LD") // TODO: same as above - + PORT_START("P2.KC1") PORT_DIPNAME( 0x01, 0x00, "P2.ROW2" ) PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) @@ -3022,7 +3022,7 @@ MACHINE_CONFIG_START(naomi_state::naomigd_kb) MCFG_DC_KEYBOARD_ADD("dcctrl0", "maple_dc", 1, ":P1.M", ":P1.LD", ":P1.KC1", ":P1.KC2", ":P1.KC3", ":P1.KC4", ":P1.KC5", ":P1.KC6") MCFG_DC_KEYBOARD_ADD("dcctrl1", "maple_dc", 2, ":P2.M", ":P2.LD", ":P2.KC1", ":P2.KC2", ":P2.KC3", ":P2.KC4", ":P2.KC5", ":P2.KC6") MACHINE_CONFIG_END - + /* * Naomi 2 */ diff --git a/src/mame/drivers/nbmj9195.cpp b/src/mame/drivers/nbmj9195.cpp index 2ecffb5ac6c..21e65184d65 100644 --- a/src/mame/drivers/nbmj9195.cpp +++ b/src/mame/drivers/nbmj9195.cpp @@ -3492,6 +3492,7 @@ ROM_START( shabdama ) ROM_END // PCB pics are rather blurry, might better fit in another driver +// LD QUIZ 第4å¼¾ ç”ãˆãŸã‚‚ã‚“å‹ã¡! ROM_START( ldquiz4 ) ROM_REGION( 0x10000, "maincpu", 0 ) // 27512 ROM_LOAD( "1.e3", 0x00000, 0x10000, CRC(49255f66) SHA1(bdd01987331c2aadea7f588d39c48c70cd43fc71) ) @@ -3558,4 +3559,4 @@ GAME( 1994, mjegolf, 0, mjegolf, mjegolf, nbmj9195_state, init_nbmj919 GAME( 1991, shabdama, 0, shabdama, mjuraden, nbmj9195_state, init_nbmj9195, ROT0, "Nichibutsu", "LD Mahjong #4 Shabon-Dama", MACHINE_NOT_WORKING | MACHINE_NO_SOUND | MACHINE_SUPPORTS_SAVE ) -GAME( 1992, ldquiz4, 0, shabdama, mjuraden, nbmj9195_state, init_nbmj9195, ROT0, "Nichibutsu", "LD Quiz 4 - Kotaemon Gachi (Japan)", MACHINE_NOT_WORKING | MACHINE_NO_SOUND | MACHINE_SUPPORTS_SAVE ) +GAME( 1992, ldquiz4, 0, shabdama, mjuraden, nbmj9195_state, init_nbmj9195, ROT0, "Nichibutsu", "LD Quiz dai 4-dan - Kotaetamon Gachi! (Japan)", MACHINE_NOT_WORKING | MACHINE_NO_SOUND | MACHINE_SUPPORTS_SAVE ) diff --git a/src/mame/drivers/nmk16.cpp b/src/mame/drivers/nmk16.cpp index 69908cce8f3..d582277afb4 100644 --- a/src/mame/drivers/nmk16.cpp +++ b/src/mame/drivers/nmk16.cpp @@ -1442,21 +1442,21 @@ static INPUT_PORTS_START( tomagic ) PORT_BIT( 0xff00, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_START("IN1") // $080002.w - PORT_BIT( 0x0001, IP_ACTIVE_LOW, IPT_UNKNOWN ) - PORT_BIT( 0x0002, IP_ACTIVE_LOW, IPT_UNKNOWN ) - PORT_BIT( 0x0004, IP_ACTIVE_LOW, IPT_UNKNOWN ) - PORT_BIT( 0x0008, IP_ACTIVE_LOW, IPT_UNKNOWN ) + PORT_BIT( 0x0001, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT ) PORT_8WAY PORT_PLAYER(1) + PORT_BIT( 0x0002, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT ) PORT_8WAY PORT_PLAYER(1) + PORT_BIT( 0x0004, IP_ACTIVE_LOW, IPT_JOYSTICK_DOWN ) PORT_8WAY PORT_PLAYER(1) + PORT_BIT( 0x0008, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) PORT_8WAY PORT_PLAYER(1) PORT_BIT( 0x0010, IP_ACTIVE_LOW, IPT_BUTTON1 ) PORT_PLAYER(1) PORT_BIT( 0x0020, IP_ACTIVE_LOW, IPT_BUTTON2 ) PORT_PLAYER(1) - PORT_BIT( 0x0040, IP_ACTIVE_LOW, IPT_UNKNOWN ) + PORT_BIT( 0x0040, IP_ACTIVE_LOW, IPT_BUTTON3 ) PORT_PLAYER(1) PORT_BIT( 0x0080, IP_ACTIVE_LOW, IPT_UNKNOWN ) - PORT_BIT( 0x0100, IP_ACTIVE_LOW, IPT_UNKNOWN ) - PORT_BIT( 0x0200, IP_ACTIVE_LOW, IPT_UNKNOWN ) - PORT_BIT( 0x0400, IP_ACTIVE_LOW, IPT_UNKNOWN ) - PORT_BIT( 0x0800, IP_ACTIVE_LOW, IPT_UNKNOWN ) + PORT_BIT( 0x0100, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT ) PORT_8WAY PORT_PLAYER(2) + PORT_BIT( 0x0200, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT ) PORT_8WAY PORT_PLAYER(2) + PORT_BIT( 0x0400, IP_ACTIVE_LOW, IPT_JOYSTICK_DOWN ) PORT_8WAY PORT_PLAYER(2) + PORT_BIT( 0x0800, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) PORT_8WAY PORT_PLAYER(2) PORT_BIT( 0x1000, IP_ACTIVE_LOW, IPT_BUTTON1 ) PORT_PLAYER(2) PORT_BIT( 0x2000, IP_ACTIVE_LOW, IPT_BUTTON2 ) PORT_PLAYER(2) - PORT_BIT( 0x4000, IP_ACTIVE_LOW, IPT_UNKNOWN ) + PORT_BIT( 0x4000, IP_ACTIVE_LOW, IPT_BUTTON3 ) PORT_PLAYER(2) PORT_BIT( 0x8000, IP_ACTIVE_LOW, IPT_UNKNOWN ) PORT_START("DSW1") @@ -7054,7 +7054,7 @@ ROM_START( tomagic ) ROM_LOAD( "9.bin", 0x000000, 0x20000, CRC(fcceb24b) SHA1(49e3162c34dfa2ef54ffe190ba91bff73cebe12b) ) ROM_REGION( 0x80000, "bgtile", 0 ) - ROM_LOAD( "10.bin", 0x040000, 0x40000, BAD_DUMP CRC(6d5ee72a) SHA1(f90746cb5bbd87213dece062b7efd59d8fd56d84) ) // half size + ROM_LOAD( "10.bin", 0x000000, 0x80000, CRC(14ef466c) SHA1(02711bd44e146dc30d68cd199023834a63170b0f) ) ROM_REGION( 0x200000, "sprites", 0 ) /* 16x16 sprite tiles */ ROM_LOAD16_BYTE( "7.bin", 0x100001, 0x80000, CRC(0a297c78) SHA1(effe1ee2ab64cb9fbeae0d168346168245942034) ) @@ -8246,4 +8246,4 @@ GAME( 2001, firehawkv, spec2k, firehawk, firehawkv, nmk16_state, empty GAME( 1991, manybloc, 0, manybloc, manybloc, nmk16_state, init_tharrier, ROT270, "Bee-Oh", "Many Block", MACHINE_NO_COCKTAIL | MACHINE_IMPERFECT_SOUND ) // clone board, different sound / bg hardware, but similar memory maps, same tx layer, sprites etc. -GAME( 1997, tomagic, 0, tomagic, tomagic, nmk16_tomagic_state, init_tomagic, ROT0, "Hobbitron T.K.Trading Co. Ltd.", "Tom Tom Magic", MACHINE_NOT_WORKING ) // there are many gambling related strings in the ROM, and an alt version is called Lucky Ball, possibly that one is a gambling title and this isn't? +GAME( 1997, tomagic, 0, tomagic, tomagic, nmk16_tomagic_state, init_tomagic, ROT0, "Hobbitron T.K.Trading Co. Ltd.", "Tom Tom Magic", 0 ) // there are many gambling related strings in the ROM, and an alt version is called Lucky Ball, possibly that one is a gambling title and this isn't? diff --git a/src/mame/drivers/pc9801.cpp b/src/mame/drivers/pc9801.cpp index 2a16c07b68e..9b9d9475d8a 100644 --- a/src/mame/drivers/pc9801.cpp +++ b/src/mame/drivers/pc9801.cpp @@ -7,7 +7,7 @@ driver by Angelo Salese TODO: - - move sound bios ROMs into pc9801_26 / pc9801_86 devices + - move sound bios ROMs into pc9801_26 / pc9801_86 devices - proper 8251 uart hook-up on keyboard - SASI/SCSI support; - Write a PC80S31K device (also used on PC-8801 and PC-88VA, it's the FDC + Z80 sub-system); @@ -649,7 +649,7 @@ void pc9801_state::pc9801_map(address_map &map) { map(0xa0000, 0xa3fff).rw(this, FUNC(pc9801_state::tvram_r), FUNC(pc9801_state::tvram_w)); //TVRAM map(0xa8000, 0xbffff).rw(this, FUNC(pc9801_state::gvram_r), FUNC(pc9801_state::gvram_w)); //bitmap VRAM -// map(0xcc000, 0xcffff).rom().region("sound_bios", 0); //sound BIOS +// map(0xcc000, 0xcffff).rom().region("sound_bios", 0); //sound BIOS map(0xd6000, 0xd6fff).rom().region("fdc_bios_2dd", 0); //floppy BIOS 2dd map(0xd7000, 0xd7fff).rom().region("fdc_bios_2hd", 0); //floppy BIOS 2hd map(0xe8000, 0xfffff).rom().region("ipl", 0); @@ -1405,8 +1405,8 @@ void pc9801_state::pc9821_map(address_map &map) map(0x000a0000, 0x000a3fff).rw(this, FUNC(pc9801_state::tvram_r), FUNC(pc9801_state::tvram_w)); map(0x000a4000, 0x000a4fff).rw(this, FUNC(pc9801_state::pc9801rs_knjram_r), FUNC(pc9801_state::pc9801rs_knjram_w)); map(0x000a8000, 0x000bffff).rw(this, FUNC(pc9801_state::pc9821_grcg_gvram_r), FUNC(pc9801_state::pc9821_grcg_gvram_w)); -// map(0x000cc000, 0x000cffff).rom().region("sound_bios", 0); //sound BIOS -// map(0x000d8000, 0x000d9fff).rom().region("ide",0) +// map(0x000cc000, 0x000cffff).rom().region("sound_bios", 0); //sound BIOS +// map(0x000d8000, 0x000d9fff).rom().region("ide",0) map(0x000da000, 0x000dbfff).ram(); // ide ram map(0x000e0000, 0x000e7fff).rw(this, FUNC(pc9801_state::pc9821_grcg_gvram0_r), FUNC(pc9801_state::pc9821_grcg_gvram0_w)); map(0x000e8000, 0x000fffff).m(m_ipl, FUNC(address_map_bank_device::amap16)); @@ -2680,21 +2680,21 @@ TODO: doesn't boot, missing roms? ROM_START( pc9801vm ) ROM_REGION( 0x30000, "ipl", ROMREGION_ERASEFF ) -// ROM_LOAD( "itf_ux.rom", 0x10000, 0x08000, BAD_DUMP CRC(c7942563) SHA1(61bb210d64c7264be939b11df1e9cd14ffeee3c9) ) -// ROM_LOAD( "bios_vm.rom", 0x18000, 0x18000, CRC(2e2d7cee) SHA1(159549f845dc70bf61955f9469d2281a0131b47f) ) +// ROM_LOAD( "itf_ux.rom", 0x10000, 0x08000, BAD_DUMP CRC(c7942563) SHA1(61bb210d64c7264be939b11df1e9cd14ffeee3c9) ) +// ROM_LOAD( "bios_vm.rom", 0x18000, 0x18000, CRC(2e2d7cee) SHA1(159549f845dc70bf61955f9469d2281a0131b47f) ) // bios - ROM_LOAD16_BYTE( "cpu_board_1a_23128e.bin", 0x10001, 0x4000, CRC(9965c914) SHA1(1ed318b774340bd532ef02ac02f39a012354dbf8) ) - ROM_LOAD16_BYTE( "cpu_board_4a_d23128ec.bin", 0x10000, 0x4000, CRC(e7c24a70) SHA1(cc9584b8e56b391f103e9d559d397d0bc6d00b35) ) + ROM_LOAD16_BYTE( "cpu_board_1a_23128e.bin", 0x10001, 0x4000, CRC(9965c914) SHA1(1ed318b774340bd532ef02ac02f39a012354dbf8) ) + ROM_LOAD16_BYTE( "cpu_board_4a_d23128ec.bin", 0x10000, 0x4000, CRC(e7c24a70) SHA1(cc9584b8e56b391f103e9d559d397d0bc6d00b35) ) // itf - ROM_LOAD16_BYTE( "cpu_board_2a_d23c256ec.bin", 0x18001, 0x8000, CRC(3874970d) SHA1(e50ec5ae38f00dbfd156288dd42c7f2a2bf8bc35) ) - ROM_LOAD16_BYTE( "cpu_board_3a_23c256e.bin", 0x18000, 0x8000, CRC(4128276e) SHA1(32acb7eee779a31838a17ce51b05a9a987af4099) ) + ROM_LOAD16_BYTE( "cpu_board_2a_d23c256ec.bin", 0x18001, 0x8000, CRC(3874970d) SHA1(e50ec5ae38f00dbfd156288dd42c7f2a2bf8bc35) ) + ROM_LOAD16_BYTE( "cpu_board_3a_23c256e.bin", 0x18000, 0x8000, CRC(4128276e) SHA1(32acb7eee779a31838a17ce51b05a9a987af4099) ) ROM_REGION( 0x80000, "chargen", 0 ) -// ROM_LOAD( "font_vm.rom", 0x000000, 0x046800, BAD_DUMP CRC(456d9fc7) SHA1(78ba9960f135372825ab7244b5e4e73a810002ff) ) +// ROM_LOAD( "font_vm.rom", 0x000000, 0x046800, BAD_DUMP CRC(456d9fc7) SHA1(78ba9960f135372825ab7244b5e4e73a810002ff) ) // TODO: it invertes X pixel order and loads 8x8 charset bank in interleaved form, needs mods in own driver_init - ROM_LOAD( "main_board_12f_d2364ec.bin", 0x000000, 0x002000, CRC(11197271) SHA1(8dbd2f25daeed545ea2c74d849f0a209ceaf4dd7) ) + ROM_LOAD( "main_board_12f_d2364ec.bin", 0x000000, 0x002000, CRC(11197271) SHA1(8dbd2f25daeed545ea2c74d849f0a209ceaf4dd7) ) // contains some 8x16 chars - ROM_LOAD( "main_board_8h_d23256ac.bin", 0x002000, 0x008000, CRC(62a32ba6) SHA1(cdab480ae0dad9d128e52afb15e6c0b2b122cc3f) ) + ROM_LOAD( "main_board_8h_d23256ac.bin", 0x002000, 0x008000, CRC(62a32ba6) SHA1(cdab480ae0dad9d128e52afb15e6c0b2b122cc3f) ) ROM_REGION( 0x80000, "raw_kanji", ROMREGION_ERASEFF ) // on main board, uPD23100 type roms @@ -2705,7 +2705,7 @@ ROM_START( pc9801vm ) ROM_REGION( 0x100000, "kanji", ROMREGION_ERASEFF ) ROM_REGION( 0x80000, "new_chargen", ROMREGION_ERASEFF ) -// LOAD_KANJI_ROMS +// LOAD_KANJI_ROMS // LOAD_IDE_ROM ROM_END diff --git a/src/mame/drivers/pgm.cpp b/src/mame/drivers/pgm.cpp index e4c3ae7e645..c37033bf78f 100644 --- a/src/mame/drivers/pgm.cpp +++ b/src/mame/drivers/pgm.cpp @@ -4960,6 +4960,6 @@ GAME( 2008, kovshxas, kovshp, pgm_arm_type1, kovsh, pgm_arm_ty //乱世拳皇/Luà nshì quánhuáng GAME( 200?, kovlsqh, kovshp, pgm_arm_type1, kovsh, pgm_arm_type1_state, init_kovlsqh2, ROT0, "bootleg", "Luanshi Quanhuang (bootleg of Knights of Valour Super Heroes Plus, ver. 200CN)", MACHINE_IMPERFECT_SOUND | MACHINE_UNEMULATED_PROTECTION | MACHINE_NOT_WORKING | MACHINE_SUPPORTS_SAVE ) /* need internal rom of IGS027A */ GAME( 200?, kovlsqh2, kovshp, pgm_arm_type1, kovsh, pgm_arm_type1_state, init_kovlsqh2, ROT0, "bootleg", "Luanshi Quanhuang 2 (bootleg of Knights of Valour Super Heroes Plus, ver. 200CN)", MACHINE_IMPERFECT_SOUND | MACHINE_UNEMULATED_PROTECTION | MACHINE_NOT_WORKING | MACHINE_SUPPORTS_SAVE ) /* need internal rom of IGS027A */ -//乱世街霸/Luà nshì jiÄ“ bà +//乱世街霸/Luà nshì jiÄ“ bà GAME( 200?, kovlsjb, kovshp, pgm_arm_type1, kovsh, pgm_arm_type1_state, init_kovlsqh2, ROT0, "bootleg", "Luanshi Jie Ba (bootleg of Knights of Valour Super Heroes Plus, ver. 200CN, set 1)", MACHINE_IMPERFECT_SOUND | MACHINE_UNEMULATED_PROTECTION | MACHINE_NOT_WORKING | MACHINE_SUPPORTS_SAVE ) /* need internal rom of IGS027A */ GAME( 200?, kovlsjba, kovshp, pgm_arm_type1, kovsh, pgm_arm_type1_state, init_kovlsqh2, ROT0, "bootleg", "Luanshi Jie Ba (bootleg of Knights of Valour Super Heroes Plus, ver. 200CN, set 2)", MACHINE_IMPERFECT_SOUND | MACHINE_UNEMULATED_PROTECTION | MACHINE_NOT_WORKING | MACHINE_SUPPORTS_SAVE ) /* need internal rom of IGS027A */ diff --git a/src/mame/drivers/pk8020.cpp b/src/mame/drivers/pk8020.cpp index 2ca2c9852b1..b58e930bbe8 100644 --- a/src/mame/drivers/pk8020.cpp +++ b/src/mame/drivers/pk8020.cpp @@ -180,14 +180,14 @@ static void pk8020_floppies(device_slot_interface &device) /* * interrupts * - * 0 external devices - * 1 uart rx ready - * 2 uart tx ready - * 3 lan - * 4 vblank - * 5 timer ch2 - * 6 printer - * 7 floppy + * 0 external devices + * 1 uart rx ready + * 2 uart tx ready + * 3 lan + * 4 vblank + * 5 timer ch2 + * 6 printer + * 7 floppy */ /* Machine driver */ MACHINE_CONFIG_START(pk8020_state::pk8020) diff --git a/src/mame/drivers/qtsbc.cpp b/src/mame/drivers/qtsbc.cpp index 3d54091e7e5..b4f8a4f723b 100644 --- a/src/mame/drivers/qtsbc.cpp +++ b/src/mame/drivers/qtsbc.cpp @@ -15,7 +15,7 @@ Chips: P8251, D8253C, MK3880N-4 (Z80). 3x 6-sw dips. Unmarked crystal. A blue jumper marked 4M and 2M (between U11 and U12) selects the CPU clock. The RS232 port uses a 26-pin header (J1) rather than the conventional DB25 -connector. The second 26-pin header (J2) is for the parallel port. +connector. The second 26-pin header (J2) is for the parallel port. Feature list from QT ad: - 1K RAM (which can be located at any 1K boundary) plus one each diff --git a/src/mame/drivers/rowamet.cpp b/src/mame/drivers/rowamet.cpp index 653d039887c..74188c8f5a8 100644 --- a/src/mame/drivers/rowamet.cpp +++ b/src/mame/drivers/rowamet.cpp @@ -45,15 +45,18 @@ public: , m_digits(*this, "digit%u", 0U) { } + void rowamet(machine_config &config); + +protected: DECLARE_READ8_MEMBER(sound_r); DECLARE_WRITE8_MEMBER(mute_w); DECLARE_READ8_MEMBER(io_r); DECLARE_WRITE8_MEMBER(io_w); TIMER_DEVICE_CALLBACK_MEMBER(timer_a); - void rowamet(machine_config &config); void rowamet_map(address_map &map); void rowamet_sub_io(address_map &map); void rowamet_sub_map(address_map &map); + private: uint8_t m_out_offs; uint8_t m_sndcmd; diff --git a/src/mame/drivers/rungun.cpp b/src/mame/drivers/rungun.cpp index 51530bb5afd..0646ccd52d6 100644 --- a/src/mame/drivers/rungun.cpp +++ b/src/mame/drivers/rungun.cpp @@ -109,7 +109,7 @@ WRITE16_MEMBER(rungun_state::sysregs_w) membank("spriteram_bank")->set_entry((data & 0x80) >> 7); m_video_mux_bank = ((data & 0x80) >> 7) ^ 1; ioport("EEPROMOUT")->write(data, 0xff); - + machine().bookkeeping().coin_counter_w(0, data & 0x08); machine().bookkeeping().coin_counter_w(1, data & 0x10); } @@ -383,7 +383,7 @@ void rungun_state::machine_start() save_item(NAME(m_sound_status)); save_item(NAME(m_sound_nmi_clk)); //save_item(NAME(m_ttl_vram)); - + } void rungun_state::machine_reset() @@ -454,14 +454,14 @@ MACHINE_CONFIG_START(rungun_state::rng) MCFG_K054321_ADD("k054321", "lspeaker", "rspeaker") // SFX - MCFG_DEVICE_ADD("k054539_1", K054539, XTAL(18'432'000)) + MCFG_DEVICE_ADD("k054539_1", K054539, 18.432_MHz_XTAL) MCFG_DEVICE_ADDRESS_MAP(0, k054539_map) MCFG_K054539_TIMER_HANDLER(WRITELINE(*this, rungun_state, k054539_nmi_gen)) MCFG_SOUND_ROUTE(0, "lspeaker", 1.0) MCFG_SOUND_ROUTE(1, "rspeaker", 1.0) - // BGM, volumes handtuned to make SFXs heardable (still not 100% right tho) - MCFG_DEVICE_ADD("k054539_2", K054539, XTAL(18'432'000)) + // BGM, volumes handtuned to make SFXs audible (still not 100% right tho) + MCFG_DEVICE_ADD("k054539_2", K054539, 18.432_MHz_XTAL) MCFG_DEVICE_ADDRESS_MAP(0, k054539_map) MCFG_SOUND_ROUTE(0, "lspeaker", 0.25) MCFG_SOUND_ROUTE(1, "rspeaker", 0.25) diff --git a/src/mame/drivers/seicupbl.cpp b/src/mame/drivers/seicupbl.cpp index f2000226e59..755543816fe 100644 --- a/src/mame/drivers/seicupbl.cpp +++ b/src/mame/drivers/seicupbl.cpp @@ -163,18 +163,18 @@ void seicupbl_state::draw_sprites(screen_device &screen, bitmap_ind16 &bitmap,co switch (cur_pri) { // gumdam swamp monster l2 - case 0: pri_mask = -256; break; + case 0: pri_mask = -256; break; // (players and football goal, should go above sidelines but behind portraits when there's a goal) case 1: pri_mask = 0xfff0; break; // masking effect for gundam l2 monster - case 2: pri_mask = -4; break; + case 2: pri_mask = -4; break; // cupsoc (radar dots) - case 3: pri_mask = 0x0000; break; + case 3: pri_mask = 0x0000; break; // gundam level 2/3 player case 4: pri_mask = -32; break; //case 5: pri_mask = 0; break; // insert coin in gundam - case 6: pri_mask = 0; break; + case 6: pri_mask = 0; break; //case 7: pri_mask = 0; break; default: printf("unhandled pri %d\n",cur_pri); pri_mask=0; @@ -292,16 +292,16 @@ uint32_t seicupbl_state::screen_update( screen_device &screen, bitmap_ind16 &bit m_sc_layer[i]->set_scrolly(0, m_vregs[i*2+1]); } - if (!(m_layer_disable&0x0001)) + if (!(m_layer_disable&0x0001)) m_sc_layer[0]->draw(screen, bitmap, cliprect, 0, 1); - - if (!(m_layer_disable&0x0002)) + + if (!(m_layer_disable&0x0002)) m_sc_layer[1]->draw(screen, bitmap, cliprect, 0, 2); - - if (!(m_layer_disable&0x0004)) + + if (!(m_layer_disable&0x0004)) m_sc_layer[2]->draw(screen, bitmap, cliprect, 0, 4); - - if (!(m_layer_disable&0x0008)) + + if (!(m_layer_disable&0x0008)) m_sc_layer[3]->draw(screen, bitmap, cliprect, 0, 8); if (!(m_layer_disable&0x0010)) diff --git a/src/mame/drivers/seta2.cpp b/src/mame/drivers/seta2.cpp index 3b79cc77028..5971a9fa713 100644 --- a/src/mame/drivers/seta2.cpp +++ b/src/mame/drivers/seta2.cpp @@ -4258,7 +4258,7 @@ ROM_START( trophyh ) /* Version 1.00 - v: Thu Mar 28 12:35:50 2002 JST-9 - on a ROM_REGION( 0x500000, "x1snd", 0 ) // Samples // Leave 1MB empty (addressable by the chip) - ROM_LOAD( "as1105m01.u18", 0x100000, 0x400000, CRC(633d0df8) SHA1(3401c424f5c207ef438a9269e0c0e7d482771fed) ) + ROM_LOAD( "as1105m01.u18", 0x100000, 0x400000, CRC(633d0df8) SHA1(3401c424f5c207ef438a9269e0c0e7d482771fed) ) ROM_END ROM_START( trophyht ) /* V1.00 Location Test - v: Tue Feb 26 18:18:43 2002 JST-9 - on a P0-145-1 main PCB with a P1-115A flash ROM board */ @@ -4364,7 +4364,7 @@ GAME( 2001, wschamp, 0, samshoot, wschamp, seta2_state, empty_init, GAME( 2001, wschampa, wschamp, samshoot, wschamp, seta2_state, empty_init, ROT0, "Sammy USA Corporation", "Wing Shooting Championship V1.01", MACHINE_NO_COCKTAIL | MACHINE_IMPERFECT_GRAPHICS ) GAME( 2001, wschampb, wschamp, samshoot, wschamp, seta2_state, empty_init, ROT0, "Sammy USA Corporation", "Wing Shooting Championship V1.00", MACHINE_NO_COCKTAIL | MACHINE_IMPERFECT_GRAPHICS ) GAME( 2002, trophyh, 0, samshoot, trophyh, seta2_state, empty_init, ROT0, "Sammy USA Corporation", "Trophy Hunting - Bear & Moose V1.0", MACHINE_NO_COCKTAIL | MACHINE_IMPERFECT_GRAPHICS ) -GAME( 2002, trophyht, trophyh, samshoot, trophyht, seta2_state, empty_init, ROT0, "Sammy USA Corporation", "Trophy Hunting - Bear & Moose V1.0 (Location Test)", MACHINE_NO_COCKTAIL | MACHINE_IMPERFECT_GRAPHICS ) +GAME( 2002, trophyht, trophyh, samshoot, trophyht, seta2_state, empty_init, ROT0, "Sammy USA Corporation", "Trophy Hunting - Bear & Moose V1.0 (location test)", MACHINE_NO_COCKTAIL | MACHINE_IMPERFECT_GRAPHICS ) GAME( 2000, funcube, 0, funcube, funcube, funcube_state, init_funcube, ROT0, "Namco", "Funcube (v1.5)", MACHINE_NO_COCKTAIL ) GAME( 2001, funcube2, 0, funcube2, funcube, funcube_state, init_funcube2, ROT0, "Namco", "Funcube 2 (v1.1)", MACHINE_NO_COCKTAIL ) GAME( 2001, funcube3, 0, funcube3, funcube, funcube_state, init_funcube3, ROT0, "Namco", "Funcube 3 (v1.1)", MACHINE_NO_COCKTAIL ) diff --git a/src/mame/drivers/simpl156.cpp b/src/mame/drivers/simpl156.cpp index 3b0fac1d6c2..5468f372058 100644 --- a/src/mame/drivers/simpl156.cpp +++ b/src/mame/drivers/simpl156.cpp @@ -1056,8 +1056,8 @@ void simpl156_state::init_simpl156() for (uint32_t x = 0; x < length; x++) { uint32_t addr = bitswap<24> (x,23, - 22,21, 0,20, - 19,18,17,16, + 22,21, 0,20, + 19,18,17,16, 15,14,13,12, 11,10, 9, 8, 7, 6, 5, 4, diff --git a/src/mame/drivers/spectra.cpp b/src/mame/drivers/spectra.cpp index 9170c7d8b7c..9c2adec6e45 100644 --- a/src/mame/drivers/spectra.cpp +++ b/src/mame/drivers/spectra.cpp @@ -57,14 +57,17 @@ public: , m_digits(*this, "digit%u", 0U) { } + void spectra(machine_config &config); + +protected: DECLARE_READ8_MEMBER(porta_r); DECLARE_READ8_MEMBER(portb_r); DECLARE_WRITE8_MEMBER(porta_w); DECLARE_WRITE8_MEMBER(portb_w); TIMER_DEVICE_CALLBACK_MEMBER(nmitimer); TIMER_DEVICE_CALLBACK_MEMBER(outtimer); - void spectra(machine_config &config); void spectra_map(address_map &map); + private: uint8_t m_porta; uint8_t m_portb; diff --git a/src/mame/drivers/subsino.cpp b/src/mame/drivers/subsino.cpp index e840760a910..3c2b9440e22 100644 --- a/src/mame/drivers/subsino.cpp +++ b/src/mame/drivers/subsino.cpp @@ -964,7 +964,7 @@ WRITE8_MEMBER(subsino_state::out_c_w) for (uint8_t reel = 0; reel < 3; reel++) m_reel_tilemap[reel]->mark_all_dirty(); -// popmessage("data %02x\n",data); +// popmessage("data %02x\n",data); } void subsino_state::tisub_map(address_map &map) diff --git a/src/mame/drivers/taitogn.cpp b/src/mame/drivers/taitogn.cpp index 80130271701..895286ab5a5 100644 --- a/src/mame/drivers/taitogn.cpp +++ b/src/mame/drivers/taitogn.cpp @@ -592,7 +592,7 @@ READ32_MEMBER(taitogn_state::zsg2_ext_r) switch (offset & 0x300000) { case 0x000000: - case 0x100000: + case 0x100000: case 0x200000: return m_sndflash[offset >> 20]->read(offset & 0xfffff) | m_sndflash[offset >> 20]->read((offset & 0xfffff) | 1) << 16; default: diff --git a/src/mame/drivers/tandy1t.cpp b/src/mame/drivers/tandy1t.cpp index d9bf6c9bf88..9084f710007 100644 --- a/src/mame/drivers/tandy1t.cpp +++ b/src/mame/drivers/tandy1t.cpp @@ -420,7 +420,7 @@ void tandy1000_state::machine_start() else m_maincpu->space(AS_PROGRAM).install_readwrite_handler(m_ram->size() - (128*1024), 640*1024 - 1, read8_delegate(FUNC(tandy1000_state::vram_r), this), write8_delegate(FUNC(tandy1000_state::vram_w), this), 0xffff); - machine().device<nvram_device>("nvram")->set_base(m_eeprom_ee, sizeof(m_eeprom_ee)); + subdevice<nvram_device>("nvram")->set_base(m_eeprom_ee, sizeof(m_eeprom_ee)); } READ8_MEMBER( tandy1000_state::tandy1000_bank_r ) diff --git a/src/mame/drivers/tatsumi.cpp b/src/mame/drivers/tatsumi.cpp index f5d1275ac78..ca4215651e4 100644 --- a/src/mame/drivers/tatsumi.cpp +++ b/src/mame/drivers/tatsumi.cpp @@ -27,7 +27,7 @@ changes the size at runtime. Big Fight/Cyclewarriors - misc graphics problems. Cyclewarriors - test mode text does not appear as it needs a -256 Y scroll offset from somewhere. - + reference of bigfight : https://youtu.be/aUUoUCr6yhk Emulation by Bryan McPhail, mish@tendril.co.uk @@ -161,6 +161,14 @@ /***************************************************************************/ + +WRITE8_MEMBER(cyclwarr_state::cyclwarr_sound_w) +{ + m_soundlatch->write(space, 0, data); + m_audiocpu->pulse_input_line(INPUT_LINE_NMI, attotime::zero); +} + + READ16_MEMBER(cyclwarr_state::cyclwarr_sprite_r) { return m_spriteram[offset]; @@ -306,7 +314,7 @@ void cyclwarr_state::cyclwarr_68000a_map(address_map &map) map(0x0a4000, 0x0a4001).w(this, FUNC(cyclwarr_state::bigfight_a40000_w)); map(0x0a6000, 0x0a6001).w(this, FUNC(cyclwarr_state::bigfight_a60000_w)); - map(0x0b8000, 0x0b8001).w(m_soundlatch, FUNC(generic_latch_8_device::write)).umask16(0xff00).cswidth(16); + map(0x0b8000, 0x0b8001).w(this, FUNC(cyclwarr_state::cyclwarr_sound_w)).umask16(0xff00); map(0x0b9000, 0x0b900f).rw("io1", FUNC(cxd1095_device::read), FUNC(cxd1095_device::write)).umask16(0x00ff).cswidth(16); map(0x0ba000, 0x0ba00f).rw("io2", FUNC(cxd1095_device::read), FUNC(cxd1095_device::write)).umask16(0x00ff).cswidth(16); map(0x0c0000, 0x0c3fff).rw(this, FUNC(cyclwarr_state::cyclwarr_sprite_r), FUNC(cyclwarr_state::cyclwarr_sprite_w)).share("spriteram"); @@ -362,7 +370,7 @@ void cyclwarr_state::bigfight_68000a_map(address_map &map) map(0x0a4000, 0x0a4001).w(this, FUNC(cyclwarr_state::bigfight_a40000_w)); map(0x0a6000, 0x0a6001).w(this, FUNC(cyclwarr_state::bigfight_a60000_w)); - map(0x0b8000, 0x0b8001).w(m_soundlatch, FUNC(generic_latch_8_device::write)).umask16(0xff00).cswidth(16); + map(0x0b8000, 0x0b8001).w(this, FUNC(cyclwarr_state::cyclwarr_sound_w)).umask16(0xff00); map(0x0b9000, 0x0b900f).rw("io1", FUNC(cxd1095_device::read), FUNC(cxd1095_device::write)).umask16(0x00ff).cswidth(16); map(0x0ba000, 0x0ba00f).rw("io2", FUNC(cxd1095_device::read), FUNC(cxd1095_device::write)).umask16(0x00ff).cswidth(16); map(0x0c0000, 0x0c3fff).rw(this, FUNC(cyclwarr_state::cyclwarr_sprite_r), FUNC(cyclwarr_state::cyclwarr_sprite_w)).share("spriteram"); @@ -627,8 +635,8 @@ static INPUT_PORTS_START( cyclwarr ) PORT_DIPNAME( 0x04, 0x04, "Ticket Dispenser" ) PORT_DIPLOCATION("SW2:3") PORT_DIPSETTING( 0x04, "10000" ) PORT_DIPSETTING( 0x00, "15000" ) - PORT_DIPNAME( 0x18, 0x00, "Machine Type" ) PORT_DIPLOCATION("SW2:4,5") - PORT_DIPSETTING( 0x00, "2 Players" ) + PORT_DIPNAME( 0x18, 0x08, "Machine Type" ) PORT_DIPLOCATION("SW2:4,5") +// PORT_DIPSETTING( 0x00, "2 Players" ) // same as 4 players but text layout is 2p (invalid setting) PORT_DIPSETTING( 0x08, "2 Players" ) PORT_DIPSETTING( 0x10, "3 Players" ) PORT_DIPSETTING( 0x18, "4 Players" ) @@ -1020,7 +1028,7 @@ MACHINE_CONFIG_START(cyclwarr_state::cyclwarr) SPEAKER(config, "rspeaker").front_right(); MCFG_GENERIC_LATCH_8_ADD("soundlatch") - MCFG_GENERIC_LATCH_DATA_PENDING_CB(INPUTLINE("audiocpu", INPUT_LINE_NMI)) +// MCFG_GENERIC_LATCH_DATA_PENDING_CB(INPUTLINE("audiocpu", INPUT_LINE_NMI)) MCFG_DEVICE_ADD("ymsnd", YM2151, CLOCK_1 / 4) MCFG_YM2151_IRQ_HANDLER(INPUTLINE("audiocpu", INPUT_LINE_IRQ0)) @@ -1080,7 +1088,7 @@ MACHINE_CONFIG_START(cyclwarr_state::bigfight) SPEAKER(config, "rspeaker").front_right(); MCFG_GENERIC_LATCH_8_ADD("soundlatch") - MCFG_GENERIC_LATCH_DATA_PENDING_CB(INPUTLINE("audiocpu", INPUT_LINE_NMI)) +// MCFG_GENERIC_LATCH_DATA_PENDING_CB(INPUTLINE("audiocpu", INPUT_LINE_NMI)) MCFG_DEVICE_ADD("ymsnd", YM2151, CLOCK_1 / 4) MCFG_YM2151_IRQ_HANDLER(INPUTLINE("audiocpu", INPUT_LINE_IRQ0)) @@ -1484,9 +1492,9 @@ void cyclwarr_state::init_cyclwarr() /* http://www.tatsu-mi.co.jp/game/trace/index.html */ /* ** 1987 grayout - Gray Out (not dumped yet) */ -GAME( 1988, apache3, 0, apache3, apache3, apache3_state, init_apache3, ROT0, "Tatsumi", "Apache 3", MACHINE_IMPERFECT_GRAPHICS ) -GAME( 1988, apache3a, apache3, apache3, apache3, apache3_state, init_apache3, ROT0, "Tatsumi (Kana Corporation license)", "Apache 3 (Kana Corporation license)", MACHINE_IMPERFECT_GRAPHICS ) +GAME( 1988, apache3, 0, apache3, apache3, apache3_state, init_apache3, ROT0, "Tatsumi", "Apache 3", MACHINE_IMPERFECT_GRAPHICS | MACHINE_NOT_WORKING ) +GAME( 1988, apache3a, apache3, apache3, apache3, apache3_state, init_apache3, ROT0, "Tatsumi (Kana Corporation license)", "Apache 3 (Kana Corporation license)", MACHINE_IMPERFECT_GRAPHICS | MACHINE_NOT_WORKING ) GAMEL(1989, roundup5, 0, roundup5, roundup5, roundup5_state, init_roundup5, ROT0, "Tatsumi", "Round Up 5 - Super Delta Force", MACHINE_IMPERFECT_GRAPHICS, layout_roundup5 ) -GAME( 1991, cyclwarr, 0, cyclwarr, cyclwarr, cyclwarr_state, init_cyclwarr, ROT0, "Tatsumi", "Cycle Warriors (rev C)", MACHINE_IMPERFECT_GRAPHICS ) // Rev C & B CPU code -GAME( 1991, cyclwarra, cyclwarr, cyclwarr, cyclwarb, cyclwarr_state, init_cyclwarr, ROT0, "Tatsumi", "Cycle Warriors (rev B)", MACHINE_IMPERFECT_GRAPHICS ) // Rev B & A CPU code +GAME( 1991, cyclwarr, 0, cyclwarr, cyclwarr, cyclwarr_state, init_cyclwarr, ROT0, "Tatsumi", "Cycle Warriors (rev C)", MACHINE_IMPERFECT_GRAPHICS | MACHINE_NOT_WORKING ) // Rev C & B CPU code +GAME( 1991, cyclwarra, cyclwarr, cyclwarr, cyclwarb, cyclwarr_state, init_cyclwarr, ROT0, "Tatsumi", "Cycle Warriors (rev B)", MACHINE_IMPERFECT_GRAPHICS | MACHINE_NOT_WORKING ) // Rev B & A CPU code GAME( 1992, bigfight, 0, bigfight, bigfight, cyclwarr_state, init_cyclwarr, ROT0, "Tatsumi", "Big Fight - Big Trouble In The Atlantic Ocean", MACHINE_IMPERFECT_GRAPHICS ) diff --git a/src/mame/drivers/unior.cpp b/src/mame/drivers/unior.cpp index aaedeb1cfd4..bc772d7e75e 100644 --- a/src/mame/drivers/unior.cpp +++ b/src/mame/drivers/unior.cpp @@ -61,6 +61,9 @@ public: , m_p_vram(*this, "vram") { } + void unior(machine_config &config); + +protected: DECLARE_WRITE8_MEMBER(vram_w); DECLARE_WRITE8_MEMBER(scroll_w); DECLARE_READ8_MEMBER(ppi0_b_r); @@ -75,9 +78,9 @@ public: DECLARE_READ8_MEMBER(dma_r); I8275_DRAW_CHARACTER_MEMBER(display_pixels); - void unior(machine_config &config); void unior_io(address_map &map); void unior_mem(address_map &map); + private: uint8_t m_4c; uint8_t m_4e; diff --git a/src/mame/drivers/univac.cpp b/src/mame/drivers/univac.cpp index da5d92964c8..dbe8490dcf4 100644 --- a/src/mame/drivers/univac.cpp +++ b/src/mame/drivers/univac.cpp @@ -74,6 +74,9 @@ public: , m_framecnt(0) { } + void uts20(machine_config &config); + +protected: DECLARE_READ8_MEMBER(ram_r); DECLARE_READ8_MEMBER(bank_r); DECLARE_WRITE8_MEMBER(ram_w); @@ -86,10 +89,8 @@ public: u32 screen_update(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect); - void uts20(machine_config &config); void io_map(address_map &map); void mem_map(address_map &map); -protected: virtual void machine_start() override; virtual void machine_reset() override; virtual void device_post_load() override; diff --git a/src/mame/drivers/vamphalf.cpp b/src/mame/drivers/vamphalf.cpp index 54fd538e360..e0a3fc4017f 100644 --- a/src/mame/drivers/vamphalf.cpp +++ b/src/mame/drivers/vamphalf.cpp @@ -138,7 +138,7 @@ public: DECLARE_WRITE32_MEMBER(eeprom32_w); DECLARE_WRITE16_MEMBER(flipscreen_w); DECLARE_WRITE32_MEMBER(flipscreen32_w); - + void banked_oki(int chip); void common_map(address_map &map); @@ -2845,7 +2845,7 @@ ROMs: VROM1/VROM2 - ST M27C4001 4MBit DIP32 EPROM ROM0/ROM1 - ST M27C4001 4MBit DIP32 EPROM * ROM2/ROM3 - Unpopulated space for DIP32 EPROM (up to 4MBit) - + */ ROM_START( boonggab ) diff --git a/src/mame/drivers/vertigo.cpp b/src/mame/drivers/vertigo.cpp index 10ff3ce80da..ed97be3ae51 100644 --- a/src/mame/drivers/vertigo.cpp +++ b/src/mame/drivers/vertigo.cpp @@ -19,15 +19,11 @@ #include "cpu/m6805/m68705.h" #include "cpu/m6805/m6805.h" -#include "cpu/m6809/m6809.h" #include "cpu/m68000/m68000.h" #include "machine/pit8253.h" #include "machine/nvram.h" #include "screen.h" -#define EXIDY440_AUDIO_CLOCK (XTAL(12'979'200) / 4) -#define EXIDY440_MC3418_CLOCK (EXIDY440_AUDIO_CLOCK / 4 / 16) - /************************************* * @@ -53,21 +49,6 @@ void vertigo_state::vertigo_map(address_map &map) map(0x800000, 0x81ffff).rom(); } -void vertigo_state::exidy440_audio_map(address_map &map) -{ - map(0x0000, 0x7fff).noprw(); - map(0x8000, 0x801f).mirror(0x03e0).rw(m_custom, FUNC(exidy440_sound_device::m6844_r), FUNC(exidy440_sound_device::m6844_w)); - map(0x8400, 0x840f).mirror(0x03f0).rw(m_custom, FUNC(exidy440_sound_device::sound_volume_r), FUNC(exidy440_sound_device::sound_volume_w)); - map(0x8800, 0x8800).mirror(0x03ff).r(m_custom, FUNC(exidy440_sound_device::sound_command_r)).nopw(); - map(0x8c00, 0x93ff).noprw(); - map(0x9400, 0x9403).mirror(0x03fc).nopr().w(m_custom, FUNC(exidy440_sound_device::sound_banks_w)); - map(0x9800, 0x9800).mirror(0x03ff).nopr().w(m_custom, FUNC(exidy440_sound_device::sound_interrupt_clear_w)); - map(0x9c00, 0x9fff).noprw(); - map(0xa000, 0xbfff).ram(); - map(0xc000, 0xdfff).noprw(); - map(0xe000, 0xffff).rom(); -} - /************************************* * @@ -139,7 +120,12 @@ MACHINE_CONFIG_START(vertigo_state::vertigo) MCFG_ADC0808_IN2_CB(IOPORT("PADDLE")) // IN3-IN7 tied to Vss - exidy440_audio(config); + SPEAKER(config, "lspeaker").front_left(); + SPEAKER(config, "rspeaker").front_right(); + + MCFG_DEVICE_ADD("440audio", EXIDY440, EXIDY440_MC3418_CLOCK) + MCFG_SOUND_ROUTE(0, "lspeaker", 1.0) + MCFG_SOUND_ROUTE(1, "rspeaker", 1.0) MCFG_DEVICE_ADD("pit", PIT8254, 0) MCFG_PIT8253_CLK0(24_MHz_XTAL / 100) @@ -165,32 +151,6 @@ MACHINE_CONFIG_START(vertigo_state::vertigo) MCFG_SCREEN_UPDATE_DEVICE("vector", vector_device, screen_update) MACHINE_CONFIG_END -MACHINE_CONFIG_START(vertigo_state::exidy440_audio) - - MCFG_DEVICE_ADD("audiocpu", MC6809, EXIDY440_AUDIO_CLOCK) - MCFG_DEVICE_PROGRAM_MAP(exidy440_audio_map) - MCFG_DEVICE_VBLANK_INT_DRIVER("screen", driver_device, irq0_line_assert) - - SPEAKER(config, "lspeaker").front_left(); - SPEAKER(config, "rspeaker").front_right(); - - MCFG_DEVICE_ADD("custom", EXIDY440, EXIDY440_MC3418_CLOCK) - MCFG_SOUND_ROUTE(0, "lspeaker", 1.0) - MCFG_SOUND_ROUTE(1, "rspeaker", 1.0) - -// MCFG_DEVICE_ADD("cvsd1", MC3418, EXIDY440_MC3418_CLOCK) -// MCFG_SOUND_ROUTE(ALL_OUTPUTS, "lspeaker", 1.0) - -// MCFG_DEVICE_ADD("cvsd2", MC3418, EXIDY440_MC3418_CLOCK) -// MCFG_SOUND_ROUTE(ALL_OUTPUTS, "rspeaker", 1.0) - -// MCFG_DEVICE_ADD("cvsd3", MC3417, EXIDY440_MC3417_CLOCK) -// MCFG_SOUND_ROUTE(ALL_OUTPUTS, "lspeaker", 1.0) - -// MCFG_DEVICE_ADD("cvsd4", MC3417, EXIDY440_MC3417_CLOCK) -// MCFG_SOUND_ROUTE(ALL_OUTPUTS, "rspeaker", 1.0) -MACHINE_CONFIG_END - /************************************* * @@ -238,10 +198,10 @@ ROM_START( topgunnr ) ROMX_LOAD( "vuc.03", 7, 0x200, CRC(23c1f136) SHA1(0eb959aa8fb6028dd97bdaa28981cec16652bf2d), ROM_NIBBLE | ROM_SHIFT_NIBBLE_LO | ROM_SKIP(7)) ROMX_LOAD( "vuc.04", 7, 0x200, CRC(a5389228) SHA1(922d49c949e31413bbbff118c04965b649864a67), ROM_NIBBLE | ROM_SHIFT_NIBBLE_HI | ROM_SKIP(7)) - ROM_REGION( 0x010000, "audiocpu", 0 ) - ROM_LOAD( "vga1_7.g7", 0x0e000, 0x2000, CRC(db109b19) SHA1(c3fbb28cb4679c021bc48f844097add39a2208a5) ) + ROM_REGION( 0x02000, "440audio:audiocpu", 0 ) + ROM_LOAD( "vga1_7.g7", 0x00000, 0x2000, CRC(db109b19) SHA1(c3fbb28cb4679c021bc48f844097add39a2208a5) ) - ROM_REGION( 0x20000, "cvsd", 0 ) + ROM_REGION( 0x20000, "440audio:samples", 0 ) ROM_LOAD( "vga1_7.l6", 0x00000, 0x2000, CRC(20cbf97a) SHA1(13e138b08ba3328db6a2fba95a369422455d1c5c) ) ROM_LOAD( "vga1_7.m6", 0x02000, 0x2000, CRC(76197050) SHA1(d26701ba83a34384348fa34e3de78cc69dc5362e) ) ROM_LOAD( "vga1_7.n6", 0x04000, 0x2000, CRC(b93d7cbb) SHA1(1a4d05e03765b66ff20b963c5a0b5f7c3d5a360c) ) diff --git a/src/mame/drivers/vii.cpp b/src/mame/drivers/vii.cpp index 4bbfd165317..982136b61b6 100644 --- a/src/mame/drivers/vii.cpp +++ b/src/mame/drivers/vii.cpp @@ -1289,7 +1289,7 @@ void spg2xx_cart_state::machine_start() void spg2xx_game_state::machine_start() { - memset(m_video_regs, 0, 0x100 * sizeof(m_video_regs[0])); + memset(m_video_regs, 0, 0x100 * sizeof(m_video_regs[0])); memset(m_io_regs, 0, 0x200 * sizeof(m_io_regs[0])); m_current_bank = 0; diff --git a/src/mame/drivers/witch.cpp b/src/mame/drivers/witch.cpp index c7548f3089e..5e0f6f0181c 100644 --- a/src/mame/drivers/witch.cpp +++ b/src/mame/drivers/witch.cpp @@ -217,7 +217,7 @@ Interesting memory locations TODO : - Figure out the ports for the "PayOut" stuff (a006/a00c?); - Hook up the OKI M5202; - - lagging sprites on witch (especially noticeable when game scrolls up/down) + - lagging sprites on witch (especially noticeable when game scrolls up/down) */ #include "emu.h" @@ -461,7 +461,7 @@ WRITE8_MEMBER(keirinou_state::write_keirinou_a002) m_bg_bank = new_bg_bank; m_gfx1_tilemap->mark_all_dirty(); } -// m_mainbank->set_entry((data >> 6) & 3); +// m_mainbank->set_entry((data >> 6) & 3); } WRITE8_MEMBER(witch_state::write_a006) @@ -849,8 +849,8 @@ static INPUT_PORTS_START( keirinou ) PORT_DIPSETTING( 0x05, "90%" ) PORT_DIPSETTING( 0x04, "95%" ) PORT_DIPSETTING( 0x03, "100%" ) -// PORT_DIPSETTING( 0x01, "80%" ) -// PORT_DIPSETTING( 0x00, "90%" ) +// PORT_DIPSETTING( 0x01, "80%" ) +// PORT_DIPSETTING( 0x00, "90%" ) PORT_DIPNAME( 0x08, 0x08, "Double-Up Rate" ) PORT_DIPSETTING( 0x08, "90%" ) PORT_DIPSETTING( 0x00, "100%" ) @@ -1026,7 +1026,7 @@ MACHINE_CONFIG_START(keirinou_state::keirinou) MCFG_PALETTE_ADD("palette", 0x200+0x80) MCFG_GFXDECODE_MODIFY("gfxdecode", gfx_keirinou) -// MCFG_PALETTE_FORMAT(IIBBGGRR) +// MCFG_PALETTE_FORMAT(IIBBGGRR) MCFG_DEVICE_MODIFY("ppi1") // Keirin Ou does have two individual PPIs (NEC D8255AC-2) MCFG_I8255_OUT_PORTC_CB(WRITE8(*this, keirinou_state, write_keirinou_a002)) @@ -1137,20 +1137,20 @@ ROM_END ROM_START( keirinou ) /* ES8611 PCB */ ROM_REGION( 0x10000, "maincpu", ROMREGION_ERASE00 ) - ROM_LOAD( "y5-03.y5", 0x000000, 0x008000, CRC(df2acc37) SHA1(9ad953843ba7859a55888fb87591cc8d322136ad) ) + ROM_LOAD( "y5-03.y5", 0x000000, 0x008000, CRC(df2acc37) SHA1(9ad953843ba7859a55888fb87591cc8d322136ad) ) ROM_REGION( 0x10000, "sub", ROMREGION_ERASE00 ) - ROM_LOAD( "y8.y8", 0x000000, 0x008000, CRC(b34111ac) SHA1(4ed7229846adbb27695bf3dd532247b1f8f6e83e) ) + ROM_LOAD( "y8.y8", 0x000000, 0x008000, CRC(b34111ac) SHA1(4ed7229846adbb27695bf3dd532247b1f8f6e83e) ) // rearranged so that it fits available gfx decode ROM_REGION( 0x10000, "gfx1", ROMREGION_ERASE00 ) ROM_LOAD( "a6.a6", 0x0000, 0x4000, CRC(6d59a5e4) SHA1(4580756ee7db4a088ad02cd56f78fd55fef6ec0a) ) ROM_CONTINUE( 0x8000, 0x4000 ) - ROM_LOAD( "c6-02.c6", 0x4000, 0x4000, CRC(c3ecc620) SHA1(9d5e18acef2ad48b8f1c4ed5bb002bb48ab6e7a7) ) + ROM_LOAD( "c6-02.c6", 0x4000, 0x4000, CRC(c3ecc620) SHA1(9d5e18acef2ad48b8f1c4ed5bb002bb48ab6e7a7) ) ROM_CONTINUE( 0xc000, 0x4000 ) ROM_REGION( 0x10000, "gfx2", ROMREGION_ERASE00 ) - ROM_LOAD( "k5.k5", 0x0000, 0x04000, CRC(1ba6d1c0) SHA1(95203af518c52d731969086e326c9335dee8c465) ) + ROM_LOAD( "k5.k5", 0x0000, 0x04000, CRC(1ba6d1c0) SHA1(95203af518c52d731969086e326c9335dee8c465) ) ROM_CONTINUE( 0x8000, 0x04000 ) ROM_CONTINUE( 0x4000, 0x04000 ) ROM_CONTINUE( 0xc000, 0x04000 ) diff --git a/src/mame/drivers/zr107.cpp b/src/mame/drivers/zr107.cpp index 77315e36ec2..31d8a16626c 100644 --- a/src/mame/drivers/zr107.cpp +++ b/src/mame/drivers/zr107.cpp @@ -809,8 +809,7 @@ MACHINE_CONFIG_START(zr107_state::zr107) MCFG_K056832_CONFIG("gfx2", K056832_BPP_8, 1, 0, "none") MCFG_K056832_PALETTE("palette") - MCFG_DEVICE_ADD("k001005", K001005, 0) - MCFG_K001005_TEXEL_CHIP("k001006_1") + MCFG_DEVICE_ADD("k001005", K001005, 0, "k001006_1") MCFG_DEVICE_ADD("k001006_1", K001006, 0) MCFG_K001006_GFX_REGION("gfx1") @@ -883,8 +882,7 @@ MACHINE_CONFIG_START(zr107_state::jetwave) MCFG_K001604_ROZ_OFFSET(16384) MCFG_K001604_PALETTE("palette") - MCFG_DEVICE_ADD("k001005", K001005, 0) - MCFG_K001005_TEXEL_CHIP("k001006_1") + MCFG_DEVICE_ADD("k001005", K001005, 0, "k001006_1") MCFG_DEVICE_ADD("k001006_1", K001006, 0) MCFG_K001006_GFX_REGION("gfx1") diff --git a/src/mame/includes/abc80x.h b/src/mame/includes/abc80x.h index 81405a0d100..c3f61f25cbe 100644 --- a/src/mame/includes/abc80x.h +++ b/src/mame/includes/abc80x.h @@ -59,11 +59,11 @@ #define Z80SIO_TAG "z80sio" #define Z80DART_TAG "z80dart" #define DISCRETE_TAG "discrete" -#define CASSETTE_TAG "cassette" +#define CASSETTE_TAG "cassette" #define RS232_A_TAG "rs232a" #define RS232_B_TAG "rs232b" #define ABC_KEYBOARD_PORT_TAG "kb" -#define TIMER_CTC_TAG "timer_ctc" +#define TIMER_CTC_TAG "timer_ctc" #define TIMER_CASSETTE_TAG "timer_cass" diff --git a/src/mame/includes/atarist.h b/src/mame/includes/atarist.h index 15c3930ada0..669556e449d 100644 --- a/src/mame/includes/atarist.h +++ b/src/mame/includes/atarist.h @@ -85,6 +85,7 @@ public: : driver_device(mconfig, type, tag), m_maincpu(*this, M68000_TAG), m_fdc(*this, WD1772_TAG), + m_floppy(*this, WD1772_TAG ":%u", 0U), m_mfp(*this, MC68901_TAG), m_acia0(*this, MC6850_0_TAG), m_acia1(*this, MC6850_1_TAG), @@ -128,6 +129,7 @@ public: required_device<cpu_device> m_maincpu; required_device<wd1772_device> m_fdc; + required_device_array<floppy_connector, 2> m_floppy; required_device<mc68901_device> m_mfp; required_device<acia6850_device> m_acia0; required_device<acia6850_device> m_acia1; @@ -325,8 +327,6 @@ public: bitmap_rgb32 m_bitmap; - floppy_image_device *floppy_devices[2]; - DECLARE_FLOPPY_FORMATS(floppy_formats); IRQ_CALLBACK_MEMBER(atarist_int_ack); diff --git a/src/mame/includes/exidy440.h b/src/mame/includes/exidy440.h index 37adcb4b7ca..168a6a59ce3 100644 --- a/src/mame/includes/exidy440.h +++ b/src/mame/includes/exidy440.h @@ -25,7 +25,7 @@ public: m_spriteram(*this, "spriteram"), m_scanline(*this, "scanline"), m_maincpu(*this, "maincpu"), - m_custom(*this, "custom"), + m_custom(*this, "440audio"), m_screen(*this, "screen"), m_palette(*this, "palette") { } @@ -61,7 +61,7 @@ protected: void draw_sprites(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect, int scroll_offset, int check_collision); void update_screen(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect, int scroll_offset, int check_collision); uint32_t screen_update_exidy440(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect); - INTERRUPT_GEN_MEMBER(exidy440_vblank_interrupt); + DECLARE_WRITE_LINE_MEMBER(vblank_interrupt_w); TIMER_CALLBACK_MEMBER(delayed_sound_command_w); TIMER_CALLBACK_MEMBER(beam_firq_callback); TIMER_CALLBACK_MEMBER(collide_firq_callback); @@ -73,7 +73,6 @@ protected: virtual void video_start() override; void exidy440_video(machine_config &config); void exidy440_map(address_map &map); - void exidy440_audio_map(address_map &map); required_shared_ptr<uint8_t> m_imageram; required_shared_ptr<uint8_t> m_spriteram; diff --git a/src/mame/includes/exterm.h b/src/mame/includes/exterm.h index 22a29c32534..e913b844be3 100644 --- a/src/mame/includes/exterm.h +++ b/src/mame/includes/exterm.h @@ -26,7 +26,7 @@ public: m_master_videoram(*this, "master_videoram"), m_slave_videoram(*this, "slave_videoram"), m_dial(*this, "DIAL%u", 0U), - m_input(*this, "P%u", 1U) { } + m_input(*this, "P%u", 1U) { } void exterm(machine_config &config); diff --git a/src/mame/includes/fmtowns.h b/src/mame/includes/fmtowns.h index fd69c8f3d03..ca7376ab6d7 100644 --- a/src/mame/includes/fmtowns.h +++ b/src/mame/includes/fmtowns.h @@ -147,7 +147,7 @@ class towns_state : public driver_device required_device<rs232_port_device> m_rs232; required_device<screen_device> m_screen; required_device<msm58321_device> m_rtc; - + required_memory_bank m_bank_cb000_r; required_memory_bank m_bank_cb000_w; required_memory_bank m_bank_f8000_r; diff --git a/src/mame/includes/fuukifg2.h b/src/mame/includes/fuukifg2.h index 73552fadf31..e0dcb2dfa7e 100644 --- a/src/mame/includes/fuukifg2.h +++ b/src/mame/includes/fuukifg2.h @@ -48,7 +48,7 @@ public: required_shared_ptr<uint16_t> m_vregs; required_shared_ptr<uint16_t> m_unknown; required_shared_ptr<uint16_t> m_priority; - + required_memory_bank m_soundbank; /* video-related */ diff --git a/src/mame/includes/jaguar.h b/src/mame/includes/jaguar.h index dc0d7cd0f79..db839dbe7e1 100644 --- a/src/mame/includes/jaguar.h +++ b/src/mame/includes/jaguar.h @@ -95,7 +95,7 @@ public: optional_memory_region m_romboard_region; optional_shared_ptr<uint32_t> m_mainram; optional_shared_ptr<uint32_t> m_mainram2; - + optional_memory_bank m_maingfxbank; optional_memory_bank m_gpugfxbank; optional_memory_bank m_mainsndbank; diff --git a/src/mame/includes/markham.h b/src/mame/includes/markham.h index cc12d4d7a36..11349331224 100644 --- a/src/mame/includes/markham.h +++ b/src/mame/includes/markham.h @@ -115,4 +115,4 @@ private: uint8_t m_coin2_lock_cnt; }; -#endif // MAME_INCLUDES_MARKHAM_H
\ No newline at end of file +#endif // MAME_INCLUDES_MARKHAM_H diff --git a/src/mame/includes/msx.h b/src/mame/includes/msx.h index d45f079d6ff..11d3e254f00 100644 --- a/src/mame/includes/msx.h +++ b/src/mame/includes/msx.h @@ -417,6 +417,7 @@ public: void hx10s(machine_config &config); void piopx7uk(machine_config &config); void hc5(machine_config &config); + void dgnmsx(machine_config &config); void fdpc200(machine_config &config); void hx22(machine_config &config); void fs1300(machine_config &config); diff --git a/src/mame/includes/poly.h b/src/mame/includes/poly.h index 35271ad7e84..bcfa1421a7c 100644 --- a/src/mame/includes/poly.h +++ b/src/mame/includes/poly.h @@ -66,7 +66,7 @@ public: , m_adlc(*this, "mc6854") , m_ptm(*this, "ptm") , m_irqs(*this, "irqs") -// , m_kr2376(*this, "kr2376") +// , m_kr2376(*this, "kr2376") , m_kbd(*this, "X%u", 0) , m_modifiers(*this, "MODIFIERS") , m_speaker(*this, "speaker") diff --git a/src/mame/includes/popeye.h b/src/mame/includes/popeye.h index 05cf375d78d..fde4df516a2 100644 --- a/src/mame/includes/popeye.h +++ b/src/mame/includes/popeye.h @@ -38,8 +38,9 @@ protected: static const res_net_decode_info mb7051_decode_info; static const res_net_decode_info mb7052_decode_info; static const res_net_info txt_mb7051_net_info; - static const res_net_info bak_mb7051_net_info; + static const res_net_info tnx1_bak_mb7051_net_info; static const res_net_info obj_mb7052_net_info; + virtual const res_net_info bak_mb7051_net_info() { return tnx1_bak_mb7051_net_info; }; std::unique_ptr<bitmap_ind16> m_sprite_bitmap; std::vector<uint8_t> m_sprite_ram; @@ -76,6 +77,8 @@ protected: virtual void maincpu_program_map(address_map &map); void maincpu_io_map(address_map &map); + + virtual bool bootleg_sprites() const { return false; } }; class tpp1_state : public tnx1_state @@ -84,6 +87,9 @@ class tpp1_state : public tnx1_state protected: virtual DECLARE_PALETTE_INIT(palette_init) override; virtual void draw_background(bitmap_ind16 &bitmap, const rectangle &cliprect) override; + + static const res_net_info tpp1_bak_mb7051_net_info; + virtual const res_net_info bak_mb7051_net_info() override { return tpp1_bak_mb7051_net_info; }; }; class popeyebl_state : public tpp1_state @@ -92,6 +98,8 @@ class popeyebl_state : public tpp1_state protected: virtual void decrypt_rom() override; virtual void maincpu_program_map(address_map &map) override; + + virtual bool bootleg_sprites() const override { return true; } }; class tpp2_state : public tpp1_state diff --git a/src/mame/includes/sub.h b/src/mame/includes/sub.h index 6b531ca2453..7eedaa418c8 100644 --- a/src/mame/includes/sub.h +++ b/src/mame/includes/sub.h @@ -56,14 +56,14 @@ public: void subm_map(address_map &map); void subm_sound_io(address_map &map); void subm_sound_map(address_map &map); - + protected: virtual void machine_start() override; virtual void video_start() override; - + private: tilemap_t *m_tilemap; - + required_device<cpu_device> m_maincpu; required_device<cpu_device> m_soundcpu; required_device<gfxdecode_device> m_gfxdecode; @@ -75,7 +75,7 @@ private: required_shared_ptr<uint8_t> m_spriteram; required_shared_ptr<uint8_t> m_spriteram2; required_shared_ptr<uint8_t> m_scrolly; - + void draw_sprites(bitmap_ind16 &bitmap, const rectangle &cliprect); }; diff --git a/src/mame/includes/supbtime.h b/src/mame/includes/supbtime.h index 01316b61474..dd48e89d15e 100644 --- a/src/mame/includes/supbtime.h +++ b/src/mame/includes/supbtime.h @@ -2,7 +2,7 @@ // copyright-holders: Bryan McPhail, David Haywood, Dirk Best /*************************************************************************** - Super Burger Time + Super Burger Time ***************************************************************************/ diff --git a/src/mame/includes/tatsumi.h b/src/mame/includes/tatsumi.h index ab536791c21..186ed7d7029 100644 --- a/src/mame/includes/tatsumi.h +++ b/src/mame/includes/tatsumi.h @@ -188,11 +188,13 @@ public: DECLARE_WRITE16_MEMBER(bigfight_a40000_w); DECLARE_WRITE16_MEMBER(bigfight_a60000_w); DECLARE_WRITE8_MEMBER(cyclwarr_control_w); + DECLARE_WRITE8_MEMBER(cyclwarr_sound_w); template<int Bank> DECLARE_READ16_MEMBER(cyclwarr_videoram_r); template<int Bank> DECLARE_WRITE16_MEMBER(cyclwarr_videoram_w); void init_cyclwarr(); template<int Bank> TILE_GET_INFO_MEMBER(get_tile_info_bigfight); + template<int Bank> TILE_GET_INFO_MEMBER(get_tile_info_cyclwarr_road); DECLARE_VIDEO_START(cyclwarr); DECLARE_VIDEO_START(bigfight); uint32_t screen_update_cyclwarr(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect); @@ -212,7 +214,7 @@ private: required_shared_ptr<uint16_t> m_cyclwarr_cpub_ram; required_shared_ptr_array<uint16_t, 2> m_cyclwarr_videoram; required_region_ptr<uint8_t> m_cyclwarr_tileclut; - + std::vector<uint8_t> m_mask; tilemap_t *m_layer[4]; @@ -221,7 +223,8 @@ private: uint16_t m_bigfight_a40000[2]; uint16_t m_bigfight_bank; uint16_t m_bigfight_last_bank; + uint16_t m_cyclwarr_color_bank; void tile_expand(); - void draw_bg(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect, tilemap_t *src, const uint16_t* scrollx, const uint16_t* scrolly, int xscroll_offset, int yscroll_offset); + void draw_bg(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect, tilemap_t *src, const uint16_t* scrollx, const uint16_t* scrolly, int xscroll_offset, int yscroll_offset, bool rowscroll_enable, bool is_road); }; diff --git a/src/mame/includes/tp84.h b/src/mame/includes/tp84.h index 7d38587e2c3..999e594e3cf 100644 --- a/src/mame/includes/tp84.h +++ b/src/mame/includes/tp84.h @@ -80,4 +80,4 @@ public: void tp84b_cpu1_map(address_map &map); }; -#endif // MAME_INCLUDES_TP84
\ No newline at end of file +#endif // MAME_INCLUDES_TP84 diff --git a/src/mame/includes/vertigo.h b/src/mame/includes/vertigo.h index d9e60ba8065..f515234bb5f 100644 --- a/src/mame/includes/vertigo.h +++ b/src/mame/includes/vertigo.h @@ -30,8 +30,7 @@ public: vertigo_state(const machine_config &mconfig, device_type type, const char *tag) : driver_device(mconfig, type, tag), m_maincpu(*this, "maincpu"), - m_audiocpu(*this, "audiocpu"), - m_custom(*this, "custom"), + m_custom(*this, "440audio"), m_ttl74148(*this, "74148"), m_vector(*this, "vector"), m_adc(*this, "adc"), @@ -132,7 +131,6 @@ private: void update_irq_encoder(int line, int state); required_device<cpu_device> m_maincpu; - required_device<cpu_device> m_audiocpu; required_device<exidy440_sound_device> m_custom; required_device<ttl74148_device> m_ttl74148; required_device<vector_device> m_vector; diff --git a/src/mame/layout/irrmaze.lay b/src/mame/layout/irrmaze.lay index ab1eefce7c8..8afa551b1e7 100644 --- a/src/mame/layout/irrmaze.lay +++ b/src/mame/layout/irrmaze.lay @@ -25,7 +25,7 @@ copyright-holders:Vas Crabb <rect state="0"><color red="0.4" green="0.4" blue="0.4" /></rect> <rect state="1"><color red="1" green="0.3" blue="0.2" /></rect> </element> - + <element name="timerlamp"> <disk state="0"><color red="0.3" green="0" blue="0" /></disk> <disk state="1"><color red="1" green="0.3" blue="0.1" /></disk> @@ -70,7 +70,7 @@ copyright-holders:Vas Crabb <bezel element="marquee"><bounds x="0" y="0" width="23" height="2.5" /></bezel> <bezel element="colorlamp" name="sit13"><bounds x="0" y="0" width="11.5" height="1" /></bezel> - <bezel element="colorlamp" name="sit12"><bounds x="11.5" y="0" width="11.5" height="1" /></bezel> + <bezel element="colorlamp" name="sit12"><bounds x="11.5" y="0" width="11.5" height="1" /></bezel> <bezel element="timerlamp" name="sit9"><bounds x="2" y="1.25" width="1" height="1" /></bezel> <bezel element="timerlamp" name="sit8"><bounds x="4" y="1.25" width="1" height="1" /></bezel> <bezel element="timerlamp" name="sit7"><bounds x="6" y="1.25" width="1" height="1" /></bezel> diff --git a/src/mame/machine/dc-ctrl.cpp b/src/mame/machine/dc-ctrl.cpp index 36b56ab73e0..30861245381 100644 --- a/src/mame/machine/dc-ctrl.cpp +++ b/src/mame/machine/dc-ctrl.cpp @@ -55,7 +55,7 @@ void dc_common_device::maple_w(const uint32_t *data, uint32_t in_size) break; } } - + /******************************* * * Dreamcast Controller @@ -140,7 +140,7 @@ void dc_keyboard_device::fixed_status(uint32_t *dest) dest[1] = 0x00201000; // 1st function dest[2] = 0x00000008; // No 2nd function (doc returns 8 here tho?) dest[3] = 0x00000000; // No 3rd function - dest[4] = region; + dest[4] = region; copy_with_spaces(((uint8_t *)dest) + 18, model, 30); copy_with_spaces(((uint8_t *)dest) + 48, license, 60); dest[27] = electric_current; diff --git a/src/mame/machine/dc-ctrl.h b/src/mame/machine/dc-ctrl.h index 51b040be08e..3b0aab2898d 100644 --- a/src/mame/machine/dc-ctrl.h +++ b/src/mame/machine/dc-ctrl.h @@ -50,14 +50,14 @@ protected: uint32_t id; uint32_t electric_current; uint32_t region; - + ioport_port *port[8]; - + virtual void fixed_status(uint32_t *dest) = 0; virtual void free_status(uint32_t *dest) = 0; virtual void read(uint32_t *dest) = 0; }; - + class dc_controller_device : public dc_common_device { public: diff --git a/src/mame/machine/hal2.h b/src/mame/machine/hal2.h index c835fa69cab..4a0025c60b0 100644 --- a/src/mame/machine/hal2.h +++ b/src/mame/machine/hal2.h @@ -63,4 +63,4 @@ protected: DECLARE_DEVICE_TYPE(SGI_HAL2, hal2_device) -#endif // MAME_MACHINE_HAL2_H
\ No newline at end of file +#endif // MAME_MACHINE_HAL2_H diff --git a/src/mame/machine/interpro_ioga.cpp b/src/mame/machine/interpro_ioga.cpp index ee620503745..df0a601ce73 100644 --- a/src/mame/machine/interpro_ioga.cpp +++ b/src/mame/machine/interpro_ioga.cpp @@ -915,7 +915,7 @@ WRITE32_MEMBER(interpro_ioga_device::timer0_w) // restart the timer //if (m_prescaler & 0xffff) - // m_timer0->adjust(attotime::zero, 0, attotime::from_ticks(m_prescaler & 0xffff, 60_Hz_XTAL)); + // m_timer0->adjust(attotime::zero, 0, attotime::from_ticks(m_prescaler & 0xffff, 60_Hz_XTAL)); //else m_timer0->adjust(attotime::zero, 0, attotime::from_hz(60_Hz_XTAL)); } diff --git a/src/mame/machine/konppc.cpp b/src/mame/machine/konppc.cpp index b1047a87d2a..866e8eee884 100644 --- a/src/mame/machine/konppc.cpp +++ b/src/mame/machine/konppc.cpp @@ -129,8 +129,8 @@ WRITE32_MEMBER( konppc_device::cgboard_dsp_comm_w_ppc ) if (cgboard_id < MAX_CG_BOARDS) { - cpu_device &dsp = *m_dsp[cgboard_id]; - if (offset == 0) + cpu_device &dsp = *m_dsp[cgboard_id]; + if (offset == 0) { if (ACCESSING_BITS_24_31) { diff --git a/src/mame/machine/model1io2.cpp b/src/mame/machine/model1io2.cpp index 9dff2ed14ed..28fe3d153da 100644 --- a/src/mame/machine/model1io2.cpp +++ b/src/mame/machine/model1io2.cpp @@ -4,45 +4,45 @@ Sega Model 1 I/O Board (Advanced) - Used by: - - Wing War (R360) (837-10859) - - NetMerc (837-11659) - - Virtua Cop (837-11130 with 837-11131) - - Diagnostic LCD: - - It's possible to attach a small LCD to the board and enable a - diagnostic mode. To try this in MAME, enable the 'Diagnostic' - view, then map keys to I/O board buttons. Hold button 0 and - press F3 to reset. The main screen will display 'I/O board error' - but the LCD at the bottom is now active. Control it with board - buttons 0 (up), 1 (down) and 2 (select). - - It's also possible to show some debug values while the game is - running. To do this, hold board button '1' and push reset. Use - buttons 0 and 1 to scroll the screen. - - Debug mode: - - You can attach a terminal to SIO channel B. Attach it to the - MAME slot option 'ioboard:cn8'. You need to enable both JP3 - and JP4 jumpers and hold board button 0 at startup. - - Default settings are 9600-8-N-1. It will output "RS". - You can then enter the following commands: - - - DT[word1][word2]: Returns word2 bytes from location word1 - - GO: ? - - IN[byte1]: Return value from I/O port byte1 - - LH: ? - - OP[byte1][byte2]: Write value byte2 to I/O port byte1 - - T: Nothing - - XR: Return 26 bytes starting at location ff07 - - XM[26 bytes]: Write 26 bytes to location starting at ff07 - - ZP[word1][word2]: ff03=word1, ff05=word2 - - VR: Return id string - - NMI is related to the debug mode, not hooked up. + Used by: + - Wing War (R360) (837-10859) + - NetMerc (837-11659) + - Virtua Cop (837-11130 with 837-11131) + + Diagnostic LCD: + + It's possible to attach a small LCD to the board and enable a + diagnostic mode. To try this in MAME, enable the 'Diagnostic' + view, then map keys to I/O board buttons. Hold button 0 and + press F3 to reset. The main screen will display 'I/O board error' + but the LCD at the bottom is now active. Control it with board + buttons 0 (up), 1 (down) and 2 (select). + + It's also possible to show some debug values while the game is + running. To do this, hold board button '1' and push reset. Use + buttons 0 and 1 to scroll the screen. + + Debug mode: + + You can attach a terminal to SIO channel B. Attach it to the + MAME slot option 'ioboard:cn8'. You need to enable both JP3 + and JP4 jumpers and hold board button 0 at startup. + + Default settings are 9600-8-N-1. It will output "RS". + You can then enter the following commands: + + - DT[word1][word2]: Returns word2 bytes from location word1 + - GO: ? + - IN[byte1]: Return value from I/O port byte1 + - LH: ? + - OP[byte1][byte2]: Write value byte2 to I/O port byte1 + - T: Nothing + - XR: Return 26 bytes starting at location ff07 + - XM[26 bytes]: Write 26 bytes to location starting at ff07 + - ZP[word1][word2]: ff03=word1, ff05=word2 + - VR: Return id string + + NMI is related to the debug mode, not hooked up. ***************************************************************************/ @@ -72,10 +72,10 @@ void model1io2_device::mem_map(address_map &map) map(0x8040, 0x8040).portr("board"); map(0x8080, 0x8080).portr("dsw1"); map(0x8100, 0x810f).rw(this, FUNC(model1io2_device::fpga_r), FUNC(model1io2_device::fpga_w)); -// map(0x8180, 0x8183).nopr(); // displayed as 4 byte values in the diagnostic screen -// map(0x81a0, 0x81af).nopw(); // the (reserved) test in the diagnostic screen sets these +// map(0x8180, 0x8183).nopr(); // displayed as 4 byte values in the diagnostic screen +// map(0x81a0, 0x81af).nopw(); // the (reserved) test in the diagnostic screen sets these map(0x8200, 0x8203).mirror(0x04).rw("adc", FUNC(msm6253_device::d0_r), FUNC(msm6253_device::address_w)); -// map(0x8400, 0x8400) // jumps here when debug mode is set and board button 0 is not active on reset +// map(0x8400, 0x8400) // jumps here when debug mode is set and board button 0 is not active on reset map(0xe000, 0xefff).ram(); // backup ram map(0xf000, 0xffff).ram(); } diff --git a/src/mame/machine/naomi.cpp b/src/mame/machine/naomi.cpp index dcaf49d86ac..e4ecf881d6a 100644 --- a/src/mame/machine/naomi.cpp +++ b/src/mame/machine/naomi.cpp @@ -251,7 +251,7 @@ CUSTOM_INPUT_MEMBER(naomi_state::naomi_mp_r) CUSTOM_INPUT_MEMBER(naomi_state::naomi_kb_r) { // TODO: player 2 input reading -// const int *tagptr = (const int *)param; +// const int *tagptr = (const int *)param; uint8_t retval = 0; static const char *const keynames[] = { @@ -261,10 +261,10 @@ CUSTOM_INPUT_MEMBER(naomi_state::naomi_kb_r) for(int i=0;i<5;i++) { uint32_t row; - + // read the current row row = ioport(keynames[i])->read(); - + // if anything is pressed, convert the 32-bit raw value to keycode if(row != 0) { diff --git a/src/mame/machine/nb1412m2.cpp b/src/mame/machine/nb1412m2.cpp index f25e354fa5c..2af537f0a53 100644 --- a/src/mame/machine/nb1412m2.cpp +++ b/src/mame/machine/nb1412m2.cpp @@ -7,50 +7,50 @@ Nichibutsu 1412M2 device emulation Written by Angelo Salese Fancy data decrypter + timer + ? -Most creative usage is hooked up in Mighty Guy sound CPU, -other games just uses it as a much simpler protection chip providing code +Most creative usage is hooked up in Mighty Guy sound CPU, +other games just uses it as a much simpler protection chip providing code snippets. -It is unknown at current stage if inside the chip there's a MCU +It is unknown at current stage if inside the chip there's a MCU (with internal ROM). TODO: -- main sound timer is "jumpy" (like BGM tempo gets screwy then fixes itself somehow), +- main sound timer is "jumpy" (like BGM tempo gets screwy then fixes itself somehow), fiddling with port 0x90 seems to improve things, why? - DAC timer is guessworked; Legacy notes from drivers: -- m_mAmazonProtReg[4] bit 0 used on hiscore data (clear on code), - 0x29f vs 0x29e (not an offset?) +- m_mAmazonProtReg[4] bit 0 used on hiscore data (clear on code), + 0x29f vs 0x29e (not an offset?) - static const uint16_t mAmazonProtData[] = { - 0x0000,0x5000,0x5341,0x4b45,0x5349,0x4755,0x5245, <- default high scores (0x40db4) - wrong data ? - 0x0000,0x4000,0x0e4b,0x4154,0x5544,0x4f4e,0x0e0e, - 0x0000,0x3000,0x414e,0x4b41,0x4b45,0x5544,0x4f4e, - 0x0000,0x2000,0x0e0e,0x4b49,0x5455,0x4e45,0x0e0e, - 0x0000,0x1000,0x0e4b,0x414b,0x4553,0x4f42,0x410e, - - 0x4ef9,0x0000,0x62fa,0x0000,0x4ef9,0x0000,0x805E,0x0000, <- code (0x40d92) - 0xc800 <- checksum + 0x0000,0x5000,0x5341,0x4b45,0x5349,0x4755,0x5245, <- default high scores (0x40db4) - wrong data ? + 0x0000,0x4000,0x0e4b,0x4154,0x5544,0x4f4e,0x0e0e, + 0x0000,0x3000,0x414e,0x4b41,0x4b45,0x5544,0x4f4e, + 0x0000,0x2000,0x0e0e,0x4b49,0x5455,0x4e45,0x0e0e, + 0x0000,0x1000,0x0e4b,0x414b,0x4553,0x4f42,0x410e, + + 0x4ef9,0x0000,0x62fa,0x0000,0x4ef9,0x0000,0x805E,0x0000, <- code (0x40d92) + 0xc800 <- checksum }; - static const uint16_t mAmatelasProtData[] = { - 0x0000,0x5000,0x5341,0x4b45,0x5349,0x4755,0x5245, <- default high scores (0x40db4) - 0x0000,0x4000,0x0e4b,0x4154,0x5544,0x4f4e,0x0e0e, - 0x0000,0x3000,0x414e,0x4b41,0x4b45,0x5544,0x4f4e, - 0x0000,0x2000,0x0e0e,0x4b49,0x5455,0x4e45,0x0e0e, - 0x0000,0x1000,0x0e4b,0x414b,0x4553,0x4f42,0x410e, - 0x4ef9,0x0000,0x632e,0x0000,0x4ef9,0x0000,0x80C2,0x0000, <- code (0x40d92) - 0x6100 <- checksum + 0x0000,0x5000,0x5341,0x4b45,0x5349,0x4755,0x5245, <- default high scores (0x40db4) + 0x0000,0x4000,0x0e4b,0x4154,0x5544,0x4f4e,0x0e0e, + 0x0000,0x3000,0x414e,0x4b41,0x4b45,0x5544,0x4f4e, + 0x0000,0x2000,0x0e0e,0x4b49,0x5455,0x4e45,0x0e0e, + 0x0000,0x1000,0x0e4b,0x414b,0x4553,0x4f42,0x410e, + 0x4ef9,0x0000,0x632e,0x0000,0x4ef9,0x0000,0x80C2,0x0000, <- code (0x40d92) + 0x6100 <- checksum }; - static const uint16_t mHoreKidProtData[] = { - 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, <- N/A - 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, - 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, - 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, - 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, - 0x4e75,0x4e75,0x4e75,0x4e75,0x4e75,0x4e75,0x4e75,0x4e75, <- code (0x40dba) It actually never jumps there? - 0x1800 <- checksum + 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, <- N/A + 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, + 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, + 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, + 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, + 0x4e75,0x4e75,0x4e75,0x4e75,0x4e75,0x4e75,0x4e75,0x4e75, <- code (0x40dba) It actually never jumps there? + 0x1800 <- checksum }; - mightguy: @@ -70,7 +70,7 @@ Legacy notes from drivers: * * 0x92: data in/out (for dac?) * 0x94: test register? (W 0xaa, checks if R 0xaa) - + ***************************************************************************/ #include "emu.h" @@ -97,23 +97,23 @@ void nb1412m2_device::nb1412m2_map(address_map &map) map(0x33, 0x34).w(this, FUNC(nb1412m2_device::rom_address_w)); map(0x35, 0x36).w(this, FUNC(nb1412m2_device::rom_adjust_w)); map(0x37, 0x37).r(this, FUNC(nb1412m2_device::rom_decrypt_r)); - + // timer map(0x40, 0x40).w(this, FUNC(nb1412m2_device::timer_w)); map(0x41, 0x41).rw(this, FUNC(nb1412m2_device::timer_r), FUNC(nb1412m2_device::timer_ack_w)); map(0x42, 0x43).nopw(); // always 0x03 - + // DAC control map(0x11, 0x11).nopw(); // - unknown (volume/channel control?) map(0x18, 0x18).w(this, FUNC(nb1412m2_device::dac_timer_w)); // timer frequency map(0x19, 0x19).nopw(); // 2 written at POST map(0x51, 0x52).w(this, FUNC(nb1412m2_device::dac_address_w)); // start address - + // latches? map(0x90, 0x90).rw(this, FUNC(nb1412m2_device::const90_r),FUNC(nb1412m2_device::const90_w)); //ram(); map(0x92, 0x92).ram(); map(0x94, 0x94).ram(); //rw(this,FUNC(nb1412m2_device::xor_r),FUNC(nb1412m2_device::xor_w)); - + // 16-bit registers (1=upper address), more latches? map(0xa0, 0xa1).ram(); map(0xa2, 0xa3).ram(); @@ -155,11 +155,11 @@ void nb1412m2_device::device_start() save_item(NAME(m_dac_playback)); save_item(NAME(m_dac_frequency)); save_item(NAME(m_const90)); - + m_timer = timer_alloc(TIMER_MAIN); m_timer->adjust(attotime::never); m_dac_timer = timer_alloc(TIMER_DAC); - + m_dac_cb.resolve_safe(); } @@ -199,9 +199,9 @@ void nb1412m2_device::device_timer(emu_timer &timer, device_timer_id id, int par m_dac_current_address++; m_dac_current_address&= m_data.mask(); if(dac_value == 0x80) - m_dac_playback = false; + m_dac_playback = false; } - + break; default: assert_always(false, "Unknown id in nb1412m2_device::device_timer"); @@ -214,7 +214,7 @@ void nb1412m2_device::device_timer(emu_timer &timer, device_timer_id id, int par WRITE8_MEMBER( nb1412m2_device::rom_op_w ) { -// data == 2 starts DAC playback +// data == 2 starts DAC playback if(data == 2) { m_dac_current_address = m_dac_start_address; @@ -223,9 +223,9 @@ WRITE8_MEMBER( nb1412m2_device::rom_op_w ) m_dac_playback = true; } // TODO: data == 5 probably loads the result into 0x37 -// if(data != 5) -// printf("%02x rom_op\n",data); - +// if(data != 5) +// printf("%02x rom_op\n",data); + m_rom_op = data; } @@ -271,22 +271,22 @@ READ8_MEMBER( nb1412m2_device::rom_decrypt_r ) // summing adjust entry and actual value needed always make 0x143 therefore: prot_adj = (0x43 - m_data[m_adj_address]) & 0xff; -// printf("%02x %04x %04x %02x\n",m_data[m_adj_address],m_rom_address,m_adj_address,m_rom_op); - - return m_data[m_rom_address & 0x1fff] - prot_adj; +// printf("%02x %04x %04x %02x\n",m_data[m_adj_address],m_rom_address,m_adj_address,m_rom_op); + + return m_data[m_rom_address & 0x1fff] - prot_adj; } // Mighty Guy specifics READ8_MEMBER( nb1412m2_device::timer_r ) { - return m_timer_reg == true; + return m_timer_reg == true; } WRITE8_MEMBER( nb1412m2_device::timer_w ) { if(data != 1) logerror("nb1412m2: timer_w with data == %02x\n",data); - + // TODO: timing of this, related to m_const90? m_timer->adjust(attotime::from_hz(960)); } @@ -315,8 +315,8 @@ WRITE8_MEMBER( nb1412m2_device::dac_address_w ) // 0xd0 - 0xe0 - 0xf0 are the settings used WRITE8_MEMBER( nb1412m2_device::dac_timer_w ) { -// popmessage("%02x",data); - // TODO: unknown algo, 0xe0*18 gives 4032 Hz which seems close enough for sample 36 +// popmessage("%02x",data); + // TODO: unknown algo, 0xe0*18 gives 4032 Hz which seems close enough for sample 36 m_dac_frequency = data*18; } diff --git a/src/mame/machine/nb1412m2.h b/src/mame/machine/nb1412m2.h index 6cc46c14542..a570a7a4021 100644 --- a/src/mame/machine/nb1412m2.h +++ b/src/mame/machine/nb1412m2.h @@ -40,7 +40,7 @@ public: DECLARE_WRITE8_MEMBER( command_w ); DECLARE_WRITE8_MEMBER( data_w ); DECLARE_READ8_MEMBER( data_r ); - + DECLARE_WRITE8_MEMBER( rom_address_w ); DECLARE_READ8_MEMBER( rom_decrypt_r ); DECLARE_WRITE8_MEMBER( rom_op_w ); @@ -60,8 +60,8 @@ public: void nb1412m2_map(address_map &map); protected: // device-level overrides -// virtual void device_validity_check(validity_checker &valid) const override; -// virtual void device_add_mconfig(machine_config &config) override; +// virtual void device_validity_check(validity_checker &valid) const override; +// virtual void device_add_mconfig(machine_config &config) override; virtual void device_start() override; virtual void device_reset() override; virtual void device_timer(emu_timer &timer, device_timer_id id, int param, void *ptr) override; diff --git a/src/mame/machine/pgmprot_igs027a_type3.h b/src/mame/machine/pgmprot_igs027a_type3.h index a6582b7acb1..def297cc738 100644 --- a/src/mame/machine/pgmprot_igs027a_type3.h +++ b/src/mame/machine/pgmprot_igs027a_type3.h @@ -66,4 +66,4 @@ INPUT_PORTS_EXTERN(theglad); INPUT_PORTS_EXTERN(happy6); INPUT_PORTS_EXTERN(svg); INPUT_PORTS_EXTERN(svgtw); -INPUT_PORTS_EXTERN(svgpcb);
\ No newline at end of file +INPUT_PORTS_EXTERN(svgpcb); diff --git a/src/mame/machine/poly.cpp b/src/mame/machine/poly.cpp index 67d5112f62f..8d5fd97dda5 100644 --- a/src/mame/machine/poly.cpp +++ b/src/mame/machine/poly.cpp @@ -223,28 +223,28 @@ WRITE8_MEMBER(polydev_state::fdc_inv_w) uint32_t poly_state::screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect) { /* - PA0 Not used. Connected to CA2. - PA1 ( Mix colour 0) Blue 1) Green 0) Red 1) No - PA2 ( Graphics 1 0) 0) 1) 1) Mix - PA3 1 = Enable Teletext 1 screen - PA4 1 = 480 Graphics mode. 0 = 240 Graphics mode. - PA5 1 = Enable Graphics 1 screen or 480 Graphics screen. - PA6 1 = Mix Mode 0 = Priority mode - PA7 Must be 0. Connected to PA7 and timer G3. - - PB0 1 = Enable Teletext 2 screen. - PB1 1 = Enable Graphics 2 (must be 0 for 480 Graphics) - PB2 ( Mix colour 0) Blue 1) Green 0) Red 1) No - PB3 ( Graphics 2 0) 0) 1) 1) Mix - PB4 1 = Enable Red Background - PB5 1 = Enable Green Background - PB6 1 = Enable Blue Background - PB7 Not used. - - CA1 Connected to PA7 and timer G3. Must be 0. - CA2 Not used. Connected to PA0. - CB1 Not used. - CB2 Not used. + PA0 Not used. Connected to CA2. + PA1 ( Mix colour 0) Blue 1) Green 0) Red 1) No + PA2 ( Graphics 1 0) 0) 1) 1) Mix + PA3 1 = Enable Teletext 1 screen + PA4 1 = 480 Graphics mode. 0 = 240 Graphics mode. + PA5 1 = Enable Graphics 1 screen or 480 Graphics screen. + PA6 1 = Mix Mode 0 = Priority mode + PA7 Must be 0. Connected to PA7 and timer G3. + + PB0 1 = Enable Teletext 2 screen. + PB1 1 = Enable Graphics 2 (must be 0 for 480 Graphics) + PB2 ( Mix colour 0) Blue 1) Green 0) Red 1) No + PB3 ( Graphics 2 0) 0) 1) 1) Mix + PB4 1 = Enable Red Background + PB5 1 = Enable Green Background + PB6 1 = Enable Blue Background + PB7 Not used. + + CA1 Connected to PA7 and timer G3. Must be 0. + CA2 Not used. Connected to PA0. + CB1 Not used. + CB2 Not used. */ /* Enable Teletext 1 screen */ diff --git a/src/mame/machine/seibucop/seibucop.cpp b/src/mame/machine/seibucop/seibucop.cpp index 8bdb5d5688d..1cf410684cb 100644 --- a/src/mame/machine/seibucop/seibucop.cpp +++ b/src/mame/machine/seibucop/seibucop.cpp @@ -36,10 +36,10 @@ - (fixed) several if not all enemies definitely wants some sort of "axis aligned bounding box" in order to stop from going out of range (when i.e. first boss goes to bottom of the screen and become unreachable) - (btanb) Throw is made by quickly double jumping (!) - - (btanb) seldomly enemies thrown animates weirdly (bounces to the left when thrown to the right). - Culprit is with command 0x905 param +0x28, but it looks like this parameter is coming - from program ROM itself. Also a PCB recording video shows the same phenomenon, it's just sloppy - programming basically. + - (btanb) seldomly enemies thrown animates weirdly (bounces to the left when thrown to the right). + Culprit is with command 0x905 param +0x28, but it looks like this parameter is coming + from program ROM itself. Also a PCB recording video shows the same phenomenon, it's just sloppy + programming basically. Heated Barrel - (btanb) if player moves in diagonal a bogus projectile is fired. - gives random value to hi-score if you continue (only the first time, not a bug?); @@ -49,9 +49,9 @@ - (fixed) level 3+ boss movements looks wrong; - stage 3 "homing" missiles doesn't seem to like our 6200 hookup here, except it's NOT 6200!? - (fixed) barrels seen in later levels seems to fail an axis aligned bounding box, not unlike Legionnaire. - Godzilla - - few elements doesn't collide properly (i.e. Super X missiles, Tokyo's tower in stage 1), - Z axis check makes no sense whatsoever. Kludged to work in per-game driver_init. + Godzilla + - few elements doesn't collide properly (i.e. Super X missiles, Tokyo's tower in stage 1), + Z axis check makes no sense whatsoever. Kludged to work in per-game driver_init. SD Gundam - stage 3: mid-boss still has the sprite garbage bug; - stage 4: has sprite stuck on bottom-left of screen; @@ -537,7 +537,7 @@ int raiden2cop_device::find_trigger_match(uint16_t triggerval, uint16_t mask) if (triggerval == 0xa180 || triggerval == 0xa980 || triggerval == 0xb100 || triggerval == 0xb900) /* collisions */ otherlog = 0; - + // TODO: disable Z axis in driver code. if (triggerval == 0xb000 || triggerval == 0xb800) otherlog = 0; diff --git a/src/mame/machine/seicopbl.cpp b/src/mame/machine/seicopbl.cpp index f19425ee2d8..d31aff0cc8d 100644 --- a/src/mame/machine/seicopbl.cpp +++ b/src/mame/machine/seicopbl.cpp @@ -69,13 +69,13 @@ WRITE16_MEMBER(seibu_cop_bootleg_device::cmd_trigger_w) m_host_space->write_word((m_reg[6] + offs + 4), ((m_host_space->read_word(m_reg[5] + offs + 4) + dir_offset) / div)); break; } - + /* - read32 10(r0) - add32 4(r0) - addmem32 4(r0) - addmem16 1c(r0) - write16h 1c(r0) + read32 10(r0) + add32 4(r0) + addmem32 4(r0) + addmem16 1c(r0) + write16h 1c(r0) */ // 0x0204 variant used from time to time (goal post collision) case 0x0204: @@ -89,51 +89,51 @@ WRITE16_MEMBER(seibu_cop_bootleg_device::cmd_trigger_w) m_host_space->write_word(m_reg[0] + 0x1c + offs, m_host_space->read_word(m_reg[0] + 0x1c + offs) + delta); break; } - + // jumping is done with this case 0x0905: { //printf("%08x %08x\n",m_reg[0],offs); - + int val = m_host_space->read_dword(m_reg[0] + 16 + offs); int delta = m_host_space->read_dword(m_reg[0] + 0x28 + offs); - + //printf("%08x + %08x = ",val,delta); val += delta; //printf("%08x\n",val); - + m_host_space->write_dword(m_reg[0] + 16 + offs, val); break; } - + /* - 0x138e - write16h 8(r0) - sub32 8(r1) - ? 4(r0) - sub32 4(r1) - ? 36(r0) - addmem16 34(r0) - addmem16 34(r0) - sub32 34(r0) - 0xe38e - write16h 8(r0) - sub32 8(r2) - ? 4(r0) - sub32 4(r2) - ? 36(r0) - addmem16 34(r0) - addmem16 34(r0) - sub32 34(r0) + 0x138e + write16h 8(r0) + sub32 8(r1) + ? 4(r0) + sub32 4(r1) + ? 36(r0) + addmem16 34(r0) + addmem16 34(r0) + sub32 34(r0) + 0xe38e + write16h 8(r0) + sub32 8(r2) + ? 4(r0) + sub32 4(r2) + ? 36(r0) + addmem16 34(r0) + addmem16 34(r0) + sub32 34(r0) */ // normal tackle - case 0x118e: + case 0x118e: case 0x130e: case 0x138e: // tackling ball hit? - case 0x330e: + case 0x330e: case 0xe30e: case 0xe18e: { @@ -142,7 +142,7 @@ WRITE16_MEMBER(seibu_cop_bootleg_device::cmd_trigger_w) int sx = (m_host_space->read_dword(m_reg[0]+8) >> 16); int dy = (m_host_space->read_dword(m_reg[target_reg]+4) >> 16); int dx = (m_host_space->read_dword(m_reg[target_reg]+8) >> 16); - + #if 0 if(data == 0xe30e) { @@ -152,7 +152,7 @@ WRITE16_MEMBER(seibu_cop_bootleg_device::cmd_trigger_w) #endif dy -= sy; dx -= sx; - + #if 0 if(data == 0xe30e) { @@ -162,25 +162,25 @@ WRITE16_MEMBER(seibu_cop_bootleg_device::cmd_trigger_w) #endif //m_status = 7; - if(!dx) + if(!dx) { m_status = 0x8000; m_angle = 0; - } + } else { m_status = 0; m_angle = atan(double(dy)/double(dx)) * 128.0 / M_PI; - + //printf("%f\n",atan(double(dy)/double(dx))); - + if(dx<0) { m_angle += 0x80; } } - + m_dy = dy; m_dx = dx; @@ -190,7 +190,7 @@ WRITE16_MEMBER(seibu_cop_bootleg_device::cmd_trigger_w) { return; } - + if(data & 0x80) m_host_space->write_byte(m_reg[0]+(0x37), m_angle & 0xff); @@ -213,7 +213,7 @@ WRITE16_MEMBER(seibu_cop_bootleg_device::cmd_trigger_w) case 0x42c2: { int div = m_host_space->read_word(m_reg[0] + (0x34)); - + if (!div) { m_status |= 0x8000; @@ -229,11 +229,11 @@ WRITE16_MEMBER(seibu_cop_bootleg_device::cmd_trigger_w) // shoot/pass is done with this /* - 0x5105 - sub32 (r0) - write16h 8(r0) - addmem32 4(r0) - outputs to 0x046/0x047 (d104_move_offset ?) + 0x5105 + sub32 (r0) + write16h 8(r0) + addmem32 4(r0) + outputs to 0x046/0x047 (d104_move_offset ?) */ case 0x5105: { @@ -243,10 +243,10 @@ WRITE16_MEMBER(seibu_cop_bootleg_device::cmd_trigger_w) break; } /* - 0x5905 - write16h 10(r2) - sub32 8(r0) - addmem32 4(r1) + 0x5905 + write16h 10(r2) + sub32 8(r0) + addmem32 4(r1) */ case 0x5905: { @@ -255,7 +255,7 @@ WRITE16_MEMBER(seibu_cop_bootleg_device::cmd_trigger_w) m_host_space->write_dword(m_reg[1] + 4 + offs,val); break; } - + /* 00000-0ffff: amp = x/256 @@ -308,10 +308,10 @@ WRITE16_MEMBER(seibu_cop_bootleg_device::cmd_trigger_w) } /* - sub32 4(r2) - write16h (r3) - addmem32 4(r1) - outputs to 0x046/0x047 (d104_move_offset ?) + sub32 4(r2) + write16h (r3) + addmem32 4(r1) + outputs to 0x046/0x047 (d104_move_offset ?) */ case 0xd104: { diff --git a/src/mame/machine/seicopbl.h b/src/mame/machine/seicopbl.h index f53d592fd58..4951366f356 100644 --- a/src/mame/machine/seicopbl.h +++ b/src/mame/machine/seicopbl.h @@ -30,7 +30,7 @@ public: DECLARE_READ16_MEMBER( prng_r ); DECLARE_READ16_MEMBER( scale_r ); DECLARE_WRITE16_MEMBER( scale_w ); - + void seibucopbl_map(address_map &map); protected: // device-level overrides diff --git a/src/mame/machine/vertigo.cpp b/src/mame/machine/vertigo.cpp index ca6d77eebe5..4f4a7b56ec2 100644 --- a/src/mame/machine/vertigo.cpp +++ b/src/mame/machine/vertigo.cpp @@ -48,8 +48,7 @@ WRITE_LINE_MEMBER(vertigo_state::v_irq4_w) WRITE_LINE_MEMBER(vertigo_state::v_irq3_w) { - if (state) - m_audiocpu->set_input_line(INPUT_LINE_IRQ0, ASSERT_LINE); + m_custom->sound_interrupt_w(state); update_irq_encoder(INPUT_LINE_IRQ3, state); } @@ -101,9 +100,9 @@ WRITE16_MEMBER(vertigo_state::vertigo_wsot_w) { /* Reset sound cpu */ if ((data & 2) == 0) - m_audiocpu->set_input_line(INPUT_LINE_RESET, ASSERT_LINE); + m_custom->sound_reset_w(ASSERT_LINE); else - m_audiocpu->set_input_line(INPUT_LINE_RESET, CLEAR_LINE); + m_custom->sound_reset_w(CLEAR_LINE); } diff --git a/src/mame/mame.lst b/src/mame/mame.lst index ec9097f0186..1830e45bfaf 100644 --- a/src/mame/mame.lst +++ b/src/mame/mame.lst @@ -11158,8 +11158,8 @@ deadang // (c) 1988 Seibu Kaihatsu ghunter // (c) 1988 Seibu Kaihatsu ghunters // (c) 1988 Seibu Kaihatsu + Segasa/Sonic license leadang // (c) 1988 Seibu Kaihatsu -popnrun // (c) 1987 Seibu Kaihatsu + Yukai Tsukai -popnruna // (c) 1987 Seibu Kaihatsu + Yukai Tsukai +popnrun // (c) 1987 Seibu Kaihatsu + Yukai Tsukai +popnruna // (c) 1987 Seibu Kaihatsu + Yukai Tsukai @source:dec0.cpp automat // bootleg @@ -15567,6 +15567,7 @@ istellar // (c) 1983 Funai / Gakken @source:istrebiteli.cpp istreb // +motogonki // @source:iteagle.cpp bbh2sp // @@ -17732,6 +17733,7 @@ hypbbc2pk // 1999 - Hyper Bishi Bashi Champ - 2 Player (GX hyperbbc // 1998 - Hyper Bishi Bashi (GQ876 VER. EAA) hyperbbca // 1998 - Hyper Bishi Bashi (GQ876 VER. AAA) hyperbbck // 1998 - Hyper Bishi Bashi (GE876 VER. KAA) +jppyex98 // 1998 - Jikkyou Powerful Pro Yakyuu EX '98 (GC811 VER. JAA) konam80a // 1998 - Konami 80's AC Special (GC826 VER. AAA) konam80j // 1998 - Konami 80's Gallery (GC826 VER. JAA) konam80k // 1998 - Konami 80's AC Special (GC826 VER. KAA) @@ -28126,6 +28128,7 @@ cx5m128 // cx5m2 // cx7m // 1986 MSX2 cx7m128 // 1986 MSX2 +dgnmsx // 1985 MSX dpc100 // 1984 MSX Korea dpc180 // 1984 MSX Korea dpc200 // 1984 MSX Korea diff --git a/src/mame/video/deadang.cpp b/src/mame/video/deadang.cpp index 3771451eb04..bd1766e9921 100644 --- a/src/mame/video/deadang.cpp +++ b/src/mame/video/deadang.cpp @@ -99,10 +99,10 @@ TILE_GET_INFO_MEMBER(popnrun_state::get_popnrun_text_tile_info) // TODO: not entirely correct (title screen/ranking colors) // might be down to bitplanes too int color = (attr & 3) ^ 1; - + if(attr & 0x40) tile |= 1; - + SET_TILE_INFO_MEMBER(0,tile,color,0); } @@ -227,7 +227,7 @@ void popnrun_state::popnrun_draw_sprites(screen_device &screen, bitmap_ind16 &bi if (fy) fy=0; else fy=1; if (m_spriteram[offs+2]&0x100) x=0-(0xff-x); #endif - + color = (m_spriteram[offs+0]>>12)&0x7; sprite = m_spriteram[offs+0]&0xfff; @@ -239,7 +239,7 @@ void popnrun_state::popnrun_draw_sprites(screen_device &screen, bitmap_ind16 &bi if (fy) fy=0; else fy=1; } #endif - + m_gfxdecode->gfx(1)->prio_transpen(bitmap,cliprect, sprite, color,fx,fy,x,y, @@ -252,23 +252,23 @@ uint32_t popnrun_state::popnrun_screen_update(screen_device &screen, bitmap_ind1 // TODO: different scroll RAM hookup // 0x18 seems to enable the various layers /* Setup the tilemaps */ -// m_pf3_layer->set_scrolly(0, ((m_scroll_ram[0x01]&0xf0)<<4)+((m_scroll_ram[0x02]&0x7f)<<1)+((m_scroll_ram[0x02]&0x80)>>7) ); -// m_pf3_layer->set_scrollx(0, ((m_scroll_ram[0x09]&0xf0)<<4)+((m_scroll_ram[0x0a]&0x7f)<<1)+((m_scroll_ram[0x0a]&0x80)>>7) ); -// m_pf1_layer->set_scrolly(0, ((m_scroll_ram[0x11]&0x10)<<4)+((m_scroll_ram[0x12]&0x7f)<<1)+((m_scroll_ram[0x12]&0x80)>>7) ); -// m_pf1_layer->set_scrollx(0, ((m_scroll_ram[0x19]&0x10)<<4)+((m_scroll_ram[0x1a]&0x7f)<<1)+((m_scroll_ram[0x1a]&0x80)>>7) ); -// m_pf2_layer->set_scrolly(0, ((m_scroll_ram[0x21]&0xf0)<<4)+((m_scroll_ram[0x22]&0x7f)<<1)+((m_scroll_ram[0x22]&0x80)>>7) ); -// m_pf2_layer->set_scrollx(0, ((m_scroll_ram[0x29]&0xf0)<<4)+((m_scroll_ram[0x2a]&0x7f)<<1)+((m_scroll_ram[0x2a]&0x80)>>7) ); +// m_pf3_layer->set_scrolly(0, ((m_scroll_ram[0x01]&0xf0)<<4)+((m_scroll_ram[0x02]&0x7f)<<1)+((m_scroll_ram[0x02]&0x80)>>7) ); +// m_pf3_layer->set_scrollx(0, ((m_scroll_ram[0x09]&0xf0)<<4)+((m_scroll_ram[0x0a]&0x7f)<<1)+((m_scroll_ram[0x0a]&0x80)>>7) ); +// m_pf1_layer->set_scrolly(0, ((m_scroll_ram[0x11]&0x10)<<4)+((m_scroll_ram[0x12]&0x7f)<<1)+((m_scroll_ram[0x12]&0x80)>>7) ); +// m_pf1_layer->set_scrollx(0, ((m_scroll_ram[0x19]&0x10)<<4)+((m_scroll_ram[0x1a]&0x7f)<<1)+((m_scroll_ram[0x1a]&0x80)>>7) ); +// m_pf2_layer->set_scrolly(0, ((m_scroll_ram[0x21]&0xf0)<<4)+((m_scroll_ram[0x22]&0x7f)<<1)+((m_scroll_ram[0x22]&0x80)>>7) ); +// m_pf2_layer->set_scrollx(0, ((m_scroll_ram[0x29]&0xf0)<<4)+((m_scroll_ram[0x2a]&0x7f)<<1)+((m_scroll_ram[0x2a]&0x80)>>7) ); m_pf3_layer->enable(!(m_scroll_ram[0x34]&1)); m_pf1_layer->enable(!(m_scroll_ram[0x34]&2)); m_pf2_layer->enable(!(m_scroll_ram[0x34]&4)); -// flip_screen_set(m_scroll_ram[0x34]&0x40 ); +// flip_screen_set(m_scroll_ram[0x34]&0x40 ); bitmap.fill(1, cliprect); screen.priority().fill(0, cliprect); // 32 pixels? -// int scrollx = (m_scroll_ram[0x4/2] & 0x0f); - +// int scrollx = (m_scroll_ram[0x4/2] & 0x0f); + // debug tilemap code // this is likely to be collision data for(int x=0;x<16;x++) @@ -277,7 +277,7 @@ uint32_t popnrun_state::popnrun_screen_update(screen_device &screen, bitmap_ind1 { int tile = m_video_data[y+x*8+0xc0] & 0xff; int res_x, res_y; - + if(tile != 0) { res_x = (x*16) & 0xff; @@ -287,7 +287,7 @@ uint32_t popnrun_state::popnrun_screen_update(screen_device &screen, bitmap_ind1 } tile = m_video_data[y+x*8+0xc0] >> 8; - + if(tile != 0) { res_x = (x*16) & 0xff; @@ -297,7 +297,7 @@ uint32_t popnrun_state::popnrun_screen_update(screen_device &screen, bitmap_ind1 } } } - + //m_pf3_layer->draw(screen, bitmap, cliprect, 0,1); //m_pf1_layer->draw(screen, bitmap, cliprect, 0,2); //m_pf2_layer->draw(screen, bitmap, cliprect, 0,4); diff --git a/src/mame/video/exidy440.cpp b/src/mame/video/exidy440.cpp index 710cb8f0f9d..df28b2b340d 100644 --- a/src/mame/video/exidy440.cpp +++ b/src/mame/video/exidy440.cpp @@ -230,11 +230,14 @@ void exidy440_state::exidy440_update_firq() } -INTERRUPT_GEN_MEMBER(exidy440_state::exidy440_vblank_interrupt) +WRITE_LINE_MEMBER(exidy440_state::vblank_interrupt_w) { /* set the FIRQ line on a VBLANK */ - m_firq_vblank = 1; - exidy440_update_firq(); + if (state) + { + m_firq_vblank = 1; + exidy440_update_firq(); + } } @@ -465,6 +468,8 @@ MACHINE_CONFIG_START(exidy440_state::exidy440_video) MCFG_SCREEN_RAW_PARAMS(PIXEL_CLOCK, HTOTAL, HBEND, HBSTART, VTOTAL, VBEND, VBSTART) MCFG_SCREEN_UPDATE_DRIVER(exidy440_state, screen_update_exidy440) MCFG_SCREEN_PALETTE("palette") + MCFG_SCREEN_VBLANK_CALLBACK(WRITELINE(*this, exidy440_state, vblank_interrupt_w)) + MCFG_DEVCB_CHAIN_OUTPUT(WRITELINE("440audio", exidy440_sound_device, sound_interrupt_w)) MACHINE_CONFIG_END diff --git a/src/mame/video/k001005.cpp b/src/mame/video/k001005.cpp index 5d4290684c5..a64d40a93c7 100644 --- a/src/mame/video/k001005.cpp +++ b/src/mame/video/k001005.cpp @@ -3,9 +3,6 @@ #include "emu.h" #include "k001005.h" -#include "video/k001006.h" - - /*****************************************************************************/ /* Konami K001005 Polygon Renderer (KS10071) */ @@ -1186,18 +1183,18 @@ void k001005_renderer::draw(bitmap_rgb32 &bitmap, const rectangle &cliprect) DEFINE_DEVICE_TYPE(K001005, k001005_device, "k001005", "K001005 Polygon Renderer") k001005_device::k001005_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) - : device_t(mconfig, K001005, tag, owner, clock), - device_video_interface(mconfig, *this), - m_k001006(nullptr), - m_fifo(nullptr), - m_status(0), - m_ram_ptr(0), - m_fifo_read_ptr(0), - m_fifo_write_ptr(0), - m_reg_far_z(0) + : device_t(mconfig, K001005, tag, owner, clock) + , device_video_interface(mconfig, *this) + , m_k001006(*this, finder_base::DUMMY_TAG) + , m_fifo(nullptr) + , m_status(0) + , m_ram_ptr(0) + , m_fifo_read_ptr(0) + , m_fifo_write_ptr(0) + , m_reg_far_z(0) { - m_ram[0] = nullptr; - m_ram[1] = nullptr; + m_ram[0] = nullptr; + m_ram[1] = nullptr; } //------------------------------------------------- @@ -1206,8 +1203,6 @@ k001005_device::k001005_device(const machine_config &mconfig, const char *tag, d void k001005_device::device_start() { - m_k001006 = machine().device(m_k001006_tag); - m_ram[0] = std::make_unique<uint16_t[]>(0x140000); m_ram[1] = std::make_unique<uint16_t[]>(0x140000); diff --git a/src/mame/video/k001005.h b/src/mame/video/k001005.h index 1dc6cd745d9..cf7a12fa0a4 100644 --- a/src/mame/video/k001005.h +++ b/src/mame/video/k001005.h @@ -7,6 +7,7 @@ #include "video/poly.h" #include "cpu/sharc/sharc.h" +#include "video/k001006.h" #include <float.h> @@ -104,7 +105,14 @@ class k001005_device : public device_t, public device_video_interface public: k001005_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); - void set_texel_chip(const char *tag) { m_k001006_tag = tag; } + template <typename T> k001005_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&texel_tag) + : k001005_device(mconfig, tag, owner, clock) + { + set_texel_tag(std::forward<T>(texel_tag)); + } + + + template <typename T> void set_texel_tag(T &&tag) { m_k001006.set_tag(std::forward<T>(tag)); } void draw(bitmap_rgb32 &bitmap, const rectangle &cliprect); void swap_buffers(); @@ -120,8 +128,7 @@ protected: private: // internal state - device_t *m_k001006; - const char *m_k001006_tag; + optional_device<k001006_device> m_k001006; std::unique_ptr<uint16_t[]> m_ram[2]; std::unique_ptr<uint32_t[]> m_fifo; @@ -138,8 +145,4 @@ private: DECLARE_DEVICE_TYPE(K001005, k001005_device) - -#define MCFG_K001005_TEXEL_CHIP(_tag) \ - downcast<k001005_device &>(*device).set_texel_chip(_tag); - #endif // MAME_VIDEO_K001005_H diff --git a/src/mame/video/popeye.cpp b/src/mame/video/popeye.cpp index b33c1ddd24a..31078090302 100644 --- a/src/mame/video/popeye.cpp +++ b/src/mame/video/popeye.cpp @@ -86,7 +86,21 @@ const res_net_info tnx1_state::txt_mb7051_net_info = } }; -const res_net_info tnx1_state::bak_mb7051_net_info = +const res_net_info tnx1_state::tnx1_bak_mb7051_net_info = +{ + RES_NET_VCC_5V | RES_NET_VBIAS_5V | RES_NET_VIN_MB7051 | RES_NET_MONITOR_SANYO_EZV20, + { + { RES_NET_AMP_DARLINGTON, 470, 0, 3, { 1200, 680, 470 } }, + { RES_NET_AMP_DARLINGTON, 470, 0, 3, { 1200, 680, 470 } }, +#if USE_NEW_COLOR + { RES_NET_AMP_DARLINGTON, 680, 0, 2, { 680, 470, 0 } } +#else + { RES_NET_AMP_DARLINGTON, 680, 0, 2, { 1300, 470, 0 } } +#endif + } +}; + +const res_net_info tpp1_state::tpp1_bak_mb7051_net_info = { RES_NET_VCC_5V | RES_NET_VBIAS_5V | RES_NET_VIN_MB7051 | RES_NET_MONITOR_SANYO_EZV20, { @@ -141,39 +155,10 @@ void tnx1_state::update_palette() { uint8_t *color_prom = m_color_prom + 16 * ((m_palette_bank & 0x08) >> 3); -#if USE_NEW_COLOR std::vector<rgb_t> rgb; - compute_res_net_all(rgb, color_prom, mb7051_decode_info, bak_mb7051_net_info); + compute_res_net_all(rgb, color_prom, mb7051_decode_info, bak_mb7051_net_info()); m_palette->set_pen_colors(0, rgb); -#else - for (int i = 0; i < 16; i++) - { - /* red component */ - int bit0 = (~color_prom[i] >> 0) & 0x01; - int bit1 = (~color_prom[i] >> 1) & 0x01; - int bit2 = (~color_prom[i] >> 2) & 0x01; - int r = 0x1c * bit0 + 0x31 * bit1 + 0x47 * bit2; - /* green component */ - bit0 = (~color_prom[i] >> 3) & 0x01; - bit1 = (~color_prom[i] >> 4) & 0x01; - bit2 = (~color_prom[i] >> 5) & 0x01; - int g = 0x1c * bit0 + 0x31 * bit1 + 0x47 * bit2; - /* blue component */ - bit0 = 0; - bit1 = (~color_prom[i] >> 6) & 0x01; - bit2 = (~color_prom[i] >> 7) & 0x01; - //if (m_bitmap_type == TYPE_TNX1) - //{ - // /* Sky Skipper has different weights */ - // bit0 = bit1; - // bit1 = 0; - //} - int b = 0x1c * bit0 + 0x31 * bit1 + 0x47 * bit2; - - m_palette->set_pen_color(i, rgb_t(r, g, b)); - } -#endif } if ((m_palette_bank ^ m_palette_bank_cache) & 0x08) @@ -181,7 +166,6 @@ void tnx1_state::update_palette() uint8_t *color_prom = m_color_prom + 32 + 16 * ((m_palette_bank & 0x08) >> 3); /* characters */ -#if USE_NEW_COLOR for (int i = 0; i < 16; i++) { int r = compute_res_net((color_prom[i] >> 0) & 0x07, 0, txt_mb7051_net_info); @@ -190,63 +174,16 @@ void tnx1_state::update_palette() m_palette->set_pen_color(16 + (2 * i) + 0, rgb_t(0, 0, 0)); m_palette->set_pen_color(16 + (2 * i) + 1, rgb_t(r, g, b)); } -#else - for (int i = 0; i < 16; i++) - { - /* red component */ - int bit0 = (~color_prom[i] >> 0) & 0x01; - int bit1 = (~color_prom[i] >> 1) & 0x01; - int bit2 = (~color_prom[i] >> 2) & 0x01; - int r = 0x21 * bit0 + 0x47 * bit1 + 0x97 * bit2; - /* green component */ - bit0 = (~color_prom[i] >> 3) & 0x01; - bit1 = (~color_prom[i] >> 4) & 0x01; - bit2 = (~color_prom[i] >> 5) & 0x01; - int g = 0x21 * bit0 + 0x47 * bit1 + 0x97 * bit2; - /* blue component */ - bit0 = 0; - bit1 = (~color_prom[i] >> 6) & 0x01; - bit2 = (~color_prom[i] >> 7) & 0x01; - int b = 0x21 * bit0 + 0x47 * bit1 + 0x97 * bit2; - - m_palette->set_pen_color(16 + (2 * i) + 1, rgb_t(r, g, b)); - } -#endif } if ((m_palette_bank ^ m_palette_bank_cache) & 0x07) { uint8_t *color_prom = m_color_prom_spr + 32 * (m_palette_bank & 0x07); -#if USE_NEW_COLOR /* sprites */ std::vector<rgb_t> rgb; compute_res_net_all(rgb, color_prom, mb7052_decode_info, obj_mb7052_net_info); m_palette->set_pen_colors(48, rgb); -#else - for (int i = 0; i < 32; i++) - { - int bit0, bit1, bit2, r, g, b; - - /* red component */ - bit0 = (~color_prom[i] >> 0) & 0x01; - bit1 = (~color_prom[i] >> 1) & 0x01; - bit2 = (~color_prom[i] >> 2) & 0x01; - r = 0x21 * bit0 + 0x47 * bit1 + 0x97 * bit2; - /* green component */ - bit0 = (~color_prom[i] >> 3) & 0x01; - bit1 = (~color_prom[i] >> 4) & 0x01; - bit2 = (~color_prom[i] >> 5) & 0x01; - g = 0x21 * bit0 + 0x47 * bit1 + 0x97 * bit2; - /* blue component */ - bit0 = 0; - bit1 = (~color_prom[i] >> 6) & 0x01; - bit2 = (~color_prom[i] >> 7) & 0x01; - b = 0x21 * bit0 + 0x47 * bit1 + 0x97 * bit2; - - m_palette->set_pen_color(48 + i, rgb_t(r, g, b)); - } -#endif } m_palette_bank_cache = m_palette_bank; @@ -373,6 +310,7 @@ void tnx1_state::draw_sprites(bitmap_ind16 &bitmap, const rectangle &cliprect) } } + int flipx = 0; for (int i = 0; i < 64; i++) { struct attribute_memory *a = &attributes[i]; @@ -383,9 +321,23 @@ void tnx1_state::draw_sprites(bitmap_ind16 &bitmap, const rectangle &cliprect) const uint8_t *source_base = gfx->get_data(a->code % gfx->elements()); const uint8_t *source = source_base + (a->row ^ a->flipy) * gfx->rowbytes(); + if (bootleg_sprites() && flipx != a->flipx) + { + int px = a->sx - 7; + if (px >= 0 && px < 512) + { + if (flip_screen()) + px ^= 0x1ff; + + m_sprite_bitmap->pix(y, px) = 0; + } + + flipx = a->flipx; + } + for (int x = 0; x < 16; x++) { - int px = a->sx + x - 8; + int px = a->sx + x - 6; if (px >= 0 && px < 512) { if (flip_screen()) @@ -483,7 +435,7 @@ void tpp2_state::draw_background(bitmap_ind16 &bitmap, const rectangle &cliprect else { // TODO: confirm the memory layout - int sx = x + (2 * m_background_scroll[0]) + 0x72; + int sx = x + (2 * m_background_scroll[0]) + 0x70; int shift = (sy & 4); bitmap.pix16(y, x) = (m_background_ram[((sx / 8) & 0x3f) + ((sy / 8) * 0x40)] >> shift) & 0xf; diff --git a/src/mame/video/sub.cpp b/src/mame/video/sub.cpp index 9e092ae7318..9f7d243b04a 100644 --- a/src/mame/video/sub.cpp +++ b/src/mame/video/sub.cpp @@ -40,7 +40,7 @@ PALETTE_INIT_MEMBER(sub_state, sub) TILE_GET_INFO_MEMBER(sub_state::get_tile_info) { int code = m_vram[tile_index] | ((m_attr[tile_index]&0xe0)<<3); - int color = (m_attr[tile_index]&0x1f)+0x40; + int color = (m_attr[tile_index]&0x1f)+0x40; SET_TILE_INFO_MEMBER(0, code, color, 0); } @@ -107,10 +107,10 @@ void sub_state::draw_sprites(bitmap_ind16 &bitmap, const rectangle &cliprect) if(dx) x = 0xe0 - x; - + gfx->transpen(bitmap,cliprect,spr_offs,col,fx,fy,x,y,0); - } + } } diff --git a/src/mame/video/supbtime.cpp b/src/mame/video/supbtime.cpp index 97a734602f8..797e61d1e4d 100644 --- a/src/mame/video/supbtime.cpp +++ b/src/mame/video/supbtime.cpp @@ -2,10 +2,10 @@ // copyright-holders: Bryan McPhail, David Haywood, Dirk Best /*************************************************************************** - Super Burger Time - - Video mixing - + Super Burger Time + + Video mixing + ***************************************************************************/ #include "emu.h" diff --git a/src/mame/video/tatsumi.cpp b/src/mame/video/tatsumi.cpp index 71154bd763b..ef3f330c1a9 100644 --- a/src/mame/video/tatsumi.cpp +++ b/src/mame/video/tatsumi.cpp @@ -87,6 +87,17 @@ TILE_GET_INFO_MEMBER(cyclwarr_state::get_tile_info_bigfight) tileinfo.mask_data = &m_mask[((tile&0x3ff)|(bank<<10))<<3]; } +template<int Bank> +TILE_GET_INFO_MEMBER(cyclwarr_state::get_tile_info_cyclwarr_road) +{ + int tile=m_cyclwarr_videoram[Bank][(tile_index+0x400)&0x7fff]; + int bank = (m_bigfight_a40000[0] >> (((tile&0xc00)>>10)*4))&0xf; + SET_TILE_INFO_MEMBER(1,(tile&0x3ff)|(bank<<10),((tile>>12)&0xf) | m_cyclwarr_color_bank,0); + // TODO: enables transparent pen on sideways + tileinfo.mask_data = &m_mask[((tile&0x3ff)|(bank<<10))<<3]; +} + + /********************************************************************/ void cyclwarr_state::tile_expand() @@ -119,7 +130,7 @@ void cyclwarr_state::tile_expand() uint8_t respix = m_cyclwarr_tileclut[(c << 3)|pix]; *dest++ = respix; // Transparent pixels are set by both the tile pixel data==0 AND colour palette==0 - m_mask[(c << 3) | (y & 7)] |= ((pix != 0) || ((pix == 0) && (respix != 0))) ? (0x80 >> (x & 7)) : 0; + m_mask[(c << 3) | (y & 7)] |= ((pix != 0) && (respix != 0)) ? (0x80 >> (x & 7)) : 0; } c0base += gx0->rowbytes(); } @@ -156,8 +167,7 @@ VIDEO_START_MEMBER(cyclwarr_state,cyclwarr) { tile_expand(); m_layer[0] = &machine().tilemap().create(*m_gfxdecode, tilemap_get_info_delegate(FUNC(cyclwarr_state::get_tile_info_bigfight<0>),this),TILEMAP_SCAN_ROWS,8,8,64,512); - //m_layer[1] = &machine().tilemap().create(*m_gfxdecode, tilemap_get_info_delegate(FUNC(cyclwarr_state::get_tile_info_bigfight<0>),this),TILEMAP_SCAN_ROWS,8,8,64,512); - m_layer[1] = &machine().tilemap().create(*m_gfxdecode, tilemap_get_info_delegate(FUNC(cyclwarr_state::get_tile_info_bigfight<0>),this),TILEMAP_SCAN_ROWS,8,8,128,256); + m_layer[1] = &machine().tilemap().create(*m_gfxdecode, tilemap_get_info_delegate(FUNC(cyclwarr_state::get_tile_info_cyclwarr_road<0>),this),TILEMAP_SCAN_ROWS,8,8,128,256); m_layer[2] = &machine().tilemap().create(*m_gfxdecode, tilemap_get_info_delegate(FUNC(cyclwarr_state::get_tile_info_bigfight<1>),this),TILEMAP_SCAN_ROWS,8,8,64,512); m_layer[3] = &machine().tilemap().create(*m_gfxdecode, tilemap_get_info_delegate(FUNC(cyclwarr_state::get_tile_info_bigfight<1>),this),TILEMAP_SCAN_ROWS,8,8,64,512); @@ -899,7 +909,8 @@ void tatsumi_state::update_cluts(int fake_palette_offset, int object_base, int l /**********************************************************************/ -void cyclwarr_state::draw_bg(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect, tilemap_t *src, const uint16_t* scrollx, const uint16_t* scrolly, int xscroll_offset, int yscroll_offset) +// TODO: rowscroll_enable might be selectable somehow +void cyclwarr_state::draw_bg(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect, tilemap_t *src, const uint16_t* scrollx, const uint16_t* scrolly, int xscroll_offset, int yscroll_offset, bool rowscroll_enable, bool is_road) { rectangle clip; clip.min_x = cliprect.min_x; @@ -907,8 +918,17 @@ void cyclwarr_state::draw_bg(screen_device &screen, bitmap_rgb32 &bitmap, const for (int y=cliprect.min_y; y<=cliprect.max_y; y++) { clip.min_y = clip.max_y = y; - int src_x = scrollx[y] + xscroll_offset; - int src_y = scrolly[y] + yscroll_offset; + int y_base = rowscroll_enable ? y : 0; + int src_x = scrollx[y_base] + xscroll_offset; + int src_y = scrolly[y_base] + yscroll_offset; + // special handling for cycle warriors road: it reads in scrolly table bits 15-13 an + // additional tile color bank and per scanline. + if(is_road == true && scrolly[y_base] & 0x8000) + { + m_cyclwarr_color_bank = (scrolly[y_base] >> 13) & 3; + src->mark_all_dirty(); + } + src->set_scrollx(0,src_x); src->set_scrolly(0,src_y); src->draw(screen, bitmap, clip, 0, 0); @@ -1029,12 +1049,12 @@ uint32_t cyclwarr_state::screen_update_cyclwarr(screen_device &screen, bitmap_rg bitmap.fill(m_palette->pen(0), cliprect); - draw_bg(screen, bitmap, cliprect, m_layer[3], &m_cyclwarr_videoram[1][0x000], &m_cyclwarr_videoram[1][0x100], 8, -0x80); - draw_bg(screen, bitmap, cliprect, m_layer[2], &m_cyclwarr_videoram[1][0x200], &m_cyclwarr_videoram[1][0x300], 8, -0x80); - draw_bg(screen, bitmap, cliprect, m_layer[1], &m_cyclwarr_videoram[0][0x000], &m_cyclwarr_videoram[0][0x100], 8, -0x40); + draw_bg(screen, bitmap, cliprect, m_layer[3], &m_cyclwarr_videoram[1][0x000], &m_cyclwarr_videoram[1][0x100], 8, -0x80,false, false); + draw_bg(screen, bitmap, cliprect, m_layer[2], &m_cyclwarr_videoram[1][0x200], &m_cyclwarr_videoram[1][0x300], 8, -0x80,false, false); + draw_bg(screen, bitmap, cliprect, m_layer[1], &m_cyclwarr_videoram[0][0x000], &m_cyclwarr_videoram[0][0x100], 8, -0x40,true, true); update_cluts(8192, 4096, 8192); draw_sprites(bitmap,cliprect,0,(m_sprite_control_ram[0xe0]&0x1000) ? 0x1000 : 0); - draw_bg(screen, bitmap, cliprect, m_layer[0], &m_cyclwarr_videoram[0][0x200], &m_cyclwarr_videoram[0][0x300], 0x10, -0x80); + draw_bg(screen, bitmap, cliprect, m_layer[0], &m_cyclwarr_videoram[0][0x200], &m_cyclwarr_videoram[0][0x300], 0x10, -0x80,false, false); return 0; } @@ -1052,12 +1072,12 @@ uint32_t cyclwarr_state::screen_update_bigfight(screen_device &screen, bitmap_rg } bitmap.fill(m_palette->pen(0), cliprect); - draw_bg(screen, bitmap, cliprect, m_layer[3], &m_cyclwarr_videoram[1][0x000], &m_cyclwarr_videoram[1][0x100], 8, -0x40); - draw_bg(screen, bitmap, cliprect, m_layer[2], &m_cyclwarr_videoram[1][0x200], &m_cyclwarr_videoram[1][0x300], 8, -0x40); - draw_bg(screen, bitmap, cliprect, m_layer[1], &m_cyclwarr_videoram[0][0x000], &m_cyclwarr_videoram[0][0x100], 8, -0x40); + draw_bg(screen, bitmap, cliprect, m_layer[3], &m_cyclwarr_videoram[1][0x000], &m_cyclwarr_videoram[1][0x100], 8, -0x40,true, false); + draw_bg(screen, bitmap, cliprect, m_layer[2], &m_cyclwarr_videoram[1][0x200], &m_cyclwarr_videoram[1][0x300], 8, -0x40,true, false); + draw_bg(screen, bitmap, cliprect, m_layer[1], &m_cyclwarr_videoram[0][0x000], &m_cyclwarr_videoram[0][0x100], 8, -0x40,true, false); update_cluts(8192, 4096, 8192); draw_sprites(bitmap,cliprect,0,(m_sprite_control_ram[0xe0]&0x1000) ? 0x1000 : 0); - draw_bg(screen, bitmap, cliprect, m_layer[0], &m_cyclwarr_videoram[0][0x200], &m_cyclwarr_videoram[0][0x300], 0x10, -0x40); + draw_bg(screen, bitmap, cliprect, m_layer[0], &m_cyclwarr_videoram[0][0x200], &m_cyclwarr_videoram[0][0x300], 0x10, -0x40,true, false); return 0; } diff --git a/src/osd/modules/output/network.cpp b/src/osd/modules/output/network.cpp index 6c0af498204..f4db109c829 100644 --- a/src/osd/modules/output/network.cpp +++ b/src/osd/modules/output/network.cpp @@ -63,7 +63,7 @@ private: char *msg_value = strtok(NULL, equals_delimiter); //printf("handle_message: msg_name [%s] msg_value [%s]\n", msg_name, msg_value); - + if (std::strcmp(msg_name, "mame_message") == 0) { const char *comma_delimiter = ","; @@ -71,7 +71,7 @@ private: msg_value = strtok(NULL, comma_delimiter); int id = atoi(msg_name); int value = atoi(msg_value); - + switch(id) { case IM_MAME_PAUSE: diff --git a/src/osd/modules/output/output_module.h b/src/osd/modules/output/output_module.h index 53cc46135ac..9046fda3252 100644 --- a/src/osd/modules/output/output_module.h +++ b/src/osd/modules/output/output_module.h @@ -17,8 +17,8 @@ #define OSD_OUTPUT_PROVIDER "output" -#define IM_MAME_PAUSE 0 -#define IM_MAME_SAVESTATE 1 +#define IM_MAME_PAUSE 0 +#define IM_MAME_SAVESTATE 1 class output_module { diff --git a/src/osd/modules/output/win32_output.cpp b/src/osd/modules/output/win32_output.cpp index 64ab54014e0..3ee2cd6c17e 100644 --- a/src/osd/modules/output/win32_output.cpp +++ b/src/osd/modules/output/win32_output.cpp @@ -54,7 +54,7 @@ static UINT om_mame_register_client; static UINT om_mame_unregister_client; static UINT om_mame_get_id_string; -static UINT im_mame_message; +static UINT im_mame_message; //============================================================ // FUNCTION PROTOTYPES @@ -220,7 +220,7 @@ static LRESULT CALLBACK output_window_proc(HWND wnd, UINT message, WPARAM wparam // get a string for an ID else if (message == om_mame_get_id_string) return output.send_id_string((HWND)wparam, lparam); - + // received a message else if (message == im_mame_message) { @@ -238,7 +238,7 @@ static LRESULT CALLBACK output_window_proc(HWND wnd, UINT message, WPARAM wparam output.machine().schedule_save("auto"); break; } - + return 0; } diff --git a/src/osd/modules/output/win32_output.h b/src/osd/modules/output/win32_output.h index 6b52a164051..f0996b52082 100644 --- a/src/osd/modules/output/win32_output.h +++ b/src/osd/modules/output/win32_output.h @@ -64,9 +64,9 @@ #define OM_MAME_GET_ID_STRING TEXT("MAMEOutputGetIDString") // IM_MAME_MESSAGE: send message to MAME -// WPARAM = ID of the message +// WPARAM = ID of the message // LPARAM = value -#define IM_MAME_MESSAGE TEXT("MAMEInputMessage") +#define IM_MAME_MESSAGE TEXT("MAMEInputMessage") // // These constants are used to identify WM_COPYDATA messages |