bus/cpc: Simplify handler signatures (nw)

This commit is contained in:
AJR 2020-06-07 18:36:33 -04:00
parent fc4092f42a
commit cc3f16ec95
30 changed files with 140 additions and 140 deletions

View File

@ -51,7 +51,7 @@ void cpc_amdrum_device::device_start()
{ {
m_slot = dynamic_cast<cpc_expansion_slot_device *>(owner()); m_slot = dynamic_cast<cpc_expansion_slot_device *>(owner());
address_space &space = m_slot->cpu().space(AS_IO); address_space &space = m_slot->cpu().space(AS_IO);
space.install_write_handler(0xff00,0xffff, write8_delegate(*this, FUNC(cpc_amdrum_device::dac_w))); space.install_write_handler(0xff00,0xffff, write8smo_delegate(*this, FUNC(cpc_amdrum_device::dac_w)));
} }
//------------------------------------------------- //-------------------------------------------------
@ -63,7 +63,7 @@ void cpc_amdrum_device::device_reset()
// TODO // TODO
} }
WRITE8_MEMBER(cpc_amdrum_device::dac_w) void cpc_amdrum_device::dac_w(uint8_t data)
{ {
m_dac->write(data); m_dac->write(data);
} }

View File

@ -27,7 +27,7 @@ public:
// construction/destruction // construction/destruction
cpc_amdrum_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); cpc_amdrum_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
DECLARE_WRITE8_MEMBER(dac_w); void dac_w(uint8_t data);
protected: protected:
// device-level overrides // device-level overrides

View File

@ -74,7 +74,7 @@ void cpc_brunword4_device::device_start()
{ {
m_slot = dynamic_cast<cpc_expansion_slot_device *>(owner()); m_slot = dynamic_cast<cpc_expansion_slot_device *>(owner());
address_space &space = m_slot->cpu().space(AS_IO); address_space &space = m_slot->cpu().space(AS_IO);
space.install_write_handler(0xdf00,0xdfff, write8_delegate(*this, FUNC(cpc_brunword4_device::rombank_w))); space.install_write_handler(0xdf00,0xdfff, write8smo_delegate(*this, FUNC(cpc_brunword4_device::rombank_w)));
} }
void cpc_brunword4_device::device_reset() void cpc_brunword4_device::device_reset()
@ -82,7 +82,7 @@ void cpc_brunword4_device::device_reset()
m_rombank_active = false; m_rombank_active = false;
} }
WRITE8_MEMBER(cpc_brunword4_device::rombank_w) void cpc_brunword4_device::rombank_w(uint8_t data)
{ {
if((data & 0xc0) == 0xc0 && (data & 0x04) == 0) if((data & 0xc0) == 0xc0 && (data & 0x04) == 0)
{ {
@ -95,7 +95,7 @@ WRITE8_MEMBER(cpc_brunword4_device::rombank_w)
m_rombank_active = false; m_rombank_active = false;
return; return;
} }
m_slot->rom_select(space,0,data & 0x3f); // repeats every 64 ROMs, this breaks upper cart ROM selection on the Plus m_slot->rom_select(data & 0x3f); // repeats every 64 ROMs, this breaks upper cart ROM selection on the Plus
} }
void cpc_brunword4_device::set_mapping(uint8_t type) void cpc_brunword4_device::set_mapping(uint8_t type)

View File

@ -22,7 +22,7 @@ public:
// optional information overrides // optional information overrides
virtual const tiny_rom_entry *device_rom_region() const override; virtual const tiny_rom_entry *device_rom_region() const override;
DECLARE_WRITE8_MEMBER(rombank_w); void rombank_w(uint8_t data);
virtual void set_mapping(uint8_t type) override; virtual void set_mapping(uint8_t type) override;
protected: protected:

View File

@ -46,7 +46,7 @@ void cpc_pds_device::device_start()
m_slot = dynamic_cast<cpc_expansion_slot_device *>(owner()); m_slot = dynamic_cast<cpc_expansion_slot_device *>(owner());
address_space &space = m_slot->cpu().space(AS_IO); address_space &space = m_slot->cpu().space(AS_IO);
space.install_readwrite_handler(0xfbec,0xfbef, read8_delegate(*this, FUNC(cpc_pds_device::pio_r)), write8_delegate(*this, FUNC(cpc_pds_device::pio_w))); space.install_readwrite_handler(0xfbec,0xfbef, read8sm_delegate(*this, FUNC(cpc_pds_device::pio_r)), write8sm_delegate(*this, FUNC(cpc_pds_device::pio_w)));
} }
//------------------------------------------------- //-------------------------------------------------
@ -59,12 +59,12 @@ void cpc_pds_device::device_reset()
} }
READ8_MEMBER(cpc_pds_device::pio_r) uint8_t cpc_pds_device::pio_r(offs_t offset)
{ {
return m_pio->read(offset); return m_pio->read(offset);
} }
WRITE8_MEMBER(cpc_pds_device::pio_w) void cpc_pds_device::pio_w(offs_t offset, uint8_t data)
{ {
m_pio->write(offset,data); m_pio->write(offset,data);
} }

View File

@ -36,8 +36,8 @@ public:
// construction/destruction // construction/destruction
cpc_pds_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); cpc_pds_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
DECLARE_READ8_MEMBER(pio_r); uint8_t pio_r(offs_t offset);
DECLARE_WRITE8_MEMBER(pio_w); void pio_w(offs_t offset, uint8_t data);
protected: protected:
// device-level overrides // device-level overrides

View File

