src/devices: some more MCFG macros removal (nw)

This commit is contained in:
Ivan Vangelista 2019-01-11 18:13:29 +01:00
parent 8b06f277f0
commit dc7008ac9e
43 changed files with 143 additions and 313 deletions

View File

@ -75,10 +75,11 @@ void dmv_k803_device::device_reset()
// device_add_mconfig - add device configuration
//-------------------------------------------------
MACHINE_CONFIG_START(dmv_k803_device::device_add_mconfig)
MCFG_DEVICE_ADD("rtc", MM58167, XTAL(32'768))
MCFG_MM58167_IRQ_CALLBACK(WRITELINE(*this, dmv_k803_device, rtc_irq_w))
MACHINE_CONFIG_END
void dmv_k803_device::device_add_mconfig(machine_config &config)
{
MM58167(config, m_rtc, XTAL(32'768));
m_rtc->irq().set(FUNC(dmv_k803_device::rtc_irq_w));
}
//-------------------------------------------------
// input_ports - device-specific input ports

View File

@ -15,8 +15,6 @@
#include "imagedev/flopdrv.h"
#define MCFG_MC6843_IRQ_CALLBACK(_write) \
downcast<mc6843_device &>(*device).set_irq_wr_callback(DEVCB_##_write);
class mc6843_device : public device_t
{

View File

@ -31,30 +31,6 @@
#include <queue>
//**************************************************************************
// INTERFACE CONFIGURATION MACROS
//**************************************************************************
#define MCFG_MC6852_RX_CLOCK(_clock) \
downcast<mc6852_device &>(*device).set_rx_clock(_clock);
#define MCFG_MC6852_TX_CLOCK(_clock) \
downcast<mc6852_device &>(*device).set_tx_clock(_clock);
#define MCFG_MC6852_TX_DATA_CALLBACK(_write) \
downcast<mc6852_device &>(*device).set_tx_data_wr_callback(DEVCB_##_write);
#define MCFG_MC6852_IRQ_CALLBACK(_write) \
downcast<mc6852_device &>(*device).set_irq_wr_callback(DEVCB_##_write);
#define MCFG_MC6852_SM_DTR_CALLBACK(_write) \
downcast<mc6852_device &>(*device).set_sm_dtr_wr_callback(DEVCB_##_write);
#define MCFG_MC6852_TUF_CALLBACK(_write) \
downcast<mc6852_device &>(*device).set_tuf_wr_callback(DEVCB_##_write);
//**************************************************************************
// TYPE DEFINITIONS
//**************************************************************************
@ -70,10 +46,6 @@ public:
void set_rx_clock(int clock) { m_rx_clock = clock; }
void set_tx_clock(int clock) { m_tx_clock = clock; }
template <class Object> devcb_base &set_tx_data_wr_callback(Object &&cb) { return m_write_tx_data.set_callback(std::forward<Object>(cb)); }
template <class Object> devcb_base &set_irq_wr_callback(Object &&cb) { return m_write_irq.set_callback(std::forward<Object>(cb)); }
template <class Object> devcb_base &set_sm_dtr_wr_callback(Object &&cb) { return m_write_sm_dtr.set_callback(std::forward<Object>(cb)); }
template <class Object> devcb_base &set_tuf_wr_callback(Object &&cb) { return m_write_tuf.set_callback(std::forward<Object>(cb)); }
auto tx_data_callback() { return m_write_tx_data.bind(); }
auto irq_callback() { return m_write_irq.bind(); }

View File

@ -25,22 +25,6 @@
#include "dirtc.h"
//**************************************************************************
// INTERFACE CONFIGURATION MACROS
//**************************************************************************
#define MCFG_MCCS1850_INT_CALLBACK(_write) \
downcast<mccs1850_device &>(*device).set_int_wr_callback(DEVCB_##_write);
#define MCFG_MCCS1850_PSE_CALLBACK(_write) \
downcast<mccs1850_device &>(*device).set_pse_wr_callback(DEVCB_##_write);
#define MCFG_MCCS1850_NUC_CALLBACK(_write) \
downcast<mccs1850_device &>(*device).set_nuc_wr_callback(DEVCB_##_write);
//**************************************************************************
// TYPE DEFINITIONS
//**************************************************************************
@ -55,9 +39,9 @@ public:
// construction/destruction
mccs1850_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
template <class Object> devcb_base &set_int_wr_callback(Object &&cb) { return int_cb.set_callback(std::forward<Object>(cb)); }
template <class Object> devcb_base &set_pse_wr_callback(Object &&cb) { return pse_cb.set_callback(std::forward<Object>(cb)); }
template <class Object> devcb_base &set_nuc_wr_callback(Object &&cb) { return nuc_cb.set_callback(std::forward<Object>(cb)); }
auto int_wr_callback() { return int_cb.bind(); }
auto pse_wr_callback() { return pse_cb.bind(); }
auto nuc_wr_callback() { return nuc_cb.bind(); }
DECLARE_WRITE_LINE_MEMBER( ce_w );
DECLARE_WRITE_LINE_MEMBER( sck_w );

View File

@ -12,15 +12,6 @@
#pragma once
/***************************************************************************
DEVICE CONFIGURATION MACROS
***************************************************************************/
#define MCFG_MCF5206E_PERIPHERAL_ADD(_tag) \
MCFG_DEVICE_ADD(_tag, MCF5206E_PERIPHERAL, 0)
/***************************************************************************
TYPE DEFINITIONS
***************************************************************************/

View File

@ -14,14 +14,6 @@
#include "dirtc.h"
//**************************************************************************
// INTERFACE CONFIGURATION MACROS
//**************************************************************************
#define MCFG_MM58167_IRQ_CALLBACK(_cb) \
downcast<mm58167_device &>(*device).set_irq_cb(DEVCB_##_cb);
//**************************************************************************
// TYPE DEFINITIONS
//**************************************************************************
@ -38,7 +30,6 @@ public:
DECLARE_READ8_MEMBER(read);
DECLARE_WRITE8_MEMBER(write);
template <class Object> devcb_base &set_irq_cb(Object &&wr) { return m_irq_w.set_callback(std::forward<Object>(wr)); }
auto irq() { return m_irq_w.bind(); }
devcb_write_line m_irq_w;

View File

@ -16,16 +16,30 @@ class nsc810_device : public device_t
{
public:
// construction/destruction
nsc810_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, uint32_t clk0, uint32_t clk1)
: nsc810_device(mconfig, tag, owner, clock)
{
set_timer0_clock(clk0);
set_timer1_clock(clk1);
}
nsc810_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, const XTAL &clk0, const XTAL &clk1)
: nsc810_device(mconfig, tag, owner, clock)
{
set_timer0_clock(clk0.value());
set_timer1_clock(clk1.value());
}
nsc810_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
template <class Object> devcb_base &set_portA_read_callback(Object &&cb) { return m_portA_r.set_callback(std::forward<Object>(cb)); }
template <class Object> devcb_base &set_portB_read_callback(Object &&cb) { return m_portB_r.set_callback(std::forward<Object>(cb)); }
template <class Object> devcb_base &set_portC_read_callback(Object &&cb) { return m_portC_r.set_callback(std::forward<Object>(cb)); }
template <class Object> devcb_base &set_portA_write_callback(Object &&cb) { return m_portA_w.set_callback(std::forward<Object>(cb)); }
template <class Object> devcb_base &set_portB_write_callback(Object &&cb) { return m_portB_w.set_callback(std::forward<Object>(cb)); }
template <class Object> devcb_base &set_portC_write_callback(Object &&cb) { return m_portC_w.set_callback(std::forward<Object>(cb)); }
template <class Object> devcb_base &set_timer0_callback(Object &&cb) { return m_timer0_out.set_callback(std::forward<Object>(cb)); }
template <class Object> devcb_base &set_timer1_callback(Object &&cb) { return m_timer1_out.set_callback(std::forward<Object>(cb)); }
auto portA_read_callback() { return m_portA_r.bind(); }
auto portB_read_callback() { return m_portB_r.bind(); }
auto portC_read_callback() { return m_portC_r.bind(); }
auto portA_write_callback() { return m_portA_w.bind(); }
auto portB_write_callback() { return m_portB_w.bind(); }
auto portC_write_callback() { return m_portC_w.bind(); }
auto timer0_callback() { return m_timer0_out.bind(); }
auto timer1_callback() { return m_timer1_out.bind(); }
void set_timer0_clock(uint32_t clk) { m_timer0_clock = clk; }
void set_timer0_clock(const XTAL &clk) { set_timer0_clock(clk.value()); }

View File

@ -12,19 +12,6 @@
#pragma once
///*************************************************************************
// INTERFACE CONFIGURATION MACROS
///*************************************************************************
#define MCFG_HD44102_ADD(_tag, _screen_tag, _sx, _sy) \
MCFG_DEVICE_ADD(_tag, HD44102, 0) \
MCFG_VIDEO_SET_SCREEN(_screen_tag) \
downcast<hd44102_device &>(*device).set_offsets(_sx, _sy);
///*************************************************************************
// TYPE DEFINITIONS
///*************************************************************************

View File

@ -44,26 +44,6 @@
#define I8275_DRAW_CHARACTER_MEMBER(_name) void _name(bitmap_rgb32 &bitmap, int x, int y, uint8_t linecount, uint8_t charcode, uint8_t lineattr, uint8_t lten, uint8_t rvv, uint8_t vsp, uint8_t gpa, uint8_t hlgt)
#define MCFG_I8275_CHARACTER_WIDTH(_value) \
downcast<i8275_device &>(*device).set_character_width(_value);
#define MCFG_I8275_DRAW_CHARACTER_CALLBACK_OWNER(_class, _method) \
downcast<i8275_device &>(*device).set_display_callback(&_class::_method, #_class "::" #_method, this);
#define MCFG_I8275_DRQ_CALLBACK(_write) \
downcast<i8275_device &>(*device).set_drq_wr_callback(DEVCB_##_write);
#define MCFG_I8275_IRQ_CALLBACK(_write) \
downcast<i8275_device &>(*device).set_irq_wr_callback(DEVCB_##_write);
#define MCFG_I8275_HRTC_CALLBACK(_write) \
downcast<i8275_device &>(*device).set_hrtc_wr_callback(DEVCB_##_write);
#define MCFG_I8275_VRTC_CALLBACK(_write) \
downcast<i8275_device &>(*device).set_vrtc_wr_callback(DEVCB_##_write);
//**************************************************************************
// TYPE DEFINITIONS
//**************************************************************************
@ -96,10 +76,6 @@ public:
set_display_callback(draw_character_delegate(callback, name, nullptr, static_cast<FunctionClass *>(nullptr)));
}
template <class Object> devcb_base &set_drq_wr_callback(Object &&cb) { return m_write_drq.set_callback(std::forward<Object>(cb)); }
template <class Object> devcb_base &set_irq_wr_callback(Object &&cb) { return m_write_irq.set_callback(std::forward<Object>(cb)); }
template <class Object> devcb_base &set_hrtc_wr_callback(Object &&cb) { return m_write_hrtc.set_callback(std::forward<Object>(cb)); }
template <class Object> devcb_base &set_vrtc_wr_callback(Object &&cb) { return m_write_vrtc.set_callback(std::forward<Object>(cb)); }
auto drq_wr_callback() { return m_write_drq.bind(); }
auto irq_wr_callback() { return m_write_irq.bind(); }
auto hrtc_wr_callback() { return m_write_hrtc.bind(); }

View File

@ -26,21 +26,6 @@
#pragma once
//**************************************************************************
// INTERFACE CONFIGURATION MACROS
//**************************************************************************
#define MCFG_MB88303_VOW_CALLBACK(_write) \
downcast<mb88303_device &>(*device).set_vow_callback(DEVCB_##_write);
#define MCFG_MB88303_VOBN_CALLBACK(_write) \
downcast<mb88303_device &>(*device).set_vob_n_callback(DEVCB_##_write);
#define MCFG_MB88303_DO_CALLBACK(_write) \
downcast<mb88303_device &>(*device).set_do_callback(DEVCB_##_write);
//**************************************************************************
// TYPE DEFINITIONS
//**************************************************************************
@ -56,9 +41,9 @@ public:
// construction/destruction
mb88303_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
template <class Object> devcb_base &set_vow_callback(Object &&cb) { return m_write_vow.set_callback(std::forward<Object>(cb)); }
template <class Object> devcb_base &set_vobn_callback(Object &&cb) { return m_write_vobn.set_callback(std::forward<Object>(cb)); }
template <class Object> devcb_base &set_do_callback(Object &&cb) { return m_write_do.set_callback(std::forward<Object>(cb)); }
auto vow_callback() { return m_write_vow.bind(); }
auto vobn_callback() { return m_write_vobn.bind(); }
auto do_callback() { return m_write_do.bind(); }
DECLARE_WRITE8_MEMBER(da_w);
DECLARE_WRITE_LINE_MEMBER(adm_w);

View File

@ -15,11 +15,6 @@
#pragma once
#define MCFG_MSM6222B_ADD( _tag ) \
MCFG_DEVICE_ADD( _tag, MSM6222B, 0 )
#define MCFG_MSM6222B_01_ADD( _tag ) \
MCFG_DEVICE_ADD( _tag, MSM6222B_01, 0 )
class msm6222b_device : public device_t {
public:

View File

@ -29,21 +29,6 @@
#pragma once
//**************************************************************************
// INTERFACE CONFIGURATION MACROS
//**************************************************************************
#define MCFG_SAA5050_D_CALLBACK(_read) \
downcast<saa5050_device &>(*device).set_d_rd_callback(DEVCB_##_read);
#define MCFG_SAA5050_SCREEN_SIZE(_cols, _rows, _size) \
downcast<saa5050_device &>(*device).set_screen_size(_cols, _rows, _size);
//**************************************************************************
// TYPE DEFINITIONS
//**************************************************************************
@ -58,7 +43,6 @@ public:
void set_screen_size(int cols, int rows, int size) { m_cols = cols; m_rows = rows; m_size = size; }
template <class Object> devcb_base &set_d_rd_callback(Object &&cb) { return m_read_d.set_callback(std::forward<Object>(cb)); }
auto d_cb() { return m_read_d.bind(); }
// optional information overrides

View File

@ -17,17 +17,6 @@
#pragma once
#define MCFG_SED1200D0A_ADD( _tag ) \
MCFG_DEVICE_ADD( _tag, SED1200D0A, 0 )
#define MCFG_SED1200F0A_ADD( _tag ) \
MCFG_DEVICE_ADD( _tag, SED1200F0A, 0 )
#define MCFG_SED1200D0B_ADD( _tag ) \
MCFG_DEVICE_ADD( _tag, SED1200D0B, 0 )
#define MCFG_SED1200F0B_ADD( _tag ) \
MCFG_DEVICE_ADD( _tag, SED1200F0B, 0 )
class sed1200_device : public device_t {
public:

View File

@ -65,7 +65,4 @@ private:
// device type definition
DECLARE_DEVICE_TYPE(T6A04, t6a04_device)
#define MCFG_T6A04_SIZE(_width, _height) \
downcast<t6a04_device &>(*device).set_size(_width, _height);
#endif // MAME_VIDEO_T6A04_H

View File

@ -25,15 +25,6 @@
#pragma once
//**************************************************************************
// INTERFACE CONFIGURATION MACROS
//**************************************************************************
#define MCFG_TEA1002_ADD(_tag, _clock) \
MCFG_DEVICE_ADD(_tag, TEA1002, _clock)
//**************************************************************************
// TYPE DEFINITIONS
//**************************************************************************

View File

@ -43,26 +43,6 @@
#define UPD3301_DRAW_CHARACTER_MEMBER(_name) void _name(bitmap_rgb32 &bitmap, int y, int sx, uint8_t cc, uint8_t lc, int hlgt, int rvv, int vsp, int sl0, int sl12, int csr, int gpa)
#define MCFG_UPD3301_CHARACTER_WIDTH(_value) \
downcast<upd3301_device &>(*device).set_character_width(_value);
#define MCFG_UPD3301_DRAW_CHARACTER_CALLBACK_OWNER(_class, _method) \
downcast<upd3301_device &>(*device).set_display_callback(&_class::_method, #_class "::" #_method, this);
#define MCFG_UPD3301_DRQ_CALLBACK(_write) \
downcast<upd3301_device &>(*device).set_drq_wr_callback(DEVCB_##_write);
#define MCFG_UPD3301_INT_CALLBACK(_write) \
downcast<upd3301_device &>(*device).set_int_wr_callback(DEVCB_##_write);
#define MCFG_UPD3301_HRTC_CALLBACK(_write) \
downcast<upd3301_device &>(*device).set_hrtc_wr_callback(DEVCB_##_write);
#define MCFG_UPD3301_VRTC_CALLBACK(_write) \
downcast<upd3301_device &>(*device).set_vrtc_wr_callback(DEVCB_##_write);
//**************************************************************************
// TYPE DEFINITIONS
//**************************************************************************
@ -93,10 +73,6 @@ public:
set_display_callback(draw_character_delegate(callback, name, nullptr, static_cast<FunctionClass *>(nullptr)));
}
template <class Object> devcb_base &set_drq_wr_callback(Object &&cb) { return m_write_drq.set_callback(std::forward<Object>(cb)); }
template <class Object> devcb_base &set_int_wr_callback(Object &&cb) { return m_write_int.set_callback(std::forward<Object>(cb)); }
template <class Object> devcb_base &set_hrtc_wr_callback(Object &&cb) { return m_write_hrtc.set_callback(std::forward<Object>(cb)); }
template <class Object> devcb_base &set_vrtc_wr_callback(Object &&cb) { return m_write_vrtc.set_callback(std::forward<Object>(cb)); }
auto drq_wr_callback() { return m_write_drq.bind(); }
auto int_wr_callback() { return m_write_int.bind(); }
auto hrtc_wr_callback() { return m_write_hrtc.bind(); }

View File

@ -83,7 +83,7 @@ MACHINE_CONFIG_START(adder5_state::bfm_ad5)
MCFG_DEVICE_ADD("maincpu", MCF5206E, 40000000) /* MCF5206eFT */
MCFG_DEVICE_PROGRAM_MAP(ad5_map)
MCFG_DEVICE_PERIODIC_INT_DRIVER(adder5_state, ad5_fake_timer_int, 1000)
MCFG_MCF5206E_PERIPHERAL_ADD("maincpu_onboard")
MCF5206E_PERIPHERAL(config, "maincpu_onboard", 0);
SPEAKER(config, "lspeaker").front_left();
SPEAKER(config, "rspeaker").front_right();

View File

@ -213,7 +213,7 @@ WRITE8_MEMBER(bfm_sc5_state::bfm_sc5_duart_output_w)
MACHINE_CONFIG_START(bfm_sc5_state::bfm_sc5)
MCFG_DEVICE_ADD("maincpu", MCF5206E, 40000000) /* MCF5206eFT */
MCFG_DEVICE_PROGRAM_MAP(sc5_map)
MCFG_MCF5206E_PERIPHERAL_ADD("maincpu_onboard")
MCF5206E_PERIPHERAL(config, "maincpu_onboard", 0);
/* sound hardware */
SPEAKER(config, "mono").front_center();

View File

@ -458,17 +458,19 @@ void cgc7900_state::machine_reset()
MACHINE_DRIVER( cgc7900 )
-------------------------------------------------*/
MACHINE_CONFIG_START(cgc7900_state::cgc7900)
void cgc7900_state::cgc7900(machine_config &config)
{
/* basic machine hardware */
MCFG_DEVICE_ADD(M68000_TAG, M68000, XTAL(28'480'000)/4)
MCFG_DEVICE_PROGRAM_MAP(cgc7900_mem)
M68000(config, m_maincpu, XTAL(28'480'000)/4);
m_maincpu->set_addrmap(AS_PROGRAM, &cgc7900_state::cgc7900_mem);
i8035_device &kbmcu(I8035(config, I8035_TAG, 1000000));
kbmcu.set_addrmap(AS_PROGRAM, &cgc7900_state::keyboard_mem);
kbmcu.set_disable();
/* MCFG_DEVICE_ADD(AM2910_TAG, AM2910, XTAL(17'360'000))
MCFG_DEVICE_PROGRAM_MAP(omti10_mem)*/
// am2910_device &am2910(AM2910(config, AM2910_TAG, XTAL(17'360'000)));
// am2910.set_addrmap(AS_PROGRAM, &cgc7900_state::omti10_mem);
/* video hardware */
cgc7900_video(config);
@ -481,8 +483,8 @@ MACHINE_CONFIG_START(cgc7900_state::cgc7900)
generic_keyboard_device &keyboard(GENERIC_KEYBOARD(config, "keyboard", 0));
keyboard.set_keyboard_callback(FUNC(cgc7900_state::kbd_put));
MCFG_DEVICE_ADD(MM58167_TAG, MM58167, XTAL(32'768))
MCFG_MM58167_IRQ_CALLBACK(WRITELINE(*this, cgc7900_state, irq<0x0>))
mm58167_device &rtc(MM58167(config, MM58167_TAG, XTAL(32'768)));
rtc.irq().set(FUNC(cgc7900_state::irq<0x0>));
com8116_device &k1135a(COM8116(config, K1135A_TAG, XTAL(5'068'800)));
k1135a.fr_handler().set(m_i8251_0, FUNC(i8251_device::write_txc));
@ -511,7 +513,7 @@ MACHINE_CONFIG_START(cgc7900_state::cgc7900)
rs232_port_device &rs449(RS232_PORT(config, "rs449", default_rs232_devices, nullptr));
rs449.rxd_handler().set(m_i8251_1, FUNC(i8251_device::write_rxd));
rs449.dsr_handler().set(m_i8251_1, FUNC(i8251_device::write_dsr));
MACHINE_CONFIG_END
}
/***************************************************************************
ROMS

View File

@ -89,7 +89,7 @@ MACHINE_CONFIG_START(gaminator_state::gaminator)
MCFG_DEVICE_ADD("maincpu", MCF5206E, 40000000) /* definitely Coldfire, model / clock uncertain */
MCFG_DEVICE_PROGRAM_MAP(gaminator_map)
MCFG_DEVICE_VBLANK_INT_DRIVER("screen", gaminator_state, irq6_line_hold) // irq6 seems to be needed to get past the ROM checking
MCFG_MCF5206E_PERIPHERAL_ADD("maincpu_onboard")
MCF5206E_PERIPHERAL(config, "maincpu_onboard", 0);
MCFG_SCREEN_ADD("screen", RASTER)
MCFG_SCREEN_RAW_PARAMS(XTAL(25'174'800),900,0,640,526,0,480)

View File

@ -487,8 +487,8 @@ MACHINE_CONFIG_START(gimix_state::gimix)
MCFG_DEVICE_PROGRAM_MAP(gimix_mem)
/* rtc */
MCFG_DEVICE_ADD("rtc", MM58167, 32.768_kHz_XTAL)
MCFG_MM58167_IRQ_CALLBACK(WRITELINE(*this, gimix_state,irq_w))
mm58167_device &rtc(MM58167(config, "rtc", 32.768_kHz_XTAL));
rtc.irq().set(FUNC(gimix_state::irq_w));
/* timer */
ptm6840_device &ptm(PTM6840(config, "timer", 2'000'000)); // clock is a guess

View File

@ -1390,12 +1390,12 @@ MACHINE_CONFIG_START(hp64k_state::hp64k)
MCFG_TIMER_DRIVER_ADD_PERIODIC("linesync_timer", hp64k_state, hp64k_line_sync, attotime::from_hz(50))
// Clock = 25 MHz / 9 * (112/114)
MCFG_DEVICE_ADD("crtc", I8275, 2729045)
MCFG_VIDEO_SET_SCREEN("screen")
MCFG_I8275_CHARACTER_WIDTH(9)
MCFG_I8275_DRAW_CHARACTER_CALLBACK_OWNER(hp64k_state, crtc_display_pixels)
MCFG_I8275_DRQ_CALLBACK(WRITELINE(*this, hp64k_state, hp64k_crtc_drq_w))
MCFG_I8275_VRTC_CALLBACK(WRITELINE(*this, hp64k_state, hp64k_crtc_vrtc_w))
I8275(config, m_crtc, 2729045);
m_crtc->set_screen("screen");
m_crtc->set_character_width(9);
m_crtc->set_display_callback(FUNC(hp64k_state::crtc_display_pixels), this);
m_crtc->drq_wr_callback().set(FUNC(hp64k_state::hp64k_crtc_drq_w));
m_crtc->vrtc_wr_callback().set(FUNC(hp64k_state::hp64k_crtc_vrtc_w));
MCFG_SCREEN_ADD_MONOCHROME("screen", RASTER, rgb_t::green())
MCFG_SCREEN_UPDATE_DEVICE("crtc", i8275_device, screen_update)

View File

@ -751,9 +751,9 @@ MACHINE_CONFIG_START(hp_ipc_state::hp_ipc_base)
MCFG_SOFTWARE_LIST_ADD("flop_list","hp_ipc")
MCFG_DEVICE_ADD("rtc", MM58167, 32.768_kHz_XTAL)
MCFG_MM58167_IRQ_CALLBACK(WRITELINE(*this, hp_ipc_state, irq_1))
// MCFG_MM58167_STANDBY_IRQ_CALLBACK(WRITELINE(*this, hp_ipc_state, irq_6))
mm58167_device &rtc(MM58167(config, "rtc", 32.768_kHz_XTAL));
rtc.irq().set(FUNC(hp_ipc_state::irq_1));
// rtc.standby_irq().set(FUNC(hp_ipc_state::irq_6));
hp_hil_mlc_device &mlc(HP_HIL_MLC(config, "mlc", XTAL(15'920'000)/2));
mlc.int_callback().set(FUNC(hp_ipc_state::irq_2));

View File

@ -407,13 +407,13 @@ MACHINE_CONFIG_START(hunter2_state::hunter2)
MCFG_MM58274C_MODE24(0) // 12 hour
MCFG_MM58274C_DAY1(1) // monday
MCFG_NSC810_ADD("iotimer",XTAL(4'000'000),XTAL(4'000'000))
MCFG_NSC810_PORTA_READ(READ8(*this, hunter2_state,keyboard_r))
MCFG_NSC810_PORTB_READ(READ8(*this, hunter2_state,serial_dsr_r))
MCFG_NSC810_PORTB_WRITE(WRITE8(*this, hunter2_state,keyboard_w))
MCFG_NSC810_PORTC_READ(READ8(*this, hunter2_state,serial_rx_r))
MCFG_NSC810_TIMER0_OUT(WRITELINE(*this, hunter2_state,timer0_out))
MCFG_NSC810_TIMER1_OUT(WRITELINE(*this, hunter2_state,timer1_out))
nsc810_device &iotimer(NSC810(config, "iotimer", 0, XTAL(4'000'000), XTAL(4'000'000)));
iotimer.portA_read_callback().set(FUNC(hunter2_state::keyboard_r));
iotimer.portB_read_callback().set(FUNC(hunter2_state::serial_dsr_r));
iotimer.portB_write_callback().set(FUNC(hunter2_state::keyboard_w));
iotimer.portC_read_callback().set(FUNC(hunter2_state::serial_rx_r));
iotimer.timer0_callback().set(FUNC(hunter2_state::timer0_out));
iotimer.timer1_callback().set(FUNC(hunter2_state::timer1_out));
RS232_PORT(config, m_rs232, default_rs232_devices, nullptr);
m_rs232->cts_handler().set(FUNC(hunter2_state::cts_w));

View File

@ -150,9 +150,9 @@ MACHINE_CONFIG_START(ipds_state::ipds)
MCFG_DEVICE_ADD("gfxdecode", GFXDECODE, "palette", gfx_ipds)
PALETTE(config, m_palette, palette_device::MONOCHROME);
MCFG_DEVICE_ADD("i8275", I8275, XTAL(19'660'800) / 4)
MCFG_I8275_CHARACTER_WIDTH(6)
MCFG_I8275_DRAW_CHARACTER_CALLBACK_OWNER(ipds_state, crtc_display_pixels)
I8275(config, m_crtc, XTAL(19'660'800) / 4);
m_crtc->set_character_width(6);
m_crtc->set_display_callback(FUNC(ipds_state::crtc_display_pixels), this);
generic_keyboard_device &keyboard(GENERIC_KEYBOARD(config, "keyboard", 0));
keyboard.set_keyboard_callback(FUNC(ipds_state::kbd_put));

View File

@ -59,7 +59,7 @@ INPUT_PORTS_END
MACHINE_CONFIG_START(jpmsys7_state::jpmsys7)
MCFG_DEVICE_ADD("maincpu", MCF5206E, 40000000) // seems to be a Coldfire of some kind
MCFG_DEVICE_PROGRAM_MAP(jpmsys7_map)
MCFG_MCF5206E_PERIPHERAL_ADD("maincpu_onboard")
MCF5206E_PERIPHERAL(config, "maincpu_onboard", 0);
SPEAKER(config, "lspeaker").front_left();
SPEAKER(config, "rspeaker").front_right();

View File

@ -218,10 +218,10 @@ MACHINE_CONFIG_START(mikrosha_state::mikrosha)
I8255(config, m_ppi8255_2);
m_ppi8255_2->out_pb_callback().set(FUNC(radio86_state::mikrosha_8255_font_page_w));
MCFG_DEVICE_ADD("i8275", I8275, XTAL(16'000'000) / 12)
MCFG_I8275_CHARACTER_WIDTH(6)
MCFG_I8275_DRAW_CHARACTER_CALLBACK_OWNER(mikrosha_state, display_pixels)
MCFG_I8275_DRQ_CALLBACK(WRITELINE(m_dma8257,i8257_device, dreq2_w))
i8275_device &i8275(I8275(config, "i8275", XTAL(16'000'000) / 12));
i8275.set_character_width(6);
i8275.set_display_callback(FUNC(mikrosha_state::display_pixels), this);
i8275.drq_wr_callback().set(m_dma8257, FUNC(i8257_device::dreq2_w));
pit8253_device &pit8253(PIT8253(config, "pit8253", 0));
pit8253.set_clk<0>(0);

View File

@ -1016,7 +1016,7 @@ MACHINE_CONFIG_START(next_state::next_base)
// devices
MCFG_NSCSI_BUS_ADD("scsibus")
MCFG_DEVICE_ADD("rtc", MCCS1850, XTAL(32'768))
MCCS1850(config, rtc, XTAL(32'768));
SCC8530(config, scc, XTAL(25'000'000));
scc->intrq_callback().set(FUNC(next_state::scc_irq));

View File

@ -236,9 +236,9 @@ MACHINE_CONFIG_START(p2000t_state::p2000t)
MCFG_SCREEN_VISIBLE_AREA(0, 40 * 12 - 1, 0, 24 * 20 - 1)
MCFG_SCREEN_UPDATE_DEVICE("saa5050", saa5050_device, screen_update)
MCFG_DEVICE_ADD("saa5050", SAA5050, 6000000)
MCFG_SAA5050_D_CALLBACK(READ8(*this, p2000t_state, videoram_r))
MCFG_SAA5050_SCREEN_SIZE(40, 24, 80)
saa5050_device &saa5050(SAA5050(config, "saa5050", 6000000));
saa5050.d_cb().set(FUNC(p2000t_state::videoram_r));
saa5050.set_screen_size(40, 24, 80);
/* sound hardware */
SPEAKER(config, "mono").front_center();

View File

@ -498,22 +498,22 @@ MACHINE_CONFIG_START(pc8001_state::pc8001)
MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25)
/* devices */
MCFG_DEVICE_ADD(I8251_TAG, I8251, 0)
I8251(config, I8251_TAG, 0);
MCFG_DEVICE_ADD(I8255A_TAG, I8255A, 0)
I8255A(config, I8255A_TAG, 0);
I8257(config, m_dma, XTAL(4'000'000));
m_dma->out_hrq_cb().set(FUNC(pc8001_state::hrq_w));
m_dma->in_memr_cb().set(FUNC(pc8001_state::dma_mem_r));
m_dma->out_iow_cb<2>().set(UPD3301_TAG, FUNC(upd3301_device::dack_w));
m_dma->out_iow_cb<2>().set(m_crtc, FUNC(upd3301_device::dack_w));
UPD1990A(config, m_rtc);
MCFG_DEVICE_ADD(UPD3301_TAG, UPD3301, XTAL(14'318'181))
MCFG_UPD3301_CHARACTER_WIDTH(8)
MCFG_UPD3301_DRAW_CHARACTER_CALLBACK_OWNER(pc8001_state, pc8001_display_pixels)
MCFG_UPD3301_DRQ_CALLBACK(WRITELINE(m_dma, i8257_device, dreq2_w))
MCFG_VIDEO_SET_SCREEN(SCREEN_TAG)
UPD3301(config, m_crtc, XTAL(14'318'181));
m_crtc->set_character_width(8);
m_crtc->set_display_callback(FUNC(pc8001_state::pc8001_display_pixels), this);
m_crtc->drq_wr_callback().set(m_dma, FUNC(i8257_device::dreq2_w));
m_crtc->set_screen(SCREEN_TAG);
MCFG_DEVICE_ADD(m_centronics, CENTRONICS, centronics_devices, "printer")
MCFG_CENTRONICS_ACK_HANDLER(WRITELINE(*this, pc8001_state, write_centronics_ack))
@ -546,22 +546,22 @@ MACHINE_CONFIG_START(pc8001mk2_state::pc8001mk2)
MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25)
/* devices */
MCFG_DEVICE_ADD(I8251_TAG, I8251, 0)
I8251(config, I8251_TAG, 0);
MCFG_DEVICE_ADD(I8255A_TAG, I8255A, 0)
I8255A(config, I8255A_TAG, 0);
I8257(config, m_dma, XTAL(4'000'000));
m_dma->out_hrq_cb().set(FUNC(pc8001_state::hrq_w));
m_dma->in_memr_cb().set(FUNC(pc8001_state::dma_mem_r));
m_dma->out_iow_cb<2>().set(UPD3301_TAG, FUNC(upd3301_device::dack_w));
m_dma->out_iow_cb<2>().set(m_crtc, FUNC(upd3301_device::dack_w));
UPD1990A(config, m_rtc);
MCFG_DEVICE_ADD(UPD3301_TAG, UPD3301, XTAL(14'318'181))
MCFG_UPD3301_CHARACTER_WIDTH(8)
MCFG_UPD3301_DRAW_CHARACTER_CALLBACK_OWNER(pc8001_state, pc8001_display_pixels)
MCFG_UPD3301_DRQ_CALLBACK(WRITELINE(m_dma, i8257_device, dreq2_w))
MCFG_VIDEO_SET_SCREEN(SCREEN_TAG)
UPD3301(config, m_crtc, XTAL(14'318'181));
m_crtc->set_character_width(8);
m_crtc->set_display_callback(FUNC(pc8001_state::pc8001_display_pixels), this);
m_crtc->drq_wr_callback().set(m_dma, FUNC(i8257_device::dreq2_w));
m_crtc->set_screen(SCREEN_TAG);
MCFG_DEVICE_ADD(m_centronics, CENTRONICS, centronics_devices, "printer")

View File

@ -266,13 +266,13 @@ MACHINE_CONFIG_START(poly_state::poly)
MCFG_SCREEN_VISIBLE_AREA(0, 40 * 12 - 1, 0, 24 * 20 - 1)
MCFG_SCREEN_UPDATE_DRIVER(poly_state, screen_update)
MCFG_DEVICE_ADD("saa5050_1", SAA5050, 12.0576_MHz_XTAL / 2)
MCFG_SAA5050_D_CALLBACK(READ8(*this, poly_state, videoram_1_r))
MCFG_SAA5050_SCREEN_SIZE(40, 24, 40)
SAA5050(config, m_trom[0], 12.0576_MHz_XTAL / 2);
m_trom[0]->d_cb().set(FUNC(poly_state::videoram_1_r));
m_trom[0]->set_screen_size(40, 24, 40);
MCFG_DEVICE_ADD("saa5050_2", SAA5050, 12.0576_MHz_XTAL / 2)
MCFG_SAA5050_D_CALLBACK(READ8(*this, poly_state, videoram_2_r))
MCFG_SAA5050_SCREEN_SIZE(40, 24, 40)
SAA5050(config, m_trom[1], 12.0576_MHz_XTAL / 2);
m_trom[1]->d_cb().set(FUNC(poly_state::videoram_2_r));
m_trom[1]->set_screen_size(40, 24, 40);
/* sound hardware */
SPEAKER(config, "mono").front_center();

View File

@ -257,7 +257,7 @@ MACHINE_CONFIG_START(d110_state::d110)
PALETTE(config, "palette", FUNC(d110_state::d110_palette), 2);
MCFG_MSM6222B_01_ADD( m_lcd )
MSM6222B_01(config, m_lcd, 0);
MCFG_TIMER_DRIVER_ADD( m_midi_timer, d110_state, midi_timer_cb )

View File

@ -368,7 +368,7 @@ MACHINE_CONFIG_START(mt32_state::mt32)
PALETTE(config, "palette", FUNC(mt32_state::mt32_palette), 2);
MCFG_SED1200D0A_ADD( "lcd" )
SED1200D0A(config, lcd, 0);
MCFG_TIMER_DRIVER_ADD( "midi_timer", mt32_state, midi_timer_cb )

View File

@ -304,9 +304,9 @@ MACHINE_CONFIG_START(rt1715_state::rt1715)
GFXDECODE(config, "gfxdecode", "palette", gfx_rt1715);
PALETTE(config, "palette", FUNC(rt1715_state::rt1715_palette), 3);
MCFG_DEVICE_ADD("a26", I8275, 13.824_MHz_XTAL / 8)
MCFG_I8275_CHARACTER_WIDTH(8)
MCFG_I8275_DRAW_CHARACTER_CALLBACK_OWNER(rt1715_state, crtc_display_pixels)
i8275_device &a26(I8275(config, "a26", 13.824_MHz_XTAL / 8));
a26.set_character_width(8);
a26.set_display_callback(FUNC(rt1715_state::crtc_display_pixels), this);
z80ctc_device& ctc(Z80CTC(config, "a30", 9.832_MHz_XTAL / 4));
ctc.zc_callback<0>().set("a29", FUNC(z80sio_device::txca_w));

View File

@ -214,14 +214,14 @@ MACHINE_CONFIG_START(sagitta180_state::sagitta180)
MCFG_SCREEN_VISIBLE_AREA(0, 80*5-1, 0, 25*8-1)
MCFG_DEVICE_ADD("gfxdecode", GFXDECODE, "palette", gfx_sagitta180 )
MCFG_DEVICE_ADD("crtc", I8275, 12480000 / 8) /* guessed xtal */
MCFG_I8275_CHARACTER_WIDTH(8)
MCFG_I8275_DRAW_CHARACTER_CALLBACK_OWNER(sagitta180_state, crtc_display_pixels)
MCFG_I8275_DRQ_CALLBACK(WRITELINE("dma" , i8257_device , dreq2_w))
MCFG_I8275_IRQ_CALLBACK(INPUTLINE("maincpu" , I8085_INTR_LINE))
MCFG_VIDEO_SET_SCREEN("screen")
MCFG_PALETTE_ADD("palette", 3)
I8275(config, m_crtc, 12480000 / 8); /* guessed xtal */
m_crtc->set_character_width(8);
m_crtc->set_display_callback(FUNC(sagitta180_state::crtc_display_pixels), this);
m_crtc->drq_wr_callback().set(m_dma8257, FUNC(i8257_device::dreq2_w));
m_crtc->irq_wr_callback().set_inputline(m_maincpu, I8085_INTR_LINE);
m_crtc->set_screen("screen");
MCFG_PALETTE_ADD("palette", 3)
MACHINE_CONFIG_END

View File

@ -2525,7 +2525,7 @@ MACHINE_CONFIG_START(funcube_state::funcube)
MCFG_DEVICE_PROGRAM_MAP(funcube_sub_map)
MCFG_DEVICE_IO_MAP(funcube_sub_io)
MCFG_MCF5206E_PERIPHERAL_ADD("maincpu_onboard")
MCF5206E_PERIPHERAL(config, "maincpu_onboard", 0);
FUNCUBE_TOUCHSCREEN(config, "touchscreen", 200).tx_cb().set(":sub:sci1", FUNC(h8_sci_device::rx_w));

View File

@ -186,9 +186,9 @@ MACHINE_CONFIG_START(sm1800_state::sm1800)
m_ppi->in_pc_callback().set(FUNC(sm1800_state::sm1800_8255_portc_r));
m_ppi->out_pc_callback().set(FUNC(sm1800_state::sm1800_8255_portc_w));
MCFG_DEVICE_ADD("i8275", I8275, 2000000)
MCFG_I8275_CHARACTER_WIDTH(8)
MCFG_I8275_DRAW_CHARACTER_CALLBACK_OWNER(sm1800_state, crtc_display_pixels)
I8275(config, m_crtc, 2000000);
m_crtc->set_character_width(8);
m_crtc->set_display_callback(FUNC(sm1800_state::crtc_display_pixels), this);
MCFG_DEVICE_ADD("i8251", I8251, 0)
MACHINE_CONFIG_END

View File

@ -635,8 +635,7 @@ MACHINE_CONFIG_START(ti85_state::ti82)
subdevice<palette_device>("palette")->set_entries(2).set_init(FUNC(ti85_state::ti82_palette));
MCFG_DEVICE_ADD("t6a04", T6A04, 0)
MCFG_T6A04_SIZE(96, 64)
T6A04(config, "t6a04", 0).set_size(96, 64);
MCFG_DEVICE_ADD("linkport", TI8X_LINK_PORT, default_ti8x_link_devices, nullptr)
MACHINE_CONFIG_END
@ -662,8 +661,7 @@ MACHINE_CONFIG_START(ti85_state::ti83)
subdevice<palette_device>("palette")->set_entries(2).set_init(FUNC(ti85_state::ti82_palette));
MCFG_DEVICE_ADD("t6a04", T6A04, 0)
MCFG_T6A04_SIZE(96, 64)
T6A04(config, "t6a04", 0).set_size(96, 64);
MACHINE_CONFIG_END
MACHINE_CONFIG_START(ti85_state::ti86)
@ -698,8 +696,7 @@ MACHINE_CONFIG_START(ti85_state::ti83p)
ADDRESS_MAP_BANK(config, "membank3").set_map(&ti85_state::ti83p_banked_mem).set_options(ENDIANNESS_LITTLE, 8, 32, 0x4000);
ADDRESS_MAP_BANK(config, "membank4").set_map(&ti85_state::ti83p_banked_mem).set_options(ENDIANNESS_LITTLE, 8, 32, 0x4000);
MCFG_DEVICE_ADD("t6a04", T6A04, 0)
MCFG_T6A04_SIZE(96, 64)
T6A04(config, "t6a04", 0).set_size(96, 64);
MCFG_DEVICE_ADD("linkport", TI8X_LINK_PORT, default_ti8x_link_devices, nullptr)

View File

@ -177,12 +177,12 @@ MACHINE_CONFIG_START(tim100_state::tim100)
MCFG_DEVICE_ADD("gfxdecode", GFXDECODE, "palette", gfx_tim100 )
MCFG_DEVICE_ADD("crtc", I8276, XTAL(4'915'200))
MCFG_I8275_CHARACTER_WIDTH(12)
MCFG_I8275_DRAW_CHARACTER_CALLBACK_OWNER(tim100_state, crtc_display_pixels)
MCFG_I8275_DRQ_CALLBACK(WRITELINE(*this, tim100_state, drq_w))
MCFG_I8275_IRQ_CALLBACK(WRITELINE(*this, tim100_state, irq_w))
MCFG_VIDEO_SET_SCREEN("screen")
I8276(config, m_crtc, XTAL(4'915'200));
m_crtc->set_character_width(12);
m_crtc->set_display_callback(FUNC(tim100_state::crtc_display_pixels), this);
m_crtc->drq_wr_callback().set(FUNC(tim100_state::drq_w));
m_crtc->irq_wr_callback().set(FUNC(tim100_state::irq_w));
m_crtc->set_screen("screen");
MCFG_PALETTE_ADD("palette", 3)

View File

@ -426,11 +426,11 @@ MACHINE_CONFIG_START(unior_state::unior)
m_dma->in_memr_cb().set(FUNC(unior_state::dma_r));
m_dma->out_iow_cb<2>().set("crtc", FUNC(i8275_device::dack_w));
MCFG_DEVICE_ADD("crtc", I8275, XTAL(20'000'000) / 12)
MCFG_I8275_CHARACTER_WIDTH(6)
MCFG_I8275_DRAW_CHARACTER_CALLBACK_OWNER(unior_state, display_pixels)
MCFG_I8275_DRQ_CALLBACK(WRITELINE("dma",i8257_device, dreq2_w))
MCFG_VIDEO_SET_SCREEN("screen")
i8275_device &crtc(I8275(config, "crtc", XTAL(20'000'000) / 12));
crtc.set_character_width(6);
crtc.set_display_callback(FUNC(unior_state::display_pixels), this);
crtc.drq_wr_callback().set(m_dma, FUNC(i8257_device::dreq2_w));
crtc.set_screen("screen");
MACHINE_CONFIG_END
/* ROM definition */

View File

@ -215,12 +215,12 @@ MACHINE_CONFIG_START(zorba_state::zorba)
pit.out_handler<2>().append(m_uart2, FUNC(i8251_device::write_rxc));
// CRTC
MCFG_DEVICE_ADD(m_crtc, I8275, 14.318'181_MHz_XTAL / 7)
MCFG_I8275_CHARACTER_WIDTH(8)
MCFG_I8275_DRAW_CHARACTER_CALLBACK_OWNER(zorba_state, zorba_update_chr)
MCFG_I8275_DRQ_CALLBACK(WRITELINE(m_dma, z80dma_device, rdy_w))
MCFG_I8275_IRQ_CALLBACK(WRITELINE("irq0", input_merger_device, in_w<1>))
MCFG_VIDEO_SET_SCREEN("screen")
I8275(config, m_crtc, 14.318'181_MHz_XTAL / 7);
m_crtc->set_character_width(8);
m_crtc->set_display_callback(FUNC(zorba_state::zorba_update_chr), this);
m_crtc->drq_wr_callback().set(m_dma, FUNC(z80dma_device::rdy_w));
m_crtc->irq_wr_callback().set("irq0", FUNC(input_merger_device::in_w<1>));
m_crtc->set_screen("screen");
// Floppies
FD1793(config, m_fdc, 24_MHz_XTAL / 24);

View File

@ -166,9 +166,9 @@ MACHINE_CONFIG_START(abc800c_state::abc800c_video)
PALETTE(config, m_palette, FUNC(abc800c_state::abc800c_palette), 8);
MCFG_DEVICE_ADD(SAA5052_TAG, SAA5052, XTAL(12'000'000)/2)
MCFG_SAA5050_D_CALLBACK(READ8(*this, abc800c_state, char_ram_r))
MCFG_SAA5050_SCREEN_SIZE(40, 24, 40)
SAA5052(config, m_trom, XTAL(12'000'000)/2);
m_trom->d_cb().set(FUNC(abc800c_state::char_ram_r));
m_trom->set_screen_size(40, 24, 40);
MACHINE_CONFIG_END

View File

@ -140,12 +140,12 @@ MACHINE_CONFIG_START(mm1_state::mm1m6_video)
GFXDECODE(config, "gfxdecode", m_palette, gfx_mm1);
PALETTE(config, m_palette, FUNC(mm1_state::mm1_palette), 3);
MCFG_DEVICE_ADD(I8275_TAG, I8275, XTAL(18'720'000)/8)
MCFG_I8275_CHARACTER_WIDTH(HORIZONTAL_CHARACTER_PIXELS)
MCFG_I8275_DRAW_CHARACTER_CALLBACK_OWNER(mm1_state, crtc_display_pixels)
MCFG_I8275_DRQ_CALLBACK(WRITELINE(I8237_TAG, am9517a_device, dreq0_w))
MCFG_I8275_VRTC_CALLBACK(WRITELINE(UPD7220_TAG, upd7220_device, ext_sync_w))
MCFG_VIDEO_SET_SCREEN(SCREEN_TAG)
I8275(config, m_crtc, XTAL(18'720'000)/8);
m_crtc->set_character_width(HORIZONTAL_CHARACTER_PIXELS);
m_crtc->set_display_callback(FUNC(mm1_state::crtc_display_pixels), this);
m_crtc->drq_wr_callback().set(m_dmac, FUNC(am9517a_device::dreq0_w));
m_crtc->vrtc_wr_callback().set(m_hgdc, FUNC(upd7220_device::ext_sync_w));
m_crtc->set_screen("screen");
UPD7220(config, m_hgdc, XTAL(18'720'000)/8);
m_hgdc->set_addrmap(0, &mm1_state::mm1_upd7220_map);