summaryrefslogtreecommitdiffstatshomepage
path: root/src/devices/bus/apricot
diff options
context:
space:
mode:
author Vas Crabb <vas@vastheman.com>2017-05-07 23:18:47 +1000
committer Vas Crabb <vas@vastheman.com>2017-05-14 21:44:11 +1000
commit0f0d39ef81562c75e79176dd3bebb1e491ca39d5 (patch)
tree201cee7fdf55ee800f83859a92efd2cfe66cf2b3 /src/devices/bus/apricot
parente6c4be2b4d71c7a6c95be0bae111eb416ff0f9e7 (diff)
Move static data out of devices into the device types. This is a significant change, so please pay attention.
The core changes are: * Short name, full name and source file are no longer members of device_t, they are part of the device type * MACHINE_COFIG_START no longer needs a driver class * MACHINE_CONFIG_DERIVED_CLASS is no longer necessary * Specify the state class you want in the GAME/COMP/CONS line * The compiler will work out the base class where the driver init member is declared * There is one static device type object per driver rather than one per machine configuration Use DECLARE_DEVICE_TYPE or DECLARE_DEVICE_TYPE_NS to declare device type. * DECLARE_DEVICE_TYPE forward-declares teh device type and class, and declares extern object finders. * DECLARE_DEVICE_TYPE_NS is for devices classes in namespaces - it doesn't forward-declare the device type. Use DEFINE_DEVICE_TYPE or DEFINE_DEVICE_TYPE_NS to define device types. * These macros declare storage for the static data, and instantiate the device type and device finder templates. The rest of the changes are mostly just moving stuff out of headers that shouldn't be there, renaming stuff for consistency, and scoping stuff down where appropriate. Things I've actually messed with substantially: * More descriptive names for a lot of devices * Untangled the fantasy sound from the driver state, which necessitates breaking up sound/flip writes * Changed DECO BSMT2000 ready callback into a device delegate * Untangled Microprose 3D noise from driver state * Used object finders for CoCo multipak, KC85 D002, and Irem sound subdevices * Started to get TI-99 stuff out of the TI-990 directory and arrange bus devices properly * Started to break out common parts of Samsung ARM SoC devices * Turned some of FM, SID, SCSP DSP, EPIC12 and Voodoo cores into something resmbling C++ * Tried to make Z180 table allocation/setup a bit safer * Converted generic keyboard/terminal to not use WRITE8 - space/offset aren't relevant * Dynamically allocate generic terminal buffer so derived devices (e.g. teleprinter) can specify size * Imporved encapsulation of Z80DART channels * Refactored the SPC7110 bit table generator loop to make it more readable * Added wrappers for SNES PPU operations so members can be made protected * Factored out some boilerplate for YM chips with PSG * toaplan2 gfx * stic/intv resolution * Video System video * Out Run/Y-board sprite alignment * GIC video hookup * Amstrad CPC ROM box members * IQ151 ROM cart region * MSX cart IRQ callback resolution time * SMS passthrough control devices starting subslots I've smoke-tested several drivers, but I've probably missed something. Things I've missed will likely blow up spectacularly with failure to bind errors and the like. Let me know if there's more subtle breakage (could have happened in FM or Voodoo). And can everyone please, please try to keep stuff clean. In particular, please stop polluting the global namespace. Keep things out of headers that don't need to be there, and use things that can be scoped down rather than macros. It feels like an uphill battle trying to get this stuff under control while more of it's added.
Diffstat (limited to 'src/devices/bus/apricot')
-rw-r--r--src/devices/bus/apricot/expansion/cards.cpp1
-rw-r--r--src/devices/bus/apricot/expansion/cards.h10
-rw-r--r--src/devices/bus/apricot/expansion/expansion.cpp18
-rw-r--r--src/devices/bus/apricot/expansion/expansion.h47
-rw-r--r--src/devices/bus/apricot/expansion/ram.cpp12
-rw-r--r--src/devices/bus/apricot/expansion/ram.h14
-rw-r--r--src/devices/bus/apricot/keyboard/hle.cpp4
-rw-r--r--src/devices/bus/apricot/keyboard/hle.h14
-rw-r--r--src/devices/bus/apricot/keyboard/keyboard.cpp4
-rw-r--r--src/devices/bus/apricot/keyboard/keyboard.h19
10 files changed, 73 insertions, 70 deletions
diff --git a/src/devices/bus/apricot/expansion/cards.cpp b/src/devices/bus/apricot/expansion/cards.cpp
index 16804f896d8..eb5b71948c0 100644
--- a/src/devices/bus/apricot/expansion/cards.cpp
+++ b/src/devices/bus/apricot/expansion/cards.cpp
@@ -8,6 +8,7 @@
#include "emu.h"
#include "cards.h"
+#include "ram.h"
SLOT_INTERFACE_START( apricot_expansion_cards )
SLOT_INTERFACE("128k", APRICOT_128K_RAM)
diff --git a/src/devices/bus/apricot/expansion/cards.h b/src/devices/bus/apricot/expansion/cards.h
index 4d9b73b0b86..36767f81e44 100644
--- a/src/devices/bus/apricot/expansion/cards.h
+++ b/src/devices/bus/apricot/expansion/cards.h
@@ -6,13 +6,11 @@
***************************************************************************/
-#pragma once
-
-#ifndef __APRICOT_CARDS_H__
-#define __APRICOT_CARDS_H__
+#ifndef MAME_BUS_APRICOT_EXPANSION_CARDS_H
+#define MAME_BUS_APRICOT_EXPANSION_CARDS_H
-#include "ram.h"
+#pragma once
SLOT_INTERFACE_EXTERN( apricot_expansion_cards );
-#endif // __APRICOT_CARDS_H__
+#endif // MAME_BUS_APRICOT_EXPANSION_CARDS_H
diff --git a/src/devices/bus/apricot/expansion/expansion.cpp b/src/devices/bus/apricot/expansion/expansion.cpp
index 8f99831b482..b5717d320a5 100644
--- a/src/devices/bus/apricot/expansion/expansion.cpp
+++ b/src/devices/bus/apricot/expansion/expansion.cpp
@@ -14,21 +14,19 @@
// EXPANSION SLOT DEVICE
//**************************************************************************
-const device_type APRICOT_EXPANSION_SLOT = device_creator<apricot_expansion_slot_device>;
+DEFINE_DEVICE_TYPE(APRICOT_EXPANSION_SLOT, apricot_expansion_slot_device, "apricot_exp_slot", "Apricot Expansion Slot")
//-------------------------------------------------
// apricot_expansion_slot_device - constructor
//-------------------------------------------------
apricot_expansion_slot_device::apricot_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) :
- device_t(mconfig, APRICOT_EXPANSION_SLOT, "Apricot Expansion Slot", tag, owner, clock, "apricot_exp_slot", __FILE__),
- device_slot_interface(mconfig, *this)
+ apricot_expansion_slot_device(mconfig, APRICOT_EXPANSION_SLOT, tag, owner, clock)
{
}
-apricot_expansion_slot_device::apricot_expansion_slot_device(const machine_config &mconfig, device_type type, const char *name,
- const char *tag, device_t *owner, uint32_t clock, const char *shortname, const char *source) :
- device_t(mconfig, type, name, tag, owner, clock, shortname, source),
+apricot_expansion_slot_device::apricot_expansion_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) :
+ device_t(mconfig, type, tag, owner, clock),
device_slot_interface(mconfig, *this)
{
}
@@ -53,14 +51,14 @@ void apricot_expansion_slot_device::device_start()
// EXPANSION BUS DEVICE
//**************************************************************************
-const device_type APRICOT_EXPANSION_BUS = device_creator<apricot_expansion_bus_device>;
+DEFINE_DEVICE_TYPE(APRICOT_EXPANSION_BUS, apricot_expansion_bus_device, "apricot_exp_bus", "Apricot Expansion Bus")
//-------------------------------------------------
// apricot_expansion_bus_device - constructor
//-------------------------------------------------
apricot_expansion_bus_device::apricot_expansion_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) :
- device_t(mconfig, APRICOT_EXPANSION_BUS, "Apricot Expansion Bus", tag, owner, clock, "apricot_exp_bus", __FILE__),
+ device_t(mconfig, APRICOT_EXPANSION_BUS, tag, owner, clock),
m_program(nullptr),
m_io(nullptr),
m_program_iop(nullptr),
@@ -174,8 +172,8 @@ void apricot_expansion_bus_device::install_ram(offs_t addrstart, offs_t addrend,
device_apricot_expansion_card_interface::device_apricot_expansion_card_interface(const machine_config &mconfig, device_t &device) :
device_slot_card_interface(mconfig, device),
- m_next(nullptr),
- m_bus(nullptr)
+ m_bus(nullptr),
+ m_next(nullptr)
{
}
diff --git a/src/devices/bus/apricot/expansion/expansion.h b/src/devices/bus/apricot/expansion/expansion.h
index e87bcf355d4..8ea2a850bc3 100644
--- a/src/devices/bus/apricot/expansion/expansion.h
+++ b/src/devices/bus/apricot/expansion/expansion.h
@@ -41,10 +41,10 @@
***************************************************************************/
-#pragma once
+#ifndef MAME_BUS_APRICOT_EXPANSION_EXPANSION_H
+#define MAME_BUS_APRICOT_EXPANSION_EXPANSION_H
-#ifndef __APRICOT_EXPANSION_H__
-#define __APRICOT_EXPANSION_H__
+#pragma once
@@ -97,8 +97,9 @@ class apricot_expansion_slot_device : public device_t, public device_slot_interf
public:
// construction/destruction
apricot_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
- apricot_expansion_slot_device(const machine_config &mconfig, device_type type, const char *name,
- const char *tag, device_t *owner, uint32_t clock, const char *shortname, const char *source);
+
+protected:
+ apricot_expansion_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock);
// device-level overrides
virtual void device_start() override;
@@ -117,23 +118,23 @@ public:
apricot_expansion_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
virtual ~apricot_expansion_bus_device();
- template<class _Object> static devcb_base &set_dma1_handler(device_t &device, _Object object)
- { return downcast<apricot_expansion_bus_device &>(device).m_dma1_handler.set_callback(object); }
+ template <class Object> static devcb_base &set_dma1_handler(device_t &device, Object &&cb)
+ { return downcast<apricot_expansion_bus_device &>(device).m_dma1_handler.set_callback(std::forward<Object>(cb)); }
- template<class _Object> static devcb_base &set_dma2_handler(device_t &device, _Object object)
- { return downcast<apricot_expansion_bus_device &>(device).m_dma2_handler.set_callback(object); }
+ template <class Object> static devcb_base &set_dma2_handler(device_t &device, Object &&cb)
+ { return downcast<apricot_expansion_bus_device &>(device).m_dma2_handler.set_callback(std::forward<Object>(cb)); }
- template<class _Object> static devcb_base &set_ext1_handler(device_t &device, _Object object)
- { return downcast<apricot_expansion_bus_device &>(device).m_ext1_handler.set_callback(object); }
+ template <class Object> static devcb_base &set_ext1_handler(device_t &device, Object &&cb)
+ { return downcast<apricot_expansion_bus_device &>(device).m_ext1_handler.set_callback(std::forward<Object>(cb)); }
- template<class _Object> static devcb_base &set_ext2_handler(device_t &device, _Object object)
- { return downcast<apricot_expansion_bus_device &>(device).m_ext2_handler.set_callback(object); }
+ template <class Object> static devcb_base &set_ext2_handler(device_t &device, Object &&cb)
+ { return downcast<apricot_expansion_bus_device &>(device).m_ext2_handler.set_callback(std::forward<Object>(cb)); }
- template<class _Object> static devcb_base &set_int2_handler(device_t &device, _Object object)
- { return downcast<apricot_expansion_bus_device &>(device).m_int2_handler.set_callback(object); }
+ template <class Object> static devcb_base &set_int2_handler(device_t &device, Object &&cb)
+ { return downcast<apricot_expansion_bus_device &>(device).m_int2_handler.set_callback(std::forward<Object>(cb)); }
- template<class _Object> static devcb_base &set_int3_handler(device_t &device, _Object object)
- { return downcast<apricot_expansion_bus_device &>(device).m_int3_handler.set_callback(object); }
+ template <class Object> static devcb_base &set_int3_handler(device_t &device, Object &&cb)
+ { return downcast<apricot_expansion_bus_device &>(device).m_int3_handler.set_callback(std::forward<Object>(cb)); }
// inline configuration
static void set_cpu_tag(device_t &device, device_t *owner, const char *tag);
@@ -178,25 +179,29 @@ private:
};
// device type definition
-extern const device_type APRICOT_EXPANSION_BUS;
+DECLARE_DEVICE_TYPE(APRICOT_EXPANSION_BUS, apricot_expansion_bus_device)
// ======================> device_apricot_expansion_card_interface
class device_apricot_expansion_card_interface : public device_slot_card_interface
{
+ template <class ElementType> friend class simple_list;
+
public:
// construction/destruction
- device_apricot_expansion_card_interface(const machine_config &mconfig, device_t &device);
virtual ~device_apricot_expansion_card_interface();
void set_bus_device(apricot_expansion_bus_device *bus);
device_apricot_expansion_card_interface *next() const { return m_next; }
- device_apricot_expansion_card_interface *m_next;
protected:
+ device_apricot_expansion_card_interface(const machine_config &mconfig, device_t &device);
+
apricot_expansion_bus_device *m_bus;
+
+ device_apricot_expansion_card_interface *m_next;
};
@@ -204,4 +209,4 @@ protected:
#include "cards.h"
-#endif // __APRICOT_EXPANSION_H__
+#endif // MAME_BUS_APRICOT_EXPANSION_EXPANSION_H
diff --git a/src/devices/bus/apricot/expansion/ram.cpp b/src/devices/bus/apricot/expansion/ram.cpp
index 46a5bee1543..ba9b146522d 100644
--- a/src/devices/bus/apricot/expansion/ram.cpp
+++ b/src/devices/bus/apricot/expansion/ram.cpp
@@ -14,9 +14,9 @@
// DEVICE DEFINITIONS
//**************************************************************************
-const device_type APRICOT_256K_RAM = device_creator<apricot_256k_ram_device>;
-const device_type APRICOT_128K_RAM = device_creator<apricot_128k_ram_device>;
-const device_type APRICOT_512K_RAM = device_creator<apricot_512k_ram_device>;
+DEFINE_DEVICE_TYPE(APRICOT_256K_RAM, apricot_256k_ram_device, "apricot_256k_ram", "Apricot 256K RAM Expansion Board")
+DEFINE_DEVICE_TYPE(APRICOT_128K_RAM, apricot_128k_ram_device, "apricot_128k_ram", "Apricot 128K/512K RAM Expansion Board (128K)")
+DEFINE_DEVICE_TYPE(APRICOT_512K_RAM, apricot_512k_ram_device, "apricot_512k_ram", "Apricot 128K/512K RAM Expansion Board (512K)")
//**************************************************************************
@@ -44,7 +44,7 @@ ioport_constructor apricot_256k_ram_device::device_input_ports() const
//-------------------------------------------------
apricot_256k_ram_device::apricot_256k_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) :
- device_t(mconfig, APRICOT_256K_RAM, "Apricot 256K RAM Expansion Board", tag, owner, clock, "apricot_256k_ram", __FILE__),
+ device_t(mconfig, APRICOT_256K_RAM, tag, owner, clock),
device_apricot_expansion_card_interface(mconfig, *this),
m_sw(*this, "sw")
{
@@ -98,7 +98,7 @@ ioport_constructor apricot_128k_ram_device::device_input_ports() const
//-------------------------------------------------
apricot_128k_ram_device::apricot_128k_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) :
- device_t(mconfig, APRICOT_128K_RAM, "Apricot 128/512K RAM Expansion Board (128K)", tag, owner, clock, "apricot_128k_ram", __FILE__),
+ device_t(mconfig, APRICOT_128K_RAM, tag, owner, clock),
device_apricot_expansion_card_interface(mconfig, *this),
m_strap(*this, "strap")
{
@@ -152,7 +152,7 @@ ioport_constructor apricot_512k_ram_device::device_input_ports() const
//-------------------------------------------------
apricot_512k_ram_device::apricot_512k_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) :
- device_t(mconfig, APRICOT_512K_RAM, "Apricot 128/512K RAM Expansion Board (512K)", tag, owner, clock, "apricot_512k_ram", __FILE__),
+ device_t(mconfig, APRICOT_512K_RAM, tag, owner, clock),
device_apricot_expansion_card_interface(mconfig, *this),
m_strap(*this, "strap")
{
diff --git a/src/devices/bus/apricot/expansion/ram.h b/src/devices/bus/apricot/expansion/ram.h
index e9e837b660c..d6692b49ba7 100644
--- a/src/devices/bus/apricot/expansion/ram.h
+++ b/src/devices/bus/apricot/expansion/ram.h
@@ -6,10 +6,10 @@
***************************************************************************/
-#pragma once
+#ifndef MAME_BUS_APRICOT_RAM_H
+#define MAME_BUS_APRICOT_RAM_H
-#ifndef __APRICOT_RAM__
-#define __APRICOT_RAM__
+#pragma once
#include "expansion.h"
@@ -80,9 +80,9 @@ private:
// device type definition
-extern const device_type APRICOT_256K_RAM;
-extern const device_type APRICOT_128K_RAM;
-extern const device_type APRICOT_512K_RAM;
+DECLARE_DEVICE_TYPE(APRICOT_256K_RAM, apricot_256k_ram_device)
+DECLARE_DEVICE_TYPE(APRICOT_128K_RAM, apricot_128k_ram_device)
+DECLARE_DEVICE_TYPE(APRICOT_512K_RAM, apricot_512k_ram_device)
-#endif // __APRICOT_RAM__
+#endif // MAME_BUS_APRICOT_RAM_H
diff --git a/src/devices/bus/apricot/keyboard/hle.cpp b/src/devices/bus/apricot/keyboard/hle.cpp
index 7fef733b134..be7454c0da3 100644
--- a/src/devices/bus/apricot/keyboard/hle.cpp
+++ b/src/devices/bus/apricot/keyboard/hle.cpp
@@ -58,7 +58,7 @@
// DEVICE DEFINITIONS
//**************************************************************************
-const device_type APRICOT_KEYBOARD_HLE = device_creator<apricot_keyboard_hle_device>;
+DEFINE_DEVICE_TYPE(APRICOT_KEYBOARD_HLE, apricot_keyboard_hle_device, "apricotkb_hle", "Apricot Keyboard (HLE)")
//-------------------------------------------------
@@ -214,7 +214,7 @@ machine_config_constructor apricot_keyboard_hle_device::device_mconfig_additions
//-------------------------------------------------
apricot_keyboard_hle_device::apricot_keyboard_hle_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) :
- device_t(mconfig, APRICOT_KEYBOARD_HLE, "Apricot Keyboard (HLE)", tag, owner, clock, "apricotkb_hle", __FILE__),
+ device_t(mconfig, APRICOT_KEYBOARD_HLE, tag, owner, clock),
device_apricot_keyboard_interface(mconfig, *this),
device_buffered_serial_interface(mconfig, *this),
device_matrix_keyboard_interface(mconfig, *this, "row_0", "row_1", "row_2", "row_3", "row_4", "row_5", "row_6", "row_7", "row_8", "row_9", "row_a", "row_b", "row_c"),
diff --git a/src/devices/bus/apricot/keyboard/hle.h b/src/devices/bus/apricot/keyboard/hle.h
index 9096c434f65..176a3bfcc22 100644
--- a/src/devices/bus/apricot/keyboard/hle.h
+++ b/src/devices/bus/apricot/keyboard/hle.h
@@ -6,10 +6,10 @@
***************************************************************************/
-#pragma once
+#ifndef MAME_BUS_APRICOT_KEYBOARD_HLE_H
+#define MAME_BUS_APRICOT_KEYBOARD_HLE_H
-#ifndef __APRICOT_KEYBOARD_HLE_H__
-#define __APRICOT_KEYBOARD_HLE_H__
+#pragma once
#include "keyboard.h"
#include "machine/keyboard.h"
@@ -52,8 +52,6 @@ protected:
virtual void device_timer(emu_timer &timer, device_timer_id id, int param, void *ptr) override;
private:
- required_device<msm5832_device> m_rtc;
-
enum {
CMD_REQ_TIME_AND_DATE = 0xe1,
CMD_SET_TIME_AND_DATE = 0xe4,
@@ -64,12 +62,14 @@ private:
ACK_DIAGNOSTICS = 0xfb
};
+ required_device<msm5832_device> m_rtc;
+
int m_rtc_index;
};
// device type definition
-extern const device_type APRICOT_KEYBOARD_HLE;
+DECLARE_DEVICE_TYPE(APRICOT_KEYBOARD_HLE, apricot_keyboard_hle_device)
-#endif // __APRICOT_KEYBOARD_HLE_H__
+#endif // MAME_BUS_APRICOT_KEYBOARD_HLE_H
diff --git a/src/devices/bus/apricot/keyboard/keyboard.cpp b/src/devices/bus/apricot/keyboard/keyboard.cpp
index e406c0c4cd5..87c491b6693 100644
--- a/src/devices/bus/apricot/keyboard/keyboard.cpp
+++ b/src/devices/bus/apricot/keyboard/keyboard.cpp
@@ -15,7 +15,7 @@
// DEVICE DEFINITIONS
//**************************************************************************
-const device_type APRICOT_KEYBOARD_INTERFACE = device_creator<apricot_keyboard_bus_device>;
+DEFINE_DEVICE_TYPE(APRICOT_KEYBOARD_INTERFACE, apricot_keyboard_bus_device, "apricot_kbd", "Apricot Keyboard Interface")
//**************************************************************************
@@ -27,7 +27,7 @@ const device_type APRICOT_KEYBOARD_INTERFACE = device_creator<apricot_keyboard_b
//-------------------------------------------------
apricot_keyboard_bus_device::apricot_keyboard_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) :
- device_t(mconfig, APRICOT_KEYBOARD_INTERFACE, "Apricot Keyboard Interface", tag, owner, clock, "apricot_kbd", __FILE__),
+ device_t(mconfig, APRICOT_KEYBOARD_INTERFACE, tag, owner, clock),
device_slot_interface(mconfig, *this),
m_kbd(nullptr),
m_in_handler(*this)
diff --git a/src/devices/bus/apricot/keyboard/keyboard.h b/src/devices/bus/apricot/keyboard/keyboard.h
index 8fa27f672ec..e7cc28ef584 100644
--- a/src/devices/bus/apricot/keyboard/keyboard.h
+++ b/src/devices/bus/apricot/keyboard/keyboard.h
@@ -27,10 +27,10 @@
***************************************************************************/
-#pragma once
+#ifndef MAME_BUS_APRICOT_KEYBOARD_KEYBOARD_H
+#define MAME_BUS_APRICOT_KEYBOARD_KEYBOARD_H
-#ifndef __APRICOT_KEYBOARD_H__
-#define __APRICOT_KEYBOARD_H__
+#pragma once
@@ -62,8 +62,8 @@ public:
virtual ~apricot_keyboard_bus_device();
// callbacks
- template<class _Object> static devcb_base &set_in_handler(device_t &device, _Object object)
- { return downcast<apricot_keyboard_bus_device &>(device).m_in_handler.set_callback(object); }
+ template <class Object> static devcb_base &set_in_handler(device_t &device, Object &&cb)
+ { return downcast<apricot_keyboard_bus_device &>(device).m_in_handler.set_callback(std::forward<Object>(cb)); }
// called from keyboard
DECLARE_WRITE_LINE_MEMBER( in_w ) { m_in_handler(state); }
@@ -88,21 +88,22 @@ class device_apricot_keyboard_interface : public device_slot_card_interface
{
public:
// construction/destruction
- device_apricot_keyboard_interface(const machine_config &mconfig, device_t &device);
virtual ~device_apricot_keyboard_interface();
- virtual void out_w(int state) {};
+ virtual void out_w(int state) = 0;
protected:
+ device_apricot_keyboard_interface(const machine_config &mconfig, device_t &device);
+
apricot_keyboard_bus_device *m_host;
};
// device type definition
-extern const device_type APRICOT_KEYBOARD_INTERFACE;
+DECLARE_DEVICE_TYPE(APRICOT_KEYBOARD_INTERFACE, apricot_keyboard_bus_device)
// supported devices
SLOT_INTERFACE_EXTERN( apricot_keyboard_devices );
-#endif // __APRICOT_KEYBOARD_H__
+#endif // MAME_BUS_APRICOT_KEYBOARD_KEYBOARD_H