@ -106,8 +106,8 @@ void cpc_rs232_device::device_start()
m_slot = dynamic_cast<cpc_expansion_slot_device *>(owner()); m_slot = dynamic_cast<cpc_expansion_slot_device *>(owner());
address_space &space = m_slot->cpu().space(AS_IO); address_space &space = m_slot->cpu().space(AS_IO);
space.install_readwrite_handler(0xfadc,0xfadf, read8_delegate(*this, FUNC(cpc_rs232_device::dart_r)), write8_delegate(*this, FUNC(cpc_rs232_device::dart_w))); space.install_readwrite_handler(0xfadc,0xfadf, read8sm_delegate(*this, FUNC(cpc_rs232_device::dart_r)), write8sm_delegate(*this, FUNC(cpc_rs232_device::dart_w)));
space.install_readwrite_handler(0xfbdc,0xfbdf, read8_delegate(*this, FUNC(cpc_rs232_device::pit_r)), write8_delegate(*this, FUNC(cpc_rs232_device::pit_w))); space.install_readwrite_handler(0xfbdc,0xfbdf, read8sm_delegate(*this, FUNC(cpc_rs232_device::pit_r)), write8sm_delegate(*this, FUNC(cpc_rs232_device::pit_w)));
} }
//------------------------------------------------- //-------------------------------------------------
@ -135,22 +135,22 @@ WRITE_LINE_MEMBER(cpc_rs232_device::pit_out2_w)
m_dart->rxcb_w(state); m_dart->rxcb_w(state);
} }
READ8_MEMBER(cpc_rs232_device::dart_r) uint8_t cpc_rs232_device::dart_r(offs_t offset)
{ {
return m_dart->ba_cd_r(offset); return m_dart->ba_cd_r(offset);
} }
WRITE8_MEMBER(cpc_rs232_device::dart_w) void cpc_rs232_device::dart_w(offs_t offset, uint8_t data)
{ {
m_dart->ba_cd_w(offset,data); m_dart->ba_cd_w(offset,data);
} }
READ8_MEMBER(cpc_rs232_device::pit_r) uint8_t cpc_rs232_device::pit_r(offs_t offset)
{ {
return m_pit->read(offset); return m_pit->read(offset);
} }
WRITE8_MEMBER(cpc_rs232_device::pit_w) void cpc_rs232_device::pit_w(offs_t offset, uint8_t data)
{ {
m_pit->write(offset,data); m_pit->write(offset,data);
} }

View File

@ -22,10 +22,10 @@ public:
// construction/destruction // construction/destruction
cpc_rs232_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); cpc_rs232_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
DECLARE_READ8_MEMBER(dart_r); uint8_t dart_r(offs_t offset);
DECLARE_WRITE8_MEMBER(dart_w); void dart_w(offs_t offset, uint8_t data);
DECLARE_READ8_MEMBER(pit_r); uint8_t pit_r(offs_t offset);
DECLARE_WRITE8_MEMBER(pit_w); void pit_w(offs_t offset, uint8_t data);
protected: protected:
cpc_rs232_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); cpc_rs232_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock);

View File

@ -26,7 +26,7 @@ DEFINE_DEVICE_TYPE(CPC_DKSPEECH, cpc_dkspeech_device, "cpc_dkspeech", "DK'Tronic
// device I/O handlers // device I/O handlers
//------------------------------------------------- //-------------------------------------------------
READ8_MEMBER(cpc_ssa1_device::ssa1_r) uint8_t cpc_ssa1_device::ssa1_r()
{ {
uint8_t ret = 0xff; uint8_t ret = 0xff;
@ -39,12 +39,12 @@ READ8_MEMBER(cpc_ssa1_device::ssa1_r)
return ret; return ret;
} }
WRITE8_MEMBER(cpc_ssa1_device::ssa1_w) void cpc_ssa1_device::ssa1_w(uint8_t data)
{ {
m_sp0256_device->ald_w(data); m_sp0256_device->ald_w(data);
} }
READ8_MEMBER(cpc_dkspeech_device::dkspeech_r) uint8_t cpc_dkspeech_device::dkspeech_r()
{ {
uint8_t ret = 0xff; uint8_t ret = 0xff;
@ -56,7 +56,7 @@ READ8_MEMBER(cpc_dkspeech_device::dkspeech_r)
return ret; return ret;
} }
WRITE8_MEMBER(cpc_dkspeech_device::dkspeech_w) void cpc_dkspeech_device::dkspeech_w(uint8_t data)
{ {
m_sp0256_device->ald_w(data & 0x3f); m_sp0256_device->ald_w(data & 0x3f);
} }
@ -177,8 +177,8 @@ void cpc_ssa1_device::device_start()
m_rom = memregion("sp0256")->base(); m_rom = memregion("sp0256")->base();
space.install_readwrite_handler(0xfaee,0xfaee, read8_delegate(*this, FUNC(cpc_ssa1_device::ssa1_r)), write8_delegate(*this, FUNC(cpc_ssa1_device::ssa1_w))); space.install_readwrite_handler(0xfaee,0xfaee, read8smo_delegate(*this, FUNC(cpc_ssa1_device::ssa1_r)), write8smo_delegate(*this, FUNC(cpc_ssa1_device::ssa1_w)));
space.install_readwrite_handler(0xfbee,0xfbee, read8_delegate(*this, FUNC(cpc_ssa1_device::ssa1_r)), write8_delegate(*this, FUNC(cpc_ssa1_device::ssa1_w))); space.install_readwrite_handler(0xfbee,0xfbee, read8smo_delegate(*this, FUNC(cpc_ssa1_device::ssa1_r)), write8smo_delegate(*this, FUNC(cpc_ssa1_device::ssa1_w)));
} }
void cpc_dkspeech_device::device_start() void cpc_dkspeech_device::device_start()
@ -188,7 +188,7 @@ void cpc_dkspeech_device::device_start()
m_rom = memregion("sp0256")->base(); m_rom = memregion("sp0256")->base();
space.install_readwrite_handler(0xfbfe,0xfbfe, read8_delegate(*this, FUNC(cpc_dkspeech_device::dkspeech_r)), write8_delegate(*this, FUNC(cpc_dkspeech_device::dkspeech_w))); space.install_readwrite_handler(0xfbfe,0xfbfe, read8smo_delegate(*this, FUNC(cpc_dkspeech_device::dkspeech_r)), write8smo_delegate(*this, FUNC(cpc_dkspeech_device::dkspeech_w)));
} }
//------------------------------------------------- //-------------------------------------------------

View File

