mirror of
https://github.com/holub/mame
synced 2025-06-06 04:43:45 +03:00
taito_l: split giant state class up into family tree, reduce tagmap lookups
This commit is contained in:
parent
936498261b
commit
d3b9d5482f
@ -5,18 +5,18 @@
|
|||||||
namespace {
|
namespace {
|
||||||
|
|
||||||
ROM_START( m68705p3 )
|
ROM_START( m68705p3 )
|
||||||
ROM_REGION(0x0073, "bootstrap", 0)
|
ROM_REGION(0x0073, "bootstrap", 0)
|
||||||
ROM_LOAD("bootstrap.bin", 0x0000, 0x0073, CRC(696e1383) SHA1(45104fe1dbd683d251ed2b9411b1f4befbb5aff4))
|
ROM_LOAD("bootstrap.bin", 0x0000, 0x0073, CRC(696e1383) SHA1(45104fe1dbd683d251ed2b9411b1f4befbb5aff4))
|
||||||
ROM_END
|
ROM_END
|
||||||
|
|
||||||
ROM_START( m68705p5 )
|
ROM_START( m68705p5 )
|
||||||
ROM_REGION(0x0073, "bootstrap", 0)
|
ROM_REGION(0x0073, "bootstrap", 0)
|
||||||
ROM_LOAD("bootstrap.bin", 0x0000, 0x0073, CRC(f70a8620) SHA1(c154f78c23f10bb903a531cb19e99121d5f7c19c))
|
ROM_LOAD("bootstrap.bin", 0x0000, 0x0073, CRC(f70a8620) SHA1(c154f78c23f10bb903a531cb19e99121d5f7c19c))
|
||||||
ROM_END
|
ROM_END
|
||||||
|
|
||||||
ROM_START( m68705u3 )
|
ROM_START( m68705u3 )
|
||||||
ROM_REGION(0x0078, "bootstrap", 0)
|
ROM_REGION(0x0078, "bootstrap", 0)
|
||||||
ROM_LOAD("bootstrap.bin", 0x0000, 0x0073, CRC(5946479b) SHA1(834ea00aef5de12dbcd6421a6e21d5ea96cfbf37))
|
ROM_LOAD("bootstrap.bin", 0x0000, 0x0073, CRC(5946479b) SHA1(834ea00aef5de12dbcd6421a6e21d5ea96cfbf37))
|
||||||
ROM_END
|
ROM_END
|
||||||
|
|
||||||
} // anonymous namespace
|
} // anonymous namespace
|
||||||
@ -479,9 +479,9 @@ m68705p_device::m68705p_device(
|
|||||||
char const *source)
|
char const *source)
|
||||||
: m68705_new_device(mconfig, tag, owner, clock, type, name, 11, address_map_delegate(FUNC(m68705p_device::p_map), this), shortname, source)
|
: m68705_new_device(mconfig, tag, owner, clock, type, name, 11, address_map_delegate(FUNC(m68705p_device::p_map), this), shortname, source)
|
||||||
{
|
{
|
||||||
set_port_open_drain<0>(true); // Port A is open drain with internal pull-ups
|
set_port_open_drain<0>(true); // Port A is open drain with internal pull-ups
|
||||||
set_port_mask<2>(0xf0); // Port C is four bits wide
|
set_port_mask<2>(0xf0); // Port C is four bits wide
|
||||||
set_port_mask<3>(0xff); // Port D isn't present
|
set_port_mask<3>(0xff); // Port D isn't present
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -546,7 +546,7 @@ ADDRESS_MAP_END
|
|||||||
m68705u3_device::m68705u3_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock)
|
m68705u3_device::m68705u3_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock)
|
||||||
: m68705_new_device(mconfig, tag, owner, clock, M68705U3, "MC68705U3", 11, address_map_delegate(FUNC(m68705u3_device::u_map), this), "m68705u3", __FILE__)
|
: m68705_new_device(mconfig, tag, owner, clock, M68705U3, "MC68705U3", 11, address_map_delegate(FUNC(m68705u3_device::u_map), this), "m68705u3", __FILE__)
|
||||||
{
|
{
|
||||||
set_port_open_drain<0>(true); // Port A is open drain with internal pull-ups
|
set_port_open_drain<0>(true); // Port A is open drain with internal pull-ups
|
||||||
}
|
}
|
||||||
|
|
||||||
tiny_rom_entry const *m68705u3_device::device_rom_region() const
|
tiny_rom_entry const *m68705u3_device::device_rom_region() const
|
||||||
|
@ -133,7 +133,7 @@ protected:
|
|||||||
DECLARE_WRITE8_MEMBER(pcr_w);
|
DECLARE_WRITE8_MEMBER(pcr_w);
|
||||||
|
|
||||||
TIMER_CALLBACK_MEMBER(timer_68705_increment);
|
TIMER_CALLBACK_MEMBER(timer_68705_increment);
|
||||||
|
|
||||||
virtual void device_timer(emu_timer &timer, device_timer_id id, int param, void *ptr) override;
|
virtual void device_timer(emu_timer &timer, device_timer_id id, int param, void *ptr) override;
|
||||||
|
|
||||||
// device-level overrides
|
// device-level overrides
|
||||||
@ -148,19 +148,19 @@ protected:
|
|||||||
emu_timer *m_68705_timer;
|
emu_timer *m_68705_timer;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
required_region_ptr<u8> m_user_rom;
|
required_region_ptr<u8> m_user_rom;
|
||||||
|
|
||||||
bool m_port_open_drain[PORT_COUNT];
|
bool m_port_open_drain[PORT_COUNT];
|
||||||
u8 m_port_mask[PORT_COUNT];
|
u8 m_port_mask[PORT_COUNT];
|
||||||
u8 m_port_input[PORT_COUNT];
|
u8 m_port_input[PORT_COUNT];
|
||||||
u8 m_port_latch[PORT_COUNT];
|
u8 m_port_latch[PORT_COUNT];
|
||||||
u8 m_port_ddr[PORT_COUNT];
|
u8 m_port_ddr[PORT_COUNT];
|
||||||
devcb_read8 m_port_cb_r[PORT_COUNT];
|
devcb_read8 m_port_cb_r[PORT_COUNT];
|
||||||
devcb_write8 m_port_cb_w[PORT_COUNT];
|
devcb_write8 m_port_cb_w[PORT_COUNT];
|
||||||
|
|
||||||
u8 m_pcr;
|
u8 m_pcr;
|
||||||
u8 m_pl_data;
|
u8 m_pl_data;
|
||||||
u16 m_pl_addr;
|
u16 m_pl_addr;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
@ -238,6 +238,6 @@ protected:
|
|||||||
#define M68705_INT_MASK 0x03
|
#define M68705_INT_MASK 0x03
|
||||||
#define M68705_IRQ_LINE (M6805_IRQ_LINE + 0)
|
#define M68705_IRQ_LINE (M6805_IRQ_LINE + 0)
|
||||||
#define M68705_INT_TIMER (M6805_IRQ_LINE + 1)
|
#define M68705_INT_TIMER (M6805_IRQ_LINE + 1)
|
||||||
#define M68705_VPP_LINE (M6805_IRQ_LINE + 2)
|
#define M68705_VPP_LINE (M6805_IRQ_LINE + 2)
|
||||||
|
|
||||||
#endif // MAME_CPU_M6805_M68705_H
|
#endif // MAME_CPU_M6805_M68705_H
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -8,12 +8,13 @@ class taitol_state : public driver_device
|
|||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
taitol_state(const machine_config &mconfig, device_type type, const char *tag)
|
taitol_state(const machine_config &mconfig, device_type type, const char *tag)
|
||||||
: driver_device(mconfig, type, tag),
|
: driver_device(mconfig, type, tag)
|
||||||
m_maincpu(*this, "maincpu"),
|
, m_main_cpu(*this, "maincpu")
|
||||||
m_audiocpu(*this, "audiocpu"),
|
, m_main_prg(*this, "maincpu")
|
||||||
m_msm(*this, "msm"),
|
, m_main_bnk(*this, "bank1")
|
||||||
m_gfxdecode(*this, "gfxdecode"),
|
, m_ram_bnks(*this, "bank%u", 2)
|
||||||
m_palette(*this, "palette")
|
, m_gfxdecode(*this, "gfxdecode")
|
||||||
|
, m_palette(*this, "palette")
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -37,38 +38,11 @@ public:
|
|||||||
u8 *m_current_base[4];
|
u8 *m_current_base[4];
|
||||||
|
|
||||||
int m_cur_rombank;
|
int m_cur_rombank;
|
||||||
int m_cur_rombank2;
|
|
||||||
int m_cur_rambank[4];
|
int m_cur_rambank[4];
|
||||||
int m_irq_adr_table[3];
|
int m_irq_adr_table[3];
|
||||||
int m_irq_enable;
|
int m_irq_enable;
|
||||||
int m_adpcm_pos;
|
|
||||||
int m_adpcm_data;
|
|
||||||
int m_trackx;
|
|
||||||
int m_tracky;
|
|
||||||
int m_mux_ctrl;
|
|
||||||
int m_extport;
|
|
||||||
int m_last_irq_level;
|
int m_last_irq_level;
|
||||||
int m_high;
|
int m_high;
|
||||||
int m_high2;
|
|
||||||
int m_last_data_adr;
|
|
||||||
int m_last_data;
|
|
||||||
int m_cur_bank;
|
|
||||||
|
|
||||||
const u8 *m_mcu_reply;
|
|
||||||
int m_mcu_pos;
|
|
||||||
int m_mcu_reply_len;
|
|
||||||
|
|
||||||
const char *m_porte0_tag;
|
|
||||||
const char *m_porte1_tag;
|
|
||||||
const char *m_portf0_tag;
|
|
||||||
const char *m_portf1_tag;
|
|
||||||
|
|
||||||
/* devices */
|
|
||||||
required_device<cpu_device> m_maincpu;
|
|
||||||
optional_device<cpu_device> m_audiocpu;
|
|
||||||
optional_device<msm5205_device> m_msm;
|
|
||||||
required_device<gfxdecode_device> m_gfxdecode;
|
|
||||||
required_device<palette_device> m_palette;
|
|
||||||
|
|
||||||
/* memory buffers */
|
/* memory buffers */
|
||||||
u8 m_rambanks[0x1000 * 12];
|
u8 m_rambanks[0x1000 * 12];
|
||||||
@ -79,60 +53,25 @@ public:
|
|||||||
DECLARE_WRITE8_MEMBER(irq_enable_w);
|
DECLARE_WRITE8_MEMBER(irq_enable_w);
|
||||||
DECLARE_READ8_MEMBER(irq_enable_r);
|
DECLARE_READ8_MEMBER(irq_enable_r);
|
||||||
DECLARE_WRITE8_MEMBER(rombankswitch_w);
|
DECLARE_WRITE8_MEMBER(rombankswitch_w);
|
||||||
DECLARE_WRITE8_MEMBER(rombank2switch_w);
|
|
||||||
DECLARE_READ8_MEMBER(rombankswitch_r);
|
DECLARE_READ8_MEMBER(rombankswitch_r);
|
||||||
DECLARE_READ8_MEMBER(rombank2switch_r);
|
|
||||||
DECLARE_WRITE8_MEMBER(rambankswitch_w);
|
DECLARE_WRITE8_MEMBER(rambankswitch_w);
|
||||||
DECLARE_READ8_MEMBER(rambankswitch_r);
|
DECLARE_READ8_MEMBER(rambankswitch_r);
|
||||||
DECLARE_WRITE8_MEMBER(bank0_w);
|
DECLARE_WRITE8_MEMBER(bank0_w);
|
||||||
DECLARE_WRITE8_MEMBER(bank1_w);
|
DECLARE_WRITE8_MEMBER(bank1_w);
|
||||||
DECLARE_WRITE8_MEMBER(bank2_w);
|
DECLARE_WRITE8_MEMBER(bank2_w);
|
||||||
DECLARE_WRITE8_MEMBER(bank3_w);
|
DECLARE_WRITE8_MEMBER(bank3_w);
|
||||||
DECLARE_WRITE8_MEMBER(control2_w);
|
|
||||||
DECLARE_WRITE8_MEMBER(mcu_data_w);
|
|
||||||
DECLARE_WRITE8_MEMBER(mcu_control_w);
|
DECLARE_WRITE8_MEMBER(mcu_control_w);
|
||||||
DECLARE_READ8_MEMBER(mcu_data_r);
|
|
||||||
DECLARE_READ8_MEMBER(mcu_control_r);
|
DECLARE_READ8_MEMBER(mcu_control_r);
|
||||||
DECLARE_READ8_MEMBER(mux_r);
|
|
||||||
DECLARE_WRITE8_MEMBER(mux_w);
|
|
||||||
DECLARE_WRITE8_MEMBER(mux_ctrl_w);
|
|
||||||
DECLARE_WRITE8_MEMBER(champwr_msm5205_lo_w);
|
|
||||||
DECLARE_WRITE8_MEMBER(champwr_msm5205_hi_w);
|
|
||||||
DECLARE_READ8_MEMBER(horshoes_tracky_reset_r);
|
|
||||||
DECLARE_READ8_MEMBER(horshoes_trackx_reset_r);
|
|
||||||
DECLARE_READ8_MEMBER(horshoes_tracky_lo_r);
|
|
||||||
DECLARE_READ8_MEMBER(horshoes_tracky_hi_r);
|
|
||||||
DECLARE_READ8_MEMBER(horshoes_trackx_lo_r);
|
|
||||||
DECLARE_READ8_MEMBER(horshoes_trackx_hi_r);
|
|
||||||
DECLARE_WRITE8_MEMBER(sound_bankswitch_w);
|
|
||||||
DECLARE_WRITE8_MEMBER(horshoes_bankg_w);
|
|
||||||
DECLARE_WRITE8_MEMBER(taitol_bankc_w);
|
DECLARE_WRITE8_MEMBER(taitol_bankc_w);
|
||||||
DECLARE_READ8_MEMBER(taitol_bankc_r);
|
DECLARE_READ8_MEMBER(taitol_bankc_r);
|
||||||
DECLARE_WRITE8_MEMBER(taitol_control_w);
|
DECLARE_WRITE8_MEMBER(taitol_control_w);
|
||||||
DECLARE_READ8_MEMBER(taitol_control_r);
|
DECLARE_READ8_MEMBER(taitol_control_r);
|
||||||
DECLARE_READ8_MEMBER(portA_r);
|
|
||||||
DECLARE_READ8_MEMBER(portB_r);
|
|
||||||
DECLARE_READ8_MEMBER(extport_select_and_ym2203_r);
|
|
||||||
DECLARE_WRITE8_MEMBER(champwr_msm5205_start_w);
|
|
||||||
DECLARE_WRITE8_MEMBER(champwr_msm5205_stop_w);
|
|
||||||
DECLARE_WRITE8_MEMBER(champwr_msm5205_volume_w);
|
|
||||||
DECLARE_WRITE8_MEMBER(portA_w);
|
|
||||||
DECLARE_DRIVER_INIT(plottinga);
|
|
||||||
TILE_GET_INFO_MEMBER(get_bg18_tile_info);
|
TILE_GET_INFO_MEMBER(get_bg18_tile_info);
|
||||||
TILE_GET_INFO_MEMBER(get_bg19_tile_info);
|
TILE_GET_INFO_MEMBER(get_bg19_tile_info);
|
||||||
TILE_GET_INFO_MEMBER(get_ch1a_tile_info);
|
TILE_GET_INFO_MEMBER(get_ch1a_tile_info);
|
||||||
DECLARE_MACHINE_START(taito_l);
|
DECLARE_MACHINE_START(taito_l);
|
||||||
DECLARE_MACHINE_RESET(fhawk);
|
DECLARE_VIDEO_START(taito_l);
|
||||||
DECLARE_VIDEO_START(taitol);
|
DECLARE_MACHINE_RESET(taito_l);
|
||||||
DECLARE_MACHINE_RESET(kurikint);
|
|
||||||
DECLARE_MACHINE_RESET(plotting);
|
|
||||||
DECLARE_MACHINE_RESET(evilston);
|
|
||||||
DECLARE_MACHINE_RESET(champwr);
|
|
||||||
DECLARE_MACHINE_RESET(raimais);
|
|
||||||
DECLARE_MACHINE_RESET(puzznic);
|
|
||||||
DECLARE_MACHINE_RESET(horshoes);
|
|
||||||
DECLARE_MACHINE_RESET(palamed);
|
|
||||||
DECLARE_MACHINE_RESET(cachat);
|
|
||||||
u32 screen_update_taitol(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
|
u32 screen_update_taitol(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
|
||||||
void screen_eof_taitol(screen_device &screen, bool state);
|
void screen_eof_taitol(screen_device &screen, bool state);
|
||||||
TIMER_DEVICE_CALLBACK_MEMBER(vbl_interrupt);
|
TIMER_DEVICE_CALLBACK_MEMBER(vbl_interrupt);
|
||||||
@ -149,10 +88,223 @@ public:
|
|||||||
void taitol_bg19_m(int offset);
|
void taitol_bg19_m(int offset);
|
||||||
void taitol_char1a_m(int offset);
|
void taitol_char1a_m(int offset);
|
||||||
void taitol_obj1b_m(int offset);
|
void taitol_obj1b_m(int offset);
|
||||||
void draw_sprites( screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
|
void draw_sprites(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
|
||||||
void palette_notifier(int addr);
|
void palette_notifier(int addr);
|
||||||
void state_register();
|
|
||||||
void taito_machine_reset();
|
|
||||||
void bank_w(address_space &space, offs_t offset, u8 data, int banknum);
|
void bank_w(address_space &space, offs_t offset, u8 data, int banknum);
|
||||||
DECLARE_WRITE_LINE_MEMBER(champwr_msm5205_vck);
|
|
||||||
|
protected:
|
||||||
|
virtual void state_register();
|
||||||
|
virtual void taito_machine_reset();
|
||||||
|
|
||||||
|
required_device<cpu_device> m_main_cpu;
|
||||||
|
required_region_ptr<u8> m_main_prg;
|
||||||
|
required_memory_bank m_main_bnk;
|
||||||
|
required_memory_bank_array<4> m_ram_bnks;
|
||||||
|
required_device<gfxdecode_device> m_gfxdecode;
|
||||||
|
required_device<palette_device> m_palette;
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
class taitol_2cpu_state : public taitol_state
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
taitol_2cpu_state(const machine_config &mconfig, device_type type, const char *tag)
|
||||||
|
: taitol_state(mconfig, type, tag)
|
||||||
|
, m_audio_cpu(*this, "audiocpu")
|
||||||
|
, m_audio_prg(*this, "audiocpu")
|
||||||
|
, m_audio_bnk(*this, "bank7")
|
||||||
|
, m_dswa(*this, "DSWA")
|
||||||
|
, m_dswb(*this, "DSWB")
|
||||||
|
, m_in0(*this, "IN0")
|
||||||
|
, m_in1(*this, "IN1")
|
||||||
|
, m_in2(*this, "IN2")
|
||||||
|
, m_mux_ctrl(0)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
DECLARE_WRITE8_MEMBER(control2_w);
|
||||||
|
DECLARE_WRITE8_MEMBER(sound_bankswitch_w);
|
||||||
|
DECLARE_READ8_MEMBER(mux_r);
|
||||||
|
DECLARE_WRITE8_MEMBER(mux_w);
|
||||||
|
DECLARE_WRITE8_MEMBER(mux_ctrl_w);
|
||||||
|
|
||||||
|
protected:
|
||||||
|
virtual void state_register() override;
|
||||||
|
virtual void taito_machine_reset() override;
|
||||||
|
|
||||||
|
required_device<cpu_device> m_audio_cpu;
|
||||||
|
required_region_ptr<u8> m_audio_prg;
|
||||||
|
required_memory_bank m_audio_bnk;
|
||||||
|
|
||||||
|
required_ioport m_dswa;
|
||||||
|
required_ioport m_dswb;
|
||||||
|
required_ioport m_in0;
|
||||||
|
required_ioport m_in1;
|
||||||
|
required_ioport m_in2;
|
||||||
|
|
||||||
|
u8 m_mux_ctrl;
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
class taitol_3cpu_state : public taitol_2cpu_state
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
taitol_3cpu_state(const machine_config &mconfig, device_type type, const char *tag)
|
||||||
|
: taitol_2cpu_state(mconfig, type, tag)
|
||||||
|
, m_slave_prg(*this, "slave")
|
||||||
|
, m_slave_bnk(*this, "bank6")
|
||||||
|
, m_cur_rombank2(0)
|
||||||
|
, m_high2(0)
|
||||||
|
, m_cur_audio_bnk(0)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
DECLARE_WRITE8_MEMBER(rombank2switch_w);
|
||||||
|
DECLARE_READ8_MEMBER(rombank2switch_r);
|
||||||
|
DECLARE_WRITE8_MEMBER(portA_w);
|
||||||
|
|
||||||
|
protected:
|
||||||
|
virtual void state_register() override;
|
||||||
|
virtual void taito_machine_reset() override;
|
||||||
|
|
||||||
|
required_region_ptr<u8> m_slave_prg;
|
||||||
|
required_memory_bank m_slave_bnk;
|
||||||
|
|
||||||
|
u8 m_cur_rombank2;
|
||||||
|
u8 m_high2;
|
||||||
|
u8 m_cur_audio_bnk;
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
class champwr_state : public taitol_3cpu_state
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
champwr_state(const machine_config &mconfig, device_type type, const char *tag)
|
||||||
|
: taitol_3cpu_state(mconfig, type, tag)
|
||||||
|
, m_msm(*this, "msm")
|
||||||
|
, m_adpcm_rgn(*this, "adpcm")
|
||||||
|
, m_adpcm_pos(0)
|
||||||
|
, m_adpcm_data(-1)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
DECLARE_WRITE_LINE_MEMBER(msm5205_vck);
|
||||||
|
|
||||||
|
DECLARE_WRITE8_MEMBER(msm5205_lo_w);
|
||||||
|
DECLARE_WRITE8_MEMBER(msm5205_hi_w);
|
||||||
|
DECLARE_WRITE8_MEMBER(msm5205_start_w);
|
||||||
|
DECLARE_WRITE8_MEMBER(msm5205_stop_w);
|
||||||
|
DECLARE_WRITE8_MEMBER(msm5205_volume_w);
|
||||||
|
|
||||||
|
protected:
|
||||||
|
virtual void state_register() override;
|
||||||
|
virtual void taito_machine_reset() override;
|
||||||
|
|
||||||
|
required_device<msm5205_device> m_msm;
|
||||||
|
required_region_ptr<u8> m_adpcm_rgn;
|
||||||
|
|
||||||
|
int m_adpcm_pos;
|
||||||
|
int m_adpcm_data;
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
class taitol_1cpu_state : public taitol_state
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
taitol_1cpu_state(const machine_config &mconfig, device_type type, const char *tag)
|
||||||
|
: taitol_state(mconfig, type, tag)
|
||||||
|
, m_ymsnd(*this, "ymsnd")
|
||||||
|
, m_porte0_tag(nullptr)
|
||||||
|
, m_porte1_tag(nullptr)
|
||||||
|
, m_portf0_tag(nullptr)
|
||||||
|
, m_portf1_tag(nullptr)
|
||||||
|
, m_extport(0)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
DECLARE_READ8_MEMBER(portA_r);
|
||||||
|
DECLARE_READ8_MEMBER(portB_r);
|
||||||
|
DECLARE_READ8_MEMBER(extport_select_and_ym2203_r);
|
||||||
|
|
||||||
|
DECLARE_DRIVER_INIT(plottinga);
|
||||||
|
|
||||||
|
DECLARE_MACHINE_RESET(plotting);
|
||||||
|
DECLARE_MACHINE_RESET(puzznic);
|
||||||
|
DECLARE_MACHINE_RESET(palamed);
|
||||||
|
DECLARE_MACHINE_RESET(cachat);
|
||||||
|
|
||||||
|
protected:
|
||||||
|
virtual void state_register() override;
|
||||||
|
virtual void taito_machine_reset() override;
|
||||||
|
|
||||||
|
required_device<ym2203_device> m_ymsnd;
|
||||||
|
|
||||||
|
char const *m_porte0_tag;
|
||||||
|
char const *m_porte1_tag;
|
||||||
|
char const *m_portf0_tag;
|
||||||
|
char const *m_portf1_tag;
|
||||||
|
|
||||||
|
int m_extport;
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
class puzznic_state : public taitol_1cpu_state
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
puzznic_state(const machine_config &mconfig, device_type type, const char *tag)
|
||||||
|
: taitol_1cpu_state(mconfig, type, tag)
|
||||||
|
, m_mcu_reply(nullptr)
|
||||||
|
, m_mcu_pos(0)
|
||||||
|
, m_mcu_reply_len(0)
|
||||||
|
, m_last_data_adr(0)
|
||||||
|
, m_last_data(0)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
DECLARE_READ8_MEMBER(mcu_data_r);
|
||||||
|
DECLARE_WRITE8_MEMBER(mcu_data_w);
|
||||||
|
|
||||||
|
protected:
|
||||||
|
virtual void state_register() override;
|
||||||
|
virtual void taito_machine_reset() override;
|
||||||
|
|
||||||
|
u8 const * m_mcu_reply;
|
||||||
|
int m_mcu_pos;
|
||||||
|
int m_mcu_reply_len;
|
||||||
|
int m_last_data_adr;
|
||||||
|
int m_last_data;
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
class horshoes_state : public taitol_1cpu_state
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
horshoes_state(const machine_config &mconfig, device_type type, const char *tag)
|
||||||
|
: taitol_1cpu_state(mconfig, type, tag)
|
||||||
|
, m_analog0(*this, "AN0")
|
||||||
|
, m_analog1(*this, "AN1")
|
||||||
|
, m_trackx(0)
|
||||||
|
, m_tracky(0)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
DECLARE_READ8_MEMBER(tracky_reset_r);
|
||||||
|
DECLARE_READ8_MEMBER(trackx_reset_r);
|
||||||
|
DECLARE_READ8_MEMBER(tracky_lo_r);
|
||||||
|
DECLARE_READ8_MEMBER(tracky_hi_r);
|
||||||
|
DECLARE_READ8_MEMBER(trackx_lo_r);
|
||||||
|
DECLARE_READ8_MEMBER(trackx_hi_r);
|
||||||
|
DECLARE_WRITE8_MEMBER(bankg_w);
|
||||||
|
|
||||||
|
DECLARE_MACHINE_RESET(horshoes);
|
||||||
|
|
||||||
|
protected:
|
||||||
|
virtual void state_register() override;
|
||||||
|
virtual void taito_machine_reset() override;
|
||||||
|
|
||||||
|
required_ioport m_analog0;
|
||||||
|
required_ioport m_analog1;
|
||||||
|
|
||||||
|
int m_trackx;
|
||||||
|
int m_tracky;
|
||||||
};
|
};
|
||||||
|
@ -56,7 +56,7 @@ TILE_GET_INFO_MEMBER(taitol_state::get_ch1a_tile_info)
|
|||||||
|
|
||||||
***************************************************************************/
|
***************************************************************************/
|
||||||
|
|
||||||
VIDEO_START_MEMBER(taitol_state,taitol)
|
VIDEO_START_MEMBER(taitol_state, taito_l)
|
||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
@ -83,7 +83,7 @@ VIDEO_START_MEMBER(taitol_state,taitol)
|
|||||||
|
|
||||||
***************************************************************************/
|
***************************************************************************/
|
||||||
|
|
||||||
WRITE8_MEMBER(taitol_state::horshoes_bankg_w)
|
WRITE8_MEMBER(horshoes_state::bankg_w)
|
||||||
{
|
{
|
||||||
if (m_horshoes_gfxbank != data)
|
if (m_horshoes_gfxbank != data)
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user