mirror of
https://github.com/holub/mame
synced 2025-04-23 08:49:55 +03:00
misc cleanup and devcb3 prep (nw)
This commit is contained in:
parent
3094b15507
commit
5931e88686
@ -312,7 +312,7 @@ WRITE8_MEMBER( ecb_grip21_device::ppi_pc_w )
|
||||
m_sti->i7_w(m_ia);
|
||||
|
||||
// PROF-80 handshaking
|
||||
m_ppi_pc = (!BIT(data, 7) << 7) | (!BIT(data, 5) << 6) | (m_ppi->pa_r() & 0x3f);
|
||||
m_ppi_pc = (!BIT(data, 7) << 7) | (!BIT(data, 5) << 6) | (m_ppi->read_pa() & 0x3f);
|
||||
}
|
||||
|
||||
//-------------------------------------------------
|
||||
|
@ -162,7 +162,7 @@ INPUT_PORTS_END
|
||||
READ8_MEMBER( isa8_ibm_mfc_device::ppi0_i_a )
|
||||
{
|
||||
// Read data from the Z80 PIU
|
||||
return m_d71055c_1->pa_r();
|
||||
return m_d71055c_1->read_pa();
|
||||
}
|
||||
|
||||
WRITE8_MEMBER( isa8_ibm_mfc_device::ppi0_o_b )
|
||||
@ -210,7 +210,7 @@ WRITE8_MEMBER( isa8_ibm_mfc_device::ppi1_o_a )
|
||||
READ8_MEMBER( isa8_ibm_mfc_device::ppi1_i_b )
|
||||
{
|
||||
// Read data from the PC PIU
|
||||
return m_d71055c_0->pb_r();
|
||||
return m_d71055c_0->read_pb();
|
||||
}
|
||||
|
||||
WRITE8_MEMBER( isa8_ibm_mfc_device::ppi1_o_c )
|
||||
|
@ -36,7 +36,7 @@ DECLARE_DEVICE_TYPE(S2650, s2650_device)
|
||||
#define MCFG_S2650_INTACK_HANDLER(_devcb) \
|
||||
devcb = &downcast<s2650_device &>(*device).set_intack_handler(DEVCB_##_devcb);
|
||||
|
||||
class s2650_device : public cpu_device, public s2650_disassembler::config
|
||||
class s2650_device : public cpu_device, public s2650_disassembler::config
|
||||
{
|
||||
public:
|
||||
// construction/destruction
|
||||
|
@ -876,22 +876,20 @@ WRITE8_MEMBER( i8255_device::write )
|
||||
|
||||
READ8_MEMBER( i8255_device::pa_r )
|
||||
{
|
||||
return pa_r();
|
||||
return read_pa();
|
||||
}
|
||||
|
||||
|
||||
//-------------------------------------------------
|
||||
// pb_r - port A read
|
||||
// read_pa - port A read
|
||||
//-------------------------------------------------
|
||||
|
||||
uint8_t i8255_device::pa_r()
|
||||
uint8_t i8255_device::read_pa()
|
||||
{
|
||||
uint8_t data = 0xff;
|
||||
|
||||
if (port_mode(PORT_A) == MODE_OUTPUT)
|
||||
{
|
||||
data = m_output[PORT_A];
|
||||
}
|
||||
|
||||
return data;
|
||||
}
|
||||
@ -903,15 +901,15 @@ uint8_t i8255_device::pa_r()
|
||||
|
||||
READ8_MEMBER( i8255_device::pb_r )
|
||||
{
|
||||
return pb_r();
|
||||
return read_pb();
|
||||
}
|
||||
|
||||
|
||||
//-------------------------------------------------
|
||||
// pb_r - port B read
|
||||
// read_pb - port B read
|
||||
//-------------------------------------------------
|
||||
|
||||
uint8_t i8255_device::pb_r()
|
||||
uint8_t i8255_device::read_pb()
|
||||
{
|
||||
uint8_t data = 0xff;
|
||||
|
||||
|
@ -89,10 +89,10 @@ public:
|
||||
DECLARE_WRITE8_MEMBER( write );
|
||||
|
||||
DECLARE_READ8_MEMBER( pa_r );
|
||||
uint8_t pa_r();
|
||||
uint8_t read_pa();
|
||||
|
||||
DECLARE_READ8_MEMBER( pb_r );
|
||||
uint8_t pb_r();
|
||||
uint8_t read_pb();
|
||||
|
||||
DECLARE_WRITE_LINE_MEMBER( pc2_w );
|
||||
DECLARE_WRITE_LINE_MEMBER( pc4_w );
|
||||
|
@ -704,7 +704,7 @@ MACHINE_CONFIG_START(monsterb_sound_device::device_add_mconfig)
|
||||
MCFG_MCS48_PORT_PROG_OUT_CB(WRITELINE(m_i8243, i8243_device, prog_w))
|
||||
|
||||
MCFG_DEVICE_ADD(m_i8243, I8243, 0)
|
||||
MCFG_I8243_READHANDLER(NOOP)
|
||||
MCFG_I8243_READHANDLER(CONSTANT(0))
|
||||
MCFG_I8243_WRITEHANDLER(WRITE8(*this, monsterb_sound_device, n7751_rom_control_w))
|
||||
|
||||
MCFG_DEVICE_ADD(m_samples, SAMPLES)
|
||||
|
@ -55,7 +55,7 @@ WRITE16_MEMBER(drgnmst_state::coin_w)
|
||||
|
||||
WRITE8_MEMBER(drgnmst_state::snd_command_w)
|
||||
{
|
||||
m_snd_command = (data & 0xff);
|
||||
m_snd_command = data;
|
||||
m_maincpu->yield();
|
||||
}
|
||||
|
||||
|
@ -191,8 +191,8 @@ Notes:
|
||||
class kinst_state : public driver_device
|
||||
{
|
||||
public:
|
||||
kinst_state(const machine_config &mconfig, device_type type, const char *tag)
|
||||
: driver_device(mconfig, type, tag),
|
||||
kinst_state(const machine_config &mconfig, device_type type, const char *tag) :
|
||||
driver_device(mconfig, type, tag),
|
||||
m_rambase(*this, "rambase"),
|
||||
m_rambase2(*this, "rambase2"),
|
||||
m_control(*this, "control"),
|
||||
|
@ -1817,7 +1817,7 @@ MACHINE_CONFIG_START(model1_state::wingwar360)
|
||||
MCFG_DEVICE_MODIFY("ioboard")
|
||||
MCFG_MODEL1IO2_IN2_CB(READ8(*this, model1_state, r360_r))
|
||||
MCFG_MODEL1IO2_DRIVE_WRITE_CB(WRITE8(*this, model1_state, r360_w))
|
||||
MCFG_MODEL1IO2_AN2_CB(NOOP)
|
||||
MCFG_MODEL1IO2_AN2_CB(CONSTANT(0))
|
||||
MCFG_MODEL1IO2_OUTPUT_CB(WRITE8(*this, model1_state, wingwar360_outputs_w))
|
||||
|
||||
MCFG_DEFAULT_LAYOUT(layout_model1io2)
|
||||
|
@ -732,8 +732,8 @@ TIMER_CALLBACK_MEMBER(norautp_state::ppi2_ack)
|
||||
m_ppi8255[2]->pc6_w(param);
|
||||
if (param == 0)
|
||||
{
|
||||
uint8_t np_addr = m_ppi8255[2]->pb_r();
|
||||
uint8_t vram_data = m_ppi8255[2]->pa_r();
|
||||
uint8_t const np_addr = m_ppi8255[2]->read_pb();
|
||||
uint8_t const vram_data = m_ppi8255[2]->read_pa();
|
||||
m_np_vram[np_addr] = vram_data;
|
||||
}
|
||||
}
|
||||
|
@ -298,7 +298,7 @@ WRITE8_MEMBER(segag80r_state::coin_count_w)
|
||||
|
||||
READ8_MEMBER(segag80r_state::sindbadm_sound_data_r)
|
||||
{
|
||||
uint8_t result = m_ppi->pa_r();
|
||||
uint8_t result = m_ppi->read_pa();
|
||||
if (!machine().side_effects_disabled())
|
||||
{
|
||||
m_ppi->pc6_w(0);
|
||||
|
@ -1981,7 +1981,7 @@ MACHINE_CONFIG_START(segas16a_state::system16a)
|
||||
MCFG_MCS48_PORT_P2_OUT_CB(WRITE8(*this, segas16a_state, n7751_p2_w))
|
||||
MCFG_MCS48_PORT_PROG_OUT_CB(WRITELINE("n7751_8243", i8243_device, prog_w))
|
||||
|
||||
MCFG_I8243_ADD("n7751_8243", NOOP, WRITE8(*this, segas16a_state,n7751_rom_offset_w))
|
||||
MCFG_I8243_ADD("n7751_8243", CONSTANT(0), WRITE8(*this, segas16a_state,n7751_rom_offset_w))
|
||||
|
||||
MCFG_NVRAM_ADD_0FILL("nvram")
|
||||
|
||||
|
@ -261,7 +261,7 @@ WRITE8_MEMBER( sitcom_timer_state::update_pia_pa )
|
||||
WRITE8_MEMBER( sitcom_timer_state::update_pia_pb )
|
||||
{
|
||||
if (!m_dac_cs && !BIT(data, 0))
|
||||
update_dac(m_pia->pa_r());
|
||||
update_dac(m_pia->read_pa());
|
||||
m_dac_wr = BIT(data, 0);
|
||||
m_dac_cs = BIT(data, 1);
|
||||
|
||||
|
@ -1,5 +1,10 @@
|
||||
// license:BSD-3-Clause
|
||||
// copyright-holders:Bryan McPhail, David Haywood
|
||||
#ifndef MAME_INCLUDES_DYNDUKE_H
|
||||
#define MAME_INCLUDES_DYNDUKE_H
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "audio/seibu.h"
|
||||
#include "video/bufsprite.h"
|
||||
#include "emupal.h"
|
||||
@ -7,8 +12,8 @@
|
||||
class dynduke_state : public driver_device
|
||||
{
|
||||
public:
|
||||
dynduke_state(const machine_config &mconfig, device_type type, const char *tag)
|
||||
: driver_device(mconfig, type, tag),
|
||||
dynduke_state(const machine_config &mconfig, device_type type, const char *tag) :
|
||||
driver_device(mconfig, type, tag),
|
||||
m_maincpu(*this, "maincpu"),
|
||||
m_slave(*this, "slave"),
|
||||
m_seibu_sound(*this, "seibu_sound"),
|
||||
@ -18,7 +23,8 @@ public:
|
||||
m_scroll_ram(*this, "scroll_ram"),
|
||||
m_videoram(*this, "videoram"),
|
||||
m_back_data(*this, "back_data"),
|
||||
m_fore_data(*this, "fore_data") { }
|
||||
m_fore_data(*this, "fore_data")
|
||||
{ }
|
||||
|
||||
void dynduke(machine_config &config);
|
||||
void dbldyn(machine_config &config);
|
||||
@ -72,3 +78,5 @@ private:
|
||||
void sound_decrypted_opcodes_map(address_map &map);
|
||||
void sound_map(address_map &map);
|
||||
};
|
||||
|
||||
#endif // MAME_INCLUDES_DYNDUKE_H
|
||||
|
@ -1,5 +1,10 @@
|
||||
// license:BSD-3-Clause
|
||||
// copyright-holders:R. Belmont, Olivier Galibert, ElSemi, Angelo Salese
|
||||
#ifndef MAME_INCLUDES_MODEL2_H
|
||||
#define MAME_INCLUDES_MODEL2_H
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "audio/dsbz80.h"
|
||||
#include "audio/segam1audio.h"
|
||||
#include "cpu/i960/i960.h"
|
||||
@ -28,8 +33,8 @@ struct triangle;
|
||||
class model2_state : public driver_device
|
||||
{
|
||||
public:
|
||||
model2_state(const machine_config &mconfig, device_type type, const char *tag)
|
||||
: driver_device(mconfig, type, tag),
|
||||
model2_state(const machine_config &mconfig, device_type type, const char *tag) :
|
||||
driver_device(mconfig, type, tag),
|
||||
m_textureram0(*this, "textureram0"),
|
||||
m_textureram1(*this, "textureram1"),
|
||||
m_workram(*this, "workram"),
|
||||
@ -736,3 +741,5 @@ struct quad_m2
|
||||
uint16_t texheader[4];
|
||||
uint8_t luma;
|
||||
};
|
||||
|
||||
#endif // MAME_INCLUDES_MODEL2_H
|
||||
|
@ -1,5 +1,10 @@
|
||||
// license:BSD-3-Clause
|
||||
// copyright-holders:R. Belmont, Ville Linde
|
||||
#ifndef MAME_INCLUDES_MODEL3_H
|
||||
#define MAME_INCLUDES_MODEL3_H
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "cpu/powerpc/ppc.h"
|
||||
#include "video/poly.h"
|
||||
#include "bus/scsi/scsi.h"
|
||||
@ -57,8 +62,8 @@ class model3_renderer;
|
||||
class model3_state : public driver_device
|
||||
{
|
||||
public:
|
||||
model3_state(const machine_config &mconfig, device_type type, const char *tag)
|
||||
: driver_device(mconfig, type, tag),
|
||||
model3_state(const machine_config &mconfig, device_type type, const char *tag) :
|
||||
driver_device(mconfig, type, tag),
|
||||
m_maincpu(*this,"maincpu"),
|
||||
m_lsi53c810(*this, "lsi53c810"),
|
||||
m_audiocpu(*this, "audiocpu"),
|
||||
@ -66,7 +71,7 @@ public:
|
||||
m_eeprom(*this, "eeprom"),
|
||||
m_screen(*this, "screen"),
|
||||
m_rtc(*this, "rtc"),
|
||||
m_adc_ports(*this, {"AN0", "AN1", "AN2", "AN3", "AN4", "AN5", "AN6", "AN7"}),
|
||||
m_adc_ports(*this, "AN%u", 0U),
|
||||
m_work_ram(*this, "work_ram"),
|
||||
m_paletteram64(*this, "paletteram64"),
|
||||
m_dsbz80(*this, DSBZ80_TAG),
|
||||
@ -353,3 +358,5 @@ private:
|
||||
void model3_mem(address_map &map);
|
||||
void model3_snd(address_map &map);
|
||||
};
|
||||
|
||||
#endif // MAME_INCLUDES_MODEL3_H
|
||||
|
@ -5,6 +5,10 @@
|
||||
Mr. Flea
|
||||
|
||||
*************************************************************************/
|
||||
#ifndef MAME_INCLUDES_MRFLEA_H
|
||||
#define MAME_INCLUDES_MRFLEA_H
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "machine/pic8259.h"
|
||||
#include "machine/timer.h"
|
||||
@ -14,8 +18,8 @@
|
||||
class mrflea_state : public driver_device
|
||||
{
|
||||
public:
|
||||
mrflea_state(const machine_config &mconfig, device_type type, const char *tag)
|
||||
: driver_device(mconfig, type, tag),
|
||||
mrflea_state(const machine_config &mconfig, device_type type, const char *tag) :
|
||||
driver_device(mconfig, type, tag),
|
||||
m_videoram(*this, "videoram"),
|
||||
m_spriteram(*this, "spriteram"),
|
||||
m_maincpu(*this, "maincpu"),
|
||||
@ -23,7 +27,8 @@ public:
|
||||
m_pic(*this, "pic"),
|
||||
m_gfxdecode(*this, "gfxdecode"),
|
||||
m_screen(*this, "screen"),
|
||||
m_palette(*this, "palette") { }
|
||||
m_palette(*this, "palette")
|
||||
{ }
|
||||
|
||||
void mrflea(machine_config &config);
|
||||
|
||||
@ -58,3 +63,5 @@ private:
|
||||
void mrflea_slave_io_map(address_map &map);
|
||||
void mrflea_slave_map(address_map &map);
|
||||
};
|
||||
|
||||
#endif // MAME_INCLUDES_MRFLEA_H
|
||||
|
@ -1,5 +1,10 @@
|
||||
// license:BSD-3-Clause
|
||||
// copyright-holders:Nicola Salmoria
|
||||
#ifndef MAME_INCLUDES_PACMAN_H
|
||||
#define MAME_INCLUDES_PACMAN_H
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "machine/watchdog.h"
|
||||
#include "sound/namco.h"
|
||||
#include "emupal.h"
|
||||
@ -240,3 +245,5 @@ private:
|
||||
uint8_t jumpshot_decrypt(int addr, uint8_t e);
|
||||
void jumpshot_decode();
|
||||
};
|
||||
|
||||
#endif // MAME_INCLUDES_PACMAN_H
|
||||
|
@ -5,6 +5,10 @@
|
||||
Sega System 16B hardware
|
||||
|
||||
***************************************************************************/
|
||||
#ifndef MAME_INCLUDES_SEGAS16B_H
|
||||
#define MAME_INCLUDES_SEGAS16B_H
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "cpu/m68000/m68000.h"
|
||||
#include "cpu/mcs51/mcs51.h"
|
||||
@ -369,3 +373,5 @@ private:
|
||||
uint8_t m_rle_byte;
|
||||
void isgsm_map(address_map &map);
|
||||
};
|
||||
|
||||
#endif // MAME_INCLUDES_SEGAS16B_H
|
||||
|
@ -5,6 +5,10 @@
|
||||
Sega System 16A/16B/18/Outrun/Hang On/X-Board/Y-Board hardware
|
||||
|
||||
***************************************************************************/
|
||||
#ifndef MAME_INCLUDES_SEGAS18_H
|
||||
#define MAME_INCLUDES_SEGAS18_H
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "cpu/m68000/m68000.h"
|
||||
#include "cpu/mcs51/mcs51.h"
|
||||
@ -176,3 +180,5 @@ private:
|
||||
uint8_t m_lghost_value;
|
||||
uint8_t m_lghost_select;
|
||||
};
|
||||
|
||||
#endif // MAME_INCLUDES_SEGAS18_H
|
||||
|
@ -4,6 +4,10 @@
|
||||
* Sega System 24
|
||||
*
|
||||
*/
|
||||
#ifndef MAME_INCLUDES_SEGAS24_H
|
||||
#define MAME_INCLUDES_SEGAS24_H
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "machine/timer.h"
|
||||
#include "video/segaic24.h"
|
||||
@ -176,3 +180,5 @@ private:
|
||||
void system24_cpu1_map(address_map &map);
|
||||
void system24_cpu2_map(address_map &map);
|
||||
};
|
||||
|
||||
#endif // MAME_INCLUDES_SEGAS24_H
|
||||
|
@ -5,6 +5,10 @@
|
||||
Sega Y-Board hardware
|
||||
|
||||
***************************************************************************/
|
||||
#ifndef MAME_INCLUDES_SEGAYBD_H
|
||||
#define MAME_INCLUDES_SEGAYBD_H
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "cpu/m68000/m68000.h"
|
||||
#include "cpu/z80/z80.h"
|
||||
@ -138,3 +142,5 @@ private:
|
||||
uint8_t m_misc_io_data;
|
||||
bitmap_ind16 m_tmp_bitmap;
|
||||
};
|
||||
|
||||
#endif // MAME_INCLUDES_SEGAYBD_H
|
||||
|
@ -1,5 +1,9 @@
|
||||
// license:BSD-3-Clause
|
||||
// copyright-holders:Luca Elia
|
||||
#ifndef MAME_INCLUDES_SETA_H
|
||||
#define MAME_INCLUDES_SETA_H
|
||||
|
||||
#pragma once
|
||||
|
||||
/***************************************************************************
|
||||
|
||||
@ -68,7 +72,8 @@ public:
|
||||
m_gun_recoil(*this,"Player%u_Gun_Recoil", 1U),
|
||||
m_leds(*this, "led%u", 0U),
|
||||
m_gfxdecode(*this, "gfxdecode"),
|
||||
m_palette(*this, "palette") { }
|
||||
m_palette(*this, "palette")
|
||||
{ }
|
||||
|
||||
void keroppij(machine_config &config);
|
||||
void madshark(machine_config &config);
|
||||
@ -487,3 +492,5 @@ private:
|
||||
void update_hoppers();
|
||||
void show_outputs();
|
||||
};
|
||||
|
||||
#endif // MAME_INCLUDES_SETA_H
|
||||
|
@ -1,5 +1,9 @@
|
||||
// license:BSD-3-Clause
|
||||
// copyright-holders:Zsolt Vasvari
|
||||
#ifndef MAME_INCLUDES_SUPRLOCO_H
|
||||
#define MAME_INCLUDES_SUPRLOCO_H
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "machine/i8255.h"
|
||||
#include "emupal.h"
|
||||
@ -7,8 +11,8 @@
|
||||
class suprloco_state : public driver_device
|
||||
{
|
||||
public:
|
||||
suprloco_state(const machine_config &mconfig, device_type type, const char *tag)
|
||||
: driver_device(mconfig, type, tag),
|
||||
suprloco_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_gfxdecode(*this, "gfxdecode"),
|
||||
@ -16,7 +20,8 @@ public:
|
||||
m_spriteram(*this, "spriteram"),
|
||||
m_videoram(*this, "videoram"),
|
||||
m_scrollram(*this, "scrollram"),
|
||||
m_decrypted_opcodes(*this, "decrypted_opcodes") { }
|
||||
m_decrypted_opcodes(*this, "decrypted_opcodes")
|
||||
{ }
|
||||
|
||||
void suprloco(machine_config &config);
|
||||
|
||||
@ -54,3 +59,5 @@ private:
|
||||
void main_map(address_map &map);
|
||||
void sound_map(address_map &map);
|
||||
};
|
||||
|
||||
#endif // MAME_INCLUDES_SUPRLOCO_H
|
||||
|
Loading…
Reference in New Issue
Block a user