@ -61,8 +61,8 @@ public:
void set_sby(uint8_t state) { m_sby = state; } void set_sby(uint8_t state) { m_sby = state; }
uint8_t get_sby() { return m_sby; } uint8_t get_sby() { return m_sby; }
DECLARE_READ8_MEMBER(ssa1_r); uint8_t ssa1_r();
DECLARE_WRITE8_MEMBER(ssa1_w); void ssa1_w(uint8_t data);
protected: protected:
// device-level overrides // device-level overrides
@ -98,8 +98,8 @@ public:
void set_sby(uint8_t state) { m_sby = state; } void set_sby(uint8_t state) { m_sby = state; }
uint8_t get_sby() { return m_sby; } uint8_t get_sby() { return m_sby; }
DECLARE_READ8_MEMBER(dkspeech_r); uint8_t dkspeech_r();
DECLARE_WRITE8_MEMBER(dkspeech_w); void dkspeech_w(uint8_t data);
protected: protected:
// device-level overrides // device-level overrides

View File

@ -96,4 +96,4 @@ WRITE_LINE_MEMBER( cpc_expansion_slot_device::irq_w ) { m_out_irq_cb(state); }
WRITE_LINE_MEMBER( cpc_expansion_slot_device::nmi_w ) { m_out_nmi_cb(state); } WRITE_LINE_MEMBER( cpc_expansion_slot_device::nmi_w ) { m_out_nmi_cb(state); }
WRITE_LINE_MEMBER( cpc_expansion_slot_device::reset_w ) { m_out_reset_cb(state); } WRITE_LINE_MEMBER( cpc_expansion_slot_device::reset_w ) { m_out_reset_cb(state); }
WRITE_LINE_MEMBER( cpc_expansion_slot_device::romdis_w ) { m_out_romdis_cb(state); } WRITE_LINE_MEMBER( cpc_expansion_slot_device::romdis_w ) { m_out_romdis_cb(state); }
WRITE8_MEMBER( cpc_expansion_slot_device::rom_select ) { m_out_rom_select(data); } void cpc_expansion_slot_device::rom_select(uint8_t data) { m_out_rom_select(data); }

View File

@ -116,7 +116,7 @@ public:
DECLARE_WRITE_LINE_MEMBER( nmi_w ); DECLARE_WRITE_LINE_MEMBER( nmi_w );
DECLARE_WRITE_LINE_MEMBER( reset_w ); DECLARE_WRITE_LINE_MEMBER( reset_w );
DECLARE_WRITE_LINE_MEMBER( romdis_w ); DECLARE_WRITE_LINE_MEMBER( romdis_w );
DECLARE_WRITE8_MEMBER( rom_select ); void rom_select(uint8_t data);
void set_rom_bank(uint8_t sel) { if(m_card) m_card->set_rom_bank(sel); } // tell device the currently selected ROM void set_rom_bank(uint8_t sel) { if(m_card) m_card->set_rom_bank(sel); } // tell device the currently selected ROM
void set_mapping(uint8_t type) { if(m_card) m_card->set_mapping(type); } // tell device to enable any ROM or RAM mapping void set_mapping(uint8_t type) { if(m_card) m_card->set_mapping(type); } // tell device to enable any ROM or RAM mapping

View File

@ -75,9 +75,9 @@ void cpc_ddi1_device::device_start()
m_slot = dynamic_cast<cpc_expansion_slot_device *>(owner()); m_slot = dynamic_cast<cpc_expansion_slot_device *>(owner());
address_space &space = m_slot->cpu().space(AS_IO); address_space &space = m_slot->cpu().space(AS_IO);
space.install_write_handler(0xfa7e,0xfa7f, write8_delegate(*this, FUNC(cpc_ddi1_device::motor_w))); space.install_write_handler(0xfa7e,0xfa7f, write8sm_delegate(*this, FUNC(cpc_ddi1_device::motor_w)));
space.install_readwrite_handler(0xfb7e,0xfb7f, read8_delegate(*this, FUNC(cpc_ddi1_device::fdc_r)), write8_delegate(*this, FUNC(cpc_ddi1_device::fdc_w))); space.install_readwrite_handler(0xfb7e,0xfb7f, read8sm_delegate(*this, FUNC(cpc_ddi1_device::fdc_r)), write8sm_delegate(*this, FUNC(cpc_ddi1_device::fdc_w)));
space.install_write_handler(0xdf00,0xdfff, write8_delegate(*this, FUNC(cpc_ddi1_device::rombank_w))); space.install_write_handler(0xdf00,0xdfff, write8smo_delegate(*this, FUNC(cpc_ddi1_device::rombank_w)));
} }
//------------------------------------------------- //-------------------------------------------------
@ -89,7 +89,7 @@ void cpc_ddi1_device::device_reset()
m_rom_active = false; m_rom_active = false;
} }
WRITE8_MEMBER(cpc_ddi1_device::motor_w) void cpc_ddi1_device::motor_w(offs_t offset, uint8_t data)
{ {
switch(offset) switch(offset)
{ {
@ -111,7 +111,7 @@ WRITE8_MEMBER(cpc_ddi1_device::motor_w)
} }
} }
WRITE8_MEMBER(cpc_ddi1_device::fdc_w) void cpc_ddi1_device::fdc_w(offs_t offset, uint8_t data)
{ {
switch(offset) switch(offset)
{ {
@ -121,7 +121,7 @@ WRITE8_MEMBER(cpc_ddi1_device::fdc_w)
} }
} }
READ8_MEMBER(cpc_ddi1_device::fdc_r) uint8_t cpc_ddi1_device::fdc_r(offs_t offset)
{ {
uint8_t data = 0xff; uint8_t data = 0xff;
@ -137,13 +137,13 @@ READ8_MEMBER(cpc_ddi1_device::fdc_r)
return data; return data;
} }
WRITE8_MEMBER(cpc_ddi1_device::rombank_w) void cpc_ddi1_device::rombank_w(uint8_t data)
{ {
if(data == 0x07) if(data == 0x07)
m_rom_active = true; m_rom_active = true;
else else
m_rom_active = false; m_rom_active = false;
m_slot->rom_select(space,0,data); m_slot->rom_select(data);
} }
void cpc_ddi1_device::set_mapping(uint8_t type) void cpc_ddi1_device::set_mapping(uint8_t type)

View File

@ -23,10 +23,10 @@ public:
// construction/destruction // construction/destruction
cpc_ddi1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); cpc_ddi1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
DECLARE_WRITE8_MEMBER(motor_w); void motor_w(offs_t offset, uint8_t data);
DECLARE_WRITE8_MEMBER(fdc_w); void fdc_w(offs_t offset, uint8_t data);
DECLARE_READ8_MEMBER(fdc_r); uint8_t fdc_r(offs_t offset);
DECLARE_WRITE8_MEMBER(rombank_w); void rombank_w(uint8_t data);
protected: protected:
// device-level overrides // device-level overrides

