summaryrefslogtreecommitdiffstatshomepage
path: root/src/emu/machine/tms6100.h
diff options
context:
space:
mode:
author Miodrag Milanovic <mmicko@gmail.com>2012-09-03 13:56:17 +0000
committer Miodrag Milanovic <mmicko@gmail.com>2012-09-03 13:56:17 +0000
commitb711b1a007c3a4a75e78eb88f9a6afe4d4180728 (patch)
tree1498465a0134d7b039fce9271d2b388d218425d4 /src/emu/machine/tms6100.h
parentf552908ea962ecdd7e94ea609c84144815b64557 (diff)
conversion of legacy devices into modern wip (no whatsnew)
Diffstat (limited to 'src/emu/machine/tms6100.h')
-rw-r--r--src/emu/machine/tms6100.h34
1 files changed, 32 insertions, 2 deletions
diff --git a/src/emu/machine/tms6100.h b/src/emu/machine/tms6100.h
index bd6a1919d20..512446b8e62 100644
--- a/src/emu/machine/tms6100.h
+++ b/src/emu/machine/tms6100.h
@@ -14,7 +14,37 @@ WRITE8_DEVICE_HANDLER( tms6100_addr_w );
READ_LINE_DEVICE_HANDLER( tms6100_data_r );
-DECLARE_LEGACY_DEVICE(TMS6100, tms6100);
-DECLARE_LEGACY_DEVICE(M58819, m58819);
+class tms6100_device : public device_t
+{
+public:
+ tms6100_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock);
+ tms6100_device(const machine_config &mconfig, device_type type, const char *name, const char *tag, device_t *owner, UINT32 clock);
+ ~tms6100_device() { global_free(m_token); }
+
+ // access to legacy token
+ void *token() const { assert(m_token != NULL); return m_token; }
+protected:
+ // device-level overrides
+ virtual void device_config_complete();
+ virtual void device_start();
+ virtual void device_reset();
+private:
+ // internal state
+ void *m_token;
+};
+
+extern const device_type TMS6100;
+
+class m58819_device : public tms6100_device
+{
+public:
+ m58819_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock);
+protected:
+ // device-level overrides
+ virtual void device_start();
+};
+
+extern const device_type M58819;
+
#endif /* __TMS6100_H__ */