Allow per-device internal layouts and remove some more MCFG_ macros.

Input and screen tags are now resolved relative to a layout's owner
device.

Easy way to demonstrate is with: mame64 intlc440 -tty ie15

Previously you'd only get the IE15 terminal's layout and you'd be unable
to use the INTELLEC 4/40 front panel.  Now you'll get the choice of
layouts from both the system and the terminal device in video options.
This commit is contained in:
Vas Crabb 2018-07-16 16:26:01 +10:00
parent 0e210f4347
commit f18c7cd65f
347 changed files with 939 additions and 980 deletions

View File

@ -166,37 +166,49 @@ class LayoutChecker(Minifyer):
except:
self.handleError('Element color attribute %s "%s" is not numeric' % (name, attrs[name]))
def checkTag(self, tag, element, attr):
if '' == tag:
self.handleError('Element %s attribute %s is empty', (element, attr))
else:
if tag.find('^') >= 0:
self.handleError('Element %s attribute %s "%s" contains parent device reference' % (element, attr, tag))
if ':' == tag[-1]:
self.handleError('Element %s attribute %s "%s" ends with separator' % (element, attr, tag))
if tag.find('::') >= 0:
self.handleError('Element %s attribute %s "%s" contains double separator' % (element, attr, tag))
def checkGroupViewItem(self, name, attrs):
if name in self.OBJECTS:
if 'element' not in attrs:
self.handleError('Element %s missing attribute element', (name, ))
elif attrs['element'] not in self.referenced_elements:
self.referenced_elements[attrs['element']] = self.formatLocation()
if 'inputtag' in attrs:
if 'inputmask' not in attrs:
self.handleError('Element %s has inputtag without inputmask attribute' % (name, ))
self.checkTag(attrs['inputtag'], name, 'inputtag')
if 'inputmask' in attrs:
try:
int(attrs['inputmask'], 0)
except:
self.handleError('Element %s attribute inputmask "%s" is not an integer' % (name, attrs['inputmask']))
self.in_object = True
self.have_bounds.append(False)
elif 'screen' == name:
if 'index' in attrs:
try:
index = long(attrs['index'])
index = long(attrs['index'], 0)
if 0 > index:
self.handleError('Element screen attribute index "%s" is negative' % (attrs['index'], ))
except:
self.handleError('Element screen attribute index "%s" is not an integer' % (attrs['index'], ))
if 'tag' in attrs:
self.handleError('Element screen has both index and tag attributes');
self.handleError('Element screen has both index and tag attributes')
if 'tag' in attrs:
tag = attrs['tag']
if '' == tag:
self.handleError('Element screen attribute tag is empty')
else:
if self.BADTAGPATTERN.search(tag):
self.handleError('Element screen attribute tag "%s" contains invalid characters' % (tag, ));
if tag.find('^') >= 0:
self.handleError('Element screen attribute tag "%s" contains parent device reference' % (tag, ));
if ':' == tag[-1]:
self.handleError('Element screen attribute tag "%s" ends with separator' % (tag, ));
if tag.find('::') >= 0:
self.handleError('Element screen attribute tag "%s" contains double separator' % (tag, ));
self.checkTag(tag, name, 'tag')
if self.BADTAGPATTERN.search(tag):
self.handleError('Element screen attribute tag "%s" contains invalid characters' % (tag, ))
self.in_object = True
self.have_bounds.append(False)
elif 'group' == name:

View File

@ -227,7 +227,7 @@ void epson_ex800_device::device_add_mconfig(machine_config &config)
upd.pc_in_cb().set(FUNC(epson_ex800_device::portc_r));
upd.pc_out_cb().set(FUNC(epson_ex800_device::portc_w));
config.m_default_layout = &layout_ex800;
config.set_default_layout(layout_ex800);
/* audio hardware */
SPEAKER(config, "mono").front_center();

View File

@ -66,7 +66,8 @@ void epson_lx800_device::lx800_mem(address_map &map)
// device_add_mconfig - add device configuration
//-------------------------------------------------
MACHINE_CONFIG_START(epson_lx800_device::device_add_mconfig)
void epson_lx800_device::device_add_mconfig(machine_config &config)
{
/* basic machine hardware */
upd7810_device &upd(UPD7810(config, m_maincpu, 14.7456_MHz_XTAL));
upd.set_addrmap(AS_PROGRAM, &epson_lx800_device::lx800_mem);
@ -82,7 +83,7 @@ MACHINE_CONFIG_START(epson_lx800_device::device_add_mconfig)
upd.an4_func().set(FUNC(epson_lx800_device::an4_r));
upd.an5_func().set(FUNC(epson_lx800_device::an5_r));
MCFG_DEFAULT_LAYOUT(layout_lx800)
config.set_default_layout(layout_lx800);
/* audio hardware */
SPEAKER(config, "mono").front_center();
@ -90,12 +91,12 @@ MACHINE_CONFIG_START(epson_lx800_device::device_add_mconfig)
m_beep->add_route(ALL_OUTPUTS, "mono", 0.05);
/* gate array */
MCFG_DEVICE_ADD("ic3b", E05A03, 0)
MCFG_E05A03_PE_LP_CALLBACK(WRITELINE(*this, epson_lx800_device, paperempty_led_w))
MCFG_E05A03_RESO_CALLBACK(WRITELINE(*this, epson_lx800_device, reset_w))
MCFG_E05A03_PE_CALLBACK(WRITELINE(*this, epson_lx800_device, centronics_pe_w))
MCFG_E05A03_DATA_CALLBACK(READ8(*this, epson_lx800_device, centronics_data_r))
MACHINE_CONFIG_END
e05a03_device &ic3b(E05A03(config, "ic3b", 0));
ic3b.pe_lp_wr_callback().set(FUNC(epson_lx800_device::paperempty_led_w));
ic3b.reso_wr_callback().set(FUNC(epson_lx800_device::reset_w));
ic3b.pe_wr_callback().set(FUNC(epson_lx800_device::centronics_pe_w));
ic3b.data_rd_callback().set(FUNC(epson_lx800_device::centronics_data_r));
}
//-------------------------------------------------
@ -184,10 +185,7 @@ ioport_constructor epson_lx800_device::device_input_ports() const
//-------------------------------------------------
epson_lx800_device::epson_lx800_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) :
device_t(mconfig, EPSON_LX800, tag, owner, clock),
device_centronics_peripheral_interface(mconfig, *this),
m_maincpu(*this, "maincpu"),
m_beep(*this, "beeper")
epson_lx800_device(mconfig, EPSON_LX800, tag, owner, clock)
{
}

View File

@ -71,6 +71,4 @@ private:
// device type definition
DECLARE_DEVICE_TYPE(EPSON_LX800, epson_lx800_device)
#endif // MAME_BUS_CENTRONICS_EPSON_LX800_H

View File

@ -127,7 +127,7 @@ MACHINE_CONFIG_START(epson_lx810l_device::device_add_mconfig)
upd.co0_func().set(FUNC(epson_lx810l_device::co0_w));
upd.co1_func().set("dac", FUNC(dac_bit_interface::write));
// MCFG_DEFAULT_LAYOUT(layout_lx800)
// config.set_default_layout(layout_lx800);
/* video hardware (simulates paper) */
MCFG_SCREEN_ADD("screen", RASTER)

View File