View File

@ -46,7 +46,7 @@ void cpc_doubler_device::device_start()
{ {
m_slot = dynamic_cast<cpc_expansion_slot_device *>(owner()); m_slot = dynamic_cast<cpc_expansion_slot_device *>(owner());
address_space &space = m_slot->cpu().space(AS_IO); address_space &space = m_slot->cpu().space(AS_IO);
space.install_read_handler(0xf0e0,0xf0e0, read8_delegate(*this, FUNC(cpc_doubler_device::ext_tape_r))); space.install_read_handler(0xf0e0,0xf0e0, read8smo_delegate(*this, FUNC(cpc_doubler_device::ext_tape_r)));
} }
//------------------------------------------------- //-------------------------------------------------
@ -58,7 +58,7 @@ void cpc_doubler_device::device_reset()
// TODO // TODO
} }
READ8_MEMBER(cpc_doubler_device::ext_tape_r) uint8_t cpc_doubler_device::ext_tape_r()
{ {
uint8_t data = 0; uint8_t data = 0;
if(m_tape->input() > 0.03) if(m_tape->input() > 0.03)

View File

@ -24,7 +24,7 @@ public:
// construction/destruction // construction/destruction
cpc_doubler_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); cpc_doubler_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
DECLARE_READ8_MEMBER(ext_tape_r); uint8_t ext_tape_r();
protected: protected:
// device-level overrides // device-level overrides

View File

@ -58,8 +58,8 @@ void cpc_hd20_device::device_start()
{ {
m_slot = dynamic_cast<cpc_expansion_slot_device *>(owner()); m_slot = dynamic_cast<cpc_expansion_slot_device *>(owner());
address_space &space = m_slot->cpu().space(AS_IO); address_space &space = m_slot->cpu().space(AS_IO);
space.install_write_handler(0xfbe0,0xfbe4, write8_delegate(*this, FUNC(cpc_hd20_device::hdc_w))); space.install_write_handler(0xfbe0,0xfbe4, write8sm_delegate(*this, FUNC(cpc_hd20_device::hdc_w)));
space.install_read_handler(0xfbe0,0xfbe4, read8_delegate(*this, FUNC(cpc_hd20_device::hdc_r))); space.install_read_handler(0xfbe0,0xfbe4, read8sm_delegate(*this, FUNC(cpc_hd20_device::hdc_r)));
} }
//------------------------------------------------- //-------------------------------------------------
@ -71,7 +71,7 @@ void cpc_hd20_device::device_reset()
// TODO // TODO
} }
READ8_MEMBER(cpc_hd20_device::hdc_r) uint8_t cpc_hd20_device::hdc_r(offs_t offset)
{ {
uint8_t ret = 0x00; uint8_t ret = 0x00;
@ -95,7 +95,7 @@ READ8_MEMBER(cpc_hd20_device::hdc_r)
return ret; return ret;
} }
WRITE8_MEMBER(cpc_hd20_device::hdc_w) void cpc_hd20_device::hdc_w(offs_t offset, uint8_t data)
{ {
switch(offset) switch(offset)
{ {

View File

@ -26,8 +26,8 @@ public:
// construction/destruction // construction/destruction
cpc_hd20_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); cpc_hd20_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
DECLARE_READ8_MEMBER(hdc_r); uint8_t hdc_r(offs_t offset);
DECLARE_WRITE8_MEMBER(hdc_w); void hdc_w(offs_t offset, uint8_t data);
protected: protected:
// device-level overrides // device-level overrides

View File

@ -89,10 +89,10 @@ void al_magicsound_device::device_start()
{ {
m_slot = dynamic_cast<cpc_expansion_slot_device *>(owner()); m_slot = dynamic_cast<cpc_expansion_slot_device *>(owner());
address_space &space = m_slot->cpu().space(AS_IO); address_space &space = m_slot->cpu().space(AS_IO);
space.install_readwrite_handler(0xf8d0,0xf8df, read8_delegate(*this, FUNC(al_magicsound_device::dmac_r)), write8_delegate(*this, FUNC(al_magicsound_device::dmac_w))); space.install_readwrite_handler(0xf8d0,0xf8df, read8sm_delegate(*this, FUNC(al_magicsound_device::dmac_r)), write8sm_delegate(*this, FUNC(al_magicsound_device::dmac_w)));
space.install_write_handler(0xf9d0,0xf9df, write8_delegate(*this, FUNC(al_magicsound_device::timer_w))); space.install_write_handler(0xf9d0,0xf9df, write8sm_delegate(*this, FUNC(al_magicsound_device::timer_w)));
space.install_write_handler(0xfad0,0xfadf, write8_delegate(*this, FUNC(al_magicsound_device::volume_w))); space.install_write_handler(0xfad0,0xfadf, write8sm_delegate(*this, FUNC(al_magicsound_device::volume_w)));
space.install_write_handler(0xfbd0,0xfbdf, write8_delegate(*this, FUNC(al_magicsound_device::mapper_w))); space.install_write_handler(0xfbd0,0xfbdf, write8sm_delegate(*this, FUNC(al_magicsound_device::mapper_w)));
m_ramptr = machine().device<ram_device>(":" RAM_TAG); m_ramptr = machine().device<ram_device>(":" RAM_TAG);
@ -110,17 +110,17 @@ void al_magicsound_device::device_reset()
set_timer_gate(false); set_timer_gate(false);
} }
READ8_MEMBER(al_magicsound_device::dmac_r) uint8_t al_magicsound_device::dmac_r(offs_t offset)
{ {
return m_dmac->read(offset); return m_dmac->read(offset);
} }
WRITE8_MEMBER(al_magicsound_device::dmac_w) void al_magicsound_device::dmac_w(offs_t offset, uint8_t data)
{ {
m_dmac->write(offset,data); m_dmac->write(offset,data);
} }
WRITE8_MEMBER(al_magicsound_device::timer_w) void al_magicsound_device::timer_w(offs_t offset, uint8_t data)
{ {
// can both PITs be selected at the same time? // can both PITs be selected at the same time?
if(offset & 0x08) if(offset & 0x08)
@ -129,12 +129,12 @@ WRITE8_MEMBER(al_magicsound_device::timer_w)
m_timer2->write(offset & 0x03,data); m_timer2->write(offset & 0x03,data);
} }
WRITE8_MEMBER(al_magicsound_device::volume_w) void al_magicsound_device::volume_w(offs_t offset, uint8_t data)
{ {
m_volume[offset & 0x03] = data & 0x3f; m_volume[offset & 0x03] = data & 0x3f;
} }
WRITE8_MEMBER(al_magicsound_device::mapper_w) void al_magicsound_device::mapper_w(offs_t offset, uint8_t data)
{ {
uint8_t channel = (offset & 0x0c) >> 2; uint8_t channel = (offset & 0x0c) >> 2;
uint8_t page = offset & 0x03; uint8_t page = offset & 0x03;

View File

@ -41,11 +41,11 @@ public:
// construction/destruction // construction/destruction
al_magicsound_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); al_magicsound_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
DECLARE_READ8_MEMBER(dmac_r); uint8_t dmac_r(offs_t offset);
DECLARE_WRITE8_MEMBER(dmac_w); void dmac_w(offs_t offset, uint8_t data);
DECLARE_WRITE8_MEMBER(timer_w); void timer_w(offs_t offset, uint8_t data);
DECLARE_WRITE8_MEMBER(volume_w); void volume_w(offs_t offset, uint8_t data);
DECLARE_WRITE8_MEMBER(mapper_w); void mapper_w(offs_t offset, uint8_t data);
protected: protected:
// device-level overrides // device-level overrides

View File

@ -61,9 +61,9 @@ void cpc_musicmachine_device::device_start()
m_slot = dynamic_cast<cpc_expansion_slot_device *>(owner()); m_slot = dynamic_cast<cpc_expansion_slot_device *>(owner());
address_space &space = m_slot->cpu().space(AS_IO); address_space &space = m_slot->cpu().space(AS_IO);
space.install_write_handler(0xf8e8,0xf8e8, write8_delegate(*this, FUNC(cpc_musicmachine_device::irqsel_w))); space.install_write_handler(0xf8e8,0xf8e8, write8smo_delegate(*this, FUNC(cpc_musicmachine_device::irqsel_w)));
space.install_readwrite_handler(0xf8ec,0xf8ef, read8_delegate(*this, FUNC(cpc_musicmachine_device::acia_r)), write8_delegate(*this, FUNC(cpc_musicmachine_device::acia_w))); space.install_readwrite_handler(0xf8ec,0xf8ef, read8sm_delegate(*this, FUNC(cpc_musicmachine_device::acia_r)), write8sm_delegate(*this, FUNC(cpc_musicmachine_device::acia_w)));
space.install_write_handler(0xf8f0,0xf8f0, write8_delegate(*this, FUNC(cpc_musicmachine_device::dac_w))); space.install_write_handler(0xf8f0,0xf8f0, write8smo_delegate(*this, FUNC(cpc_musicmachine_device::dac_w)));
// 0xf8f4 - ADC read8_delegate // 0xf8f4 - ADC read8_delegate
// 0xf8f8 - ADC start // 0xf8f8 - ADC start
} }
@ -77,12 +77,12 @@ void cpc_musicmachine_device::device_reset()
// TODO // TODO
} }
WRITE8_MEMBER(cpc_musicmachine_device::dac_w) void cpc_musicmachine_device::dac_w(uint8_t data)
{ {
m_dac->write(data); m_dac->write(data);
} }
READ8_MEMBER(cpc_musicmachine_device::acia_r) uint8_t cpc_musicmachine_device::acia_r(offs_t offset)
{ {
uint8_t ret = 0; uint8_t ret = 0;
@ -99,7 +99,7 @@ READ8_MEMBER(cpc_musicmachine_device::acia_r)
return ret; return ret;
} }
WRITE8_MEMBER(cpc_musicmachine_device::acia_w) void cpc_musicmachine_device::acia_w(offs_t offset, uint8_t data)
{ {
switch(offset) switch(offset)
{ {
@ -112,7 +112,7 @@ WRITE8_MEMBER(cpc_musicmachine_device::acia_w)
} }
} }
WRITE8_MEMBER(cpc_musicmachine_device::irqsel_w) void cpc_musicmachine_device::irqsel_w(uint8_t data)
{ {
if(data == 0x01) if(data == 0x01)
m_irq_select = true; m_irq_select = true;

View File

@ -23,10 +23,10 @@ public:
// construction/destruction // construction/destruction
cpc_musicmachine_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); cpc_musicmachine_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
DECLARE_WRITE8_MEMBER(dac_w); void dac_w(uint8_t data);
DECLARE_READ8_MEMBER(acia_r); uint8_t acia_r(offs_t offset);
DECLARE_WRITE8_MEMBER(acia_w); void acia_w(offs_t offset, uint8_t data);
DECLARE_WRITE8_MEMBER(irqsel_w); void irqsel_w(uint8_t data);
DECLARE_WRITE_LINE_MEMBER(irq_w); DECLARE_WRITE_LINE_MEMBER(irq_w);
void write_acia_clock(u8 data) { m_acia->write_txc(data); m_acia->write_rxc(data); } void write_acia_clock(u8 data) { m_acia->write_txc(data); m_acia->write_rxc(data); }

View File

@ -69,11 +69,11 @@ void cpc_playcity_device::device_start()
m_slot = dynamic_cast<cpc_expansion_slot_device *>(owner()); m_slot = dynamic_cast<cpc_expansion_slot_device *>(owner());
address_space &space = m_slot->cpu().space(AS_IO); address_space &space = m_slot->cpu().space(AS_IO);
space.install_readwrite_handler(0xf880,0xf883, read8_delegate(*this, FUNC(cpc_playcity_device::ctc_r)), write8_delegate(*this, FUNC(cpc_playcity_device::ctc_w))); space.install_readwrite_handler(0xf880,0xf883, read8sm_delegate(*this, FUNC(cpc_playcity_device::ctc_r)), write8sm_delegate(*this, FUNC(cpc_playcity_device::ctc_w)));
space.install_readwrite_handler(0xf884,0xf884, read8_delegate(*this, FUNC(cpc_playcity_device::ymz1_data_r)), write8_delegate(*this, FUNC(cpc_playcity_device::ymz1_data_w))); space.install_readwrite_handler(0xf884,0xf884, read8smo_delegate(*this, FUNC(cpc_playcity_device::ymz1_data_r)), write8smo_delegate(*this, FUNC(cpc_playcity_device::ymz1_data_w)));
space.install_readwrite_handler(0xf888,0xf888, read8_delegate(*this, FUNC(cpc_playcity_device::ymz2_data_r)), write8_delegate(*this, FUNC(cpc_playcity_device::ymz2_data_w))); space.install_readwrite_handler(0xf888,0xf888, read8smo_delegate(*this, FUNC(cpc_playcity_device::ymz2_data_r)), write8smo_delegate(*this, FUNC(cpc_playcity_device::ymz2_data_w)));
space.install_write_handler(0xf984,0xf984, write8_delegate(*this, FUNC(cpc_playcity_device::ymz1_address_w))); space.install_write_handler(0xf984,0xf984, write8smo_delegate(*this, FUNC(cpc_playcity_device::ymz1_address_w)));
space.install_write_handler(0xf988,0xf988, write8_delegate(*this, FUNC(cpc_playcity_device::ymz2_address_w))); space.install_write_handler(0xf988,0xf988, write8smo_delegate(*this, FUNC(cpc_playcity_device::ymz2_address_w)));
} }
//------------------------------------------------- //-------------------------------------------------
@ -85,44 +85,44 @@ void cpc_playcity_device::device_reset()
} }
READ8_MEMBER(cpc_playcity_device::ctc_r) uint8_t cpc_playcity_device::ctc_r(offs_t offset)
{ {
return m_ctc->read(offset); return m_ctc->read(offset);
} }
WRITE8_MEMBER(cpc_playcity_device::ctc_w) void cpc_playcity_device::ctc_w(offs_t offset, uint8_t data)
{ {
m_ctc->write(offset,data); m_ctc->write(offset,data);
if(offset == 0) if(offset == 0)
update_ymz_clock(); update_ymz_clock();
} }
WRITE8_MEMBER(cpc_playcity_device::ymz1_address_w) void cpc_playcity_device::ymz1_address_w(uint8_t data)
{ {
m_ymz1->address_w(data); m_ymz1->address_w(data);
} }
WRITE8_MEMBER(cpc_playcity_device::ymz2_address_w) void cpc_playcity_device::ymz2_address_w(uint8_t data)
{ {
m_ymz2->address_w(data); m_ymz2->address_w(data);
} }
WRITE8_MEMBER(cpc_playcity_device::ymz1_data_w) void cpc_playcity_device::ymz1_data_w(uint8_t data)
{ {
m_ymz1->data_w(data); m_ymz1->data_w(data);
} }
WRITE8_MEMBER(cpc_playcity_device::ymz2_data_w) void cpc_playcity_device::ymz2_data_w(uint8_t data)
{ {
m_ymz2->data_w(data); m_ymz2->data_w(data);
} }
READ8_MEMBER(cpc_playcity_device::ymz1_data_r) uint8_t cpc_playcity_device::ymz1_data_r()
{ {
return m_ymz1->data_r(); return m_ymz1->data_r();
} }
READ8_MEMBER(cpc_playcity_device::ymz2_data_r) uint8_t cpc_playcity_device::ymz2_data_r()
{ {
return m_ymz2->data_r(); return m_ymz2->data_r();
} }

