summaryrefslogtreecommitdiffstatshomepage
path: root/src/mame/machine/esqvfd.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/mame/machine/esqvfd.h')
-rw-r--r--src/mame/machine/esqvfd.h60
1 files changed, 29 insertions, 31 deletions
diff --git a/src/mame/machine/esqvfd.h b/src/mame/machine/esqvfd.h
index f804bc698b5..ac70201defc 100644
--- a/src/mame/machine/esqvfd.h
+++ b/src/mame/machine/esqvfd.h
@@ -1,31 +1,29 @@
// license:BSD-3-Clause
// copyright-holders:R. Belmont
-#ifndef ESQVFD_H
-#define ESQVFD_H
+#ifndef MAME_MACHINE_ESQVFD_H
+#define MAME_MACHINE_ESQVFD_H
-#define MCFG_ESQ1x22_ADD(_tag) \
- MCFG_DEVICE_ADD(_tag, ESQ1x22, 60)
+#define MCFG_ESQ1X22_ADD(_tag) \
+ MCFG_DEVICE_ADD(_tag, ESQ1X22, 60)
#define MCFG_ESQ1x22_REMOVE(_tag) \
MCFG_DEVICE_REMOVE(_tag)
-#define MCFG_ESQ2x40_ADD(_tag) \
- MCFG_DEVICE_ADD(_tag, ESQ2x40, 60)
+#define MCFG_ESQ2X40_ADD(_tag) \
+ MCFG_DEVICE_ADD(_tag, ESQ2X40, 60)
-#define MCFG_ESQ2x40_REMOVE(_tag) \
+#define MCFG_ESQ2X40_REMOVE(_tag) \
MCFG_DEVICE_REMOVE(_tag)
-#define MCFG_ESQ2x40_SQ1_ADD(_tag) \
- MCFG_DEVICE_ADD(_tag, ESQ2x40_SQ1, 60)
+#define MCFG_ESQ2X40_SQ1_ADD(_tag) \
+ MCFG_DEVICE_ADD(_tag, ESQ2X40_SQ1, 60)
-#define MCFG_ESQ2x40_SQ1_REMOVE(_tag) \
+#define MCFG_ESQ2X40_SQ1_REMOVE(_tag) \
MCFG_DEVICE_REMOVE(_tag)
-class esqvfd_t : public device_t {
+class esqvfd_device : public device_t {
public:
- esqvfd_t(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);
-
DECLARE_WRITE8_MEMBER( write ) { write_char(data); }
virtual void write_char(int data) = 0;
@@ -34,11 +32,13 @@ public:
uint32_t conv_segments(uint16_t segin);
protected:
- static const uint8_t AT_NORMAL = 0x00;
- static const uint8_t AT_BOLD = 0x01;
- static const uint8_t AT_UNDERLINE = 0x02;
- static const uint8_t AT_BLINK = 0x04;
- static const uint8_t AT_BLINKED = 0x80; // set when character should be blinked off
+ esqvfd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock);
+
+ static constexpr uint8_t AT_NORMAL = 0x00;
+ static constexpr uint8_t AT_BOLD = 0x01;
+ static constexpr uint8_t AT_UNDERLINE = 0x02;
+ static constexpr uint8_t AT_BLINK = 0x04;
+ static constexpr uint8_t AT_BLINKED = 0x80; // set when character should be blinked off
virtual void device_start() override;
virtual void device_reset() override;
@@ -54,9 +54,9 @@ protected:
uint8_t m_dirty[2][40];
};
-class esq1x22_t : public esqvfd_t {
+class esq1x22_device : public esqvfd_device {
public:
- esq1x22_t(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
+ esq1x22_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
virtual void write_char(int data) override;
@@ -66,21 +66,19 @@ protected:
private:
};
-class esq2x40_t : public esqvfd_t {
+class esq2x40_device : public esqvfd_device {
public:
- esq2x40_t(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
+ esq2x40_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
virtual void write_char(int data) override;
protected:
virtual machine_config_constructor device_mconfig_additions() const override;
-
-private:
};
-class esq2x40_sq1_t : public esqvfd_t {
+class esq2x40_sq1_device : public esqvfd_device {
public:
- esq2x40_sq1_t(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
+ esq2x40_sq1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
virtual void write_char(int data) override;
@@ -88,11 +86,11 @@ protected:
virtual machine_config_constructor device_mconfig_additions() const override;
private:
- bool m_Wait87Shift, m_Wait88Shift;
+ bool m_wait87shift, m_wait88shift;
};
-extern const device_type ESQ1x22;
-extern const device_type ESQ2x40;
-extern const device_type ESQ2x40_SQ1;
+DECLARE_DEVICE_TYPE(ESQ1X22, esq1x22_device)
+DECLARE_DEVICE_TYPE(ESQ2X40, esq2x40_device)
+DECLARE_DEVICE_TYPE(ESQ2X40_SQ1, esq2x40_sq1_device)
-#endif
+#endif // MAME_MACHINE_ESQVFD_H