@ -24,80 +24,6 @@ enum
/***********************************************************************
CONFIGURATION MACROS
***********************************************************************/
#define MCS40CB_BUSCYCLE(cls, fnc) \
mcs40_cpu_device_base::bus_cycle_delegate((&cls::fnc), (#cls "::" #fnc), DEVICE_SELF, (cls *)nullptr)
#define MCFG_I4004_BUS_CYCLE_CB(obj) \
downcast<i4004_cpu_device &>(*device).set_bus_cycle_cb((MCS40CB_##obj));
#define MCFG_I4004_SYNC_CB(obj) \
downcast<i4004_cpu_device &>(*device).set_sync_cb(DEVCB_##obj);
#define MCFG_I4004_CM_ROM_CB(obj) \
downcast<i4004_cpu_device &>(*device).set_cm_rom_cb(DEVCB_##obj);
#define MCFG_I4004_CM_RAM0_CB(obj) \
downcast<i4004_cpu_device &>(*device).set_cm_ram_cb<0>(DEVCB_##obj);
#define MCFG_I4004_CM_RAM1_CB(obj) \
downcast<i4004_cpu_device &>(*device).set_cm_ram_cb<1>(DEVCB_##obj);
#define MCFG_I4004_CM_RAM2_CB(obj) \
downcast<i4004_cpu_device &>(*device).set_cm_ram_cb<2>(DEVCB_##obj);
#define MCFG_I4004_CM_RAM3_CB(obj) \
downcast<i4004_cpu_device &>(*device).set_cm_ram_cb<3>(DEVCB_##obj);
#define MCFG_I4004_4289_PM_CB(obj) \
downcast<i4004_cpu_device &>(*device).set_4289_pm_cb(DEVCB_##obj);
#define MCFG_I4004_4289_F_L_CB(obj) \
downcast<i4004_cpu_device &>(*device).set_4289_f_l_cb(DEVCB_##obj);
#define MCFG_I4040_BUS_CYCLE_CB(obj) \
downcast<i4040_cpu_device &>(*device).set_bus_cycle_cb((MCS40CB_##obj));
#define MCFG_I4040_SYNC_CB(obj) \
downcast<i4040_cpu_device &>(*device).set_sync_cb(DEVCB_##obj);
#define MCFG_I4040_CM_ROM0_CB(obj) \
downcast<i4040_cpu_device &>(*device).set_cm_rom_cb<0>(DEVCB_##obj);
#define MCFG_I4040_CM_ROM1_CB(obj) \
downcast<i4040_cpu_device &>(*device).set_cm_rom_cb<1>(DEVCB_##obj);
#define MCFG_I4040_CM_RAM0_CB(obj) \
downcast<i4040_cpu_device &>(*device).set_cm_ram_cb<0>(DEVCB_##obj);
#define MCFG_I4040_CM_RAM1_CB(obj) \
downcast<i4040_cpu_device &>(*device).set_cm_ram_cb<1>(DEVCB_##obj);
#define MCFG_I4040_CM_RAM2_CB(obj) \
downcast<i4040_cpu_device &>(*device).set_cm_ram_cb<2>(DEVCB_##obj);
#define MCFG_I4040_CM_RAM3_CB(obj) \
downcast<i4040_cpu_device &>(*device).set_cm_ram_cb<3>(DEVCB_##obj);
#define MCFG_I4040_CY_CB(obj) \
downcast<i4040_cpu_device &>(*device).set_cy_cb(DEVCB_##obj);
#define MCFG_I4040_STP_ACK_CB(obj) \
downcast<i4040_cpu_device &>(*device).set_stp_ack_cb(DEVCB_##obj);
#define MCFG_I4040_4289_PM_CB(obj) \
downcast<i4040_cpu_device &>(*device).set_4289_pm_cb(DEVCB_##obj);
#define MCFG_I4040_4289_F_L_CB(obj) \
downcast<i4040_cpu_device &>(*device).set_4289_f_l_cb(DEVCB_##obj);
/***********************************************************************
TYPE DEFINITIONS
***********************************************************************/
@ -125,9 +51,9 @@ public:
template <typename... T> void set_ram_status_map(T &&... args) { set_addrmap(AS_RAM_STATUS, std::forward<T>(args)...); }
template <typename... T> void set_ram_ports_map(T &&... args) { set_addrmap(AS_RAM_PORTS, std::forward<T>(args)...); }
template <typename... T> void set_program_memory_map(T &&... args) { set_addrmap(AS_PROGRAM_MEMORY, std::forward<T>(args)...); }
template <typename Obj> void set_bus_cycle_cb(Obj &&cb) { m_bus_cycle_cb = std::forward<Obj>(cb); }
template <typename Obj> devcb_base &set_4289_pm_cb(Obj &&cb) { return m_4289_pm_cb.set_callback(std::forward<Obj>(cb)); }
template <typename Obj> devcb_base &set_4289_f_l_cb(Obj &&cb) { return m_4289_f_l_cb.set_callback(std::forward<Obj>(cb)); }
template <typename... T> void set_bus_cycle_cb(T &&... args) { m_bus_cycle_cb = bus_cycle_delegate(std::forward<T>(args)...); }
auto i4289_pm_cb() { return m_4289_pm_cb.bind(); }
auto i4289_f_l_cb() { return m_4289_f_l_cb.bind(); }
// chip select outputs
u8 get_cm_rom() const { return m_cm_rom; }
@ -211,11 +137,11 @@ protected:
void set_stp(int state);
// configuration helpers
template <typename Obj> devcb_base &set_sync_cb(Obj &&cb) { return m_sync_cb.set_callback(std::forward<Obj>(cb)); }
template <unsigned N, typename Obj> devcb_base &set_cm_rom_cb(Obj &&cb) { return m_cm_rom_cb[N].set_callback(std::forward<Obj>(cb)); }
template <unsigned N, typename Obj> devcb_base &set_cm_ram_cb(Obj &&cb) { return m_cm_ram_cb[N].set_callback(std::forward<Obj>(cb)); }
template <typename Obj> devcb_base &set_cy_cb(Obj &&cb) { return m_cy_cb.set_callback(std::forward<Obj>(cb)); }
template <typename Obj> devcb_base &set_stp_ack_cb(Obj &&cb) { return m_stp_ack_cb.set_callback(std::forward<Obj>(cb)); }
auto sync_cb() { return m_sync_cb.bind(); }
template <unsigned N> auto cm_rom_cb() { return m_cm_rom_cb[N].bind(); }
template <unsigned N> auto cm_ram_cb() { return m_cm_ram_cb[N].bind(); }
auto cy_cb() { return m_cy_cb.bind(); }
auto stp_ack_cb() { return m_stp_ack_cb.bind(); }
private:
enum
@ -322,9 +248,9 @@ class i4004_cpu_device : public mcs40_cpu_device_base
{
public:
// configuration helpers
template <typename Obj> devcb_base &set_sync_cb(Obj &&cb) { return mcs40_cpu_device_base::set_sync_cb(std::forward<Obj>(cb)); }
template <typename Obj> devcb_base &set_cm_rom_cb(Obj &&cb) { return set_cm_rom_cb<0>(std::forward<Obj>(cb)); }
template <unsigned N, typename Obj> devcb_base &set_cm_ram_cb(Obj &&cb) { return mcs40_cpu_device_base::set_cm_ram_cb<N>(std::forward<Obj>(cb)); }
auto sync_cb() { return mcs40_cpu_device_base::sync_cb(); }
auto cm_rom_cb() { return cm_rom_cb<0>(); }
template <unsigned N> auto cm_ram_cb() { return mcs40_cpu_device_base::cm_ram_cb<N>(); }
i4004_cpu_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock);
@ -345,9 +271,9 @@ protected:
virtual u8 do_io(u8 opr, u8 opa) override;
// configuration helpers
using mcs40_cpu_device_base::set_sync_cb;
using mcs40_cpu_device_base::set_cm_rom_cb;
using mcs40_cpu_device_base::set_cm_ram_cb;
using mcs40_cpu_device_base::sync_cb;
using mcs40_cpu_device_base::cm_rom_cb;
using mcs40_cpu_device_base::cm_ram_cb;
};
@ -355,11 +281,11 @@ class i4040_cpu_device : public i4004_cpu_device
{
public:
// configuration helpers
template <typename Obj> devcb_base &set_sync_cb(Obj &&cb) { return i4004_cpu_device::set_sync_cb(std::forward<Obj>(cb)); }
template <unsigned N, typename Obj> devcb_base &set_cm_rom_cb(Obj &&cb) { return set_cm_rom_cb<N>(std::forward<Obj>(cb)); }
template <unsigned N, typename Obj> devcb_base &set_cm_ram_cb(Obj &&cb) { return set_cm_ram_cb<N>(std::forward<Obj>(cb)); }
template <typename Obj> devcb_base &set_cy_cb(Obj &&cb) { return i4004_cpu_device::set_cy_cb(std::forward<Obj>(cb)); }
template <typename Obj> devcb_base &set_stp_ack_cb(Obj &&cb) { return i4004_cpu_device::set_stp_ack_cb(std::forward<Obj>(cb)); }
auto sync_cb() { return i4004_cpu_device::sync_cb(); }
template <unsigned N> auto cm_rom_cb() { return cm_rom_cb<N>(); }
template <unsigned N> auto cm_ram_cb() { return cm_ram_cb<N>(); }
auto cy_cb() { return i4004_cpu_device::cy_cb(); }
auto stp_ack_cb() { return i4004_cpu_device::stp_ack_cb(); }
i4040_cpu_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock);
@ -375,11 +301,11 @@ protected:
virtual cycle do_cycle1(u8 opr, u8 opa, pmem &program_op) override;
// configuration helpers
using mcs40_cpu_device_base::set_sync_cb;
using mcs40_cpu_device_base::set_cm_rom_cb;
using mcs40_cpu_device_base::set_cm_ram_cb;
using mcs40_cpu_device_base::set_cy_cb;
using mcs40_cpu_device_base::set_stp_ack_cb;
using mcs40_cpu_device_base::sync_cb;
using mcs40_cpu_device_base::cm_rom_cb;
using mcs40_cpu_device_base::cm_ram_cb;
using mcs40_cpu_device_base::cy_cb;
using mcs40_cpu_device_base::stp_ack_cb;
};

View File

@ -11,26 +11,6 @@
#pragma once
/***************************************************************************
DEVICE CONFIGURATION MACROS
***************************************************************************/
#define MCFG_E05A03_NLQ_LP_CALLBACK(_write) \
downcast<e05a03_device &>(*device).set_nlq_lp_wr_callback(DEVCB_##_write);
#define MCFG_E05A03_PE_LP_CALLBACK(_write) \
downcast<e05a03_device &>(*device).set_pe_lp_wr_callback(DEVCB_##_write);
#define MCFG_E05A03_RESO_CALLBACK(_write) \
downcast<e05a03_device &>(*device).set_reso_wr_callback(DEVCB_##_write);
#define MCFG_E05A03_PE_CALLBACK(_write) \
downcast<e05a03_device &>(*device).set_pe_wr_callback(DEVCB_##_write);
#define MCFG_E05A03_DATA_CALLBACK(_read) \
downcast<e05a03_device &>(*device).set_data_rd_callback(DEVCB_##_read);
/***************************************************************************
TYPE DEFINITIONS
***************************************************************************/
@ -40,11 +20,11 @@ class e05a03_device : public device_t
public:
e05a03_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
template <class Object> devcb_base &set_nlq_lp_wr_callback(Object &&cb) { return m_write_nlq_lp.set_callback(std::forward<Object>(cb)); }
template <class Object> devcb_base &set_pe_lp_wr_callback(Object &&cb) { return m_write_pe_lp.set_callback(std::forward<Object>(cb)); }
template <class Object> devcb_base &set_reso_wr_callback(Object &&cb) { return m_write_reso.set_callback(std::forward<Object>(cb)); }
template <class Object> devcb_base &set_pe_wr_callback(Object &&cb) { return m_write_pe.set_callback(std::forward<Object>(cb)); }
template <class Object> devcb_base &set_data_rd_callback(Object &&cb) { return m_read_data.set_callback(std::forward<Object>(cb)); }
auto nlq_lp_wr_callback() { return m_write_nlq_lp.bind(); }
auto pe_lp_wr_callback() { return m_write_pe_lp.bind(); }
auto reso_wr_callback() { return m_write_reso.bind(); }
auto pe_wr_callback() { return m_write_pe.bind(); }
auto data_rd_callback() { return m_read_data.bind(); }
DECLARE_WRITE8_MEMBER( write );
DECLARE_READ8_MEMBER( read );

View File

@ -574,7 +574,7 @@ MACHINE_CONFIG_START(ie15_device::ie15core)
MCFG_DEVICE_PROGRAM_MAP(ie15_mem)
MCFG_DEVICE_IO_MAP(ie15_io)
MCFG_DEFAULT_LAYOUT(layout_ie15)
config.set_default_layout(layout_ie15);
/* Devices */
MCFG_DEVICE_ADD("keyboard", IE15_KEYBOARD, 0)

View File

@ -1810,7 +1810,7 @@ MACHINE_CONFIG_START(gba_lcd_device::device_add_mconfig)
MCFG_SCREEN_UPDATE_DEVICE(DEVICE_SELF, gba_lcd_device, screen_update)
MCFG_SCREEN_PALETTE("palette")
MCFG_DEFAULT_LAYOUT(layout_lcd)
config.set_default_layout(layout_lcd);
MCFG_PALETTE_ADD("palette", 32768)
MCFG_PALETTE_INIT_OWNER(gba_lcd_device, gba)
MACHINE_CONFIG_END

View File

@ -40,23 +40,14 @@
*/
// C/R pins (0538: d0-d7 for rows)
#define MCFG_HLCD0538_WRITE_COLS_CB(_devcb) \
downcast<hlcd0538_device &>(*device).set_write_cols_callback(DEVCB_##_devcb);
// INTERRUPT pin
#define MCFG_HLCD0538_INTERRUPT_CB(_devcb) \
downcast<hlcd0538_device &>(*device).set_write_interrupt_callback(DEVCB_##_devcb);
class hlcd0538_device : public device_t
{
public:
hlcd0538_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock);
// configuration helpers
template <typename Object> devcb_base &set_write_cols_callback(Object &&cb) { return m_write_cols.set_callback(std::forward<Object>(cb)); }
template <typename Object> devcb_base &set_write_interrupt_callback(Object &&cb) { return m_write_interrupt.set_callback(std::forward<Object>(cb)); }
auto write_cols_callback() { return m_write_cols.bind(); } // C/R pins (0538: d0-d7 for rows)
auto write_interrupt_callback() { return m_write_interrupt.bind(); } // INTERRUPT pin
DECLARE_WRITE_LINE_MEMBER(write_clk);
DECLARE_WRITE_LINE_MEMBER(write_lcd);

View File

@ -32,13 +32,11 @@
#define DEVCB_READ8(tag, _class, _func) (std::forward_as_tuple((tag), &_class::_func, #_class "::" #_func))
#define DEVCB_READ16(tag, _class, _func) (std::forward_as_tuple((tag), &_class::_func, #_class "::" #_func))
#define DEVCB_READ32(tag, _class, _func) (std::forward_as_tuple((tag), &_class::_func, #_class "::" #_func))
#define DEVCB_READ64(tag, _class, _func) (std::forward_as_tuple((tag), &_class::_func, #_class "::" #_func))
#define DEVCB_READLINE(tag, _class, _func) (std::forward_as_tuple((tag), &_class::_func, #_class "::" #_func))
#define DEVCB_WRITE8(tag, _class, _func) (std::forward_as_tuple((tag), &_class::_func, #_class "::" #_func))
#define DEVCB_WRITE16(tag, _class, _func) (std::forward_as_tuple((tag), &_class::_func, #_class "::" #_func))
#define DEVCB_WRITE32(tag, _class, _func) (std::forward_as_tuple((tag), &_class::_func, #_class "::" #_func))
#define DEVCB_WRITE64(tag, _class, _func) (std::forward_as_tuple((tag), &_class::_func, #_class "::" #_func))
#define DEVCB_WRITELINE(tag, _class, _func) (std::forward_as_tuple((tag), &_class::_func, #_class "::" #_func))
template <typename T> struct devcb_constant_t { T m_value; };

View File

@ -117,7 +117,7 @@
<bounds left="0" right="800" top="550" bottom="600" />
</bezel>
-->
<screen index="0">
<screen tag="screen">
<bounds x="0" y="0" width="800" height="550" />
</screen>
</view>

View File

@ -13,6 +13,7 @@
#include "screen.h"
#include <ctype.h>
#include <cstring>
//**************************************************************************
@ -37,10 +38,10 @@ private:
machine_config::machine_config(const game_driver &gamedrv, emu_options &options)
: m_minimum_quantum(attotime::zero)
, m_default_layout(nullptr)
, m_gamedrv(gamedrv)
, m_options(options)
, m_root_device()
, m_default_layouts([] (char const *a, char const *b) { return 0 > std::strcmp(a, b); })
, m_current_device(nullptr)
{
// add the root device
@ -115,6 +116,19 @@ machine_config::~machine_config()
}
//-------------------------------------------------
// set_default_layout - set layout for current
// device
//-------------------------------------------------
void machine_config::set_default_layout(internal_layout const &layout)
{
std::pair<default_layout_map::iterator, bool> const ins(m_default_layouts.emplace(current_device().tag(), &layout));
if (!ins.second)
ins.first->second = &layout;
}
//-------------------------------------------------
// device_add - configuration helper to add a
// new device
@ -296,9 +310,21 @@ device_t *machine_config::device_find(device_t *owner, const char *tag)
// to a device about to be removed from the tree
//-------------------------------------------------
void machine_config::remove_references(ATTR_UNUSED device_t &device)
void machine_config::remove_references(device_t &device)
{
// remove default layouts for subdevices
char const *const tag(device.tag());
std::size_t const taglen(std::strlen(tag));
default_layout_map::iterator it(m_default_layouts.lower_bound(tag));
while ((m_default_layouts.end() != it) && !std::strncmp(tag, it->first, taglen))
{
if (!it->first[taglen] || (':' == it->first[taglen]))
it = m_default_layouts.erase(it);
else
++it;
}
// iterate over all devices and remove any references
for (device_t &scan : device_iterator(root_device()))
scan.subdevices().m_tagmap.clear(); //remove(&device);
scan.subdevices().m_tagmap.clear();
}

View File

@ -19,6 +19,7 @@
#define MAME_EMU_MCONFIG_H
#include <cassert>
#include <map>
#include <memory>
#include <tuple>
#include <type_traits>
@ -100,15 +101,20 @@ public:
device_t &root_device() const { assert(m_root_device); return *m_root_device; }
device_t &current_device() const { assert(m_current_device); return *m_current_device; }
emu_options &options() const { return m_options; }
inline device_t *device(const char *tag) const { return root_device().subdevice(tag); }
template <class DeviceClass> inline DeviceClass *device(const char *tag) const { return downcast<DeviceClass *>(device(tag)); }
device_t *device(const char *tag) const { return root_device().subdevice(tag); }
template <class DeviceClass> DeviceClass *device(const char *tag) const { return downcast<DeviceClass *>(device(tag)); }
template <typename T> void apply_default_layouts(T &&op) const
{
for (std::pair<char const *, internal_layout const *> const &lay : m_default_layouts)
op(*device(lay.first), *lay.second);
}
// public state
attotime m_minimum_quantum; // minimum scheduling quantum
std::string m_perfect_cpu_quantum; // tag of CPU to use for "perfect" scheduling
// other parameters
const internal_layout * m_default_layout; // default layout for this machine
// configuration methods
void set_default_layout(internal_layout const &layout);
// helpers during configuration; not for general use
token begin_configuration(device_t &device)
@ -167,18 +173,20 @@ public:
private:
class current_device_stack;
typedef std::map<char const *, internal_layout const *, bool (*)(char const *, char const *)> default_layout_map;
// internal helpers
std::pair<const char *, device_t *> resolve_owner(const char *tag) const;
std::tuple<const char *, device_t *, device_t *> prepare_replace(const char *tag);
device_t &add_device(std::unique_ptr<device_t> &&device, device_t *owner);
device_t &replace_device(std::unique_ptr<device_t> &&device, device_t &owner, device_t *existing);
void remove_references(ATTR_UNUSED device_t &device);
void remove_references(device_t &device);
// internal state
game_driver const & m_gamedrv;
emu_options & m_options;
std::unique_ptr<device_t> m_root_device;
default_layout_map m_default_layouts;
device_t * m_current_device;
};
@ -243,10 +251,6 @@ Ends a machine_config.
#define MCFG_QUANTUM_PERFECT_CPU(_cputag) \
config.m_perfect_cpu_quantum = subtag(_cputag);
// core video parameters
#define MCFG_DEFAULT_LAYOUT(_layout) \
config.m_default_layout = &(_layout);
// add/remove devices
#define MCFG_DEVICE_ADD(_tag, ...) \
device = emu::detail::device_add_impl(config, _tag, __VA_ARGS__);

View File

@ -1589,7 +1589,7 @@ void render_target::load_layout_files(const internal_layout *layoutfile, bool si
// if there's an explicit file, load that first
const char *basename = m_manager.machine().basename();
if (layoutfile)
have_artwork |= load_layout_file(basename, layoutfile);
have_artwork |= load_layout_file(basename, *layoutfile);
// if we're only loading this file, we know our final result
if (!singlefile)
@ -1602,7 +1602,7 @@ void render_target::load_layout_files(util::xml::data_node const &rootnode, bool
// if there's an explicit file, load that first
const char *basename = m_manager.machine().basename();
have_artwork |= load_layout_file(basename, rootnode);
have_artwork |= load_layout_file(m_manager.machine().root_device(), basename, rootnode);
// if we're only loading this file, we know our final result
if (!singlefile)
@ -1637,9 +1637,10 @@ void render_target::load_additional_layout_files(const char *basename, bool have
// if a default view has been specified, use that as a fallback
if (system.default_layout != nullptr)
have_default |= load_layout_file(nullptr, system.default_layout);
if (m_manager.machine().config().m_default_layout != nullptr)
have_default |= load_layout_file(nullptr, m_manager.machine().config().m_default_layout);
have_default |= load_layout_file(nullptr, *system.default_layout);
m_manager.machine().config().apply_default_layouts(
[this, &have_default] (device_t &dev, internal_layout const &layout)
{ have_default |= load_layout_file(nullptr, layout, &dev); });
// try to load another file based on the parent driver name
int cloneof = driver_list::clone(system);
@ -1682,9 +1683,9 @@ void render_target::load_additional_layout_files(const char *basename, bool have
if (screens == 1)
{
if (system.flags & ORIENTATION_SWAP_XY)
load_layout_file(nullptr, &layout_vertical);
load_layout_file(nullptr, layout_vertical);
else
load_layout_file(nullptr, &layout_horizont);
load_layout_file(nullptr, layout_horizont);
if (m_filelist.empty())
throw emu_fatalerror("Couldn't parse default layout??");
}
@ -1693,7 +1694,7 @@ void render_target::load_additional_layout_files(const char *basename, bool have
{
if (screens == 2)
{
load_layout_file(nullptr, &layout_dualhsxs);
load_layout_file(nullptr, layout_dualhsxs);
if (m_filelist.empty())
throw emu_fatalerror("Couldn't parse default layout??");
}
@ -1703,7 +1704,7 @@ void render_target::load_additional_layout_files(const char *basename, bool have
{
if (!view_by_index(0))
{
load_layout_file(nullptr, &layout_noscreens);
load_layout_file(nullptr, layout_noscreens);
if (m_filelist.empty())
throw emu_fatalerror("Couldn't parse default layout??");
}
@ -1854,7 +1855,7 @@ void render_target::load_additional_layout_files(const char *basename, bool have
}
// try to parse it
if (!load_layout_file(nullptr, *root))
if (!load_layout_file(m_manager.machine().root_device(), nullptr, *root))
throw emu_fatalerror("Couldn't parse generated layout??");
}
}
@ -1865,11 +1866,10 @@ void render_target::load_additional_layout_files(const char *basename, bool have
// and append it to our list
//-------------------------------------------------
bool render_target::load_layout_file(const char *dirname, const internal_layout *layout_data)
bool render_target::load_layout_file(const char *dirname, const internal_layout &layout_data, device_t *device)
{
// +1 to ensure data is terminated for XML parser
auto tempout = make_unique_clear<u8[]>(layout_data->decompressed_size+1);
auto tempout = make_unique_clear<u8 []>(layout_data.decompressed_size + 1);
z_stream stream;
int zerr;
@ -1877,7 +1877,7 @@ bool render_target::load_layout_file(const char *dirname, const internal_layout
/* initialize the stream */
memset(&stream, 0, sizeof(stream));
stream.next_out = tempout.get();
stream.avail_out = layout_data->decompressed_size;
stream.avail_out = layout_data.decompressed_size;
zerr = inflateInit(&stream);
@ -1888,8 +1888,8 @@ bool render_target::load_layout_file(const char *dirname, const internal_layout
}
/* decompress this chunk */
stream.next_in = (unsigned char*)layout_data->data;
stream.avail_in = layout_data->compressed_size;
stream.next_in = (unsigned char *)layout_data.data;
stream.avail_in = layout_data.compressed_size;
zerr = inflate(&stream, Z_NO_FLUSH);
/* stop at the end of the stream */
@ -1911,55 +1911,55 @@ bool render_target::load_layout_file(const char *dirname, const internal_layout
return false;
}
return load_layout_file(dirname, (const char*)tempout.get());
util::xml::file::ptr rootnode(util::xml::file::string_read(reinterpret_cast<char const *>(tempout.get()), nullptr));
tempout.reset();
// if we didn't get a properly-formatted XML file, record a warning and exit
if (!load_layout_file(device ? *device : m_manager.machine().root_device(), dirname, *rootnode))
{
osd_printf_warning("Improperly formatted XML string, ignoring\n");
return false;
}
else
{
return true;
}
}
bool render_target::load_layout_file(const char *dirname, const char *filename)
{
util::xml::file::ptr rootnode;
if (filename[0] == '<')
// build the path and optionally prepend the directory
std::string fname = std::string(filename).append(".lay");
if (dirname)
fname.insert(0, PATH_SEPARATOR).insert(0, dirname);
// attempt to open the file; bail if we can't
emu_file layoutfile(m_manager.machine().options().art_path(), OPEN_FLAG_READ);
osd_file::error const filerr(layoutfile.open(fname.c_str()));
if (filerr != osd_file::error::NONE)
return false;
// read the file
util::xml::file::ptr rootnode(util::xml::file::read(layoutfile, nullptr));
// if we didn't get a properly-formatted XML file, record a warning and exit
if (!load_layout_file(m_manager.machine().root_device(), dirname, *rootnode))
{
// if the first character of the "file" is an open brace, assume it is an XML string
rootnode = util::xml::file::string_read(filename, nullptr);
osd_printf_warning("Improperly formatted XML file '%s', ignoring\n", filename);
return false;
}
else
{
// otherwise, assume it is a file
// build the path and optionally prepend the directory
std::string fname = std::string(filename).append(".lay");
if (dirname != nullptr)
fname.insert(0, PATH_SEPARATOR).insert(0, dirname);
// attempt to open the file; bail if we can't
emu_file layoutfile(m_manager.machine().options().art_path(), OPEN_FLAG_READ);
osd_file::error filerr = layoutfile.open(fname.c_str());
if (filerr != osd_file::error::NONE)
return false;
// read the file
rootnode = util::xml::file::read(layoutfile, nullptr);
return true;
}
// if we didn't get a properly-formatted XML file, record a warning and exit
if (!load_layout_file(dirname, *rootnode))
{
if (filename[0] != '<')
osd_printf_warning("Improperly formatted XML file '%s', ignoring\n", filename);
else
osd_printf_warning("Improperly formatted XML string, ignoring\n");
return false;
}
return true;
}
bool render_target::load_layout_file(const char *dirname, util::xml::data_node const &rootnode)
bool render_target::load_layout_file(device_t &device, const char *dirname, util::xml::data_node const &rootnode)
{
// parse and catch any errors
try
{
m_filelist.emplace_back(m_manager.machine(), rootnode, dirname);
m_filelist.emplace_back(device, rootnode, dirname);
}
catch (emu_fatalerror &)
{

View File

@ -806,7 +806,7 @@ public:
public:
// construction/destruction
item(
running_machine &machine,
device_t &device,
util::xml::data_node const &itemnode,
element_map &elemmap,
render_bounds const &transform);
@ -846,7 +846,7 @@ public:
// construction/destruction
layout_view(
running_machine &machine,
device_t &device,
util::xml::data_node const &viewnode,
element_map &elemmap,
group_map const &groupmap);
@ -873,12 +873,14 @@ public:
private:
// add items, recursing for groups
void add_items(
running_machine &machine,
device_t &device,
util::xml::data_node const &parentnode,
element_map &elemmap,
group_map const &groupmap,
render_bounds const &transform);
static std::string make_name(device_t &device, util::xml::data_node const &viewnode);
// internal state
std::string m_name; // name of the layout
float m_aspect; // X/Y of the layout
@ -909,7 +911,7 @@ public:
using view_list = std::list<layout_view>;
// construction/destruction
layout_file(running_machine &machine, util::xml::data_node const &rootnode, char const *dirname);
layout_file(device_t &device, util::xml::data_node const &rootnode, char const *dirname);
~layout_file();
// getters
@ -1020,8 +1022,8 @@ private:
void load_layout_files(util::xml::data_node const &rootnode, bool singlefile);
void load_additional_layout_files(const char *basename, bool have_artwork);
bool load_layout_file(const char *dirname, const char *filename);
bool load_layout_file(const char *dirname, const internal_layout *layout_data);
bool load_layout_file(const char *dirname, util::xml::data_node const &rootnode);
bool load_layout_file(const char *dirname, const internal_layout &layout_data, device_t *device = nullptr);
bool load_layout_file(device_t &device, const char *dirname, util::xml::data_node const &rootnode);
void add_container_primitives(render_primitive_list &list, const object_transform &root_xform, const object_transform &xform, render_container &container, int blendmode);
void add_element_primitives(render_primitive_list &list, const object_transform &xform, layout_element &element, int state, int blendmode);
bool map_point_internal(s32 target_x, s32 target_y, render_container *container, float &mapped_x, float &mapped_y, ioport_port *&mapped_input_port, ioport_value &mapped_input_mask);

View File

@ -2389,11 +2389,11 @@ void layout_element::component::apply_skew(bitmap_argb32 &dest, int skewwidth)
//-------------------------------------------------
layout_view::layout_view(
running_machine &machine,
device_t &device,
util::xml::data_node const &viewnode,
element_map &elemmap,
group_map const &groupmap)
: m_name(xml_get_attribute_string_with_subst(machine, viewnode, "name", ""))
: m_name(make_name(device, viewnode))
, m_aspect(1.0f)
, m_scraspect(1.0f)
{
@ -2401,10 +2401,10 @@ layout_view::layout_view(
util::xml::data_node const *const boundsnode = viewnode.get_child("bounds");
m_expbounds.x0 = m_expbounds.y0 = m_expbounds.x1 = m_expbounds.y1 = 0;
if (boundsnode)
parse_bounds(machine, boundsnode, m_expbounds);
parse_bounds(device.machine(), boundsnode, m_expbounds);
// load items
add_items(machine, viewnode, elemmap, groupmap, render_bounds{ 0.0f, 0.0f, 1.0f, 1.0f });
add_items(device, viewnode, elemmap, groupmap, render_bounds{ 0.0f, 0.0f, 1.0f, 1.0f });
// recompute the data for the view based on a default layer config
recompute(render_layer_config());
@ -2561,7 +2561,7 @@ void layout_view::resolve_tags()
//-------------------------------------------------
void layout_view::add_items(
running_machine &machine,
device_t &device,
util::xml::data_node const &parentnode,
element_map &elemmap,
group_map const &groupmap,
@ -2571,31 +2571,31 @@ void layout_view::add_items(
{
if (!strcmp(itemnode->get_name(), "backdrop"))
{
m_backdrop_list.emplace_back(machine, *itemnode, elemmap, transform);
m_backdrop_list.emplace_back(device, *itemnode, elemmap, transform);
}
else if (!strcmp(itemnode->get_name(), "screen"))
{
m_screen_list.emplace_back(machine, *itemnode, elemmap, transform);
m_screen_list.emplace_back(device, *itemnode, elemmap, transform);
}
else if (!strcmp(itemnode->get_name(), "overlay"))
{
m_overlay_list.emplace_back(machine, *itemnode, elemmap, transform);
m_overlay_list.emplace_back(device, *itemnode, elemmap, transform);
}
else if (!strcmp(itemnode->get_name(), "bezel"))
{
m_bezel_list.emplace_back(machine, *itemnode, elemmap, transform);
m_bezel_list.emplace_back(device, *itemnode, elemmap, transform);
}
else if (!strcmp(itemnode->get_name(), "cpanel"))
{
m_cpanel_list.emplace_back(machine, *itemnode, elemmap, transform);
m_cpanel_list.emplace_back(device, *itemnode, elemmap, transform);
}
else if (!strcmp(itemnode->get_name(), "marquee"))
{
m_marquee_list.emplace_back(machine, *itemnode, elemmap, transform);
m_marquee_list.emplace_back(device, *itemnode, elemmap, transform);
}
else if (!strcmp(itemnode->get_name(), "group"))
{
char const *ref(xml_get_attribute_string_with_subst(machine, *itemnode, "ref", nullptr));
char const *ref(xml_get_attribute_string_with_subst(device.machine(), *itemnode, "ref", nullptr));
if (!ref)
throw layout_syntax_error("nested group must have ref attribute");
@ -2608,11 +2608,11 @@ void layout_view::add_items(
if (itemboundsnode)
{
render_bounds itembounds;
parse_bounds(machine, itemboundsnode, itembounds);
parse_bounds(device.machine(), itemboundsnode, itembounds);
grouptrans = found->second.make_transform(itembounds, transform);
}
add_items(machine, found->second.get_groupnode(), elemmap, groupmap, grouptrans);
add_items(device, found->second.get_groupnode(), elemmap, groupmap, grouptrans);
}
else if (strcmp(itemnode->get_name(), "bounds"))
{
@ -2621,6 +2621,22 @@ void layout_view::add_items(
}
}
std::string layout_view::make_name(device_t &device, util::xml::data_node const &viewnode)
{
char const *const name(xml_get_attribute_string_with_subst(device.machine(), viewnode, "name", ""));
if (&device == &device.machine().root_device())
{
return name;
}
else
{
char const *tag(device.tag());
if (':' == *tag)
++tag;
return util::string_format("%s %s", tag, name);
}
}
//**************************************************************************
@ -2632,20 +2648,21 @@ void layout_view::add_items(
//-------------------------------------------------
layout_view::item::item(
running_machine &machine,
device_t &device,
util::xml::data_node const &itemnode,
element_map &elemmap,
render_bounds const &transform)
: m_element(nullptr)
, m_output(machine.root_device(), xml_get_attribute_string_with_subst(machine, itemnode, "name", ""))
, m_have_output(xml_get_attribute_string_with_subst(machine, itemnode, "name", "")[0])
, m_input_tag(xml_get_attribute_string_with_subst(machine, itemnode, "inputtag", ""))
, m_output(device, xml_get_attribute_string_with_subst(device.machine(), itemnode, "name", ""))
, m_have_output(xml_get_attribute_string_with_subst(device.machine(), itemnode, "name", "")[0])
, m_input_tag(xml_get_attribute_string_with_subst(device.machine(), itemnode, "inputtag", ""))
, m_input_port(nullptr)
, m_input_mask(0)
, m_screen(nullptr)
, m_orientation(ROT0)
{
// find the associated element
running_machine &machine(device.machine());
char const *const name = xml_get_attribute_string_with_subst(machine, itemnode, "element", nullptr);
if (name)
{
@ -2676,22 +2693,25 @@ layout_view::item::item(
// sanity checks
if (strcmp(itemnode.get_name(), "screen") == 0)
{
char const *const tag(itemnode.get_attribute_string("tag", nullptr));
if (tag)
m_screen = dynamic_cast<screen_device *>(machine.root_device().subdevice(tag));
if (!m_screen)
if (itemnode.has_attribute("tag"))
{
char const *const tag(xml_get_attribute_string_with_subst(machine, itemnode, "tag", ""));
m_screen = dynamic_cast<screen_device *>(device.subdevice(tag));
if (!m_screen)
throw layout_reference_error(util::string_format("invalid screen tag '%d'", tag));
}
else if (!m_screen)
{
throw layout_reference_error(util::string_format("invalid screen index %d", index));
}
}
else
else if (!m_element)
{
if (m_element == nullptr)
throw layout_syntax_error(util::string_format("item of type %s require an element tag", itemnode.get_name()));
throw layout_syntax_error(util::string_format("item of type %s require an element tag", itemnode.get_name()));
}
if (has_input())
{
m_input_port = m_element->machine().root_device().ioport(m_input_tag.c_str());
}
m_input_port = device.ioport(m_input_tag.c_str());
}
@ -2766,10 +2786,11 @@ void layout_view::item::resolve_tags()
// layout_file - constructor
//-------------------------------------------------
layout_file::layout_file(running_machine &machine, util::xml::data_node const &rootnode, const char *dirname)
layout_file::layout_file(device_t &device, util::xml::data_node const &rootnode, const char *dirname)
: m_elemmap()
, m_viewlist()
{
running_machine &machine(device.machine());
try
{
// find the layout node
@ -2814,7 +2835,7 @@ layout_file::layout_file(running_machine &machine, util::xml::data_node const &r
// if the error is allowed to propagate, the entire layout is dropped so you can't select the useful view
try
{
m_viewlist.emplace_back(machine, *viewnode, m_elemmap, groupmap);
m_viewlist.emplace_back(device, *viewnode, m_elemmap, groupmap);
}
catch (layout_reference_error const &err)
{

View File

@ -290,7 +290,7 @@ MACHINE_CONFIG_START(midcoin24cdjuke_state::midcoin24cdjuke)
MCFG_DEVICE_IO_MAP(midcoin24cdjuke_io)
MCFG_DEVICE_PERIODIC_INT_DRIVER(midcoin24cdjuke_state, irq0_line_hold, 500)
MCFG_DEFAULT_LAYOUT(layout_24cdjuke)
config.set_default_layout(layout_24cdjuke);
MCFG_DEVICE_ADD("ic11", I8255A, 0)
MCFG_I8255_IN_PORTA_CB(IOPORT("MD1"))

View File

@ -145,7 +145,7 @@ MACHINE_CONFIG_START(nixieclock_state::_4004clk)
cpu.set_ram_ports_map(&nixieclock_state::_4004clk_mp);
/* video hardware */
MCFG_DEFAULT_LAYOUT(layout_4004clk)
config.set_default_layout(layout_4004clk);
/* sound hardware */
SPEAKER(config, "speaker").front_center();

View File

@ -847,7 +847,7 @@ MACHINE_CONFIG_START(accomm_state::accomm)
MCFG_PALETTE_ADD( "palette", 16 )
MCFG_PALETTE_INIT_OWNER(accomm_state, accomm)
MCFG_DEFAULT_LAYOUT(layout_accomm)
config.set_default_layout(layout_accomm);
/* internal ram */
MCFG_RAM_ADD(RAM_TAG)

View File

@ -474,7 +474,7 @@ MACHINE_CONFIG_START(aces1_state::aces1)
MCFG_I8255_IN_PORTB_CB(READ8(*this, aces1_state, ic37_read_b)) // meters, extra lamp select
MCFG_I8255_IN_PORTC_CB(READ8(*this, aces1_state, ic37_read_c)) // reel write, extra lamp strobe
MCFG_DEFAULT_LAYOUT(layout_aces1)
config.set_default_layout(layout_aces1);
/* sound hardware */
SPEAKER(config, "mono").front_center();

View File

@ -269,7 +269,7 @@ MACHINE_CONFIG_START(acrnsys1_state::acrnsys1)
MCFG_DEVICE_ADD("maincpu", M6502, 1.008_MHz_XTAL) /* 1.008 MHz */
MCFG_DEVICE_PROGRAM_MAP(acrnsys1_map)
MCFG_DEFAULT_LAYOUT(layout_acrnsys1)
config.set_default_layout(layout_acrnsys1);
/* sound hardware */
SPEAKER(config, "mono").front_center();

View File

@ -191,7 +191,7 @@ MACHINE_CONFIG_START(aim65_state::aim65)
MCFG_DEVICE_ADD("maincpu", M6502, AIM65_CLOCK) /* 1 MHz */
MCFG_DEVICE_PROGRAM_MAP(aim65_mem)
MCFG_DEFAULT_LAYOUT(layout_aim65)
config.set_default_layout(layout_aim65);
/* alpha-numeric display */
MCFG_DEVICE_ADD("ds1", DL1416T, u32(0))

View File

@ -122,7 +122,7 @@ MACHINE_CONFIG_START(aim65_40_state::aim65_40)
MCFG_DEVICE_PROGRAM_MAP(aim65_40_mem)
/* video hardware */
MCFG_DEFAULT_LAYOUT(layout_aim65_40)
config.set_default_layout(layout_aim65_40);
/* sound hardware */

View File

@ -429,9 +429,9 @@ MACHINE_CONFIG_START(alesis_state::hr16)
MCFG_SCREEN_VBLANK_TIME(ATTOSECONDS_IN_USEC(2500)) /* not accurate */
MCFG_SCREEN_SIZE(6*16, 9*2)
MCFG_SCREEN_VISIBLE_AREA(0, 6*16-1, 0, 9*2-1)
MCFG_DEFAULT_LAYOUT(layout_lcd)
MCFG_SCREEN_UPDATE_DEVICE("hd44780", hd44780_device, screen_update)
MCFG_SCREEN_PALETTE("palette")
config.set_default_layout(layout_lcd);
MCFG_PALETTE_ADD_MONOCHROME("palette")
MCFG_PALETTE_INIT_OWNER(alesis_state, alesis)
@ -461,7 +461,7 @@ MACHINE_CONFIG_START(alesis_state::sr16)
MCFG_SCREEN_MODIFY("screen")
MCFG_SCREEN_SIZE(6*8, 9*2)
MCFG_SCREEN_VISIBLE_AREA(0, 6*8-1, 0, 9*2-1)
MCFG_DEFAULT_LAYOUT(layout_sr16)
config.set_default_layout(layout_sr16);
MCFG_DEVICE_MODIFY("hd44780")
MCFG_HD44780_LCD_SIZE(2, 8)

View File

@ -628,7 +628,7 @@ MACHINE_CONFIG_START(allied_state::allied)
MCFG_DEVICE_PROGRAM_MAP(allied_map)
/* Video */
MCFG_DEFAULT_LAYOUT(layout_allied)
config.set_default_layout(layout_allied);
/* Sound */
genpin_audio(config);

View File

@ -458,7 +458,7 @@ MACHINE_CONFIG_START(alphasmart_state::alphasmart)
MCFG_PALETTE_ADD("palette", 2)
MCFG_PALETTE_INIT_OWNER(alphasmart_state, alphasmart)
MCFG_DEFAULT_LAYOUT(layout_lcd)
config.set_default_layout(layout_lcd);
MCFG_NVRAM_ADD_0FILL("nvram")
MACHINE_CONFIG_END

View File

@ -299,7 +299,7 @@ MACHINE_CONFIG_START(alto2_state::alto2)
MCFG_SCREEN_UPDATE_DEVICE("maincpu", alto2_cpu_device, screen_update)
MCFG_SCREEN_PALETTE("palette")
MCFG_DEFAULT_LAYOUT( layout_vertical )
config.set_default_layout(layout_vertical);
MCFG_PALETTE_ADD_MONOCHROME("palette")

View File

@ -43,7 +43,7 @@ public:
: driver_device(mconfig, type, tag)
, m_maincpu(*this, "maincpu")
, m_digits(*this, "digit%u", 0U)
{ }
{ }
void amico2k(machine_config &config);
@ -221,7 +221,7 @@ MACHINE_CONFIG_START(amico2k_state::amico2k)
MCFG_DEVICE_PROGRAM_MAP(amico2k_mem)
/* video hardware */
MCFG_DEFAULT_LAYOUT( layout_amico2k )
config.set_default_layout(layout_amico2k);
MCFG_DEVICE_ADD("i8255", I8255, 0)
MCFG_I8255_IN_PORTA_CB(READ8(*this, amico2k_state, ppi_pa_r))

View File

@ -1098,7 +1098,7 @@ MACHINE_CONFIG_START(apollo_state::dsp3500)
MCFG_RAM_EXTRA_OPTIONS("4M,8M,16M,32M")
/* terminal hardware */
MCFG_DEFAULT_LAYOUT( layout_apollo_dsp )
config.set_default_layout(layout_apollo_dsp);
MACHINE_CONFIG_END
MACHINE_CONFIG_START(apollo_state::dn3500_19i)
@ -1156,7 +1156,7 @@ MACHINE_CONFIG_START(apollo_state::dsp3000)
MCFG_RAM_MODIFY("messram")
/* terminal hardware */
MCFG_DEFAULT_LAYOUT( layout_apollo_dsp )
config.set_default_layout(layout_apollo_dsp);
MACHINE_CONFIG_END
MACHINE_CONFIG_START(apollo_state::dn3000_19i)
@ -1197,7 +1197,7 @@ MACHINE_CONFIG_START(apollo_state::dsp5500)
MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.00)
/* terminal hardware */
MCFG_DEFAULT_LAYOUT( layout_apollo_dsp )
config.set_default_layout(layout_apollo_dsp);
MACHINE_CONFIG_END
MACHINE_CONFIG_START(apollo_state::dn5500_19i)

View File

@ -601,7 +601,7 @@ MACHINE_CONFIG_START(fp_state::fp)
MCFG_DEVICE_DISABLE()
/* video hardware */
MCFG_DEFAULT_LAYOUT( layout_apricotp )
config.set_default_layout(layout_apricotp);
MCFG_SCREEN_ADD(SCREEN_LCD_TAG, LCD)
MCFG_SCREEN_REFRESH_RATE(50)

View File

@ -466,7 +466,7 @@ MACHINE_CONFIG_START(atari_s1_state::atari_s1)
MCFG_SOUND_ROUTE(0, "dac", 1.0, DAC_VREF_POS_INPUT) MCFG_SOUND_ROUTE(0, "dac", -1.0, DAC_VREF_NEG_INPUT)
/* Video */
MCFG_DEFAULT_LAYOUT(layout_atari_s1)
config.set_default_layout(layout_atari_s1);
MCFG_TIMER_DRIVER_ADD_PERIODIC("nmi", atari_s1_state, nmi, attotime::from_hz(NMI_INT))
MCFG_TIMER_DRIVER_ADD_PERIODIC("timer_s", atari_s1_state, timer_s, attotime::from_hz(AUDIO_CLK))

View File

@ -497,7 +497,7 @@ MACHINE_CONFIG_START(atari_s2_state::atari_s2)
MCFG_SOUND_ROUTE(0, "dac1", 1.0, DAC_VREF_POS_INPUT) MCFG_SOUND_ROUTE(0, "dac1", -1.0, DAC_VREF_NEG_INPUT)
/* Video */
MCFG_DEFAULT_LAYOUT(layout_atari_s2)
config.set_default_layout(layout_atari_s2);
MCFG_TIMER_DRIVER_ADD_PERIODIC("irq", atari_s2_state, irq, attotime::from_hz(XTAL(4'000'000) / 8192))
MCFG_TIMER_DRIVER_ADD_PERIODIC("timer_s", atari_s2_state, timer_s, attotime::from_hz(150000))

View File

@ -778,7 +778,7 @@ MACHINE_CONFIG_START(avigo_state::avigo)
MCFG_SCREEN_VISIBLE_AREA(0, AVIGO_SCREEN_WIDTH-1, 0, AVIGO_SCREEN_HEIGHT + AVIGO_PANEL_HEIGHT -1)
MCFG_SCREEN_PALETTE("palette")
MCFG_DEFAULT_LAYOUT(layout_avigo)
config.set_default_layout(layout_avigo);
MCFG_DEVICE_ADD("gfxdecode", GFXDECODE, "palette", gfx_avigo)
MCFG_PALETTE_ADD("palette", AVIGO_NUM_COLOURS)

View File

@ -238,7 +238,7 @@ MACHINE_CONFIG_START(babbage_state::babbage)
MCFG_Z80_DAISY_CHAIN(babbage_daisy_chain)
/* video hardware */
MCFG_DEFAULT_LAYOUT(layout_babbage)
config.set_default_layout(layout_babbage);
/* Devices */
MCFG_DEVICE_ADD("z80ctc", Z80CTC, MAIN_CLOCK)

View File

@ -437,7 +437,7 @@ MACHINE_CONFIG_START(backfire_state::backfire)
MCFG_PALETTE_FORMAT(xBBBBBGGGGGRRRRR)
MCFG_DEVICE_ADD("gfxdecode", GFXDECODE, "palette", gfx_backfire)
MCFG_DEFAULT_LAYOUT(layout_dualhsxs)
config.set_default_layout(layout_dualhsxs);
MCFG_SCREEN_ADD("lscreen", RASTER)
MCFG_SCREEN_REFRESH_RATE(60)

View File

@ -316,7 +316,7 @@ MACHINE_CONFIG_START(barata_state::barata)
MCFG_MCS51_PORT_P2_OUT_CB(WRITE8(*this, barata_state, port2_w))
MCFG_MCS51_PORT_P3_OUT_CB(WRITE8(*this, barata_state, fpga_w))
MCFG_DEFAULT_LAYOUT( layout_barata )
config.set_default_layout(layout_barata);
/* sound hardware */
SPEAKER(config, "speaker").front_center();

View File

@ -870,7 +870,7 @@ MACHINE_CONFIG_START(bbc_state::bbca)
MCFG_VIDEO_START_OVERRIDE(bbc_state, bbc)
MCFG_DEFAULT_LAYOUT(layout_bbc)
config.set_default_layout(layout_bbc);
/* sound hardware */
SPEAKER(config, "mono").front_center();
@ -1313,7 +1313,7 @@ MACHINE_CONFIG_START(bbc_state::bbcm)
MCFG_MACHINE_START_OVERRIDE(bbc_state, bbcm)
MCFG_MACHINE_RESET_OVERRIDE(bbc_state, bbcm)
MCFG_DEFAULT_LAYOUT(layout_bbcm)
config.set_default_layout(layout_bbcm);
/* video hardware */
MCFG_SCREEN_ADD("screen", RASTER)

View File

@ -350,7 +350,7 @@ MACHINE_CONFIG_START(beta_state::beta)
MCFG_DEVICE_PROGRAM_MAP(beta_mem)
/* video hardware */
MCFG_DEFAULT_LAYOUT( layout_beta )
config.set_default_layout(layout_beta);
/* sound hardware */
SPEAKER(config, "mono").front_center();

View File

@ -1089,7 +1089,7 @@ MACHINE_CONFIG_START(bfm_sc1_state::scorpion1)
MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25)
MCFG_NVRAM_ADD_0FILL("nvram")
MCFG_DEFAULT_LAYOUT(layout_sc1_vfd)
config.set_default_layout(layout_sc1_vfd);
MCFG_DEVICE_ADD("reel0", REEL, STARPOINT_48STEP_REEL, 1, 3, 0x09, 4)
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(*this, bfm_sc1_state, reel_optic_cb<0>))
@ -1118,7 +1118,7 @@ MACHINE_CONFIG_START(bfm_sc1_state::scorpion1_adder2)
MCFG_DEVICE_MODIFY("maincpu")
MCFG_DEVICE_PROGRAM_MAP(sc1_adder2) // setup read and write memorymap
MCFG_DEFAULT_LAYOUT(layout_sc1_vid)
config.set_default_layout(layout_sc1_vid);
MCFG_BFM_ADDER2_ADD("adder2")
MACHINE_CONFIG_END

View File

@ -2292,7 +2292,7 @@ MACHINE_CONFIG_START(bfm_sc2_vid_state::scorpion2_vid)
MCFG_NVRAM_ADD_0FILL("nvram")
MCFG_NVRAM_ADD_CUSTOM_DRIVER("e2ram", bfm_sc2_vid_state, e2ram_init)
MCFG_DEFAULT_LAYOUT(layout_sc2_vid)
config.set_default_layout(layout_sc2_vid);
MCFG_BFM_ADDER2_ADD("adder2")
@ -3771,7 +3771,7 @@ MACHINE_CONFIG_START(bfm_sc2_awp_state::scorpion2)
MCFG_NVRAM_ADD_CUSTOM_DRIVER("e2ram", bfm_sc2_awp_state, e2ram_init)
/* video hardware */
MCFG_DEFAULT_LAYOUT(layout_sc2_vfd)
config.set_default_layout(layout_sc2_vfd);
MCFG_DEVICE_ADD("reel0", REEL, STARPOINT_48STEP_REEL, 1, 3, 0x09, 4)
MCFG_STEPPER_OPTIC_CALLBACK(WRITELINE(*this, bfm_sc2_awp_state, reel_optic_cb<0>))
@ -3828,7 +3828,7 @@ MACHINE_CONFIG_START(bfm_sc2_dmd_state::scorpion2_dm01)
MCFG_NVRAM_ADD_CUSTOM_DRIVER("e2ram", bfm_sc2_dmd_state, e2ram_init)
/* video hardware */
MCFG_DEFAULT_LAYOUT(layout_sc2_dmd)
config.set_default_layout(layout_sc2_dmd);
MCFG_DEVICE_ADD("dm01", BFM_DM01, 0)
MCFG_BFM_DM01_BUSY_CB(WRITELINE(*this, bfm_sc2_dmd_state, bfmdm01_busy))

View File

@ -913,7 +913,7 @@ MACHINE_CONFIG_START(sc4_state::sc4_common)
MCFG_BFMBDA_ADD("vfd0",0)
// MCFG_DEFAULT_LAYOUT(layout_bfm_sc4)
// config.set_default_layout(layout_bfm_sc4);
MCFG_DEVICE_ADD("ymz", YMZ280B, 16000000) // ?? Mhz
MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.0)
@ -1262,7 +1262,7 @@ MACHINE_CONFIG_START(sc4_state::sc4dmd)
sc4_common(config);
/* video hardware */
//MCFG_DEFAULT_LAYOUT(layout_sc4_dmd)
//config.set_default_layout(layout_sc4_dmd);
MCFG_DEVICE_ADD("dm01", BFM_DM01, 0)
MCFG_BFM_DM01_BUSY_CB(WRITELINE(*this, sc4_state, bfmdm01_busy))

View File

@ -227,7 +227,7 @@ MACHINE_CONFIG_START(bfm_sc5_state::bfm_sc5)
MCFG_BFMBDA_ADD("vfd0",0)
MCFG_DEFAULT_LAYOUT(layout_bfm_sc5)
config.set_default_layout(layout_bfm_sc5);
MCFG_DEVICE_ADD("ymz", YMZ280B, 16000000) // ?? Mhz
MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.0)

View File

@ -422,7 +422,7 @@ MACHINE_CONFIG_START(bfmsys85_state::bfmsys85)
MCFG_DEVICE_ADD("meters", METERS, 0)
MCFG_METERS_NUMBER(8)
MCFG_DEFAULT_LAYOUT(layout_bfmsys85)
config.set_default_layout(layout_bfmsys85);
MACHINE_CONFIG_END
// input ports for system85 board /////////////////////////////////////////

View File

@ -832,7 +832,7 @@ MACHINE_CONFIG_START(bnstars_state::bnstars)
MCFG_PALETTE_FORMAT(XBRG)
MCFG_PALETTE_MEMBITS(16)
MCFG_DEFAULT_LAYOUT(layout_dualhsxs)
config.set_default_layout(layout_dualhsxs);
MCFG_SCREEN_ADD("lscreen", RASTER)
MCFG_SCREEN_REFRESH_RATE(60)

View File

@ -216,7 +216,7 @@ MACHINE_CONFIG_START(bob85_state::bob85)
MCFG_I8085A_SOD(WRITELINE(*this, bob85_state, sod_w))
/* video hardware */
MCFG_DEFAULT_LAYOUT(layout_bob85)
config.set_default_layout(layout_bob85);
// devices
MCFG_CASSETTE_ADD("cassette")

View File

@ -550,7 +550,7 @@ MACHINE_CONFIG_START(bw2_state::bw2)
MCFG_DEVICE_IO_MAP(bw2_io)
// video hardware
MCFG_DEFAULT_LAYOUT(layout_lcd)
config.set_default_layout(layout_lcd);
MCFG_SCREEN_ADD(SCREEN_TAG, LCD)
MCFG_SCREEN_REFRESH_RATE(60)
MCFG_SCREEN_UPDATE_DEVICE( MSM6255_TAG, msm6255_device, screen_update )

View File

@ -1001,7 +1001,7 @@ MACHINE_CONFIG_START(by17_state::by17)
MCFG_NVRAM_ADD_0FILL("nvram") // 'F' filled causes Credit Display to be blank on first startup
/* Video */
MCFG_DEFAULT_LAYOUT(layout_by17)
config.set_default_layout(layout_by17);
/* Sound */
genpin_audio(config);

View File

@ -1100,7 +1100,7 @@ MACHINE_CONFIG_START(by35_state::by35)
MCFG_NVRAM_ADD_0FILL("nvram") // 'F' filled causes Credit Display to be blank on first startup
/* Video */
MCFG_DEFAULT_LAYOUT(layout_by35)
config.set_default_layout(layout_by35);
/* Sound */
genpin_audio(config);

View File

@ -387,7 +387,7 @@ MACHINE_CONFIG_START(by6803_state::by6803)
MCFG_NVRAM_ADD_0FILL("nvram")
/* Video */
//MCFG_DEFAULT_LAYOUT(layout_by6803)
//config.set_default_layout(layout_by6803);
/* Sound */
genpin_audio(config);

View File

@ -262,7 +262,7 @@ MACHINE_CONFIG_START(c80_state::c80)
MCFG_Z80_DAISY_CHAIN(c80_daisy_chain)
/* video hardware */
MCFG_DEFAULT_LAYOUT( layout_c80 )
config.set_default_layout(layout_c80);
/* devices */
MCFG_DEVICE_ADD(Z80PIO1_TAG, Z80PIO, 2500000)

View File

@ -355,7 +355,7 @@ MACHINE_CONFIG_START(cardline_state::cardline)
MCFG_MC6845_OUT_HSYNC_CB(WRITELINE(*this, cardline_state, hsync_changed))
MCFG_MC6845_OUT_VSYNC_CB(WRITELINE(*this, cardline_state, vsync_changed))
MCFG_DEFAULT_LAYOUT(layout_cardline)
config.set_default_layout(layout_cardline);
/* sound hardware */
SPEAKER(config, "lspeaker").front_left();

View File

@ -2651,7 +2651,7 @@ MACHINE_CONFIG_START(cave_state::ppsatan)
MCFG_DEVICE_ADD("gfxdecode", GFXDECODE, "palette", gfx_ppsatan)
MCFG_PALETTE_ADD("palette", 0x8000)
MCFG_PALETTE_INIT_OWNER(cave_state,ppsatan)
MCFG_DEFAULT_LAYOUT(layout_ppsatan)
config.set_default_layout(layout_ppsatan);
MCFG_VIDEO_START_OVERRIDE(cave_state,cave_3_layers)

View File

@ -600,7 +600,7 @@ MACHINE_CONFIG_START(cc40_state::cc40)
MCFG_SCREEN_VBLANK_TIME(ATTOSECONDS_IN_USEC(2500))
MCFG_SCREEN_SIZE(6*31+1, 9*1+1+1)
MCFG_SCREEN_VISIBLE_AREA(0, 6*31, 0, 9*1+1)
MCFG_DEFAULT_LAYOUT(layout_cc40)
config.set_default_layout(layout_cc40);
MCFG_SCREEN_UPDATE_DEVICE("hd44780", hd44780_device, screen_update)
MCFG_SCREEN_PALETTE("palette")

View File

@ -771,7 +771,7 @@ MACHINE_CONFIG_START(cdi_state::cdimono1_base)
MCFG_PALETTE_ADD("palette", 0x100)
MCFG_DEFAULT_LAYOUT(layout_cdi)
config.set_default_layout(layout_cdi);
MCFG_DEVICE_ADD("scc68070", CDI_68070, 0, "maincpu")
@ -819,7 +819,7 @@ MACHINE_CONFIG_START(cdi_state::cdimono2)
MCFG_PALETTE_ADD("palette", 0x100)
MCFG_DEFAULT_LAYOUT(layout_cdi)
config.set_default_layout(layout_cdi);
MCFG_MACHINE_RESET_OVERRIDE( cdi_state, cdimono2 )
@ -874,7 +874,7 @@ MACHINE_CONFIG_START(cdi_state::cdi910)
MCFG_PALETTE_ADD("palette", 0x100)
MCFG_DEFAULT_LAYOUT(layout_cdi)
config.set_default_layout(layout_cdi);
MCFG_MACHINE_RESET_OVERRIDE( cdi_state, cdimono2 )

View File

@ -267,7 +267,7 @@ MACHINE_CONFIG_START(cesclassic_state::cesclassic)
MCFG_SCREEN_UPDATE_DRIVER(cesclassic_state, screen_update)
MCFG_SCREEN_SIZE(8*16*2, 8*8+3*8)
MCFG_SCREEN_VISIBLE_AREA(0*8, 8*16*2-1, 0*8, 8*8-1)
MCFG_DEFAULT_LAYOUT( layout_lcd )
config.set_default_layout(layout_lcd);
MCFG_PALETTE_ADD("palette", 4)
MCFG_PALETTE_INIT_OWNER(cesclassic_state, cesclassic)

View File

@ -300,7 +300,7 @@ MACHINE_CONFIG_START(cfx9850_state::cfx9850)
MCFG_SCREEN_UPDATE_DRIVER(cfx9850_state, screen_update_cfx9850)
MCFG_SCREEN_PALETTE("palette")
MCFG_DEFAULT_LAYOUT(layout_lcd)
config.set_default_layout(layout_lcd);
// TODO: Verify amount of colors and palette. Colors can be changed by changing the contrast.
MCFG_PALETTE_ADD("palette", 4)

View File

@ -395,7 +395,7 @@ MACHINE_CONFIG_START(chessmst_state::chessmst)
MCFG_Z80PIO_IN_PA_CB(READ8(*this, chessmst_state, pio2_port_a_r))
MCFG_Z80PIO_OUT_PB_CB(WRITE8(*this, chessmst_state, pio2_port_b_w))
MCFG_DEFAULT_LAYOUT(layout_chessmst)
config.set_default_layout(layout_chessmst);
/* sound hardware */
SPEAKER(config, "mono").front_center();
@ -420,7 +420,7 @@ MACHINE_CONFIG_START(chessmst_state::chessmsta)
MCFG_Z80PIO_IN_PA_CB(READ8(*this, chessmst_state, pio2_port_a_r))
MCFG_Z80PIO_OUT_PB_CB(WRITE8(*this, chessmst_state, pio2_port_b_w))
MCFG_DEFAULT_LAYOUT(layout_chessmst)
config.set_default_layout(layout_chessmst);
/* sound hardware */
SPEAKER(config, "mono").front_center();
@ -446,7 +446,7 @@ MACHINE_CONFIG_START(chessmst_state::chessmstdm)
MCFG_Z80PIO_IN_PA_CB(READ8(*this, chessmst_state, pio2_port_a_r))
MCFG_Z80PIO_OUT_PB_CB(WRITE8(*this, chessmst_state, pio2_port_b_w))
MCFG_DEFAULT_LAYOUT(layout_chessmstdm)
config.set_default_layout(layout_chessmstdm);
MCFG_DEVICE_ADD("555_timer", CLOCK, 500) // from 555 timer
MCFG_CLOCK_SIGNAL_HANDLER(WRITELINE(*this, chessmst_state, timer_555_w))

View File

@ -278,7 +278,7 @@ MACHINE_CONFIG_START(chesstrv_state::chesstrv)
MCFG_DEVICE_IO_MAP( chesstrv_io )
/* video hardware */
MCFG_DEFAULT_LAYOUT( layout_chesstrv )
config.set_default_layout(layout_chesstrv);
MACHINE_CONFIG_END
MACHINE_CONFIG_START(borisdpl_state::borisdpl)
@ -288,7 +288,7 @@ MACHINE_CONFIG_START(borisdpl_state::borisdpl)
MCFG_DEVICE_IO_MAP( borisdpl_io )
/* video hardware */
MCFG_DEFAULT_LAYOUT( layout_borisdpl )
config.set_default_layout(layout_borisdpl);
//MCFG_TIMER_DRIVER_ADD_PERIODIC("timer_interrupt", borisdpl_state, timer_interrupt, attotime::from_hz(40))
MACHINE_CONFIG_END

View File

@ -351,7 +351,7 @@ MACHINE_CONFIG_START(chexx_state::chexx83)
MCFG_VIA6522_IRQ_HANDLER(WRITELINE(*this, chexx_state, via_irq_out))
// Layout
MCFG_DEFAULT_LAYOUT(layout_chexx)
config.set_default_layout(layout_chexx);
// sound hardware
SPEAKER(config, "mono").front_center();

View File

@ -2259,7 +2259,7 @@ MACHINE_CONFIG_START(cischeat_state::captflag)
MCFG_TIMER_ADD_NONE("motor_right")
// Layout
MCFG_DEFAULT_LAYOUT(layout_captflag)
config.set_default_layout(layout_captflag);
/* sound hardware */
SPEAKER(config, "lspeaker").front_left();

View File

@ -447,7 +447,7 @@ MACHINE_CONFIG_START(ckz80_state::master)
MCFG_ADDRESS_MAP_BANK_ADDR_WIDTH(16)
MCFG_TIMER_DRIVER_ADD_PERIODIC("display_decay", ckz80_state, display_decay_tick, attotime::from_msec(1))
MCFG_DEFAULT_LAYOUT(layout_ck_master)
config.set_default_layout(layout_ck_master);
/* sound hardware */
SPEAKER(config, "speaker").front_center();

View File

@ -815,7 +815,7 @@ MACHINE_CONFIG_START(clcd_state::clcd)
MCFG_SCREEN_VISIBLE_AREA(0, 480-1, 0, 128-1)
MCFG_SCREEN_PALETTE("palette")
MCFG_DEFAULT_LAYOUT(layout_lcd)
config.set_default_layout(layout_lcd);
MCFG_PALETTE_ADD("palette", 2)
MCFG_PALETTE_INIT_OWNER(clcd_state, clcd)

View File

@ -290,7 +290,7 @@ MACHINE_CONFIG_START(coco3_state::coco3)
MCFG_COCO_VHD_ADD(VHD1_TAG)
// video hardware
MCFG_DEFAULT_LAYOUT(layout_coco3)
config.set_default_layout(layout_coco3);
MCFG_DEVICE_ADD(GIME_TAG, GIME_NTSC, XTAL(28'636'363), MAINCPU_TAG, RAM_TAG, CARTRIDGE_TAG, MAINCPU_TAG)
MCFG_GIME_HSYNC_CALLBACK(WRITELINE(PIA0_TAG, pia6821_device, ca1_w))

View File

@ -3308,7 +3308,7 @@ MACHINE_CONFIG_START(coolridr_state::coolridr)
MCFG_PALETTE_ADD_RRRRRGGGGGBBBBB("palette")
MCFG_DEFAULT_LAYOUT(layout_dualhsxs)
config.set_default_layout(layout_dualhsxs);
SPEAKER(config, "lspeaker").front_left();
SPEAKER(config, "rspeaker").front_right();

View File

@ -522,7 +522,7 @@ MACHINE_CONFIG_START(cosmicos_state::cosmicos)
MCFG_COSMAC_SC_CALLBACK(WRITE8(*this, cosmicos_state, sc_w))
/* video hardware */
MCFG_DEFAULT_LAYOUT( layout_cosmicos )
config.set_default_layout(layout_cosmicos);
MCFG_DEVICE_ADD(DM9368_TAG, DM9368, 0)
MCFG_TIMER_DRIVER_ADD_PERIODIC("digit", cosmicos_state, digit_tick, attotime::from_hz(100))
MCFG_TIMER_DRIVER_ADD_PERIODIC("interrupt", cosmicos_state, int_tick, attotime::from_hz(1000))

View File

@ -285,7 +285,7 @@ MACHINE_CONFIG_START(cp1_state::cp1)
MCFG_DEVICE_ADD("i8155_cp3", I8155, 0)
MCFG_DEFAULT_LAYOUT(layout_cp1)
config.set_default_layout(layout_cp1);
MCFG_CASSETTE_ADD("cassette")

View File

@ -141,7 +141,7 @@ MACHINE_CONFIG_START(cvicny_state::cvicny)
MCFG_DEVICE_PROGRAM_MAP(cvicny_mem)
/* video hardware */
MCFG_DEFAULT_LAYOUT(layout_cvicny)
config.set_default_layout(layout_cvicny);
MACHINE_CONFIG_END
/* ROM definition */

View File

@ -407,7 +407,7 @@ MACHINE_CONFIG_START(cxgz80_state::ch2001)
MCFG_TIMER_DRIVER_ADD("speaker_off", cxgz80_state, speaker_off_callback)
MCFG_TIMER_DRIVER_ADD_PERIODIC("display_decay", cxgz80_state, display_decay_tick, attotime::from_msec(1))
MCFG_DEFAULT_LAYOUT(layout_cxg_ch2001)
config.set_default_layout(layout_cxg_ch2001);
/* sound hardware */
SPEAKER(config, "speaker").front_center();

View File

@ -828,7 +828,7 @@ MACHINE_CONFIG_START(cybertnk_state::cybertnk)
MCFG_QUANTUM_TIME(attotime::from_hz(60000))//arbitrary value,needed to get the communication to work
/* video hardware */
MCFG_DEFAULT_LAYOUT(layout_dualhsxs)
config.set_default_layout(layout_dualhsxs);
MCFG_SCREEN_ADD("lscreen", RASTER)
MCFG_SCREEN_REFRESH_RATE(60)

View File

@ -409,7 +409,7 @@ MACHINE_CONFIG_START(cybiko_state::cybikov1)
MCFG_SCREEN_PALETTE("hd66421:palette")
// video
MCFG_HD66421_ADD("hd66421")
MCFG_DEFAULT_LAYOUT(layout_lcd)
config.set_default_layout(layout_lcd);
// sound
SPEAKER(config, "mono").front_center();
MCFG_DEVICE_ADD("speaker", SPEAKER_SOUND)

View File

@ -407,7 +407,7 @@ MACHINE_CONFIG_START( cz101_state::cz101 )
MCFG_HD44780_LCD_SIZE(2, 16)
MCFG_HD44780_PIXEL_UPDATE_CB(cz101_state, lcd_pixel_update)
MCFG_DEFAULT_LAYOUT(layout_cz101)
config.set_default_layout(layout_cz101);
MACHINE_CONFIG_END

View File

@ -730,7 +730,7 @@ MACHINE_CONFIG_START(darius_state::darius)
MCFG_DEVICE_ADD("gfxdecode", GFXDECODE, "palette", gfx_darius)
MCFG_PALETTE_ADD("palette", 2048)
MCFG_PALETTE_FORMAT(xBBBBBGGGGGRRRRR)
MCFG_DEFAULT_LAYOUT(layout_darius)
config.set_default_layout(layout_darius);
MCFG_SCREEN_ADD("lscreen", RASTER)
MCFG_SCREEN_REFRESH_RATE(60)

View File

@ -131,7 +131,7 @@ MACHINE_CONFIG_START(daruma_state::daruma)
MCFG_SOUND_ROUTE(0, "mono", 1.00)
/* TODO:
MCFG_DEFAULT_LAYOUT(layout_daruma)
config.set_default_layout(layout_daruma);
Motors: MTA011
http://pdf.datasheetcatalog.com/datasheet/Shindengen/mXstzvq.pdf

View File

@ -189,7 +189,7 @@ MACHINE_CONFIG_START(datum_state::datum)
MCFG_DEVICE_PROGRAM_MAP(datum_mem)
/* video hardware */
MCFG_DEFAULT_LAYOUT(layout_datum)
config.set_default_layout(layout_datum);
/* Devices */
MCFG_DEVICE_ADD("pia1", PIA6821, 0) // keyboard & display

View File

@ -627,7 +627,7 @@ MACHINE_CONFIG_START(dbox_state::dbox)
/* LED Matrix Display */
MCFG_SDA5708_ADD("display")
MCFG_DEFAULT_LAYOUT(layout_sda5708)
config.set_default_layout(layout_sda5708);
/* IP16 74256 8 bit latch */
MCFG_LATCH8_ADD("hct259.ip16")
MCFG_LATCH8_WRITE_4(WRITELINE("display", sda5708_device, reset_w))

View File

@ -554,7 +554,7 @@ MACHINE_CONFIG_START(de_2_state::de_type1)
MCFG_DECOCPU_LAMP(WRITE8(*this, de_2_state,lamps_w))
/* Video */
MCFG_DEFAULT_LAYOUT(layout_de2)
config.set_default_layout(layout_de2);
genpin_audio(config);
de_bg_audio(config);
@ -569,7 +569,7 @@ MACHINE_CONFIG_START(de_2_state::de_type2)
MCFG_DECOCPU_LAMP(WRITE8(*this, de_2_state,lamps_w))
/* Video */
MCFG_DEFAULT_LAYOUT(layout_de2)
config.set_default_layout(layout_de2);
genpin_audio(config);
de_bg_audio(config);
@ -584,7 +584,7 @@ MACHINE_CONFIG_START(de_2_state::de_type2_alpha3)
MCFG_DECOCPU_LAMP(WRITE8(*this, de_2_state,lamps_w))
/* Video */
MCFG_DEFAULT_LAYOUT(layout_de2a3)
config.set_default_layout(layout_de2a3);
genpin_audio(config);
de_bg_audio(config);
@ -599,7 +599,7 @@ MACHINE_CONFIG_START(de_2_state::de_type3)
MCFG_DECOCPU_LAMP(WRITE8(*this, de_2_state,lamps_w))
/* Video */
MCFG_DEFAULT_LAYOUT(layout_de2a3)
config.set_default_layout(layout_de2a3);
genpin_audio(config);
de_bg_audio(config);

View File

@ -439,7 +439,7 @@ MACHINE_CONFIG_START(decwriter_state::la120)
m_ledlatch->q_out_cb<6>().set_output("led7").invert(); // SETUP
m_ledlatch->q_out_cb<7>().set_output("led8").invert(); // PAPER OUT
//MCFG_DEFAULT_LAYOUT( layout_la120 )
//config.set_default_layout(layout_la120);
/* audio hardware */
SPEAKER(config, "mono").front_center();

View File

@ -280,7 +280,7 @@ MACHINE_CONFIG_START(destiny_state::destiny)
MCFG_SCREEN_VBLANK_TIME(ATTOSECONDS_IN_USEC(2500)) /* not accurate */
MCFG_SCREEN_SIZE(6*16, 9*2)
MCFG_SCREEN_VISIBLE_AREA(0, 6*16-1, 0, 9*2-1)
MCFG_DEFAULT_LAYOUT(layout_lcd)
config.set_default_layout(layout_lcd);
MCFG_SCREEN_UPDATE_DRIVER(destiny_state, screen_update_destiny)
MCFG_SCREEN_PALETTE("palette")

View File

@ -584,7 +584,7 @@ TIMER_DEVICE_CALLBACK_MEMBER(didact_state::scan_artwork)
MACHINE_CONFIG_START(md6802_state::md6802)
MCFG_DEVICE_ADD("maincpu", M6802, XTAL(4'000'000))
MCFG_DEVICE_PROGRAM_MAP(md6802_map)
MCFG_DEFAULT_LAYOUT(layout_md6802)
config.set_default_layout(layout_md6802);
/* Devices */
MCFG_DEVICE_ADD("tb16_74145", TTL74145, 0)
@ -619,7 +619,7 @@ MACHINE_CONFIG_START(mp68a_state::mp68a)
// Trimpot seems broken/stuck at 5K Ohm thu. ROM code 1Ms delay loops suggest 1MHz+
MCFG_DEVICE_ADD("maincpu", M6800, 505000)
MCFG_DEVICE_PROGRAM_MAP(mp68a_map)
MCFG_DEFAULT_LAYOUT(layout_mp68a)
config.set_default_layout(layout_mp68a);
/* Devices */
/* PIA #1 0x500-0x503 - used differently by laborations and loaded software */

View File

@ -640,7 +640,7 @@ MACHINE_CONFIG_START(digel804_state::digel804)
MCFG_ROC10937_ADD("vfd",0) // RIGHT_TO_LEFT
/* video hardware */
MCFG_DEFAULT_LAYOUT(layout_digel804)
config.set_default_layout(layout_digel804);
MCFG_DEVICE_ADD("74c923", MM74C923, 0)
MCFG_MM74C922_DA_CALLBACK(WRITELINE(*this, digel804_state, da_w))

View File

@ -798,7 +798,7 @@ MACHINE_CONFIG_START(dmv_state::dmv)
MCFG_DEVICE_ADD("gfxdecode", GFXDECODE, "palette", gfx_dmv)
MCFG_PALETTE_ADD_3BIT_RGB("palette")
MCFG_DEFAULT_LAYOUT(layout_dmv)
config.set_default_layout(layout_dmv);
// devices
MCFG_DEVICE_ADD("upd7220", UPD7220, XTAL(5'000'000)/2) // unk clock

View File

@ -242,7 +242,7 @@ MACHINE_CONFIG_START(dauphin_state::dauphin)
MCFG_S2650_FLAG_OUTPUT(WRITELINE(*this, dauphin_state, cass_w))
/* video hardware */
MCFG_DEFAULT_LAYOUT(layout_dolphunk)
config.set_default_layout(layout_dolphunk);
/* sound hardware */
SPEAKER(config, "mono").front_center();

View File

@ -4718,7 +4718,7 @@ MACHINE_CONFIG_START(dynax_state::jantouki)
/* video hardware */
MCFG_PALETTE_ADD("palette", 512)
MCFG_PALETTE_INIT_OWNER(dynax_state,sprtmtch) // static palette
MCFG_DEFAULT_LAYOUT(layout_dualhuov)
config.set_default_layout(layout_dualhuov);
screen_device &top(SCREEN(config, "top", SCREEN_TYPE_RASTER));
top.set_refresh_hz(60);

View File

@ -250,7 +250,7 @@ MACHINE_CONFIG_START(eacc_state::eacc)
MCFG_DEVICE_ADD("maincpu", M6802, XTAL(3'579'545)) /* Divided by 4 inside the m6802*/
MCFG_DEVICE_PROGRAM_MAP(eacc_mem)
MCFG_DEFAULT_LAYOUT(layout_eacc)
config.set_default_layout(layout_eacc);
MCFG_DEVICE_ADD("pia", PIA6821, 0)
MCFG_PIA_READPB_HANDLER(READ8(*this, eacc_state, eacc_keyboard_r))

View File

@ -503,7 +503,7 @@ MACHINE_CONFIG_START(ecoinf2_state::ecoinf2_oxo)
MCFG_DEVICE_PROGRAM_MAP(oxo_memmap)
MCFG_DEVICE_IO_MAP(oxo_portmap)
MCFG_DEFAULT_LAYOUT(layout_ecoinf2)
config.set_default_layout(layout_ecoinf2);
MCFG_DEVICE_ADD("ic10_lamp", I8255, 0)
MCFG_I8255_OUT_PORTA_CB(WRITE8(*this, ecoinf2_state, ppi8255_ic10_write_a_strobedat0))

View File

@ -667,7 +667,7 @@ MACHINE_CONFIG_START(ecoinf3_state::ecoinf3_pyramid)
MCFG_DEVICE_PROGRAM_MAP(pyramid_memmap)
MCFG_DEVICE_IO_MAP(pyramid_portmap)
MCFG_DEFAULT_LAYOUT(layout_ecoinf3)
config.set_default_layout(layout_ecoinf3);
SPEAKER(config, "mono").front_center();

View File

@ -789,7 +789,7 @@ MACHINE_CONFIG_START(ecoinfr_state::ecoinfr)
MCFG_DEVICE_IO_MAP(portmap)
MCFG_TIMER_DRIVER_ADD_PERIODIC("ectimer", ecoinfr_state, ecoinfr_irq_timer, attotime::from_hz(250))
MCFG_DEFAULT_LAYOUT(layout_ecoinfr)
config.set_default_layout(layout_ecoinfr);
MCFG_DEVICE_ADD(UPD8251_TAG, I8251, 0)

View File

@ -150,7 +150,7 @@ MACHINE_CONFIG_START(elekscmp_state::elekscmp)
MCFG_DEVICE_PROGRAM_MAP(mem_map)
/* video hardware */
MCFG_DEFAULT_LAYOUT(layout_elekscmp)
config.set_default_layout(layout_elekscmp);
MACHINE_CONFIG_END
/* ROM definition */

View File

@ -249,7 +249,7 @@ MACHINE_CONFIG_START(elf2_state::elf2)
MCFG_COSMAC_SC_CALLBACK(WRITE8(*this, elf2_state, sc_w))
/* video hardware */
MCFG_DEFAULT_LAYOUT(layout_elf2)
config.set_default_layout(layout_elf2);
MCFG_DEVICE_ADD(CDP1861_TAG, CDP1861, XTAL(3'579'545)/2)
MCFG_CDP1861_IRQ_CALLBACK(INPUTLINE(CDP1802_TAG, COSMAC_INPUT_LINE_INT))

View File

@ -57,8 +57,8 @@
class enmirage_state : public driver_device
{
public:
enmirage_state(const machine_config &mconfig, device_type type, const char *tag)
: driver_device(mconfig, type, tag),
enmirage_state(const machine_config &mconfig, device_type type, const char *tag) :
driver_device(mconfig, type, tag),
m_maincpu(*this, "maincpu"),
m_fdc(*this, "wd1772"),
m_floppy_connector(*this, "wd1772:0"),
@ -224,7 +224,7 @@ MACHINE_CONFIG_START(enmirage_state::mirage)
MCFG_DEVICE_ADD("maincpu", MC6809E, 2000000)
MCFG_DEVICE_PROGRAM_MAP(mirage_map)
MCFG_DEFAULT_LAYOUT( layout_mirage )
config.set_default_layout(layout_mirage);
SPEAKER(config, "lspeaker").front_left();
SPEAKER(config, "rspeaker").front_right();

View File

@ -225,7 +225,7 @@ MACHINE_CONFIG_START(et3400_state::et3400)
MCFG_DEVICE_PROGRAM_MAP(mem_map)
/* video hardware */
MCFG_DEFAULT_LAYOUT(layout_et3400)
config.set_default_layout(layout_et3400);
// Devices
MCFG_DEVICE_ADD("pia", PIA6821, 0)

View File

@ -192,11 +192,11 @@ MACHINE_CONFIG_START(fb01_state::fb01)
MCFG_SCREEN_VBLANK_TIME(ATTOSECONDS_IN_USEC(2500)) /* not accurate */
MCFG_SCREEN_SIZE(6*16, 9)
MCFG_SCREEN_VISIBLE_AREA(0, 6*16-1, 0, 9-1)
MCFG_DEFAULT_LAYOUT(layout_lcd)
MCFG_SCREEN_UPDATE_DEVICE("hd44780", hd44780_device, screen_update)
MCFG_SCREEN_PALETTE("palette")
MCFG_DEFAULT_LAYOUT( layout_fb01 )
config.set_default_layout(layout_lcd); // why set layout only to replace?
config.set_default_layout(layout_fb01);
MCFG_PALETTE_ADD("palette", 2)
MCFG_PALETTE_INIT_OWNER(fb01_state, fb01)

View File

@ -1849,7 +1849,7 @@ MACHINE_CONFIG_START(fidel6502_state::rsc)
MCFG_PIA_CB2_HANDLER(WRITELINE(*this, fidel6502_state, csc_pia1_cb2_w))
MCFG_TIMER_DRIVER_ADD_PERIODIC("display_decay", fidelbase_state, display_decay_tick, attotime::from_msec(1))
MCFG_DEFAULT_LAYOUT(layout_fidel_rsc_v2)
config.set_default_layout(layout_fidel_rsc_v2);
/* sound hardware */
SPEAKER(config, "speaker").front_center();
@ -1883,7 +1883,7 @@ MACHINE_CONFIG_START(fidel6502_state::csc)
MCFG_PIA_CB2_HANDLER(WRITELINE(*this, fidel6502_state, csc_pia1_cb2_w))
MCFG_TIMER_DRIVER_ADD_PERIODIC("display_decay", fidelbase_state, display_decay_tick, attotime::from_msec(1))
MCFG_DEFAULT_LAYOUT(layout_fidel_csc)
config.set_default_layout(layout_fidel_csc);
/* sound hardware */
SPEAKER(config, "speaker").front_center();
@ -1905,7 +1905,7 @@ MACHINE_CONFIG_START(fidel6502_state::su9)
MCFG_MACHINE_RESET_OVERRIDE(fidel6502_state, su9)
MCFG_DEFAULT_LAYOUT(layout_fidel_su9)
config.set_default_layout(layout_fidel_su9);
MACHINE_CONFIG_END
MACHINE_CONFIG_START(fidel6502_state::eas)
@ -1934,7 +1934,7 @@ MACHINE_CONFIG_START(fidel6502_state::eas)
MCFG_NVRAM_ADD_0FILL("nvram")
MCFG_TIMER_DRIVER_ADD_PERIODIC("display_decay", fidelbase_state, display_decay_tick, attotime::from_msec(1))
MCFG_DEFAULT_LAYOUT(layout_fidel_eas)
config.set_default_layout(layout_fidel_eas);
/* sound hardware */
SPEAKER(config, "speaker").front_center();
@ -1968,7 +1968,7 @@ MACHINE_CONFIG_START(fidel6502_state::pc)
MCFG_DEVICE_REMOVE("ppi8255")
MCFG_DEVICE_REMOVE("nvram")
MCFG_DEFAULT_LAYOUT(layout_fidel_pc)
config.set_default_layout(layout_fidel_pc);
MACHINE_CONFIG_END
MACHINE_CONFIG_START(fidel6502_state::eag)
@ -1983,7 +1983,7 @@ MACHINE_CONFIG_START(fidel6502_state::eag)
MCFG_DEVICE_MODIFY("mainmap")
MCFG_DEVICE_PROGRAM_MAP(eag_map)
MCFG_DEFAULT_LAYOUT(layout_fidel_eag)
config.set_default_layout(layout_fidel_eag);
MACHINE_CONFIG_END
MACHINE_CONFIG_START(fidel6502_state::sc9d)
@ -1996,7 +1996,7 @@ MACHINE_CONFIG_START(fidel6502_state::sc9d)
MCFG_TIMER_DRIVER_ADD_PERIODIC("irq_off", fidel6502_state, irq_off, attotime::from_hz(610))
MCFG_TIMER_DRIVER_ADD_PERIODIC("display_decay", fidelbase_state, display_decay_tick, attotime::from_msec(1))
MCFG_DEFAULT_LAYOUT(layout_fidel_sc9)
config.set_default_layout(layout_fidel_sc9);
/* sound hardware */
SPEAKER(config, "speaker").front_center();
@ -2033,7 +2033,7 @@ MACHINE_CONFIG_START(fidel6502_state::playmatic)
MCFG_DEVICE_MODIFY("maincpu")
MCFG_DEVICE_CLOCK(3100000) // approximation
MCFG_DEFAULT_LAYOUT(layout_fidel_playmatic)
config.set_default_layout(layout_fidel_playmatic);
MACHINE_CONFIG_END
MACHINE_CONFIG_START(fidel6502_state::sc12)
@ -2054,7 +2054,7 @@ MACHINE_CONFIG_START(fidel6502_state::sc12)
MCFG_ADDRESS_MAP_BANK_ADDR_WIDTH(16)
MCFG_TIMER_DRIVER_ADD_PERIODIC("display_decay", fidelbase_state, display_decay_tick, attotime::from_msec(1))
MCFG_DEFAULT_LAYOUT(layout_fidel_sc12)
config.set_default_layout(layout_fidel_sc12);
/* sound hardware */
SPEAKER(config, "speaker").front_center();
@ -2101,7 +2101,7 @@ MACHINE_CONFIG_START(fidel6502_state::as12)
MCFG_TIMER_START_DELAY(attotime::from_hz(585) - attotime::from_nsec(15250)) // active for 15.25us
MCFG_TIMER_DRIVER_ADD_PERIODIC("irq_off", fidel6502_state, irq_off, attotime::from_hz(585))
MCFG_DEFAULT_LAYOUT(layout_fidel_as12)
config.set_default_layout(layout_fidel_as12);
MACHINE_CONFIG_END
MACHINE_CONFIG_START(fidel6502_state::fexcel)
@ -2114,7 +2114,7 @@ MACHINE_CONFIG_START(fidel6502_state::fexcel)
MCFG_TIMER_DRIVER_ADD_PERIODIC("irq_off", fidel6502_state, irq_off, attotime::from_hz(630))
MCFG_TIMER_DRIVER_ADD_PERIODIC("display_decay", fidelbase_state, display_decay_tick, attotime::from_msec(1))
MCFG_DEFAULT_LAYOUT(layout_fidel_ex)
config.set_default_layout(layout_fidel_ex);
/* sound hardware */
SPEAKER(config, "speaker").front_center();
@ -2169,7 +2169,7 @@ MACHINE_CONFIG_START(fidel6502_state::fdes2100)
MCFG_TIMER_START_DELAY(attotime::from_hz(585) - attotime::from_nsec(15250)) // active for 15.25us
MCFG_TIMER_DRIVER_ADD_PERIODIC("irq_off", fidel6502_state, irq_off, attotime::from_hz(585))
MCFG_DEFAULT_LAYOUT(layout_fidel_des)
config.set_default_layout(layout_fidel_des);
MACHINE_CONFIG_END
MACHINE_CONFIG_START(fidel6502_state::fdes2000)
@ -2193,7 +2193,7 @@ MACHINE_CONFIG_START(fidel6502_state::fexceld)
fexcelb(config);
/* basic machine hardware */
MCFG_DEFAULT_LAYOUT(layout_fidel_exd)
config.set_default_layout(layout_fidel_exd);
MACHINE_CONFIG_END
MACHINE_CONFIG_START(fidel6502_state::fdes2100d)
@ -2206,7 +2206,7 @@ MACHINE_CONFIG_START(fidel6502_state::fdes2100d)
MCFG_TIMER_DRIVER_ADD_PERIODIC("irq_off", fidel6502_state, irq_off, attotime::from_hz(630))
MCFG_TIMER_DRIVER_ADD_PERIODIC("display_decay", fidelbase_state, display_decay_tick, attotime::from_msec(1))
MCFG_DEFAULT_LAYOUT(layout_fidel_desdis)
config.set_default_layout(layout_fidel_desdis);
/* sound hardware */
SPEAKER(config, "speaker").front_center();
@ -2233,7 +2233,7 @@ MACHINE_CONFIG_START(fidel6502_state::fphantom)
MCFG_MACHINE_RESET_OVERRIDE(fidel6502_state, fphantom)
MCFG_TIMER_DRIVER_ADD_PERIODIC("display_decay", fidelbase_state, display_decay_tick, attotime::from_msec(1))
//MCFG_DEFAULT_LAYOUT(layout_fidel_phantom)
//config.set_default_layout(layout_fidel_phantom);
/* sound hardware */
SPEAKER(config, "speaker").front_center();
@ -2252,7 +2252,7 @@ MACHINE_CONFIG_START(fidel6502_state::chesster)
MCFG_TIMER_DRIVER_ADD_PERIODIC("irq_off", fidel6502_state, irq_off, attotime::from_hz(9615))
MCFG_TIMER_DRIVER_ADD_PERIODIC("display_decay", fidelbase_state, display_decay_tick, attotime::from_msec(1))
MCFG_DEFAULT_LAYOUT(layout_fidel_chesster)
config.set_default_layout(layout_fidel_chesster);
/* sound hardware */
SPEAKER(config, "speaker").front_center();

View File

@ -571,7 +571,7 @@ MACHINE_CONFIG_START(fidel68k_state::fex68k)
MCFG_TIMER_DRIVER_ADD_PERIODIC("irq_off", fidel68k_state, irq_off, attotime::from_hz(618))
MCFG_TIMER_DRIVER_ADD_PERIODIC("display_decay", fidelbase_state, display_decay_tick, attotime::from_msec(1))
MCFG_DEFAULT_LAYOUT(layout_fidel_ex_68k)
config.set_default_layout(layout_fidel_ex_68k);
/* sound hardware */
SPEAKER(config, "speaker").front_center();
@ -607,7 +607,7 @@ MACHINE_CONFIG_START(fidel68k_state::fdes2265)
MCFG_TIMER_DRIVER_ADD_PERIODIC("irq_off", fidel68k_state, irq_off, attotime::from_hz(597))
MCFG_TIMER_DRIVER_ADD_PERIODIC("display_decay", fidelbase_state, display_decay_tick, attotime::from_msec(1))
MCFG_DEFAULT_LAYOUT(layout_fidel_desdis_68kr)
config.set_default_layout(layout_fidel_desdis_68kr);
/* sound hardware */
SPEAKER(config, "speaker").front_center();
@ -623,7 +623,7 @@ MACHINE_CONFIG_START(fidel68k_state::fdes2325)
MCFG_DEVICE_REPLACE("maincpu", M68EC020, 20_MHz_XTAL) // MC68EC020RP25
MCFG_DEVICE_PROGRAM_MAP(fdes2325_map)
MCFG_DEFAULT_LAYOUT(layout_fidel_desdis_68kg)
config.set_default_layout(layout_fidel_desdis_68kg);
MACHINE_CONFIG_END
MACHINE_CONFIG_START(fidel68k_state::eag)
@ -638,7 +638,7 @@ MACHINE_CONFIG_START(fidel68k_state::eag)
MCFG_NVRAM_ADD_1FILL("nvram")
MCFG_TIMER_DRIVER_ADD_PERIODIC("display_decay", fidelbase_state, display_decay_tick, attotime::from_msec(1))
MCFG_DEFAULT_LAYOUT(layout_fidel_eag_68k)
config.set_default_layout(layout_fidel_eag_68k);
MCFG_RAM_ADD("ram")
MCFG_RAM_DEFAULT_SIZE("1M")

View File

@ -161,7 +161,7 @@ MACHINE_CONFIG_START(fidelmcs48_state::sc6)
MCFG_MCS48_PORT_T1_IN_CB(READLINE(*this, fidelmcs48_state, sc6_input7_r))
MCFG_TIMER_DRIVER_ADD_PERIODIC("display_decay", fidelbase_state, display_decay_tick, attotime::from_msec(1))
MCFG_DEFAULT_LAYOUT(layout_fidel_sc6)
config.set_default_layout(layout_fidel_sc6);
/* sound hardware */
SPEAKER(config, "speaker").front_center();

View File

@ -1667,7 +1667,7 @@ MACHINE_CONFIG_START(fidelz80_state::bcc)
MCFG_DEVICE_IO_MAP(bcc_io)
MCFG_TIMER_DRIVER_ADD_PERIODIC("display_decay", fidelbase_state, display_decay_tick, attotime::from_msec(1))
MCFG_DEFAULT_LAYOUT(layout_fidel_bcc)
config.set_default_layout(layout_fidel_bcc);
/* sound hardware */
SPEAKER(config, "speaker").front_center();
@ -1684,7 +1684,7 @@ MACHINE_CONFIG_START(fidelz80_state::scc)
MCFG_DEVICE_IO_MAP(scc_io)
MCFG_TIMER_DRIVER_ADD_PERIODIC("display_decay", fidelbase_state, display_decay_tick, attotime::from_msec(1))
MCFG_DEFAULT_LAYOUT(layout_fidel_sc8)
config.set_default_layout(layout_fidel_sc8);
/* sound hardware */
SPEAKER(config, "speaker").front_center();
@ -1710,7 +1710,7 @@ MACHINE_CONFIG_START(fidelz80_state::cc10)
MCFG_I8255_OUT_PORTC_CB(WRITE8(*this, fidelz80_state, vcc_ppi_portc_w))
MCFG_TIMER_DRIVER_ADD_PERIODIC("display_decay", fidelbase_state, display_decay_tick, attotime::from_msec(1))
MCFG_DEFAULT_LAYOUT(layout_fidel_cc)
config.set_default_layout(layout_fidel_cc);
/* sound hardware */
SPEAKER(config, "speaker").front_center();
@ -1736,7 +1736,7 @@ MACHINE_CONFIG_START(fidelz80_state::vcc)
MCFG_I8255_OUT_PORTC_CB(WRITE8(*this, fidelz80_state, vcc_ppi_portc_w))
MCFG_TIMER_DRIVER_ADD_PERIODIC("display_decay", fidelbase_state, display_decay_tick, attotime::from_msec(1))
MCFG_DEFAULT_LAYOUT(layout_fidel_vcc)
config.set_default_layout(layout_fidel_vcc);
MCFG_MACHINE_START_OVERRIDE(fidelz80_state,vcc)
@ -1766,7 +1766,7 @@ MACHINE_CONFIG_START(fidelz80_state::vsc)
MCFG_Z80PIO_OUT_PB_CB(WRITE8(*this, fidelz80_state, vsc_pio_portb_w))
MCFG_TIMER_DRIVER_ADD_PERIODIC("display_decay", fidelbase_state, display_decay_tick, attotime::from_msec(1))
MCFG_DEFAULT_LAYOUT(layout_fidel_vsc)
config.set_default_layout(layout_fidel_vsc);
/* sound hardware */
SPEAKER(config, "speaker").front_center();
@ -1794,7 +1794,7 @@ MACHINE_CONFIG_START(fidelz80_state::vbrc)
MCFG_I8243_ADD("i8243", CONSTANT(0), WRITE8(*this, fidelz80_state, vbrc_ioexp_port_w))
MCFG_TIMER_DRIVER_ADD_PERIODIC("display_decay", fidelbase_state, display_decay_tick, attotime::from_msec(1))
MCFG_DEFAULT_LAYOUT(layout_fidel_vbrc)
config.set_default_layout(layout_fidel_vbrc);
/* sound hardware */
SPEAKER(config, "speaker").front_center();
@ -1813,7 +1813,7 @@ MACHINE_CONFIG_START(fidelz80_state::dsc)
MCFG_TIMER_DRIVER_ADD_PERIODIC("irq_off", fidelz80_state, irq_off, attotime::from_hz(523))
MCFG_TIMER_DRIVER_ADD_PERIODIC("display_decay", fidelbase_state, display_decay_tick, attotime::from_msec(1))
MCFG_DEFAULT_LAYOUT(layout_fidel_dsc)
config.set_default_layout(layout_fidel_dsc);
/* sound hardware */
SPEAKER(config, "speaker").front_center();

View File

@ -511,7 +511,7 @@ MACHINE_CONFIG_START(fireball_state::fireball)
MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.0)
/* Video */
MCFG_DEFAULT_LAYOUT(layout_fireball)
config.set_default_layout(layout_fireball);
MACHINE_CONFIG_END

View File

@ -395,23 +395,24 @@ void flicker_state::driver_start()
}
MACHINE_CONFIG_START(flicker_state::flicker)
void flicker_state::flicker(machine_config &config)
{
// basic machine hardware
MCFG_DEVICE_ADD(m_maincpu, I4004, 5_MHz_XTAL / 8)
I4004(config, m_maincpu, 5_MHz_XTAL / 8);
m_maincpu->set_rom_map(&flicker_state::flicker_rom);
m_maincpu->set_ram_memory_map(&flicker_state::flicker_memory);
m_maincpu->set_rom_ports_map(&flicker_state::flicker_rom_ports);
m_maincpu->set_ram_status_map(&flicker_state::flicker_status);
m_maincpu->set_ram_ports_map(&flicker_state::flicker_ram_ports);
MCFG_I4004_CM_RAM1_CB(WRITELINE(*this, flicker_state, cm_ram1_w))
MCFG_I4004_CM_RAM2_CB(WRITELINE(*this, flicker_state, cm_ram2_w))
m_maincpu->cm_ram_cb<1>().set(FUNC(flicker_state::cm_ram1_w));
m_maincpu->cm_ram_cb<2>().set(FUNC(flicker_state::cm_ram2_w));
// video
MCFG_DEFAULT_LAYOUT(layout_flicker)
config.set_default_layout(layout_flicker);
// sound
genpin_audio(config);
MACHINE_CONFIG_END
}
ROM_START(flicker)

View File

@ -528,7 +528,7 @@ MACHINE_CONFIG_START(fromanc2_state::fromanc2)
MCFG_PALETTE_ADD("rpalette", 2048)
MCFG_PALETTE_FORMAT(GGGGGRRRRRBBBBBx)
MCFG_DEFAULT_LAYOUT(layout_dualhsxs)
config.set_default_layout(layout_dualhsxs);
MCFG_SCREEN_ADD("lscreen", RASTER)
MCFG_SCREEN_REFRESH_RATE(60)
@ -588,7 +588,7 @@ MACHINE_CONFIG_START(fromanc2_state::fromancr)
MCFG_PALETTE_ADD("rpalette", 2048)
MCFG_PALETTE_FORMAT(xGGGGGRRRRRBBBBB)
MCFG_DEFAULT_LAYOUT(layout_dualhsxs)
config.set_default_layout(layout_dualhsxs);
MCFG_SCREEN_ADD("lscreen", RASTER)
MCFG_SCREEN_REFRESH_RATE(60)
@ -649,7 +649,7 @@ MACHINE_CONFIG_START(fromanc2_state::fromanc4)
MCFG_PALETTE_ADD("rpalette", 2048)
MCFG_PALETTE_FORMAT(xRRRRRGGGGGBBBBB)
MCFG_DEFAULT_LAYOUT(layout_dualhsxs)
config.set_default_layout(layout_dualhsxs);
MCFG_SCREEN_ADD("lscreen", RASTER)
MCFG_SCREEN_REFRESH_RATE(60)

Some files were not shown because too many files have changed in this diff Show More