View File

@ -30,14 +30,14 @@ public:
// construction/destruction // construction/destruction
cpc_playcity_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); cpc_playcity_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
DECLARE_READ8_MEMBER(ctc_r); uint8_t ctc_r(offs_t offset);
DECLARE_WRITE8_MEMBER(ctc_w); void ctc_w(offs_t offset, uint8_t data);
DECLARE_WRITE8_MEMBER(ymz1_address_w); void ymz1_address_w(uint8_t data);
DECLARE_WRITE8_MEMBER(ymz2_address_w); void ymz2_address_w(uint8_t data);
DECLARE_WRITE8_MEMBER(ymz1_data_w); void ymz1_data_w(uint8_t data);
DECLARE_WRITE8_MEMBER(ymz2_data_w); void ymz2_data_w(uint8_t data);
DECLARE_READ8_MEMBER(ymz1_data_r); uint8_t ymz1_data_r();
DECLARE_READ8_MEMBER(ymz2_data_r); uint8_t ymz2_data_r();
virtual WRITE_LINE_MEMBER(cursor_w) override { m_ctc->trg1(state); } virtual WRITE_LINE_MEMBER(cursor_w) override { m_ctc->trg1(state); }

View File

@ -63,12 +63,12 @@ void cpc_smartwatch_device::device_start()
void cpc_smartwatch_device::device_reset() void cpc_smartwatch_device::device_reset()
{ {
address_space &space = m_slot->cpu().space(AS_PROGRAM); address_space &space = m_slot->cpu().space(AS_PROGRAM);
space.install_read_handler(0xc000,0xc001, read8_delegate(*this, FUNC(cpc_smartwatch_device::rtc_w))); space.install_read_handler(0xc000,0xc001, read8sm_delegate(*this, FUNC(cpc_smartwatch_device::rtc_w)));
space.install_read_handler(0xc004,0xc004, read8_delegate(*this, FUNC(cpc_smartwatch_device::rtc_r))); space.install_read_handler(0xc004,0xc004, read8smo_delegate(*this, FUNC(cpc_smartwatch_device::rtc_r)));
m_bank = membank(":bank7"); m_bank = membank(":bank7");
} }
READ8_MEMBER(cpc_smartwatch_device::rtc_w) uint8_t cpc_smartwatch_device::rtc_w(offs_t offset)
{ {
uint8_t* bank = (uint8_t*)m_bank->base(); uint8_t* bank = (uint8_t*)m_bank->base();
if (!machine().side_effects_disabled()) if (!machine().side_effects_disabled())
@ -81,8 +81,8 @@ READ8_MEMBER(cpc_smartwatch_device::rtc_w)
return bank[offset & 1]; return bank[offset & 1];
} }
READ8_MEMBER(cpc_smartwatch_device::rtc_r) uint8_t cpc_smartwatch_device::rtc_r()
{ {
uint8_t* bank = (uint8_t*)m_bank->base(); uint8_t* bank = (uint8_t*)m_bank->base();
return ((bank[(offset & 1)+4]) & 0xfe) | (m_rtc->read_data() & 0x01); return (bank[4] & 0xfe) | (m_rtc->read_data() & 0x01);
} }

View File

@ -23,8 +23,8 @@ public:
// construction/destruction // construction/destruction
cpc_smartwatch_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); cpc_smartwatch_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
DECLARE_READ8_MEMBER(rtc_w); uint8_t rtc_w(offs_t offset);
DECLARE_READ8_MEMBER(rtc_r); uint8_t rtc_r();
protected: protected:
// device-level overrides // device-level overrides

View File

@ -90,11 +90,11 @@ void cpc_symbiface2_device::device_start()
{ {
m_slot = dynamic_cast<cpc_expansion_slot_device *>(owner()); m_slot = dynamic_cast<cpc_expansion_slot_device *>(owner());
address_space &space = m_slot->cpu().space(AS_IO); address_space &space = m_slot->cpu().space(AS_IO);
space.install_readwrite_handler(0xfd00,0xfd07, read8_delegate(*this, FUNC(cpc_symbiface2_device::ide_cs1_r)), write8_delegate(*this, FUNC(cpc_symbiface2_device::ide_cs1_w))); space.install_readwrite_handler(0xfd00,0xfd07, read8sm_delegate(*this, FUNC(cpc_symbiface2_device::ide_cs1_r)), write8sm_delegate(*this, FUNC(cpc_symbiface2_device::ide_cs1_w)));
space.install_readwrite_handler(0xfd08,0xfd0f, read8_delegate(*this, FUNC(cpc_symbiface2_device::ide_cs0_r)), write8_delegate(*this, FUNC(cpc_symbiface2_device::ide_cs0_w))); space.install_readwrite_handler(0xfd08,0xfd0f, read8sm_delegate(*this, FUNC(cpc_symbiface2_device::ide_cs0_r)), write8sm_delegate(*this, FUNC(cpc_symbiface2_device::ide_cs0_w)));
space.install_read_handler(0xfd10,0xfd10, read8_delegate(*this, FUNC(cpc_symbiface2_device::mouse_r))); space.install_read_handler(0xfd10,0xfd10, read8smo_delegate(*this, FUNC(cpc_symbiface2_device::mouse_r)));
space.install_readwrite_handler(0xfd14,0xfd15, read8_delegate(*this, FUNC(cpc_symbiface2_device::rtc_r)), write8_delegate(*this, FUNC(cpc_symbiface2_device::rtc_w))); space.install_readwrite_handler(0xfd14,0xfd15, read8sm_delegate(*this, FUNC(cpc_symbiface2_device::rtc_r)), write8sm_delegate(*this, FUNC(cpc_symbiface2_device::rtc_w)));
space.install_readwrite_handler(0xfd17,0xfd17, read8_delegate(*this, FUNC(cpc_symbiface2_device::rom_rewrite_r)), write8_delegate(*this, FUNC(cpc_symbiface2_device::rom_rewrite_w))); space.install_readwrite_handler(0xfd17,0xfd17, read8smo_delegate(*this, FUNC(cpc_symbiface2_device::rom_rewrite_r)), write8smo_delegate(*this, FUNC(cpc_symbiface2_device::rom_rewrite_w)));
// set up ROM space (these can be writable, when mapped to &4000, or completely disabled, allowing the built-in ROMs to be visible) // set up ROM space (these can be writable, when mapped to &4000, or completely disabled, allowing the built-in ROMs to be visible)
// 32 banks of 16kB (512kB) // 32 banks of 16kB (512kB)
@ -120,7 +120,7 @@ void cpc_symbiface2_device::device_reset()
// IDE controller (custom) // IDE controller (custom)
// #FD00-07 - CS1 // #FD00-07 - CS1
// #FD08-0F - CS0 // #FD08-0F - CS0
READ8_MEMBER(cpc_symbiface2_device::ide_cs0_r) uint8_t cpc_symbiface2_device::ide_cs0_r(offs_t offset)
{ {
// data is returned in words, so it must be buffered // data is returned in words, so it must be buffered
if(offset == 0x00) // data register if(offset == 0x00) // data register
@ -141,17 +141,17 @@ READ8_MEMBER(cpc_symbiface2_device::ide_cs0_r)
return m_ide->cs0_r(offset); return m_ide->cs0_r(offset);
} }
WRITE8_MEMBER(cpc_symbiface2_device::ide_cs0_w) void cpc_symbiface2_device::ide_cs0_w(offs_t offset, uint8_t data)
{ {
m_ide->cs0_w(offset, data); m_ide->cs0_w(offset, data);
} }
READ8_MEMBER(cpc_symbiface2_device::ide_cs1_r) uint8_t cpc_symbiface2_device::ide_cs1_r(offs_t offset)
{ {
return m_ide->cs1_r(offset); return m_ide->cs1_r(offset);
} }
WRITE8_MEMBER(cpc_symbiface2_device::ide_cs1_w) void cpc_symbiface2_device::ide_cs1_w(offs_t offset, uint8_t data)
{ {
m_ide->cs1_w(offset, data); m_ide->cs1_w(offset, data);
} }
@ -159,12 +159,12 @@ WRITE8_MEMBER(cpc_symbiface2_device::ide_cs1_w)
// RTC (Dallas DS1287A) // RTC (Dallas DS1287A)
// #FD15 (write only) register select // #FD15 (write only) register select
// #FD14 (read/write) read from or write into selected register // #FD14 (read/write) read from or write into selected register
READ8_MEMBER(cpc_symbiface2_device::rtc_r) uint8_t cpc_symbiface2_device::rtc_r(offs_t offset)
{ {
return m_rtc->read(~offset & 0x01); return m_rtc->read(~offset & 0x01);
} }
WRITE8_MEMBER(cpc_symbiface2_device::rtc_w) void cpc_symbiface2_device::rtc_w(offs_t offset, uint8_t data)
{ {
m_rtc->write(~offset & 0x01, data); m_rtc->write(~offset & 0x01, data);
} }
@ -193,7 +193,7 @@ WRITE8_MEMBER(cpc_symbiface2_device::rtc_w)
D[bit4] = backward button D[bit4] = backward button
D[bit5] = 1 -> D[bit0-4] = scroll wheel offset (signed) D[bit5] = 1 -> D[bit0-4] = scroll wheel offset (signed)
*/ */
READ8_MEMBER(cpc_symbiface2_device::mouse_r) uint8_t cpc_symbiface2_device::mouse_r()
{ {
uint8_t ret = 0; uint8_t ret = 0;
int input; int input;
@ -247,11 +247,11 @@ INPUT_CHANGED_MEMBER(cpc_symbiface2_device::mouse_change_buttons)
} }
// #FD17 (read) - map currently selected ROM to 0x4000 for read/write // #FD17 (read) - map currently selected ROM to 0x4000 for read/write
READ8_MEMBER(cpc_symbiface2_device::rom_rewrite_r) uint8_t cpc_symbiface2_device::rom_rewrite_r()
{ {
uint8_t bank = get_rom_bank(); uint8_t bank = get_rom_bank();
if(bank >= 32) if(bank >= 32 || machine().side_effects_disabled())
return 0xff; return 0xff;
m_4xxx_ptr_r = (uint8_t*)machine().root_device().membank("bank3")->base(); m_4xxx_ptr_r = (uint8_t*)machine().root_device().membank("bank3")->base();
@ -267,7 +267,7 @@ READ8_MEMBER(cpc_symbiface2_device::rom_rewrite_r)
} }
// #FD17 (write) - unmap selected ROM at 0x4000 // #FD17 (write) - unmap selected ROM at 0x4000
WRITE8_MEMBER(cpc_symbiface2_device::rom_rewrite_w) void cpc_symbiface2_device::rom_rewrite_w(uint8_t data)
{ {
machine().root_device().membank("bank3")->set_base(m_4xxx_ptr_r); machine().root_device().membank("bank3")->set_base(m_4xxx_ptr_r);
machine().root_device().membank("bank4")->set_base(m_6xxx_ptr_r); machine().root_device().membank("bank4")->set_base(m_6xxx_ptr_r);

View File

@ -23,15 +23,15 @@ public:
// construction/destruction // construction/destruction
cpc_symbiface2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); cpc_symbiface2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
DECLARE_READ8_MEMBER(ide_cs0_r); uint8_t ide_cs0_r(offs_t offset);
DECLARE_WRITE8_MEMBER(ide_cs0_w); void ide_cs0_w(offs_t offset, uint8_t data);
DECLARE_READ8_MEMBER(ide_cs1_r); uint8_t ide_cs1_r(offs_t offset);
DECLARE_WRITE8_MEMBER(ide_cs1_w); void ide_cs1_w(offs_t offset, uint8_t data);
DECLARE_READ8_MEMBER(rtc_r); uint8_t rtc_r(offs_t offset);
DECLARE_WRITE8_MEMBER(rtc_w); void rtc_w(offs_t offset, uint8_t data);
DECLARE_READ8_MEMBER(mouse_r); uint8_t mouse_r();
DECLARE_READ8_MEMBER(rom_rewrite_r); uint8_t rom_rewrite_r();
DECLARE_WRITE8_MEMBER(rom_rewrite_w); void rom_rewrite_w(uint8_t data);
DECLARE_INPUT_CHANGED_MEMBER(mouse_change_x); DECLARE_INPUT_CHANGED_MEMBER(mouse_change_x);
DECLARE_INPUT_CHANGED_MEMBER(mouse_change_y); DECLARE_INPUT_CHANGED_MEMBER(mouse_change_y);
DECLARE_INPUT_CHANGED_MEMBER(mouse_change_buttons); DECLARE_INPUT_CHANGED_MEMBER(mouse_change_buttons);

View File

@ -63,8 +63,8 @@ void cpc_transtape_device::device_start()
m_ram = make_unique_clear<uint8_t[]>(0x2000); m_ram = make_unique_clear<uint8_t[]>(0x2000);
m_space->install_write_handler(0xfbf0,0xfbf0, write8_delegate(*this, FUNC(cpc_transtape_device::output_w))); m_space->install_write_handler(0xfbf0,0xfbf0, write8smo_delegate(*this, FUNC(cpc_transtape_device::output_w)));
m_space->install_read_handler(0xfbff,0xfbff, read8_delegate(*this, FUNC(cpc_transtape_device::input_r))); m_space->install_read_handler(0xfbff,0xfbff, read8smo_delegate(*this, FUNC(cpc_transtape_device::input_r)));
} }
//------------------------------------------------- //-------------------------------------------------
@ -117,17 +117,17 @@ INPUT_CHANGED_MEMBER(cpc_transtape_device::button_black_w)
} }
} }
READ8_MEMBER(cpc_transtape_device::input_r) uint8_t cpc_transtape_device::input_r()
{ {
// TODO // TODO
return 0x80; return 0x80;
} }
WRITE8_MEMBER(cpc_transtape_device::output_w) void cpc_transtape_device::output_w(uint8_t data)
{ {
// TODO // TODO
m_output = data; m_output = data;
m_slot->rom_select(space,0,get_rom_bank()); // trigger rethink m_slot->rom_select(get_rom_bank()); // trigger rethink
} }
void cpc_transtape_device::set_mapping(uint8_t type) void cpc_transtape_device::set_mapping(uint8_t type)

View File

@ -28,8 +28,8 @@ public:
virtual void set_mapping(uint8_t type) override; virtual void set_mapping(uint8_t type) override;
virtual WRITE_LINE_MEMBER( romen_w ) override { m_romen = state; } virtual WRITE_LINE_MEMBER( romen_w ) override { m_romen = state; }
DECLARE_READ8_MEMBER(input_r); uint8_t input_r();
DECLARE_WRITE8_MEMBER(output_w); void output_w(uint8_t data);
DECLARE_INPUT_CHANGED_MEMBER(button_red_w); DECLARE_INPUT_CHANGED_MEMBER(button_red_w);
DECLARE_INPUT_CHANGED_MEMBER(button_black_w); DECLARE_INPUT_CHANGED_MEMBER(button_black_w);